plan_change
Build an evidence-backed edit plan with primary context, impact candidates, validation targets, and boundary policies.
Connect Open Kioku as a local MCP server so Gemini CLI shows its evidence before it edits — files, streams, confidence, caveats — declares an edit boundary in a plan, and has its diff verified against that plan. Open Kioku does not upload source.
Install the CLI, index your repo, wire up MCP, and paste the prompt that unlocks Gemini's plan-before-edit workflow. Indexing time depends on repo size.
Install the Open Kioku CLI globally. The npm wrapper pulls the native binary for your OS — macOS, Linux, or Windows.
$ npm install -g open-kiokuOther channels: cargo install open-kioku-cli or cargo binstall open-kioku-cli from crates.io; binaries with checksums, an SBOM, and provenance on GitHub releases.
Navigate to your project root and run ok index . to build a local SQLite + Tantivy index. This scans files, parses symbols, resolves imports, maps test coverage, and builds a dependency graph — all on your machine.
$ cd /path/to/your/repo
$ ok index .
[ok] scan → parse → occurrences → store → graph → search → complete
[ok] indexed files, symbols, imports, occurrences, and tests
local indexes: .ok/index.sqlite + .ok/search/tantivyRun the one-liner below to generate the MCP config for Gemini CLI. Then paste the JSON block into your ~/.gemini/settings.json file.
$ ok mcp install gemini --repo .ok setup agent --apply is wired for Claude Code and Cursor today; for Gemini CLI the manual entry below is the supported path.
{
"mcpServers": {
"open-kioku": {
"command": "ok",
"args": [
"mcp",
"serve",
"--repo",
"/absolute/path/to/repo",
"--read-only"
],
"trust": false
}
}
}Replace /absolute/path/to/repo with the actual path to the repository you indexed in Step 2.
Start Gemini CLI and paste this prompt. It instructs Gemini to use Open Kioku's evidence tools before making any edits — building a plan from indexed facts, not guesses.
Use 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.Once connected, Gemini CLI can call these tools over MCP stdio. Every Open Kioku tool reads from the local index and does not upload source.
What to expect: on a Java repository of about ten thousand files the right file is in the top five about half the time and in the context pack about two thirds of the time; on a TypeScript repository of about nine hundred files, in the pack nearly nine in ten and in the top five about four in five. That is the retrieval floor before exact lookups and the plan → verify loop; it is re-measured nightly against frozen baselines. Numbers and method.
Build an evidence-backed edit plan with primary context, impact candidates, validation targets, and boundary policies.
After editing, verify that changes stayed inside the planned boundary. Catch scope creep before the PR.
BM25-ranked full-text search across the indexed codebase. Returns file paths, line ranges, and confidence scores.
Trace callers, dependents, and affected modules using the local dependency graph. Know the blast radius before editing.
Jump to the definition of any symbol — functions, types, constants — resolved from the symbol index.
Find every usage of a symbol across the codebase. Graph-backed, not text-matched.
Identify which tests cover the files and symbols you're about to change. Run the right tests first.
Check index health, file counts, symbol counts, and last-indexed time. Confirm the index is ready.
Assemble a focused context window with exactly the files and symbols the agent needs for a specific task.
Open Kioku is designed for teams and codebases that cannot be uploaded to a hosted index. Every tool reads from a local SQLite + Tantivy index stored in your repo's .ok/ directory.
Metadata stays under .ok/ in your repo. There is no hosted search service to provision or trust.
BM25 search, symbols, and graph operations work locally without uploading code to a model provider.
Source edits stay in your normal editor; command execution and model downloads are policy-gated, and network denial fails closed.