TokenLens

TokenLens is a local token usage dashboard for macOS. It tracks the usage of AI models like Claude, Codex, and Gemini.

Features

  • Local Dashboard: Monitor your token usage locally on macOS.
  • Model Support: Tracks usage across popular models including Claude, Codex, and Gemini.
  • Modern Stack: Built with Electron, React, TypeScript, and Vite.

Getting Started

Prerequisites

  • Node.js
  • npm (or yarn/pnpm)

Installation

  1. Clone the repository:
    git clone <repository-url>
    
  2. Install dependencies:
    npm install
    

Development

To start the Vite development server:

npm run dev

To run the Electron app in development mode:

npm run electron:dev

Build

To build the project for production:

npm run build

To package the application (creates a macOS DMG):

npm run dist

Running Tests

To run the test suite:

npm run test

Technologies Used

Description
一个大模型消耗tokens的小组件
Readme 1.7 MiB
Languages
Swift 69.4%
JavaScript 13.4%
HTML 10.9%
CSS 6.3%