Token Optimizer MCP

by ooples• 564•• Scanned•Claim this listing•Request removal
Coding Agentsaicachingclaudecompressiongemini cli extension

Measure token savings per AI coding agent, optimize context, and share a live local knowledge graph across 16 CLI clients.

Token Optimizer MCP is an open-source mcp server by ooples, written mainly in JavaScript, with 564 GitHub stars and the MIT license. Its code was last updated Nov 1, 2026.

Scan summary: scanned Nov 5, 2026 at commit 31ee445. Seen able to read environment and secrets, connect to databases. Scan policy

How to install Token Optimizer MCP

Built from the start command in the project's README: npx token-optimizer-doctor. Check the README for required keys or settings.

Claude Code · Terminal
claude mcp add token-optimizer-mcp -- npx token-optimizer-doctor
Claude Desktop · claude_desktop_config.json
{
  "mcpServers": {
    "token-optimizer-mcp": {
      "command": "npx",
      "args": [
        "token-optimizer-doctor"
      ]
    }
  }
}
Cursor · .cursor/mcp.json
{
  "mcpServers": {
    "token-optimizer-mcp": {
      "command": "npx",
      "args": [
        "token-optimizer-doctor"
      ]
    }
  }
}
VS Code · Terminal
code --add-mcp '{"name":"token-optimizer-mcp","command":"npx","args":["token-optimizer-doctor"]}'

What Token Optimizer MCP can touch

  • Run shell commandsNot seen in this scan
  • Run dynamic codeNot seen in this scan
  • Read or write filesNot seen in this scan
  • Read environment and secretsFound in the code by our scan
  • Control a web browserNot seen in this scan
  • Connect to databasesListed as a tool: wiki_query
  • Read or send messagesNot seen in this scan
  • Touch money or tradingNot seen in this scan
  • Connect to the internetNo connections seen while running

"Not seen" means our checks did not find it, and the tool may still do it. Covers commit 31ee445, Nov 5, 2026. See the scan policy.

Before you install Token Optimizer MCP

AgenticMart scanned Token Optimizer MCP on Nov 5, 2026 with automated checks for hidden code, known-malicious packages, leaked secrets and vulnerable dependencies. The result covers one commit under our scan policy, so review what access you give it and check any advisories shown here.

What it can access

  • An MCP server is a program your AI app starts and talks to. A local one runs with your user's permissions: it can see the files, environment variables and network your account can.

Before you install

  1. Pin the version you reviewed instead of always installing the latest release.
  2. Read the tool list or scripts before the first run, and keep approval prompts on for actions that write, send or delete.
  • Maintained by ooples on GitHub, 564 stars and 73 forks. Popularity is not proof of safety.
  • Last code change: Nov 1, 2026.
  • Open-source license: MIT.

Tools Token Optimizer MCP exposes (19)

