Install, connect, ask for a plan.
Indexing time depends on the size of the repository; a few thousand files take seconds. Everything is stored under the repository's own .ok/ directory.
cargo install open-kioku-cli, orcargo binstallfor the prebuilt binary.- Binaries with checksums, an SBOM and provenance on GitHub releases ↗.
- The server is read-only by default: source edits remain in Codex's own workflow.
Install Open Kioku
The npm package pulls the native binary for macOS, Linux or Windows.
npm install -g open-kioku
Connect Codex
Index the repository, then print the server entry for it.
ok setup agent --applyis wired for Claude Code and Cursor; for Codex the entry below is the supported path.ok index . ok mcp install codex --repo .
Paste what it prints into
~/.codex/config.toml, or a trusted project's.codex/config.toml:config.toml[mcp_servers.open-kioku] command = "ok" args = ["mcp", "serve", "--repo", "/absolute/path/to/repo", "--read-only"] enabled = true
Tell the agent to use it
Add this to your Codex instructions, or paste it at the start of a session.
InstructionsUse Open Kioku before editing. Check repo_status, search_code, get_definition, get_references, impact_analysis, and find_tests_for_change. Build a plan with plan_change first, then edit, and verify after the edit with verify_change.
Sixteen tools, each answering one question.
These are the ones an edit usually needs. Every tool runs against the local index and says what it could not find.
| Tool | What it answers |
|---|---|
plan_change | An edit plan with primary context, impact candidates, validation targets and the edit boundary. |
verify_change | The finished change checked against the plan's boundary. |
build_context_pack | The files, symbols and tests for one task, with confidence and caveats. |
search_code | Ranked code search with paths, line ranges and confidence. |
get_definition | Where a symbol is defined, from the local symbol index. |
get_references | Where a symbol is used, from indexed relationship edges. |
impact_analysis | What a change to a file or symbol reaches, proven edges apart from possible ones. |
find_tests_for_change | The tests that cover what is about to change. |
repo_status | Index health, coverage by language, and what was skipped and why. |
Measured every night on four real repositories: on a TypeScript repository of about nine hundred files, the right file is in the top five about four times in five. The numbers ↗ · All sixteen tools ↗