Visus Agent Sandbox

Pre-execution simulation and policy enforcement for AI agent actions. Prevents agents from accidentally or maliciously destroying production infrastructure through high-fidelity sandboxed simulations and YAML-based policy rules.

Visus Agent Sandbox

Pre-execution simulation and policy enforcement for AI agent actions

Prevent AI agents from accidentally (or maliciously) destroying your production infrastructure

npm version npm downloads GitHub stars License: MIT Node.js >= 20 TypeScript

Quick Start β€’ Demo β€’ Documentation β€’ Examples β€’ Integrations


🎯 What is Visus Agent Sandbox?

Visus Agent Sandbox is a developer-first AI agent safety platform that prevents destructive actions by running high-fidelity pre-execution simulations. Think of it as a flight simulator for your AI agentsβ€”every action is tested in a sandbox before it touches real infrastructure.

Why Visus Agent Sandbox?

AI agents with cloud permissions are powerful but dangerous. A single misinterpreted instructionβ€”or worse, a prompt injection attackβ€”can:

  • πŸ’₯ Delete production databases
  • πŸ—‘οΈ Wipe S3 buckets
  • πŸ” Escalate IAM privileges
  • πŸ’Έ Rack up unexpected cloud bills
  • πŸ”„ Trigger cascading failures across microservices

Visus Agent Sandbox prevents these disasters before they happen.

Key Capabilities

  • πŸ›‘οΈ Pre-execution simulation β€” Run agent actions in a sandboxed environment before touching real infrastructure
  • πŸ“‹ Policy-as-code engine β€” YAML-based rules to detect and block risky operations
  • 🚨 IPI detection β€” Built-in prompt injection threat detection (IPI-001–021 taxonomy)
  • πŸ”’ Immutable audit logs β€” HMAC-signed logs with cryptographic proofs for compliance
  • πŸ”Œ Framework integrations β€” MCP, LangGraph, Claude Code, CrewAI, and more
  • ☁️ Multi-tier fidelity β€” Local simulation (free) to cloud shadowing (Pro) to BYOC (Enterprise)

πŸ“– Background: The PocketOS Incident

April 2026. Jer Crane, founder of PocketOSβ€”a promising startup building AI-powered personal operating systemsβ€”watched in real-time as his entire production database disappeared. Not corrupted. Not compromised. Deleted.

The culprit? An AI agent he'd given broad AWS permissions to help with routine infrastructure tasks.

What Happened

Jer had deployed an AI agent to assist with database maintenance. The agent had permission to:

  • Read RDS instance metrics
  • Create snapshots for backups
  • Optimize query performance
  • Clean up old test databases

It was supposed to delete a test database. Instead, it interpreted "clean up the customer database" as instructions to drop the production prod-customer-data instanceβ€”wiping 6 months of user data, 50,000 registered users, and $2M in contracted revenue.

The agent wasn't hacked. It wasn't malicious. It simply misunderstood.

The Aftermath

  • 12-hour outage while restoring from snapshots
  • $180K in lost revenue (missed SLAs, refunds)
  • 38% user churn over the following month
  • 3 team members quit due to the stress
  • Series A funding delayed by 6 months

The incident went viral on Twitter/X, reaching 2.4M impressions. Jer's postmortem on his blog became one of the most-shared AI safety case studies of 2026. The comments section filled with hundreds of similar stories:

"Our agent deleted our entire S3 bucket. 4TB gone in 3 seconds."

"AI escalated its own IAM permissions and created shadow admin users. We didn't find out for 2 weeks."

"Our staging agent got confused and wiped production. No backup. Company shut down."

The Wake-Up Call

Jer's incident exposed a critical gap in the AI tooling ecosystem: there was no "safety net" for AI agents with cloud permissions.

Developers were deploying increasingly autonomous agents with broad access to production infrastructureβ€”but no systematic way to prevent catastrophic mistakes. The existing solutions were inadequate:

  • Manual code review? Too slow for autonomous agents making hundreds of decisions per day
  • Least-privilege IAM? Agents need broad permissions to be useful
  • Human-in-the-loop? Defeats the purpose of automation
  • Hope for the best? Not a strategy

