Navigation

Agent Landscape #1: The 5 Things Every Production Agent Needs

· 12 min read· Agentic AI
agentsandboxmemoryorchestrationmicrovm
Agent Landscape #1: The 5 Things Every Production Agent Needs

TLDR: Every production agent needs 5 components: orchestration (reasoning loop), durable state (survive crashes), memory (3-tier: working + long-term + session), sandboxed execution (isolated tool runtime), and multi-agent coordination (MCP/A2A/AG-UI). No single project covers all 5 — OpenClaw (378k), Hermes (190k), and AgentScope (26k) come closest at 4/5. The hard problems are distributed systems problems applied to a new domain.


The Problem

You can build a working AI agent in 50 lines of Python:

while True:
    response = llm.chat(messages, tools=tools)
    if response.tool_calls:
        for call in response.tool_calls:
            result = execute_tool(call)
            messages.append(result)
    else:
        break

This works in a demo. In production, it fails in five specific ways:

  1. The loop has no memory of itself. Restart the process and all progress is lost.
  2. The context window overflows. After 50 tool calls, the model forgets why it started.
  3. Tools run in the same process. A hallucinated os.remove("/") executes with full permissions.
  4. One agent can’t do everything. Complex tasks need specialized sub-agents that coordinate.
  5. The reasoning loop itself is fragile. No structured error handling, no retries, no multi-step planning.

Every team discovers these in production — usually in this order. After analyzing every relevant open-source project (totaling 3.0M+ GitHub stars across 11 categories), one pattern emerged: each project solves 1-2 of these problems excellently.


Component 1: Orchestration — The Reasoning Loop

The Problem

A raw LLM API call returns text. An agent needs to:

  • Decide whether to call a tool or respond
  • Parse tool arguments reliably (structured output, not regex)
  • Handle tool failures (retry? skip? escalate?)
  • Plan multi-step sequences (not just react to the last result)
  • Know when to stop (avoid infinite loops)

Without orchestration, you get agents that hallucinate tool calls, loop forever, or crash on the first error.

What’s Actually Needed

Orchestration Loop

The key architectural decisions:

  • How to represent control flow: Graph (LangGraph), roles (CrewAI), typed functions (PydanticAI), self-organizing (Hermes)
  • How to enforce structured output: JSON schema (most), Pydantic models (PydanticAI), code-as-output (Smolagents)
  • How to handle multi-agent: Shared memory (dangerous), message passing (AutoGen), delegation (DeerFlow/Hermes), handoff (Swarm)

How Projects Solve This

ApproachProjectsPatternTrade-off
Graph-basedLangGraph (34k)Nodes = functions, edges = control flow. State propagates through graph.Most expressive, steepest learning curve
Role-basedCrewAI (53k), MetaGPT (68k)Agents have roles/goals. Crews collaborate on tasks.Intuitive but shallow — hard to control fine-grained logic
Type-safePydanticAI (17k)Typed inputs/outputs, dependency injection for toolsBest DX, single-agent only
Self-improvingHermes (190k), OpenClaw (378k)Agent extracts skills from experience, improves over timeMost powerful long-term, hardest to debug/audit
Code-as-actionSmolagents (28k)LLM writes Python as its “tool”, executed in sandboxMaximally flexible, harder to constrain
VisualDify (145k), n8n (192k)Drag-and-drop workflow builderFastest to prototype, limited for complex logic

The gap: Every framework handles the “happy path” well. The difference shows in error recovery, loop control, and what happens when the LLM returns something unexpected. Most frameworks offer some error handling (PydanticAI retries on validation failure, CrewAI retries/delegates failed tasks, Smolagents feeds execution errors back to the LLM) — but LangGraph and AgentScope provide the most granular control: node-level error routing, configurable retry policies with backoff, and fallback edges.


Component 2: Durable State — Surviving Crashes

The Problem

Your agent has been working for 30 minutes. It’s made 47 tool calls, gathered data from 12 APIs, and is about to execute the final step. Then:

  • The process OOMs
  • A deploy restarts the container
  • The network partitions

All work is lost. The user starts over. Or worse: the agent partially executed something (sent half an email, created 3 of 5 resources) and now the system is in an inconsistent state.

What’s Actually Needed

Event-Sourced State

The critical subtlety for agents: LLM calls are non-deterministic. Traditional event sourcing replays by re-executing. Agent event sourcing must cache the LLM response — replaying the same prompt might produce a different plan.

How Projects Solve This

