This package is the production package surface for Agent Governance Toolkit on Claude Code.
It ships a Claude Code plugin that uses:
- Claude hooks for deterministic session, prompt, and pre-tool governance
- a bundled MCP server for operator-facing AGT inspection tools
- the AGT TypeScript SDK for policy evaluation, prompt defense, and MCP threat scanning
- a first-party Claude Code plugin package
- an experimental parity layer for the existing Copilot CLI governance work
- a publishable npm package that can also be loaded locally with Claude Code
- a Copilot-style in-process extension
- a universal governance layer for every Claude surface
- a guarantee of full Copilot CLI feature parity
This initial package enforces:
SessionStartgovernance context injectionUserPromptSubmitprompt inspection and fail-closed blockingPreToolUsetool-call inspection with allow, deny, or ask behavior
It also exposes two MCP tools:
agt_policy_statusagt_policy_check_text
- Claude slash commands are markdown-driven, so
/agt-governance:agt-statusand/agt-governance:agt-checkare thin wrappers around MCP tools rather than deterministic code handlers. PostToolUsein Claude cannot reliably redact tool output after the tool has already executed, so this package does not claim Copilot-style output suppression parity.- Hook execution is out-of-process. The package keeps enforcement in command hooks so policy errors can fail closed.
Run these commands from the repository root so the relative plugin path resolves correctly.
Install dependencies:
cd agent-governance-claude-code
npm installLoad the plugin directly:
claude --plugin-dir .\agent-governance-claude-codeclaude --plugin-dir "$(pwd)/agent-governance-claude-code"Inspect the active policy and command wiring:
/agt-governance:agt-status
/agt-governance:agt-check suspicious text to inspect
Reload after edits:
/reload-plugins
The package provides two Claude commands:
/agt-governance:agt-status/agt-governance:agt-check
For a runnable repo-local walkthrough with a sample policy override, expected prompts, and cleanup notes, see:
The package loads policy in this order:
AGT_CLAUDE_POLICY_PATH%USERPROFILE%\.claude\agt\policy.json~/.claude/agt/policy.json- bundled
config/default-policy.json
Audit entries are written to:
- Windows:
%USERPROFILE%\.claude\agt\audit-log.json - macOS/Linux:
~/.claude/agt/audit-log.json
Override with AGT_CLAUDE_AUDIT_PATH.
cd agent-governance-claude-code
npm run check
npm test