CodeNib¶
CodeNib is a multi-view data system for serving repository context to coding agents. It compiles repositories into reusable, source-linked lexical, semantic, structural, and static-navigation views, then serves the same manifest through MCP, Python APIs, the local Wiki, and evaluation harnesses.
Language support varies by surface. Start with the generated Language Capabilities matrix when you need to know which languages support chunking, graph indexing, incremental patching, or C++ core decoder parity.
User Guide¶
| Goal | Read |
|---|---|
| Turn a local repository into a Wiki | Quickstart |
| Build an index and expose it to an agent | MCP Server |
| Configure the full browser application | Web UI |
| Run without cloud-hosted LLM APIs | Running Locally |
| Understand language support and gaps | Language Capabilities |
| Add or promote a language backend | Contributing a Language |
Once an index exists, use Agent Skills for optional retrieval and reranking workflows, or RAG Ops And Planner for the query planner and graph-aware retrieval boundaries.
Concepts¶
| Surface | Description |
|---|---|
| Index and MCP | Build manifests with IndexCompiler; serve BM25, semantic, regex, Zoekt, and dependency-subgraph tools over MCP |
| Web UI | Source-linked Wiki and optional Ask flow over indexed repositories |
| Graph Range Query | LSP-aligned line-range and symbol queries with typed, source-linked results |
| Incremental Graph | Update a graph in place after a diff where the language backend supports it |
| SCIP Index | SCIP and language-server graph indexing details, cache levels, and backend behavior |
| Core C++ Backend | libigraph-based decoder acceleration and parity boundaries |
Development¶
- Contributing a Language — add a language through the shared registry and verify each supported surface.
- CI/CD — run local and remote test tiers, including serial, graph-consumer, core, and slow jobs.
- Releasing — prepare and verify a CodeNib release.
- Naming — use the project and package names consistently.
Evaluation¶
- Collecting SWE-bench Instances — sample representative instances across languages.
- Synthesis Pipeline — synthesize traversal, behavior, and multi-step queries for the CodeNib Synthesis benchmark.
- GT Locator — evaluate source-location retrieval against ground-truth patches.
- Evaluation Artifact Bundles — package reproducible evaluation outputs.
Quick Start¶
The default Wiki is deterministic, uses BM25, and needs no API key. CodeNib
detects repository languages, writes a reusable manifest under
~/.codenib/repositories, and opens the browser UI. This default fast profile
leaves the target checkout unchanged. Read the
Quickstart for profiles and troubleshooting.
Serving Docs Locally¶
Then open http://localhost:8000.