Listed by the server itself during our scan of commit 31ee445.

  • token_audit

    The one thing to run. A single ranked queue of what is costing the most in this project -- waste detectors, prompt-cache invalidation attributed to a file and line, and model routing -- each priced per session and per month, each naming how to act on it. Reports what already-applied fixes actually s

  • install_doctor

    Check that this installation actually works. Runs the real hook binaries with synthetic payloads and asserts a large read is refused and a small one is not, that session-start emits the policy, and that the graph directory is writable and private -- rather than checking that config files exist, whic

  • fleet_audit

    Look across every project on this machine at once: which projects hold the cost (ranked with dollar figures), which fixes proven in one project apply to others containing the SAME FILE CONTENTS, and how enforcing clients compare with directive ones as a natural experiment (reported with its confound

  • wiki_write

    Record a durable finding in this project's knowledge graph so a later session retrieves it instead of re-deriving it. Use it the moment you conclude something that cost real work and is not obvious from the code: a dead end and why, a decision and its rejected alternatives, a command that finally wo

  • wiki_read

    Retrieve what this project's knowledge graph already records about the files you are about to work on, so you do not re-derive it. Call it BEFORE reading a file you have not seen: it returns prior conclusions anchored to that file — dead ends and why, decisions and what was rejected, commands that w

  • wiki_query

    Read the project's knowledge graph: fetch a finding by key, search findings by terms, inspect a node and its neighbours, or get the graph's audit, token balance and overall shape. Use it when the session index mentions a finding you want in full, or to find out what the graph holds at all. NOT for a

  • expand

    Retrieve the full output behind a preview reference, served from the local store rather than by re-running anything. Pass `section` to say which named part of the preview you needed -- that is what teaches the next preview to keep it. Pass `claim` and `anchor` to record what you learned, so the same

  • waste_audit

    Report behavioural token waste in this project, ranked by cost per session and compared against the previous week. Detectors are a shipped floor plus patterns derived from this project's own history, each carrying what it has actually saved. Use action="apply" to put the fixes we own into force (rev

  • cache_audit

    Report Anthropic prompt-cache economics for this project: measured cache-read input, cache-write input, hit rate, and warm prefix size read from a Claude Code transcript, plus likely invalidation sources. Cost equivalents are labeled Anthropic-specific, excluded from universal savings, and are not i

  • model_routing

    Which model tier this project's work actually goes better on, measured from episode outcomes in the client transcript rather than guessed from task size. Reports expected cost per tier including retries, and prices BOTH mistakes: what an overpowered model wastes and what an underpowered one costs in

  • optimize_text

    Compress and cache text to reduce token usage. Returns compressed version and saves to cache for future use.

  • get_cached

    Retrieve previously cached and optimized text. Returns the original text if found in cache.

  • optimize_session

    Analyzes operations in the current session from the session JSONL log, identifies large text blocks from file-based tools (Read, Write, Edit), compresses them, and stores them in the cache to reduce future token usage. Returns a summary of the optimization.

  • smart_read

    Read files with intelligent caching, diff-based updates, and syntax-aware optimization. Measured token reduction vs reading the file: -2% to 0% first read, 99-99.9% repeated on an unchanged file (bench/tools, 3 fixtures) -- a first read returns the file plus a one-field header, so it still costs a l

  • smart_write

    Write files with an unmeasured design target of 85% token reduction through verification, atomic operations, and change tracking

  • smart_edit

    Edit files with an unmeasured design target of 90% token reduction through line-based operations and diff-only output

  • smart_glob

    Search files with glob patterns and an unmeasured design target of 75% token reduction through path-only results and smart filtering

  • smart_grep

    Search file contents with an unmeasured design target of 80% token reduction through match-only output and smart filtering

  • get_optimization_report

    Get a provenance-gated token report. Verified savings require a materialized MCP payload before and after optimization; historical and tool-reported estimates are excluded. Direct API-price equivalents use each exact captured model and route; ambiguous operations remain unpriced.

Token Optimizer MCP is an open-source mcp server by ooples, written mainly in JavaScript. Measure token savings per AI coding agent, optimize context, and share a live local knowledge graph across 16 CLI clients.

At a glance

Stars
564
Forks
73
Language
JavaScript
License
MIT
Created
Oct 2025
Last update
Nov 1, 2026
Type
MCP Server
Price
Free

Topics

aicachingclaudecompressiongemini-cli-extensionllmmcpmcp-servertoken-optimization

Questions about Token Optimizer MCP

What is Token Optimizer MCP?

Measure token savings per AI coding agent, optimize context, and share a live local knowledge graph across 16 CLI clients.

Who maintains Token Optimizer MCP?

Token Optimizer MCP is maintained by ooples on GitHub (ooples/token-optimizer-mcp). AgenticMart lists it from public repository data.

Is Token Optimizer MCP safe to use?

AgenticMart scanned Token Optimizer MCP on Nov 5, 2026 with automated checks for hidden code, known-malicious packages, leaked secrets and vulnerable dependencies. The result covers one commit under our scan policy, so review what access you give it and check any advisories shown here.

What license does Token Optimizer MCP use?

It is published under the MIT license.

Token Optimizer MCP alternatives

View more →

Similar mcp servers in Coding Agents, ranked by GitHub stars. Compare licence, recent activity and scan status before you choose.

NameStarsLicenceLast updatedScan
Token Optimizer MCP (this page)
ooples
564MITNov 1, 2026Scanned, no flagged issues
Context Mode
mksglu
33kNone foundNov 1, 2026Not scanned yet
Serena
oraios
31kNone foundOct 28, 2026Not scanned yet
Fastmcp
PrefectHQ
28kApache-2.0Nov 1, 2026Scanned, no flagged issues
Nuclear
nukeop
19kAGPL-3.0Nov 1, 2026Scanned, no flagged issues
MCP For Beginners
microsoft
18kMITOct 30, 2026Scanned, no flagged issues