{"_id":"@dhtmdgkr/llm-meter","_rev":"10-f3e1651abbe0b2c7a52302333da58494","name":"@dhtmdgkr/llm-meter","dist-tags":{"latest":"1.0.5"},"versions":{"1.0.3":{"name":"@dhtmdgkr/llm-meter","version":"1.0.3","_id":"@dhtmdgkr/llm-meter@1.0.3","maintainers":[{"name":"dhtmdgkr123","email":"osh12201@gmail.com"}],"bin":{"llm-meter":"dist/index.js"},"dist":{"shasum":"fb6f8ffe8aad86e0aadde897578292eadec944ea","tarball":"https://registry.npmjs.org/@dhtmdgkr/llm-meter/-/llm-meter-1.0.3.tgz","fileCount":3,"integrity":"sha512-IR2E+0qpoc6JD/qbTcbVPYMuMSO0O3lAQHVTy3BEOnefTkLqI81w/OScEXN50kAhAKGDAQxD/Fh1YFVNdovoyQ==","signatures":[{"sig":"MEYCIQDsYb9kQYmlFLd6AjHhkl1TkjTJKUoXbwTok5EFzKU07gIhALxDWJ/UXOwIzzDMvTaqzSUUMigdfRmxwOHhAaenP64y","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":189373},"type":"module","gitHead":"d1dbc905e70ed7393a28619ce564c8a70586a21b","scripts":{"test":"bun test","build":"bun build src/index.ts --outdir dist --target node --format esm && printf '#!/usr/bin/env node\n' | cat - dist/index.js > dist/tmp && mv dist/tmp dist/index.js && chmod +x dist/index.js","start":"bun run src/index.ts","prepublishOnly":"bun run build"},"_npmUser":{"name":"dhtmdgkr123","email":"osh12201@gmail.com"},"_npmVersion":"10.8.2","description":"A CLI tool that provides unified analysis of local token usage across three AI coding tools: Claude Code, Codex CLI, and Gemini CLI.","directories":{},"_nodeVersion":"20.20.0","dependencies":{"chalk":"^5.6.2","commander":"^14.0.3","cli-table3":"^0.6.5"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"latest"},"peerDependencies":{"typescript":"^5"},"_npmOperationalInternal":{"tmp":"tmp/llm-meter_1.0.3_1772455456802_0.021588548928993312","host":"s3://npm-registry-packages-npm-production"}},"1.0.4":{"name":"@dhtmdgkr/llm-meter","version":"1.0.4","_id":"@dhtmdgkr/llm-meter@1.0.4","maintainers":[{"name":"dhtmdgkr123","email":"osh12201@gmail.com"}],"bin":{"llm-meter":"dist/index.js"},"dist":{"shasum":"37a0ce6eaca5da44d0d45d507655207adaac9436","tarball":"https://registry.npmjs.org/@dhtmdgkr/llm-meter/-/llm-meter-1.0.4.tgz","fileCount":3,"integrity":"sha512-JKhPekxbmDbPRxv83xzG5t3AhADkW86hRpufeVLOlgH7amJk4Omim9T8Dj2kIENzgwVIo2oSdIfkmBkejuWIkg==","signatures":[{"sig":"MEQCIDb27402v3mfx/3vjm3sjgLoi05XuNmEnMSsVZRJQ2j3AiBwL44va7W5aMCFxBp66Nca5MFJMl4WZZsG5XaHWe+1zA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":189199},"type":"module","gitHead":"6e3fc43aa1e07898c667f5fa0f235cce3d0a8dd4","scripts":{"test":"bun test","build":"bun build src/index.ts --outdir dist --target node --format esm && printf '#!/usr/bin/env node\n' | cat - dist/index.js > dist/tmp && mv dist/tmp dist/index.js && chmod +x dist/index.js","start":"bun run src/index.ts","prepublishOnly":"bun run build"},"_npmUser":{"name":"dhtmdgkr123","email":"osh12201@gmail.com"},"_npmVersion":"10.8.2","description":"A CLI tool that provides unified analysis of local token usage across three AI coding tools: Claude Code, Codex CLI, and Gemini CLI.","directories":{},"_nodeVersion":"20.20.0","dependencies":{"chalk":"^5.6.2","commander":"^14.0.3","cli-table3":"^0.6.5"},"_hasShrinkwrap":false,"devDependencies":{"@types/bun":"latest"},"peerDependencies":{"typescript":"^5"},"_npmOperationalInternal":{"tmp":"tmp/llm-meter_1.0.4_1772497706993_0.2909676273404558","host":"s3://npm-registry-packages-npm-production"}},"1.0.5":{"name":"@dhtmdgkr/llm-meter","version":"1.0.5","type":"module","bin":{"llm-meter":"dist/index.js"},"scripts":{"start":"bun run src/index.ts","build":"bun build src/index.ts --outdir dist --target node --format esm && printf '#!/usr/bin/env node\n' | cat - dist/index.js > dist/tmp && mv dist/tmp dist/index.js && chmod +x dist/index.js","prepublishOnly":"bun run build","test":"TZ=Asia/Seoul bun test"},"devDependencies":{"@types/bun":"latest"},"peerDependencies":{"typescript":"^5"},"dependencies":{"chalk":"^5.6.2","cli-table3":"^0.6.5","commander":"^14.0.3"},"_id":"@dhtmdgkr/llm-meter@1.0.5","gitHead":"6b3ece1732faaa92a273d4ea1da53bdf61dee8d4","description":"A CLI tool that provides unified analysis of local token usage across three AI coding tools: Claude Code, Codex CLI, and Gemini CLI.","_nodeVersion":"20.20.0","_npmVersion":"10.8.2","dist":{"integrity":"sha512-ZjbVq9+VOTwlctcyvmdV7qFzP1UtifuRXuyabXqHK48rIWgizkXl+tuhH3UcECosxEAj88caa+qguKO60raw9g==","shasum":"40ea047d4fd504a2c8bf5fbd5362fff667856bfd","tarball":"https://registry.npmjs.org/@dhtmdgkr/llm-meter/-/llm-meter-1.0.5.tgz","fileCount":3,"unpackedSize":185184,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCNPe8zTCRUpTv+o7IsEA0GtkSTC2/34XNQ2AF0XtGV5QIhANAU6tCG6aeNpSC39AGkly9FT9G9Qb2XGQRvT3966wvz"}]},"_npmUser":{"name":"dhtmdgkr123","email":"osh12201@gmail.com"},"directories":{},"maintainers":[{"name":"dhtmdgkr123","email":"osh12201@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/llm-meter_1.0.5_1773026856847_0.9566830877965133"},"_hasShrinkwrap":false}},"time":{"created":"2026-03-02T12:44:16.699Z","modified":"2026-03-09T03:27:37.100Z","1.0.0":"2026-03-02T11:37:03.112Z","1.0.1":"2026-03-02T11:48:53.609Z","1.0.2":"2026-03-02T11:52:44.451Z","1.0.3":"2026-03-02T12:44:16.953Z","1.0.4":"2026-03-03T00:28:27.154Z","1.0.5":"2026-03-09T03:27:36.985Z"},"description":"A CLI tool that provides unified analysis of local token usage across three AI coding tools: Claude Code, Codex CLI, and Gemini CLI.","maintainers":[{"name":"dhtmdgkr123","email":"osh12201@gmail.com"}],"readme":"# llm-meter\n\nA CLI tool that provides unified analysis of local token usage across three AI coding tools: Claude Code, Codex CLI, and Gemini CLI.\n\nAll analysis is performed locally — no external API calls.\n\n## Usage\n\n```bash\n# Daily usage (default)\npnpm dlx @dhtmdgkr/llm-meter\nnpx @dhtmdgkr/llm-meter\nbunx @dhtmdgkr/llm-meter\n\n# Monthly usage\npnpm dlx @dhtmdgkr/llm-meter monthly\n\n# Specify date range\npnpm dlx @dhtmdgkr/llm-meter daily --from 2026-03-01 --to 2026-03-02\n\n# Filter by provider\npnpm dlx @dhtmdgkr/llm-meter daily --from 2026-03-01 --provider claude\n\n# Per-model breakdown\npnpm dlx @dhtmdgkr/llm-meter daily --from 2026-03-01 --verbose\n\n# JSON output\npnpm dlx @dhtmdgkr/llm-meter daily --from 2026-03-01 --json\n```\n\n### Options\n\n| Option | Description |\n|--------|-------------|\n| `--from <date>` | Start date (YYYY-MM-DD), default: 30 days ago |\n| `--to <date>` | End date (YYYY-MM-DD), default: today |\n| `--provider <name>` | Filter by provider: `claude`, `codex`, `gemini` |\n| `--verbose` | Show per-model breakdown |\n| `--json` | Output as JSON |\n\n## Output Example\n\n![sample](sample.png)\n\n## Data Sources\n\n| Provider | Local Path | Format |\n|----------|-----------|--------|\n| **Claude Code** | `~/.claude/projects/**/*.jsonl` | JSONL, `message.usage` from `type: \"assistant\"` records |\n| **Codex CLI** | `~/.codex/sessions/YYYY/MM/DD/rollout-*.jsonl` | JSONL, last `token_count` cumulative value per session |\n| **Gemini CLI** | `~/.gemini/tmp/**/session-*.json` | JSON, `tokens` from `type: \"gemini\"` entries in `messages[]` |\n\n## Pricing Model\n\nUses [LiteLLM](https://github.com/BerriAI/litellm)-based pricing data (same as ccusage).\n\n| Model | Input $/MTok | Output $/MTok | Cache Create $/MTok | Cache Read $/MTok |\n|-------|:-----------:|:------------:|:------------------:|:----------------:|\n| Claude Opus 4 | $5.00 | $25.00 | $6.25 | $0.50 |\n| Claude Sonnet 4 | $3.00 | $15.00 | $3.75 | $0.30 |\n| Claude Haiku 4.5 | $1.00 | $5.00 | $1.25 | $0.10 |\n| GPT-5.3 Codex | $1.75 | $14.00 | - | $0.175 |\n| GPT-5.4 | $2.50 | $15.00 | - | $0.25 |\n| Codex Mini | $1.50 | $6.00 | - | $0.375 |\n| o3 | $2.00 | $8.00 | - | $0.50 |\n| o4-mini | $1.10 | $4.40 | - | $0.275 |\n| Gemini 2.5 Pro | $1.25 | $10.00 | - | $0.125 |\n| Gemini 2.5 Flash | $0.30 | $2.50 | - | $0.03 |\n\nTiered pricing applies above 200K tokens (Claude Opus/Sonnet, Gemini 2.5 Pro) and 272K tokens (GPT-5.4).\n\n## Testing\n\n```bash\nbun test\n```\n\n## Compatibility with ccusage\n\nThe Claude Code portion produces identical results to [ccusage](https://github.com/ryoppippi/ccusage):\n\n- LiteLLM pricing model\n- Local timezone-based date grouping\n- Includes subagent files\n\n## Project Structure\n\n```\nsrc/\n  index.ts                  # CLI entry point\n  cli/\n    commands/daily.ts       # daily subcommand\n    commands/monthly.ts     # monthly subcommand\n    commands/shared.ts      # shared data collection logic\n    options.ts              # CLI option definitions\n    output/table.ts         # terminal table formatter\n    output/json.ts          # JSON output formatter\n  core/\n    types.ts                # shared types\n    aggregator.ts           # daily/monthly aggregation\n    date-utils.ts           # date utilities\n  providers/\n    base.ts                 # abstract base class\n    claude.ts               # Claude Code parser\n    codex.ts                # Codex CLI parser\n    gemini.ts               # Gemini CLI parser\n    registry.ts             # provider registry\n  pricing/\n    models.ts               # per-model pricing database\n    calculator.ts           # cost calculation (tiered pricing)\ntests/\n  fixtures/                 # synthetic test data\n  providers/                # provider unit tests\n  core/                     # aggregation unit tests\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md"}