Deterministic, fail-closed planner for KCP knowledge manifests: kcp_plan, kcp_load, kcp_validate.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
The reference agent for the Knowledge Context Protocol.
The Arena β β the real planner, bundled unmodified, running live in your browser, head-to-head against the usual suspects. The most deterministic agents in the world. Every decision defensible.
KCP defines how knowledge declares itself so agents can navigate it. kcp-agent is the other
half: the agent that consumes KCP end to end. Given a task and a knowledge.yaml, it produces an
inspectable load plan β which units to load and in what order, which to skip and exactly why,
how it selects sub-manifests across a federation, and what the whole thing costs β and then,
optionally, answers the task from only those units.
The valuable, novel core is LLM-free and deterministic. The plan is an audit-before-action artifact β the trusted-render principle ("a manifest may influence what an agent knows, never what it does") extended to the whole agent loop. Only the final synthesis step calls a model.
CI cross-compiles self-contained binaries (no Node/Deno required on the target) for
Linux x64/arm64, macOS x64/arm64, and Windows x64 β grab them from a release or from the
kcp-agent-natives artifact on any CI run. To build one yourself:
plan β the inspectable load plan (no API key)Each stage maps onto a layer of the spec: query scoring (Β§15), temporal validity (Β§4.22), agent
attestation (Β§3.2), federation context + agent_identity (Β§3.6), and payment / rate-limits
(Β§4.14/Β§4.15). A restricted unit the agent can't attest for is listed but marked not
load-eligible β fail-closed, with the reason attached.
Budgeting the context window. Tokens are the actually-scarce resource when feeding a model,
so --context-budget <n> names it β a token ceiling that works exactly like the money --budget:
greedy by score, and a unit that would blow the ceiling is skipped with the arithmetic in the
reason (over context budget: 1,240 tokens would exceed remaining 800 of 4,000), while a smaller
lower-scored unit still gets its chance. Since the planner works on metadata before fetching
(audit-before-action), a unit's size comes from a declared size_tokens (faithful) or bytes/4
(a flagged estimate); a unit that declares neither is admitted but counted unmeasured (the
projection is a lower bound) β unless --strict, which excludes it fail-closed. --context-budget
composes with --budget: a unit must fit both ceilings.
Use --json when another agent or integration consumes a plan. The output preserves the plan fields
at the top level and adds:
kind is plan, tree (when --follow is used), or trace (when --trace is used). Human-readable
output is not a compatibility surface. Successful JSON commands exit 0; planner or manifest errors
write diagnostics to stderr and exit non-zero.
ask β plan, then answer via Claudeask runs the same planner, loads only the load-eligible units, and asks Claude to answer from
them β treating unit content as knowledge, never as instructions. Needs @anthropic-ai/sdk (an
optional dependency) and a key; plan needs neither.
ask --loop β the audited critique loopThe deterministic scorer is lexical, so a task phrased differently from the publisher's vocabulary
can miss relevant units. --loop closes that gap without surrendering determinism β the model
proposes, the plan disposes:
A fast critic model (default claude-haiku-4-5, --loop-model to change) sees a metadata
digest of the plan β ids, intents, scores, skip reasons, never unit content β and proposes extra
lowercase search terms. A deterministic gate sanitizes, dedupes, and caps them; the task string is
extended; the planner re-plans from scratch. The loop converges when the critic runs dry, a round
adds no units, or --max-rounds (default 3) is reached. Then synthesis answers the original
task from the final plan's eligible units.
What the critic can never do: open an access gate, alter trust/temporal/audience decisions, or
spend money β terms only affect relevance scoring, nothing is loaded or paid for until the loop has
converged, and the final plan's budget arithmetic gates spending exactly as in single-shot mode.
Every round is recorded (proposed terms, accepted, rejected, units added, the full re-planned
artifact) β with --json the chain of plans is the audit log.
The same loop is available as a library (runLoop / askLoop, with an injectable critic), and
skills/kcp-navigator/SKILL.md packages the discipline as a
portable skill for agents that drive the CLI themselves.
ask --ground β verify the answer, surface what it can't substantiateThe plan's fail-closed gates decide what may be loaded; grounding extends the same discipline to what may be asserted. After synthesis, each claim in the answer is checked by a separate verifier β a distinct model call from the generator β that must attribute the claim to one of the loaded units or return nothing. The result is a two-part artifact:
A claim grounds only if the cited unit was actually loaded and its content hash matches β so a verifier that mis-attributes (or is prompt-injected into) citing a unit that was never loaded can never ground a claim: attribution is a proposal, grounding is adjudicated. Unsupported claims are surfaced, never silently dropped β the honest half of "every decision defensible". Each surfaced gap is also a signal to the publisher: the task needed evidence the manifest didn't provide. The surfaced list is capped to guard against a compromised generator flooding it with spurious gaps.
--ground-rounds <n> closes the loop: a surfaced gap seeds reformulation terms, the agent
re-navigates to try to find the missing evidence, and re-grounds β up to n rounds. Termination is
guaranteed by three independent bounds, any one of which halts: the term gate is absorbing (a
term accepted once is known forever, so re-navigation can only add units from the finite eligible
set), the round cap, and a progress guard (a round that adds no new unit halts). Oscillation
is impossible β the loaded set grows monotonically or the loop stops. Every terminal state that
isn't grounded (partial-unsupported, partial-budget, partial-rounds) still surfaces the
remaining gaps. A compromised verifier can, at worst, widen navigation within the eligible set β it
can never cross a gate, name a URL, or spend past the budget.
assess β gate what may be acted onThe plan's gates decide what may be loaded; grounding decides what may be asserted;
assess() decides whether a conclusion clears a confidence threshold before it is acted on.
It runs downstream of synthesis β confidence is a property of the output, which is exactly why it
structurally cannot be gate #14 in the pre-selection cascade.
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/kcp-agent-kcp-navigation-planner)<a href="https://allmcps.com/mcp/kcp-agent-kcp-navigation-planner"><img src="https://allmcps.com/api/badge/kcp-agent-kcp-navigation-planner?style=directory" alt="Kcp Agent β KCP navigation planner on AllMCPs" /></a>