ApproachProjectsPatternTrade-off
Full event sourcingTemporal (21k)Every decision recorded in event history. Replay on crash.Gold standard durability, but requires Temporal Server + determinism constraint awkward for LLM calls
Step-level cachingInngest (5k)Each step.run() cached individually. Crash → restart from last cached step.Serverless-friendly, simpler, but coarser granularity
CheckpointLangGraph (34k)Periodic state snapshots. Resume from last checkpoint.Simple, but loses inter-checkpoint state
Session-basedAgentScope (26k), OpenClaw (378k)Session state persisted to DB. Resume by reloading session.Practical, but no event-level granularity
NoneCrewAI, PydanticAI, Agno, most frameworksNo persistence. Crash = start over.Fine for short tasks, fatal for anything >5 minutes

The gap: Agent-native event sourcing — durability that understands LLM calls are non-deterministic, context windows need compression on replay, and tool calls have schemas that can be validated on resume — remains an open problem.


Component 3: Memory — Beyond Context Window Overflow

The Problem

Context windows are finite. GPT-4o: 128k tokens. Claude: 200k tokens. Sounds like a lot — until your agent:

  • Has a 10-turn conversation with tool results (easily 50k tokens)
  • Needs to reference facts from 3 sessions ago
  • Must remember user preferences across weeks of interaction
  • Accumulates knowledge that should persist forever

When the window fills, the model either truncates (loses critical early context), summarizes (loses detail), or fails. Without memory management, agents degrade predictably: they forget their own instructions, repeat failed approaches, and lose user trust.

What’s Actually Needed

Three-Tier Memory

The key question: who manages memory? Two schools:

  • Passive: The system automatically manages memory (truncate, summarize, embed). Simple but loses nuance.
  • Agent-managed: The agent explicitly reads/writes/forgets memory as tool calls. More powerful but adds complexity to every interaction.

How Projects Solve This

ApproachProjectsPatternTrade-off
Agent-managed (explicit)Letta/MemGPT (23k)Agent calls write_memory(), search_memory(), forget() as tools. Sleep-time consolidation.Most sophisticated, but requires running Letta server
Self-improving memoryHermes (190k), OpenClaw (378k)Agent extracts “skills” from experience, stores in skill library, retrieves on similar tasksAgents get better over time, but hard to audit what was learned
Bolt-on layerMem0 (58k)m.add(fact), m.search(query) — framework-agnostic memory APIEasiest integration (3 lines), but external to reasoning loop
Checkpoint-basedLangGraph (34k)Graph state persisted at checkpoints. Working memory only.Simple, no long-term memory
Vector DB (raw)Chroma (27k), Qdrant, LanceDBStore embeddings, answer similarity queriesPlumbing, not solution — no memory lifecycle management

The gap: No project cleanly separates the three tiers while letting the agent control all of them. Letta comes closest but requires buying into their platform. Mem0 solves storage but not working-memory management.


Component 4: Sandboxed Execution — Isolating Dangerous Actions

The Problem

Agents call tools. Tools execute real actions: run code, call APIs, modify databases, send emails. The failure modes:

  1. Hallucinated dangerous commands: rm -rf /, DROP TABLE users, kubectl delete namespace production
  2. Data exfiltration: Agent sends sensitive data to an external endpoint
  3. Resource exhaustion: Infinite loop burns $10k in compute before anyone notices
  4. Privilege escalation: Tool inherits the agent’s full permissions instead of scoped access

Most agent frameworks run tools in the same process as the agent — same permissions, same network access, same trust boundary. A hallucinated action executes with full authority.

What’s Actually Needed

Sandboxed Execution

How Projects Solve This

ApproachProjectsPatternTrade-off
MicroVM sandboxE2B (12k)Firecracker microVM per execution. Own filesystem, network, process space. ~150ms boot.Strongest isolation, managed-only, cost per hour
Container sandboxDaytona (73k)Container with snapshot/restore. <90ms boot. MCP-native.Fastest, self-hostable, slightly weaker isolation than VM
Docker per-callAgentScope (26k), OpenClaw (378k)Fresh container per tool execution with scoped env varsSelf-hostable, familiar, slower cold start (1-5s)
Serverless functionModal, Lambda, Fly.ioDecorated functions run in cloud isolationPay-per-second, GPU access (Modal), vendor lock-in
Code sandbox onlySmolagents (28k)Python code executed in restricted interpreterLightweight but only covers code, not API calls
NoneLangGraph, CrewAI, PydanticAI, most frameworksTools run in-process, same permissions as agentZero latency, zero safety

The gap: Sandboxing projects don’t integrate with agent frameworks. Framework projects don’t provide sandboxing. You always glue them together yourself — and the integration surface (credential passing, result serialization, timeout handling) is where bugs hide.


Component 5: Multi-Agent Coordination — Agents Talking to Everything

The Problem

A single agent hits limits:

  • Context window: One agent can’t hold a 200-page codebase + conversation + tool results
  • Specialization: A research agent needs different tools and prompts than a coding agent
  • Parallelism: Sequential tool calls are slow; parallel sub-agents are fast
  • Cost: Routing simple queries to GPT-4 wastes money; a triage agent can delegate to cheaper models

