Skip to content

ryanwi/agent-control-plane

Repository files navigation

agent-control-plane

CI

Safety and approval controls for AI agents.

The control plane decides when/how an agent may act. The data plane executes side effects.

Watch Demo

Watch interactive terminal recording

Agent story terminal demo

Why This Exists

Most agent stacks have strong execution layers but weak governance. This package provides:

  • Deterministic policy enforcement before execution.
  • Human/risk approval gates for high-impact actions.
  • Budget guardrails and kill-switch semantics.
  • Durable event history for audit, replay, and recovery.

Good fit:

  • Platform teams running production agent workflows.
  • Teams needing explicit human-in-the-loop and policy controls.
  • Multi-agent systems requiring auditable decisions.

Less useful:

  • One-off demos with no side effects.
  • Prompt/tooling projects that do not need governance.

Install

pip install agent-control-plane

Local Dev

uv sync --extra dev
make check

Quickstart

Use the runnable sync quickstart:

uv run python examples/quickstart_sync.py

ACP-first continuous loop examples:

uv run python examples/single_agent_continuous_loop.py
uv run python examples/multi_agent_continuous_loop.py
uv run python examples/continuous_loop_governance.py
uv run python examples/long_running_autonomous_agent.py --horizon day

Optional SDK integrations (requires provider SDK + API key):

uv run python examples/openai_agents_sdk_integration.py
uv run python examples/claude_agent_sdk_integration.py

For the narrated terminal walkthrough used in the demo video:

make demo-asciicast-agent

Core Capabilities

  • Policy and routing: PolicyEngine, ProposalRouter
  • Human approvals: ApprovalGate, scoped ticket decisions
  • Budget enforcement: BudgetTracker
  • Token governance: TokenBudgetTracker (identity-scoped token/cost budgets), ModelGovernor (model tier access policy)
  • Concurrency and kill switches: ConcurrencyGuard, KillSwitch
  • Durable events and replay: EventStore
  • Session lifecycle and recovery: SessionManager, CrashRecovery, TimeoutEscalation
  • Host wrappers: ControlPlaneFacade (sync), AsyncControlPlaneFacade (async)

Runtime Notes

  • Treat state_bearing=True events as fail-closed.
  • Prefer ScopedModelRegistry for production embedding.
  • Use SQLite for local/single-process; use Postgres for multi-worker production.

Docs & API

Examples

License

MIT

About

Production-oriented governance control plane for autonomous AI agents. Policy engine, approval gates, budget tracking, kill switches, and auditable event sourcing.

Topics

Resources

License

Stars

Watchers

Forks

Contributors