Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
codebaseGraph
codebaseGraph is a local knowledge graph for AI coding agents. It builds a syntax-level searchable graph from
Python, Rust, Go, C, C++, Fortran, Markdown, and MDX files into a LadyBugDB-backed graph, then exposes search,
compact context, schema, query helpers, and read-only MCP tools.
The shipped CLI and MCP server are native Rust binaries.
The workspace also includes k-wiki, a local-first Open Knowledge Format
(OKF) 0.1 reader, compiler, searchable static wiki, preview server, and
controlled MCP authoring service. Its source and generated state remain
separate from the code graph; see Knowledge Wiki.
Install k-wiki
Run the repository installer from its root to initialize managed wiki state:
It creates a conformant starter source bundle at knowledge/index.md and the
generated-state layout under .kwiki/, independently of .codebaseGraph/:
staging/, generations/, cache/, and site/. Rerunning the command is
safe. It also maintains an MCP-only k-wiki workflow block in both AGENTS.md
and CLAUDE.md, preserving surrounding project instructions. Use --repo-root <directory> to initialize another repository.
The starter bundle is source-controlled Markdown, while .kwiki/ is generated
state. For development from this checkout, use cargo run -p k-wiki -- install.
Register the bootstrapped wiki with an MCP client separately. This records a
stdio command for k-wiki mcp /absolute/path/to/repository/knowledge; it does
not start a persistent server process.
Supported clients are codex, claude, claude-project, github-copilot,
lmstudio, hermes, openclaw, generic, copilot-studio,
microsoft-copilot, and all. Use --repo-root, --scope, --name,
--client-config-path, or --dry-run as needed. Codex local/project,
Claude project, generic project, and GitHub Copilot targets are
repository_local; Codex user, Claude user/local, generic user/local, LM
Studio, Hermes, and OpenClaw targets are shared; Copilot Studio targets are
manual. For file-backed clients, an explicit config path is
repository_local only when it is inside the canonical repository root. Local
registrations keep k_wiki; shared and manual registrations derive
k_wiki_<sanitized-repo>_<hash8> from the
canonical path's SHA-256. Explicit names are preserved, except k_wiki is
rejected for shared/manual targets. Existing entries with different or
unparseable command/args fail closed. Legacy shared k_wiki entries are
removed when they target the same bundle; registrations for another valid
repository are renamed to that repository's deterministic shared name. The
installer preflights conflicts before writing, and failed cross-file cleanup
reports a partial migration without rolling back the local entry. --dry-run
reports registration and cleanup without writing, and
--client all resolves every client independently. Results include
target_locality and legacy_cleanup; manual targets include cleanup
instructions. The k-wiki executable must be on PATH when the client
launches it; set K_WIKI_SERVER_COMMAND before registration to record a
different executable path. The runtime remains single-bundle and
wiki_list_bundles does not accept caller-selected repository_roots. After
upgrading, replace both codebase-graph and k-wiki from the same release
archive, rerun k-wiki mcp install --client codex --scope project --verify
in each repository, and restart the MCP client.
Native release archives ship both binaries together plus checksums.txt,
install.sh, and install.ps1. Extract the archive and run the installer that
matches your platform to validate both binaries before replacing them in your
chosen bin directory.
Once registered, agents can use the k_wiki MCP server for the same wiki
maintenance operations without shelling out: wiki_validate (the equivalent
of k-wiki validate), wiki_check_links (the equivalent of k-wiki check-links), and wiki_build (the equivalent of k-wiki build). The build
tool is marked as a write operation because it writes the static site.
Quick Start
For local development from this checkout:
Install creates:
.codebaseGraph/
config.json
manifest.json
<repositoryName>_graph.ldb
The install command performs first-time setup: it materializes the initial graph, writes or updates one marked
codebaseGraph block in AGENTS.md or CLAUDE.md, and installs a Codex MCP client entry unless skipped. After setup,
the MCP server watches the repo and refreshes the graph automatically; rerunning install is not part of the refresh
workflow.
Use codebase-graph reinstall only when local setup state needs to be recreated. It moves aside the existing
.codebaseGraph state, runs install again, and refreshes the selected MCP registration without removing unrelated MCP
client entries.
MCP Install
Supported clients are codex, claude, claude-project, github-copilot, lmstudio, hermes, openclaw,
generic, copilot-studio, and microsoft-copilot.
github-copilot writes VS Code workspace configuration to .vscode/mcp.json. copilot-studio and
microsoft-copilot are metadata-only targets: they print stdio and local HTTP connection details for manual Copilot
Studio onboarding and do not provision a hosted connector, TLS, OAuth, or remote deployment.
MCP Usage
Stdio is the default transport for local MCP clients:
HTTP is available for local endpoint clients:
Keep HTTP bound to 127.0.0.1 for normal use. Remote binding requires --allow-remote and a bearer token, but does
not provide TLS, rate limiting, authorization scopes, or a multi-user security model. HTTP clients must initialize first
and send the returned Mcp-Session-Id header on later requests.
Available MCP tools:
graph_healthgraph_searchgraph_contextgraph_schemagraph_query_helpersgraph_architecture_queriesgraph_querywith write-like statements blocked
CLI Workflow
Retrieval commands emit block format by default for agent-facing output. Use --json --pretty or --format json for
structured inspection.
Freshness is automatic while codebase-graph mcp start or codebase-graph watch is running. Use build only for an
explicit manual rebuild, and use plan to inspect what a manual build would touch:
Use .codebaseGraphignore, --include, --exclude, or .codebaseGraph/config.json materialization include/exclude
arrays to tune scanned paths. Git discovery respects .gitignore by default and falls back to filesystem scanning when
Git is unavailable.
Development
Release and Security
CI runs Rust formatting, linting, tests, advisory scanning, package dry-run checks, native package builds, and artifact smoke tests. See docs/release.md for the full release process and conda-forge checklist.
Report suspected vulnerabilities privately. See SECURITY.md for supported versions, reporting expectations, and the local-first MCP security boundary.
Troubleshooting
- Missing LadyBugDB: install
codebase-graphfrom crates.io, a release artifact, or this checkout. - Stale graph: ensure
codebase-graph mcp start --config .codebaseGraph/config.jsonorcodebase-graph watch --repo-root .is running; usecodebase-graph build --repo-root . --mode fullonly for an explicit manual rebuild. - Broken setup state: run
codebase-graph reinstallto recreate.codebaseGraphand refresh the selected MCP registration. - Broken client config only: rerun
codebase-graph mcp install --client <client> --verify. - PATH or executable issues: ensure the native
codebase-graphbinary is onPATH. - Unsupported files: binary, vendor, cache, virtualenv, build, dist,
.codebase_graph, and.codebaseGraphpaths are skipped. - Lock errors: stop other graph build or install processes using the same
.codebaseGraph/<repositoryName>_graph.ldb.