Aegis Playground - Interactive AI Agent Governance
Author: Aegis Project
Description: Try Aegis governance in your browser. Write YAML policies, simulate AI agent actions, see real-time risk evaluation.
Keywords: AI agent governance, AI safety, policy engine, YAML policy, LangChain governance, CrewAI governance, MCP governance, Python AI tools, tool control, agent guardrails, AI risk management

## Loading Aegis Playground

Initializing Python runtime...

Tip: Aegis evaluates policies in under 1ms

0 Evaluated
0 Auto-approved
0 Needs Approval
0 Blocked
- Avg Latency
Works with: LangChain CrewAI OpenAI Anthropic MCP Playwright httpx Docker CI/CD Gradio
1
📝

### Write a Policy

Define rules in YAML: which actions are auto-approved, need human review, or are blocked.

→
2
🎯

### Simulate Actions

Send agent actions (navigate, read, write, delete) through the policy engine.

→
3
✅

### See the Verdict

Instantly see risk level, approval decision, matched rule, and full audit trail.

    # 50+ lines of DIY governance... per action type
    if action.type == "delete":
        if action.risk > THRESHOLD:
            logger.warning(f"High-risk: {action}")
            if not await ask_human_approval(action):
                raise PermissionError("Denied")
        # No audit trail
        # No policy hot-reload
        # Breaks when you add a new action type
        result = await executor.run(action)

    # 3 lines. Works for every action type.
    from aegis import Action, Policy, Runtime

    runtime = Runtime(executor=my_executor, policy=Policy.from_yaml("policy.yaml"))
    result = await runtime.run_one(Action("delete", "crm", params={"id": "all"}))
    # Policy checked. Approval gated. Audit logged. Done.

## Policy (YAML)

|
0 rules ✅ Valid

## Simulate Actions

### Custom Action

Type
Target
Params (JSON)

## Evaluation Result

Click an action above to see the policy evaluation result

## Audit Log

0 entries
Import
Audit entries will appear here as you evaluate actions. Try clicking a preset above, then press an action button!

## How It Works

⚠️
AI agents without governance are a liability. Uncontrolled agents can delete production data, leak PII, or trigger compliance violations. Aegis adds a policy layer in 2 lines of code — no behavior changes, just safety.
Without Aegis
`agent.run(action) # 💥 anything goes`
vs
With Aegis
`rt.run_one(action) # 🛡️ policy-checked`
What happens on each action:
1Agent calls `rt.run_one(action)`
→
2Aegis matches rules in <1ms
→
3Returns `auto` / `approve` / `block`
→
4Audit entry logged automatically
1
📝

### Write YAML Policy

Define rules for each action type: auto-approve safe reads, require human review for writes, block dangerous operations.

14 presets YAML syntax ~2 min
→
2
🤖

### Agent Sends Actions

Your AI agent (LangChain, CrewAI, OpenAI, etc.) sends each action through Aegis before executing it.

7 adapters 2 lines code ~30 sec
→
3
🛡️

### Instant Decision

Aegis evaluates risk in <1ms: auto-approve, require human approval, or block. Every decision is audit-logged.

<1ms eval 100% audit instant
🤖 AI Agent LangChain / CrewAI / OpenAI
action request
🛡️ Aegis Engine YAML policy + risk eval
decision
✅ auto 🟡 review 🔴 block

Every action is evaluated, logged, and auditable — zero blind spots.

Risk LevelExample ActionDefault Decision
LOWRead contacts✅ Auto-approve
MEDIUMUpdate record🟡 Human review
HIGHBulk export🟡 Human review
CRITICALDelete all data🔴 Blocked
PyPI v0.1.4 518+ tests MIT License Zero runtime deps <1ms eval Type-safe
Works with: LangChain CrewAI OpenAI Anthropic MCP AutoGen any Python agent

    $ pip install agent-aegis

    version: "1"
    rules:
      - name: read_auto
        approval: auto
      - name: write_review
        approval: approve
      - name: delete_block
        approval: block

    from aegis import Policy, Runtime

    policy = Policy.from_yaml("policy.yaml")
    async with Runtime(executor, policy) as rt:
        result = await rt.run_one(action)
        # result.is_allowed → True/False

    $ docker run -p 8000:8000 \
      -v ./policy.yaml:/app/policy.yaml \
      ghcr.io/acacian/aegis:latest
    # REST API at http://localhost:8000

30s to install
2 min to first policy
0 config files needed
1 dep only PyYAML

- No agent changes — wrap existing code, don't rewrite it
- Hot-reload policies — update rules without restarting your app
- Audit everything — every decision logged for compliance
- Type-safe — full type annotations, works with mypy and pyright

See it in action — no install required

## Real-World Scenarios

Click any scenario to load its policy and test actions

## Why Aegis?

The difference between hoping your AI agent behaves and knowing it does

| Without Governance | With Aegis
--- | --- | ---
Policy changes | Redeploy code | Edit YAML, hot-reload
Risk evaluation | Manual if/else chains | <1ms, declarative rules
Audit trail | Build your own logging | Built-in, compliance-ready
Human approval | Custom workflow code | One-line approval handler
Framework support | Build per framework | 7 adapters, one policy
Setup time | Days to weeks | 5 minutes

0 actions evaluated in this session

## Ready to govern your AI agents?

Add governance to any Python AI agent in 5 minutes. One pip install, one YAML file.

Star on GitHub Read the Docs