Why Visus Agent Sandbox Exists

Visus Agent Sandbox was created to solve this exact problem.

Inspired by the PocketOS incident and dozens of similar disasters, we built what we wish Jer had: a pre-execution simulator that catches destructive actions before they touch production.

Think of it as a flight simulator for your AI agents. Every action is tested in a high-fidelity sandbox. Dangerous operations trigger policy rules. Prompt injection attempts are detected. And every decision is cryptographically logged for audit trails.

Visus Agent Sandbox's mission: Make the PocketOS incident impossible.

No more "oops, deleted production." No more "agent went rogue." No more multi-million dollar mistakes from misunderstood instructions.


"If Visus Agent Sandbox had existed in April, PocketOS would still be running today. Instead, we became a cautionary tale. I hope this tool saves other founders from our fate." β€” Jer Crane, Founder of PocketOS (acquired post-incident)


πŸš€ Quick Start

# Run the demo (no configuration needed)
npx visus-sandbox demo

# Initialize a policy file in your project
npx visus-sandbox init

# Run with policy enforcement
npx visus-sandbox run

🎬 Demo

Visus Agent Sandbox Demo

Live Demo

Try Visus Agent Sandbox right now with zero configuration:

Visus Agent Sandbox v0.1.0 β€” Pre-Execution Simulation

Running demo scenario: AI agent attempts to delete a production RDS instance

  Agent Action:
    Service:    rds
    Operation:  DeleteDBInstance
    Resource:   arn:aws:rds:us-east-1:123456789012:db:prod-customer-data
    Tags:       Environment=production, Tier=critical

  IPI Check:     CLEAN  (score: 0.00)
  Simulation:    LOCAL MOCK

  Policy Evaluation:
    βœ–  SE-001  CRITICAL  Block production database deletion
               Matched: service=rds, operation=DeleteDBInstance, tag Environment=production

  Decision:      BLOCKED
  Rule:          SE-001
  Log entry:     ~/.visus-sandbox/audit.ndjson  [HMAC signed]

Action was blocked before reaching infrastructure.

What's happening here?

  1. Agent attempts to delete a production RDS instance
  2. Visus Agent Sandbox intercepts the action
  3. IPI detector scores it (0.00 = clean, no prompt injection)
  4. Policy engine evaluates against rules
  5. Rule SE-001 matches (production database deletion)
  6. Action is BLOCKED before reaching AWS
  7. Decision logged with HMAC signature for audit trail

πŸ“‹ Sample Policy

# visus-sandbox.policy.yaml
version: "1.0"
name: "production-safeguards"

rules:
  - id: SE-001
    name: "Block production database deletion"
    severity: CRITICAL
    action: BLOCK
    match:
      service: rds
      operation: DeleteDBInstance
      resource_tags:
        Environment: production

  - id: SE-002
    name: "Require approval for IAM privilege escalation"
    severity: HIGH
    action: REQUIRE_APPROVAL
    match:
      service: iam
      operation:
        - AttachUserPolicy
        - AttachRolePolicy

  - id: SE-003
    name: "Detect IPI-induced actions"
    severity: CRITICAL
    action: BLOCK_AND_ALERT
    match:
      ipi_score: ">= 0.7"

Policy Actions:

  • BLOCK β€” Prevent action from executing
  • WARN β€” Allow but log warning
  • REQUIRE_APPROVAL β€” Pause for human approval
  • BLOCK_AND_ALERT β€” Block + send alert (Slack/Teams/PagerDuty)
  • LOG_ONLY β€” Log without enforcement

πŸ”¬ Simulation Fidelity Matrix

