SigMap extracts function signatures from your codebase and writes a context file that Copilot, Claude, Cursor, and Windsurf read automatically. Every session starts informed.
SigMap scans your source files, strips function bodies and comments, and writes a compact signature index your AI tools read automatically.
Scans every source file, extracting only the public API surface — function names, class definitions, types, interfaces. No bodies. No imports. No comments.
Writes .github/copilot-instructions.md, CLAUDE.md, .cursorrules, and .windsurfrules automatically. Copilot reads these on every request.
File watcher updates on every save. Post-commit git hook updates on every commit. Context is always current — zero developer action required.
| Approach | Tokens / session | Reduction | Cost (Claude Sonnet) |
|---|---|---|---|
| No context (cold session) | baseline | ~$0.24 / session | |
| Repomix --compress | −90% | ~$0.024 | |
| SigMap | −97% | ~$0.012 | |
| SigMap + MCP (v0.3) | −99% | ~$0.001 |
Pure regex AST extraction — no compiler required, no binary dependencies, works on any machine with Node.js 18+.
SigMap and Repomix are complementary. Use both — they solve different parts of the context problem.
Always-on. Runs automatically on every save and commit. Produces a compact signature index — 4K tokens for daily Copilot use.
On-demand. Run before a deep refactor or architecture session. Packs full file content — 8K compressed tokens for detailed analysis.
No package manager. No configuration. One file, one command.
One file, no install required. Drop it in your project root or download globally.
curl -O https://raw.githubusercontent.com/manojmallick/sigmap/main/gen-context.js
Scans your project and writes .github/copilot-instructions.md automatically.
node gen-context.js
Installs a post-commit git hook and file watcher. Context stays current without thinking about it.
node gen-context.js --setup
Copilot now knows your class names, function signatures, and patterns — without reading every file on each request.
node gen-context.js --report # see your token reduction
Free forever. Zero telemetry. Runs locally. Adding a language extractor is 80 lines of code — contributions welcome.