MCP Tool Reference
Kompile's MCP server (kompile mcp-stdio and kompile serve / SSE) exposes ~100 tools covering file I/O, code intelligence, builds, scripts, background processes, subagent delegation, knowledge graphs, crawls, memory, and cross-machine sources.
Tool Profiles & Schema Optimization
Select a profile and schema compaction level when launching kompile mcp-stdio:
kompile mcp-stdio --profile=full --schema-level=compact --work-dir /path/to/projectProfiles (--profile)
| Profile | Included tools | Typical use case |
|---|---|---|
minimal | read, file_context, grep, glob, list | Ultra-low-token read-only inspection (~1k tokens) |
explore | read, read_batch, file_context, grep, grep_batch, glob, list, explore, code_search, local_code_index, code_graph, graph_search, graph_reasoning_query, fetch_result, fetch_result_batch | Read-only codebase & graph exploration (~2.5k tokens) |
core | File I/O & batch edits (read, read_batch, file_context, file_note, write, edit, edit_batch, patch, edit_patch, draft, draft_batch), search (grep, grep_batch, glob, list, explore), bash, fetch_result, fetch_result_batch, workflow (todowrite, todoread, todo_apply_batch, progress, memory, incident), web (webfetch, websearch), custom MCP gateway (mcp_tool_search, mcp_tool_call) | Day-to-day coding without specialized graph/crawl/admin tools (~3k tokens) |
full (default) | All registered tools (with dynamic group loading via activate_tools) | Full agent harness capabilities |
Schema levels (--schema-level)
compact(default) — strips verbose prose while keeping required parameter names, enums, and types.aggressive— shortest possible schema descriptions for tight context windows.moderate— balanced descriptions.none— full unabridged JSON schemas.
Dynamic Tool Groups (activate_tools)
To avoid flooding an agent's context with 100+ tool schemas on turn 1, Kompile starts with a compact core surface plus the activate_tools meta-tool. Agents activate additional groups on demand (typically cutting schema tokens by 60–70%).
Always-Active Core Tools
read, file_context, write, edit, grep, glob, list, bash, memory, fetch_result, fetch_result_batch, poll, mcp_tool_search, mcp_tool_call, activate_tools, exit_plan_mode, progress
(In stdio hosts that supply their own native file tools, host-native overlap can be configured via worker tool surface policies.)
Dynamic Groups
Additional Enforced Build & Script Tools
When Kompile's build and script enforcers are enabled, Kompile also exposes dedicated provenance-tracked tools:
build— executes whitelisted build tools (mvn,gradle,make,cmake,npm,cargo, etc.) with commit/session provenance.build_provenance— queries recorded build runs and outcomes.script_manager&script— registers and executes reusable Python/Node/shell scripts cleanly without inline ad-hoc shell scripting.
Tool Catalog by Domain
File I/O, Batch Editing & Drafts
| Tool | Summary |
|---|---|
read / read_batch | Line-numbered file reads (supports offset/limit and include_context); read_batch reads multiple files in one call and satisfies read-before-edit for all of them. |
write | Create or overwrite a file (creates parent directories automatically). |
edit / edit_batch / edit_patch | Exact string replacement; edit_batch and edit_patch apply atomic per-file multi-file edits in a single round-trip. |
patch | Apply unified diff blobs, including file add/delete operations. |
draft / draft_batch | Stage, revise, rebase, apply, or revert off-tree Git-backed draft changes without mutating the working tree. See Draft Workflow. |
grep / grep_batch | Regex content search (content, files, or count modes, context lines, glob scoping). |
glob / list / explore | Recursive file globbing, non-recursive directory listing, and structured repository exploration. |
file_context / file_note / file_activity | Contextual file summaries, persistent file notes, and multi-agent file-change notifications. See File Context & Notes. |
Code Intelligence & Language Servers
| Tool | Summary |
|---|---|
lsp | Real language-server queries across 45+ languages (definition, references, hover, symbols, workspace_symbols, rename with dry_run=true default, diagnostics, fail-closed check edit gate, and servers lifecycle). See LSP. |
local_code_index | Build, refresh, and query the offline SQLite FTS5 semantic & symbol code index. See Local Code Index. |
code_search / code_graph | Semantic code search and call/dependency graph traversal. |
diff_index | Search, filter, and sort historical coding-agent edits and unified diffs. See Diff Index. |
Execution, Builds & Background Processes
| Tool | Summary |
|---|---|
bash | System commands (git, services, shell utilities) subject to active enforcer & resource policies. |
build / build_provenance | Sanctioned build-tool execution (mvn, gradle, npm, cargo, cmake, etc.) with commit/session provenance tracking. |
script / script_manager | Register and invoke reusable Python, Node, or shell scripts cleanly. |
process | Launch, list (searchable & paginated), inspect status/output/stream, monitor, notify, or kill background processes. See Monitors & Background Control. |
process_log / process_notify | Tail/read/search/grep managed process & runtime logs; subscribe to cross-session process exit wakes. |
subprocess_watchdog | Resource admission and limits for pooled crawl/model child processes. |
edit_coordinator | Acquire/release multi-agent file locks (register_edits / release_edits), FIFO named locks, edit-lock monitors, and peer messaging. See Edit Coordinator & Message Bus. |
poll | Check status or retrieve output of asynchronous _background: true tool calls. |
process_mining / server_mode | Inspect process execution traces/timelines and query or toggle Kompile server runtime mode. |
Delegation, Todos & Progress
| Tool | Summary |
|---|---|
task / multi_task / quorum_task | Launch single subagents, parallel fan-out tasks, or multi-voter quorum consensus tasks across configured agents (kompile, claude, codex, gemini, opencode, agy). |
task_transcript | Inspect parent/child task trees and live output tails of running or completed subagents. |
subagent_resume | List and continue durable child subagent conversations with any agent. |
progress | Post or read throwaway per-transcript progress reports (newest 50 kept; enforced at subagent exit). |
todowrite / todoread / todo_apply_batch | Manage structured session task lists with filtering, sorting, pagination, and batch updates. |
role_manager / skill_manager / resolve_model | Manage agent roles, skills (Skills & Templates), and live model/provider resolution. |
Memory, History, Sources & Observability
| Tool | Summary |
|---|---|
memory / semantic_memory / ambient_garden | Persistent project & global Markdown memory, semantic vector recall, and background memory maintenance. See Persistent Memory. |
transcript_search / conversation_import / resume / sessions | Full-text transcript search, importing external CLI conversations, listing saved sessions, and resuming or switching vendors. See Import & Resume. |
sources / peer / blob_store | Unified cross-machine harness sources, encrypted TLS peer sync, and remote archive/transcript blob stores. |
insights / tool_call_catalog / cost | Read-only analytics over judge verdicts, tool latency/token usage, test milestones, crawl jobs, and dollar/quota cost (Cost Estimation). |
test_milestone / incident / performance_harness / eval | Record and query verified test milestones (Test Milestones), structured incident ledgers, performance harness runs, and agent evaluations (Guardrails & Evaluation). |
gc | Dry-run report and controlled cleanup of Kompile home stores (interactive sessions only; denied to subagents). See Disk Space & GC. |
Crawling, Pipelines & Knowledge Graphs
| Tool | Summary |
|---|---|
crawl_discover / crawl_source / crawl_documents / crawl_control / crawl_result | Discover pipeline capabilities, run single-source or batch document/connector crawls (including dryRun: true previews), monitor/cancel jobs (Crawl Jobs), and inspect results. |
pipeline / model_runtime / vlm_model_definition | Author, validate, test, and run UnifiedPipelineDefinition chains (Pipelines); bootstrap, import, convert (ONNX/TF/Keras/GGUF/SafeTensors → .sdz), optimize models, and register reusable VLM definitions. |
knowledge_search / knowledge_status / rag_search | Query project-local or server-backed RAG (Information Retrieval) and knowledge bases. |
knowledge_graph / graph_search / graph_reason / graph_reasoning_query | Discover fact sheets and predicates, search graph neighborhoods, and trace entity/fact reasoning. |
ask_graph_verify / ask_graph_query / ask_graph_explain / ask_graph_explain_fused / ask_graph_synthesize / ask_graph_claim / ask_graph_mebn | Verify claims (SUPPORTED/REFUTED/UNKNOWN), run ?variable pattern queries, explain derivation trees, run MEBN inference, and synthesize grounded answers. |
ask_graph_assert / ask_graph_retract / ask_graph_subscribe / graph_import / graph_export | Assert/retract facts, subscribe to graph changes, and import/export portable .kgraph bundles. |
graph_aggregate / graph_bayes / graph_centrality / graph_embeddings / graph_forecast / graph_psl / graph_simulate | Run aggregation, Bayesian inference, centrality, KGE embeddings, forecasting, PSL, and simulation over the graph. |
Harness Config, Guardrails, Hooks & UI
| Tool | Summary |
|---|---|
onboarding / harness_manager / project_config | Inspect current harness state (explain), configure providers/MCP wiring, and update project-level configuration. See Customize Your Harness. |
enforcer_config / policy_enforce / judge_control | Manage tool enforcer rules (Enforcer), deterministic turn-boundary policies (Policy Enforcement), and supervisory judge controls. |
hooks / config_archive | Manage PreToolUse / PostToolUse lifecycle hooks (Tool Hooks) and snapshot/restore configuration archives. |
side_panel / dictation / spin | Render rich side-panel cards, control voice dictation, and inspect/build/qualify custom Kompile spins (Spins). |
Web, Channels, Caching & MCP Gateway
| Tool | Summary |
|---|---|
webfetch / websearch / browser | Fetch web URLs as readable text, run cited web searches, and drive a CDP browser for inspection and screenshots. |
channel | Send and receive messages across configured messaging channels and integrations. |
fetch_result / fetch_result_batch | Page through or regex-filter cached large tool outputs (ref:ID) without re-running tools. |
mcp_tool_search / mcp_tool_call | Search and invoke tools exposed by connected external or custom MCP servers (Custom MCP Servers). |
activate_tools / exit_plan_mode | Dynamically load additional tool groups into the session and exit read-only planning mode with an approval summary. |
Large Output Caching & Async Calls
- Reference handles (
ref:ID): Large tool outputs are automatically cached instead of flooding the context window ([Full result cached as ref:ID — N chars, M lines]). Page through them withfetch_result(result_id="ID", offset=1, limit=80)or filter matching lines withfetch_result(result_id="ID", pattern="error"). Usefetch_result_batchto read multiple handles or slices in a single call. - Background execution: Pass
_background: trueto any tool call to receive a task ID immediately and retrieve the result later withpoll.