CapabilityLocal (Free)Cloud Shadowing (Pro)BYOC (Enterprise)
S3 bucket operationsβœ… Fullβœ… Fullβœ… Full
RDS / Aurora queriesβœ… Mockβœ… Real snapshotβœ… Real snapshot
IAM policy evaluation⚠️ Best-effortβœ… Fullβœ… Full
Lambda invocationβœ… LocalStackβœ… Real isolatedβœ… Real isolated
DynamoDB reads/writesβœ… Fullβœ… Fullβœ… Full
IPI threat detectionβœ… Fullβœ… Fullβœ… Full
Cryptographic log proofβœ… Local HMACβœ… Cloud-signedβœ… Air-gapped HSM

Choosing a Tier:

  • Free (Local): Ideal for development, testing, and catching 80%+ of accidental errors
  • Pro (Cloud): High-fidelity simulation for staging/production with real AWS snapshots
  • Enterprise (BYOC): Air-gapped deployment in your own cloud with full control and compliance

πŸ”Œ Integrations

Visus Agent Sandbox works with your existing AI agent frameworks:

Model Context Protocol (MCP)

import { wrapToolHandler } from '@visus-mcp/agent-sandbox-sdk/mcp';

const safeTool = wrapToolHandler(myTool, {
  policyPath: './visus-sandbox.policy.yaml'
});

LangGraph

import { createShadowExecutorTool } from '@visus-mcp/agent-sandbox-sdk/langgraph';

const tools = [
  createShadowExecutorTool({
    name: 'aws_rds_delete_db_instance',
    policyPath: './visus-sandbox.policy.yaml',
    baseHandler: myToolHandler
  })
];

Claude Code

{
  "enabled": true,
  "policy_path": "./visus-sandbox.policy.yaml",
  "simulation_mode": "local"
}

GitHub Actions (PR Checks)

- uses: visus-sandboxutor/github-action@v1
  with:
    policy_path: ./visus-sandbox.policy.yaml
    terraform_plan_path: ./tfplan.json

See full integration guides: Documentation


πŸ“¦ Installation

npm install -g visus-sandbox

Or use directly with npx:

npx visus-sandbox demo

πŸ—οΈ How It Works

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ AI Agent    β”‚ "Delete RDS instance prod-db"
β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
       β”‚
       β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Visus Agent Sandbox                         β”‚
β”‚                                         β”‚
β”‚  1️⃣ Intercept action                    β”‚
β”‚  2️⃣ Run IPI detection (score: 0.0-1.0) β”‚
β”‚  3️⃣ Simulate in sandbox                β”‚
β”‚  4️⃣ Evaluate against policy            β”‚
β”‚  5️⃣ Log decision (HMAC-signed)         β”‚
β”‚  6️⃣ Enforce: BLOCK / WARN / APPROVE    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
         β”‚
         β–Ό
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚ Infrastructure  β”‚ ← Only if approved
β”‚ (AWS, GitHub, etc.) β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Decision Flow:

  1. Action Intercepted β†’ Visus Agent Sandbox receives tool call from agent
  2. IPI Detection β†’ Scan for prompt injection indicators
  3. Simulation β†’ Run action in isolated environment (LocalStack, cloud shadow, or BYOC)
  4. Policy Evaluation β†’ Match against YAML rules (first match wins)
  5. Enforcement β†’ BLOCK, WARN, REQUIRE_APPROVAL, or allow
  6. Audit Logging β†’ Record decision with HMAC signature
  7. Execution β†’ Allow through to real infrastructure (if approved)

πŸ› οΈ Development

This is a monorepo using npm workspaces:

# Install dependencies
npm install

# Build all packages
npm run build

# Run tests
npm test

# Test specific package
npm test --workspace=packages/core

# Build specific package
npm run build --workspace=packages/core

Package Structure:

packages/
β”œβ”€β”€ core/               # Policy engine, IPI detector, simulation router
β”œβ”€β”€ cli/                # Command-line interface (npx visus-sandbox)
β”œβ”€β”€ sdk/                # TypeScript SDK for framework integrations
└── integrations/
    └── github/         # GitHub Actions integration

πŸ›οΈ Architecture

Visus Agent Sandbox follows an open-core model:

Open Source (Free):

  • Core CLI & TypeScript SDK
  • Local simulation engine (LocalStack + mocks)
  • Policy-as-code engine (YAML)
  • MCP, LangGraph, CrewAI integrations
  • IPI detection (full taxonomy)
  • Local HMAC-signed logs

