Show HN: Shield KYA – Open-source audit trail and gate for AI agent tool calls Shield Agent released Shield KYA, an open-source (MIT) CLI and local MCP gate that records every AI coding agent tool call on a live local dashboard and checks each call against the Agent Trust Baseline, returning Allow, Review, or Deny. The open-source client is advisory and fails open except for a small never-list of dangerous calls that is always denied, while real blocking and human approval run on the hosted Shield Agent cloud service; it installs via `npm i -g @shield-agent/kya@latest && kya start` and requires Node.js 22+ (24 recommended). The gate exits 0 on ALLOW, 4 on REQUIRE_APPROVE, and 1 on DENY or unknown so chained commands cannot skip the gate, and agents that never call evaluate stay invisible by design. Audit trail and traceability for AI agents. See what every coding agent did and check each tool call against policy. Every tool call is recorded on a live local dashboard and can be checked against the Agent Trust Baseline. The open source client is advisory and fails open an error lets the call through , apart from a small never-list of dangerous calls that is always denied. Real blocking and human approval run on the MCP policy path against a hosted workspace the Shield Agent cloud service . One command. Free forever under MIT. npm i -g @shield-agent/kya@latest && kya start Requires Node.js 22+ 24 recommended . Restart Cursor / Claude Code / Codex once so MCP loads. Hosted desk: shield-agent.com https://shield-agent.com/install . CLI and local MCP gate for Shield’s Know Your Agent path. An agent that asks Shield first gets Allow, Review, or Deny: you register the agent, wrap the tool or route it through the MCP gate or the hosted plane , and Review waits for a person. Local hooks only record and block the never-list see Hook interception hook-interception . Hosted is where enforcement lives. This package does not scan your network. Agents that never call evaluate stay invisible on purpose. Walkthrough: how you use it https://shield-agent.com/how-kya-works using . npx @shield-agent/kya@latest --help npx @shield-agent/kya@latest --version --version , -v , -V and kya version print the installed package version on one line and exit 0 . They read the local package only: no network, no banner, no config. Requires Node.js 22+ engines.node: =22 ; 24 is the recommended line. Node 20 and 21 are unsupported but work: the CLI prints a one-line warning. Node 18 and older are unsupported and some features break there HTTP serve-mcp , the gateway OTLP receiver . Below 22 the CLI offers to install Node 24 for you via volta / fnm / nvm / brew , reinstall itself, and finish the command. If you decline, it just prints the warning and continues. kya hook never warns or prompts. It works with any host that speaks MCP or OpenAPI. Vertical packs are optional. Shield is the only policy decision point the one place that decides Allow or Deny . This gate never auto-approves an irreversible side effect a change you cannot undo . If KYA API KEY is empty against an authenticated plane, network commands exit non-zero. eval-tool , wrap , and invoke exit 0 on ALLOW, 4 on REQUIRE APPROVE, and 1 on DENY or unknown, so a line like eval-tool && write cannot skip the gate. wrap runs in observe mode by default, so it exits 0 on REQUIRE APPROVE too. Set KYA HOLD=1 or pass --hold to get the 4 . --offline runs sample evaluate without a paid cloud useful for DENY and REQUIRE APPROVE demos . Creating an agent is itself a tool: offline, kya.agent.register comes back REQUIRE APPROVE. Allow, break-glass, and approve mint modes the modes that create approvals live on the control plane. npm i -g @shield-agent/kya@latest && kya start Run it in your project directory. From a clone of this repo, ./scripts/install-local.sh replaces the npm install. More ways to install same package; npm stays the reference path : Homebrew. Homebrew 7 may ask you to trust a third-party tap: run brew tap The-Pixel-Boys/tap first. The formula does not install the semantic-search runtime. Search stays lexical until you opt in see Natural-language search . brew install The-Pixel-Boys/tap/shield-kya Scoop not yet verified on Windows scoop bucket add The-Pixel-Boys https://github.com/The-Pixel-Boys/scoop-bucket.git scoop install shield-kya Claude Code users can also install the plugin claude-code-plugin ; GitHub Copilot CLI users the Copilot CLI plugin github-copilot-cli-plugin read its first paragraph before installing ; Codex CLI users the Codex plugin codex-plugin ; Gemini CLI users the Gemini CLI extension gemini-cli-extension . Cline users: npm install -g @shield-agent/kya@latest , then follow llms-install.md https://github.com/The-Pixel-Boys/shield-kya/blob/main/llms-install.md . It is written so Cline can follow it; a Cline run from that file alone has not been tested yet. That inits .kya/ , wires local MCP .mcp.json , mcp.json , .cursor/mcp.json → kya serve-mcp --stdio , also wires user-level configs for every installed host it detects ~/.claude.json , ~/.kimi-code/ , ~/.grok/ , ~/.cursor/ , … , and opens the live activity report. The report runs in the background, so you get your terminal back. kya stop stops it. kya receipt --open reopens it. Cursor, Kiro, Qwen, Amp, Droid, Cline, and Grok pick the server up live with no restart Kimi: just a new session . Claude Code, Codex, OpenCode, Gemini, Copilot CLI, and Kilo CLI load it on next launch. claude --resume keeps your conversation. kya start --no-open wire only kya start --force rewrite MCP blocks Receipt change previews clipped + redacted : on by default for writes KYA DIFF PREVIEW=0 to disable kya start covers Claude Code, Cursor, and any host that reads .mcp.json . It also auto-wires the user-level config of every installed host it detects. For the rest, kya connect writes the host's own config dialect directly: kya connect claude ~/.claude.json merges mcpServers only kya connect grok ~/.grok/config.toml appends mcp servers.shield-kya kya connect opencode ~/.config/opencode/opencode.json kya connect qwen ~/.qwen/settings.json kya connect amp ~/.config/amp/settings.json kya connect qwen --project project scope instead of global kya connect kiro --force overwrite an existing shield-kya entry Connect merges. It never rewrites a host config it cannot parse, and it keeps your other servers and keys. Supported hosts: claude , codex , grok , opencode , kilo , kiro , qwen , kimi , mastracode , amp , copilot , cursor . Each wires serve-mcp --stdio with KYA OFFLINE=1 so the gate starts keyless no API key . Set KYA API KEY in the host env when you point at an authenticated plane. Hosts without a connect target still work: kya wrap --offline --