But coordination introduces new failures:

  • How do agents discover each other’s capabilities?
  • How do you prevent infinite delegation loops?
  • How do you share context without shared mutable state?
  • Who handles failures in sub-agents?

What’s Actually Needed

Multi-Agent Coordination

How Projects Solve This

ApproachProjectsPatternTrade-off
Protocol-based (MCP)Claude Code (130k), Cursor, ZedStandard tool interface — any MCP server works with any MCP clientUniversal but no auth/billing standard yet
Protocol-based (A2A)Google ADK (20k), BeeAIAgent Cards for discovery, task delegation with lifecycleCross-framework but still maturing
Event busAutoGen (59k)Agents publish/subscribe to topics via gRPCTrue distributed, but complex ops
Sub-agent delegationDeerFlow (70k), Hermes (190k)Parent spawns children with scoped contextSimple, but single-framework only
HandoffSwarm (20k), OpenAI Agents SDK (27k)Agent transfers conversation control to specialistLow overhead, but limited to sequential delegation
Multi-agent routingOpenClaw (378k)Isolated agents per channel/account, gateway routesGood for personal multi-agent, not for inter-org
Role-based crewCrewAI (53k)Define roles + goals, framework coordinatesIntuitive but shallow coordination

The gap: Protocols define how agents communicate, but not how to handle failures, budgets, or trust between agents from different organizations. The “service mesh for agents” — discovery, load balancing, circuit breakers, mutual auth — doesn’t exist yet.


The Integration Map

Production Agent System - Integration Map


Who Covers What

No project spans all 5. Here’s the honest coverage map:

ProjectStarsOrchestrationDurabilityMemorySandboxingCoordination
OpenClaw378kYesSessionSkillsDockerMulti-agent routing
Hermes190kYesSkillsSelf-improving6 backendsSubagents
AgentScope26kYesSessionBasicDocker/E2BPipeline + MCP + A2A
LangGraph34kYesCheckpoint--Graph-based
Dify145kYesDBRAGCode sandboxWorkflows
CrewAI53kYes---Roles
Temporal21k-Full event sourcing--Child workflows
Letta23kBasic-Full 3-tier--
E2B12k---Full VM isolation-
Daytona73k-Snapshot-Container + MCP-

The closest to “complete”:

  • OpenClaw (378k) — covers 4/5 for personal use, but not enterprise multi-tenant
  • AgentScope (26k) — covers 4/5 with K8s deployment, but Alibaba ecosystem defaults
  • Hermes (190k) — covers 4/5 with self-improvement, but pre-1.0 APIs

All three still lack full event-sourced durability.


The Full Landscape at a Glance

CategoryTop projects (by stars)Combined stars
Agent FrameworksOpenClaw, AutoGPT, Hermes, DeerFlow, MetaGPT, AutoGen, CrewAI, LangGraph, Swarm~1.0M
LLM ToolkitsLangChain, LlamaIndex, DSPy, Haystack~250k
Visual / Low-CodeDify, n8n, Langflow, Flowise~540k
Coding AgentsClaude Code, Gemini CLI, OpenHands, Open Interpreter, Aider~450k
Web/ToolsFirecrawl, Browser Use, Crawl4AI, Composio, Skyvern~350k
MemoryMem0, Letta~80k
SandboxingDaytona, E2B~85k
ProtocolsMCP servers, A2A, AG-UI~125k
DurabilityPrefect, Temporal, Inngest~48k
Platform SDKsVercel AI, Semantic Kernel, AWS Strands, Cloudflare, Google ADK~84k
ObservabilityLangfuse, LangSmith, Arize Phoenix, AgentOps~45k

Total landscape: 60+ projects, 3.0M+ stars, 11 categories.


What This Means for Builders

If you’re evaluating frameworks: Ask which of the 5 components they cover. Most cover 1-2. The “Who Covers What” table above is your starting point.

If you’re building agents today: Pick orchestration first (Hermes for self-improving, LangGraph for flexible, AgentScope for all-in-one). Then add durability and sandboxing as first infrastructure investments. Accept 3-4 project integrations minimum.

If you’re building agent infrastructure: The opportunity is a unified platform that co-designs all 5 layers — with pluggable backends for laptop, Docker, Kubernetes, and serverless. This is the “Kubernetes for agents” opportunity.


The Deeper Pattern

The hard problems in agent engineering are distributed systems problems applied to a new domain:

Agent ProblemDistributed Systems Equivalent
Survive crashesEvent sourcing, write-ahead log
Memory managementTiered storage, caching, eviction
Tool isolationContainer orchestration, sandboxing
Agent coordinationService mesh, message bus, discovery
Non-deterministic replayIdempotency, cached side effects

We’ve solved all of these before. The industry just hasn’t applied them to agents in a unified way yet.


Next: Agent Landscape #2: Orchestration — Pick Your Reasoning Loop