Always use jCodemunch-MCP tools for code navigation. Never fall back to Read, Grep, Glob, or Bash for code exploration.
Exception: Use Read when you need to edit a file — the agent harness requires a Read before Edit/Write will succeed. Use jCodemunch tools to find and understand code, then Read only the specific file you're about to modify.
Start any session:
resolve_repo { "path": "." }— confirm the project is indexed. If not:index_folder { "path": "." }suggest_queries— when the repo is unfamiliar
Finding code:
- symbol by name →
search_symbols(addkind=,language=,file_pattern=,decorator=to narrow) - decorator-aware queries →
search_symbols(decorator="X")to find symbols with a specific decorator (e.g.@property,@route); combine with set-difference to find symbols lacking a decorator (e.g. "which endpoints lack CSRF protection?") - string, comment, config value →
search_text(supports regex,context_lines) - database columns (dbt/SQLMesh) →
search_columns
Reading code:
- before opening any file →
get_file_outlinefirst - one or more symbols →
get_symbol_source(single ID → flat object; array → batch) - symbol + its imports →
get_context_bundle - specific line range only →
get_file_content(last resort)
Repo structure:
get_repo_outline→ dirs, languages, symbol countsget_file_tree→ file layout, filter withpath_prefix
Relationships & impact:
- what imports this file →
find_importers - where is this name used →
find_references - is this identifier used anywhere →
check_references - file dependency graph →
get_dependency_graph - what breaks if I change X →
get_blast_radius - what symbols actually changed since last commit →
get_changed_symbols - find unreachable/dead code →
find_dead_code - class hierarchy →
get_class_hierarchy
Opening move for any task:
plan_turn { "repo": "...", "query": "your task description", "model": "<your-model-id>" }— get confidence + recommended files; themodelparameter narrows the exposed tool list to match your capabilities at zero extra requests.- Obey the confidence level:
high→ go directly to recommended symbols, max 2 supplementary readsmedium→ explore recommended files, max 5 supplementary readslow→ the feature likely doesn't exist. Report the gap to the user. Do NOT search further hoping to find it.
Interpreting search results:
- If
search_symbolsreturnsnegative_evidencewithverdict: "no_implementation_found":- Do NOT re-search with different terms hoping to find it
- Do NOT assume a related file (e.g. auth middleware) implements the missing feature (e.g. CSRF)
- DO report: "No existing implementation found for X. This would need to be created."
- DO check
related_existingfiles — they show what's nearby, not what exists
- If
verdict: "low_confidence_matches": examine the matches critically before assuming they implement the feature
After editing files:
- If PostToolUse hooks are installed (Claude Code only), edited files are auto-reindexed
- Otherwise, call
register_editwith edited file paths to invalidate caches and keep the index fresh - For bulk edits (5+ files), always use
register_editwith all paths to batch-invalidate
Token efficiency:
- If
_metacontainsbudget_warning: stop exploring and work with what you have - If
auto_compacted: trueappears: results were automatically compressed due to turn budget - Use
get_session_contextto check what you've already read — avoid re-reading the same files
Reading the response envelope (v1.74.0+):
_meta.confidence(0–1) — calibrated retrieval-quality score onsearch_symbols/plan_turn/get_ranked_context. ≥ 0.8 → trust the top result; ≤ 0.4 → widen the search or report a gap_meta.freshness—{fresh, edited_uncommitted, stale_index}counts plusrepo_is_staleflag. Per-result_freshnessfield on each symbol entry- If
repo_is_stale=true, suggestindex_folderbefore claiming current behaviour - For latency / cache health:
analyze_perf(in-memory by default;window=1h|24h|7d|allreads~/.code-index/telemetry.dbwhenperf_telemetry_enabledis on) - After a representative workload on a new repo, run
tune_weightsto learn per-repo retrieval weights from the ranking ledger
Your jcodemunch-mcp server narrows the exposed tool list based on the model you are running as. To avoid wasting requests on primitives when a composite would do, always include model="<your-model-id>" in your opening plan_turn call.
Replace <your-model-id> with your active model:
- Claude Opus variants →
claude-opus-4-7(or anyclaude-opus-*) - Claude Sonnet variants →
claude-sonnet-4-6 - Claude Haiku variants →
claude-haiku-4-5 - GPT-4o / GPT-5 / o1 / Llama → use the model id as printed by your runner
The model= parameter rides on the existing plan_turn call — it does not add a separate tool invocation. If plan_turn is not appropriate for a non-code task, call announce_model(model="...") once instead.