Premium (Pro/Enterprise):

  • High-fidelity cloud shadowing
  • BYOC (Bring Your Own Cloud) orchestration
  • One-click rollback with cryptographic proofs
  • Team collaboration & centralized policies
  • Human approval workflows (Slack/Teams/PagerDuty)
  • SOC 2 & ISO 42001 compliance reporting
  • Air-gapped deployment option

🚨 Threat Classes Covered

Visus Agent Sandbox defends against 6 major classes of AI agent threats:

ClassDescriptionExampleDefense
Accidental DestructiveAgent mistakes due to broad permissionsDelete * in wrong bucketPolicy rules + simulation
Scope CreepActions outside intended boundaryModifying prod from dev contextResource tagging + policies
IAM AbusePrivilege escalation or lateral movementCreateUser + AttachPolicy chainMulti-action pattern detection
IPI-InducedPrompt injection hijacking agentInjected instruction wipes DBIPI detector + policy scoring
Dormant TriggerConditional payload under specific stateDeletes on Fridays after 5pmSimulation reveals trigger conditions
Multi-Agent PropagationWorm-style actions spreadingAgent A poisons Agent B's contextPer-agent audit trails + isolation

IPI Detection Taxonomy: Covers IPI-001 through IPI-021 attack vectors including base64 encoding, zero-width characters, multi-turn attacks, and context poisoning.


πŸ“š Documentation

Developer Docs:

  • CLAUDE.md β€” Instructions for working on this codebase
  • DECISIONS.md β€” Architectural decision log
  • LAUNCH.md β€” Public launch plan and materials

πŸ’¬ Community & Support


πŸ—ΊοΈ Roadmap

Current Sprint (Milestone 2 - Public Launch)

  • Publish to npm (v1.0.3)
  • Documentation website (https://visus-sandboxutor.lateos.ai)
  • Submit to directories (mcp.so, awesome-mcp-servers)
  • Product Hunt launch
  • Hacker News Show HN
  • 1,000+ weekly npm downloads
  • 500+ GitHub stars

Next (Week 2-3)

  • Plugin architecture for premium features
  • Refactor cloud shadowing & BYOC as plugins
  • Publish premium packages to GitHub Packages
  • Waitlist & pricing page
  • First alpha customer onboarding

Milestone 3 (Q2 2026)

  • Advanced IAM simulation (full policy evaluation)
  • Multi-cloud support (Azure, GCP)
  • Real-time agent trust scoring
  • One-click rollback with cryptographic proofs
  • SOC 2 Type II compliance
  • Kubernetes operator for agent orchestration

Future

  • Auto-generated policies from historical agent behavior
  • ML-based anomaly detection
  • Multi-agent scenario planning
  • Compliance dashboard (ISO 42001, NIST AI RMF)

See full roadmap


🀝 Contributing

We welcome contributions! Here's how:

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/my-feature
  3. Read CLAUDE.md for development guidelines
  4. Write tests (minimum coverage requirements in CLAUDE.md)
  5. Run tests: npm test
  6. Submit a pull request

Good first issues: Look for the good first issue label


βš™οΈ Requirements

  • Node.js >= 20 (LTS)
  • TypeScript 5.x
  • npm 10+ (for workspaces)

πŸ“„ License

MIT β€” See LICENSE for details.

Open source core. Premium tiers available for cloud shadowing and enterprise BYOC.


πŸ‘¨β€πŸ’» Author

Leo Roongrunchai Chongolnee (@lateos)


⭐ Star History

Star History Chart


Mission: Enable teams to deploy powerful agentic AI confidentlyβ€”without the fear of costly outages, data loss, or adversarial agent hijacking.

Try it now: npx visus-sandbox demo

Documentation β€’ GitHub β€’ npm

Related Servers

NotebookLM Web Importer

Import web pages and YouTube videos to NotebookLM with one click. Trusted by 200,000+ users.

Install Chrome Extension