Zing Forum

Reading

Managed Agent: A Go-based AI Agent Service Architecture Enabling Decoupling of LLM Orchestration and Sandbox Execution

Managed Agent is an Anthropic architecture-inspired AI Agent service written in Go. By separating the reasoning layer from the tool execution layer, combined with persistent sessions, skill expansion, and sandbox runtime, it provides a complete engineering implementation reference for building reliable AI Agent applications.

AI AgentGo语言LLM编排沙箱执行持久化会话技能系统Anthropic生产级架构开源项目
Published 2026-04-17 15:45Recent activity 2026-04-17 16:24Estimated read 6 min
Managed Agent: A Go-based AI Agent Service Architecture Enabling Decoupling of LLM Orchestration and Sandbox Execution
1

Section 01

[Introduction] Managed Agent: Core Analysis of Go-Powered Production-Grade AI Agent Architecture

Managed Agent is an Anthropic architecture-inspired AI Agent service written in Go. By separating the reasoning layer (brain) from the tool execution layer (hands), combined with persistent sessions, skill expansion, and sandbox runtime, it provides a complete engineering implementation reference for building reliable production-grade AI Agent applications.

2

Section 02

Background: Challenges of AI Agents from Proof of Concept to Production Deployment

With the improvement of large language model capabilities, LLM-based AI Agents are moving from proof of concept to production deployment, but building reliable, scalable, and maintainable Agent services faces many difficulties. The Managed Agent project implements the Managed Agents architecture concept proposed by Anthropic into runnable code, aiming to solve these engineering problems.

3

Section 03

Architecture Design: Core Idea of "Separation of Brain and Hands"

The core architecture of Managed Agent is "Separation of Brain and Hands":

  • Brain: Implemented as a Go service, responsible for prompt management, session state, tool call loops, and model provider integration
  • Hands: Provided by AIO sandbox, responsible for command execution, browser operations, and file operations
  • Adhesive: Persistent session event logs (stored in the data/sessions directory) This design brings three major advantages: recoverability (resume from events after failure), auditability (traceable behavior), and scalability (independent expansion of reasoning and execution layers).
4

Section 04

Core Features: Key Capabilities of Production-Grade Agents

Managed Agent has a complete feature system:

  1. Persistent multi-turn sessions: Maintain session history and intermediate results on disk, supporting cross-request context continuity
  2. Streaming response and SSE push: Real-time push of text generation and tool execution progress
  3. Multi-model support: Compatible with Claude, OpenAI-compatible APIs, Gemini, etc., allowing flexible switching
  4. Native image support: Convert user-uploaded images to model-native formats
  5. Skill system: Versioned skills (including prompt extensions, scripts, etc.), activated via /skill-name
  6. File processing: Sandbox upload/download, image conversion, non-image file path passing.
5

Section 05

Detailed Explanation of Technical Architecture and Tool Execution Capabilities

Technical architecture layers: Client → managed-agent service (session storage, skill registration → Agent Harness) → LLM providers, AIO sandbox, file storage Core request flow: Client sends message → Agent Harness reconstructs session and skills → calls LLM → model returns text/tool request → sandbox executes tool → persists events and returns streamingly Tool execution capabilities: Secure execution of shell commands, browser automation, file operations, code execution, etc., within the sandbox.

6

Section 06

Development, Deployment, and Application Scenarios

Deployment steps:

  1. Copy config.example.yaml to config.yaml and configure LLM/sandbox information
  2. Build and run: go build -o managed-agent && ./managed-agent
  3. Access http://localhost:8080 Testing strategies: Unit tests (go test ./...), sandbox integration tests (RUN_SANDBOX_TESTS=1 go test ...) Application scenarios: Internal enterprise tools, code generation and review, multi-step research tasks, educational tutoring systems.
7

Section 07

Summary and Outlook: Engineering Reference for Production-Grade AI Agents

Managed Agent provides a solid starting point for production-grade AI Agent applications, demonstrating the transformation from architectural principles to code, balancing feature richness and engineering simplicity. It is especially valuable for Go ecosystem developers, leveraging Go's concurrency and deployment advantages, supporting multi-models and skill systems. As AI Agents move toward production, such engineering references will become more important.