Spearmintai / mintocode
git clone https://github.com/Spearmintai/mintocode.git
—
+~-150
stars, 24h · #62,603
+~-1.0k
stars, 7 days · #62,751
+18
stars, 30 days · #26,699
18
★ total · -98% this week
1
forks · 0 open issues
Star history (as recorded here)
LanguagePython
LicenseMIT
Created2026-09-30 (23d ago)
Last push11d ago
Watchers10
OwnerUser
Links
README excerpt
Your agent reads 19 paragraphs. Not your whole repo. **mic** compiles your codebase once. Then Claude Code, Codex, or any MCP agent gets only the functions, callers and tests a question actually needs. ⚡ 10× fewer tokens per answer · 🔋 up to 3.6× more out of your plan **Home page** · Install · How it works · Results · What's next · Reproduce ## Why mic ### ⚡ 10× fewer tokens Claude Code spends ~78k tokens exploring a repo to answer one question. mic hands over only the paragraphs that matter: **~7,300 tokens per answer**. ### 🔋 More out of your plan The expensive reading happens once, at compile time. After that, questions take one frontier call, or none: **up to 3.6× more answers** from the same plan. ### 🔌 Every agent Claude Code, Codex, OpenCode, ZCode, Cursor, VS Code, Claude Desktop, Windsurf, Gemini CLI. One compile, plain files you commit, shared by your whole team. ## Install **Claude Code** (hooks + MCP tools + `/mic:*` commands): [code] **Everything else**: Codex, OpenCode, ZCode, Cursor, VS Code, Claude Desktop, Windsurf, Gemini CLI, or no agent at all: [code] Large and unusual codebases: custom file types, .micignore , scope, cost preview **C++ with `.C`/`.H` works with no setup.** Uppercase `.C`/`.H` are read as C++ (the GCC and OpenFOAM convention), and OpenFOAM's registration macros (`addToRunTimeSelectionTable`, `make*`, `defineTypeNameAndDebug`) are indexed, so `mic where fixedValue` shows every place a type is registered. **Custom file types.** Add any other extension (or exact file name) with one command: [code] In Claude Code the same works as `/mic:config ext .tpp=cpp`. One-off alternatives: `mic compile . --ext .H,.C` or `MIC_EXTENSIONS=".H,.C"`. The resulting `.mic.json` looks like: [code] **`.micignore`** at the repo root uses gitignore syntax: `build/`, `/tutorials`, `**/lnInclude/`, `*.dep`, and `!pattern` to re-include. Files your `.gitignore` excludes are skipped already. **Start free on a huge repo.** `mic compile . --structure-only` makes no model calls: the symbol table, link graph and live-source packs work in seconds (OpenFOAM's 546k-line core: 1.7 s). Add the compiled notes later with a normal compile, or keep costs down with `--no-qa` and `--card-model sonnet`. **Preview before you spend.** `mic compile . --dry-run` prints the files, lines per language, modules and model calls a compile would make, with a token and dollar estimate, and calls no model. Every real compile prints the same estimate first. For very large repositories, `--card-model sonnet` cuts compile cost by about a third. Every agent, MCP client and model backend | Agent | What `mic install ` sets up | |---|---| | `claude` | the plugin: per-prompt link packs, session core card, read guard, MCP tools, `/mic:ask` | | `codex` | MCP server `mic` (`codex mcp add`) + SessionStart/UserPromptSubmit hooks in `~/.codex/hooks.json` | | `zcode` | MCP server in `~/.zcode/cli/config.json`; ZCode also loads the Claude plugin (same hook format)