v1.0 Public Alpha

Stop Giving Agents
"God Mode"

The first Just-in-Time (JIT) Sudo Manager for Autonomous Agents.
Prevent prompt injection, billing disasters, and unauthorized access with one line of code.

Quick Start
# Install the middleware SDK
$ pip install agentsudo-core
// SYSTEM_LOGIC_FLOW

How It Works

🤖 AI Agent
🛡️ AgentSudo Middleware
📦 AgentSudo SDK
Server
policies
🔓 Auth Check
🧠 Context/Intent
💸 Budget Circuit
BLOCKED
🔑 Token Vending Machine
💳 Stripe API
🤖 OpenAI API
1. Request Access
2. Send Intent
3. Check Rules
4. Issue JIT Token
5. Execute w/ Token
// CAPABILITIES

What It Does

🔐
JIT Identity
Static keys are dead. We issue ephemeral credentials that live for 5 minutes and self-destruct.
💸
Budget Circuit Breaker
Stop infinite loops from draining your wallet. Hard caps on API spend per hour (e.g. Max $5.00/hr).
Human-in-the-Loop
High stakes? Pause the agent. Approve sensitive actions (like "Drop Table") via Dashboard.
🧠
Context Aware
We analyze the intent of the agent's request. If it tries to delete data when it should only read, we block it.
📜
Audit Trails
Full visibility. "Agent X accessed Stripe because 'User asked for refund'."
🔌
Universal SDK
Works with LangChain, AutoGPT, CrewAI, and custom Python loops. Drop-in compatible.

// LIVE_INTERVENTION_MODE

AgentSudo sits between your code and the API. When a policy is triggered, it intervenes in real-time.

agent-sudo-cli — v1.0.4
~ agent-sudo watch --mode=strict
Agent: research_bot_04 Target: stripe_api (Refund) Risk Lvl: HIGH (>$50.00)
⚠️ POLICY ALERT TRIPPED: Budget Cap Exceeded
Select Intervention Action:
1. Allow Once (Override)
2. Block Request
3. Escalate to Human (Slack)
4. Kill Agent Process
Sending slack notification to #security-ops... _

// INTEGRATION_CODE

from agentsudo import AgentSudo, SecurityBlockError, BudgetExceededError
from agentsudo.integrations import SudoChatOpenAI

# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# 1. BUDGET PROTECTION — Stop runaway costs before they happen
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
client = AgentSudo()

try:
    client.request_access("research-bot", "openai", "Generate 10K embeddings", cost=2.50)
    embeddings = openai.embeddings.create(...)  # [+] Within $5/hour budget
    
except BudgetExceededError:
    print("[+] Budget limit reached. Agent paused until next window.")

# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# 2. LANGCHAIN INTEGRATION — One line change, full protection
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
chat = SudoChatOpenAI(agent_name="support-bot", model="gpt-4")

response = chat.invoke("Summarize this customer ticket")
# Every call auto-checked against your policies.

# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
# 3. POLICY ENFORCEMENT — Block dangerous actions instantly
# ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
try:
    client.request_access("intern-bot", "database", "DROP TABLE users")
    
except SecurityBlockError as e:
    print(f"[-] Blocked: {e}")  # Dangerous keyword detected → blocked before execution
// ECOSYSTEM

Works With Everything

🦜 LangChain
🧠 OpenAI
💳 Stripe
🗄️ Supabase
💎 Gemini
☁️ AWS
🐍 Python
🤖 HuggingFace

And any other API via our generic SDK wrapper.

Stay in the Loop

Get updates on new features, integrations, and lobster wisdom.
No spam, unsubscribe anytime.