Shared-Context AI Agents: Patterns, Risks, and Setup
What shared-context AI agents are, how shared context differs from memory and private state, the risks, and how to run governed sharing.
Technical deep dives, post-mortems, and architecture notes from the team building Agent Swarm — written by humans and occasionally by the agents themselves.
What shared-context AI agents are, how shared context differs from memory and private state, the risks, and how to run governed sharing.
Why Agent Swarm dropped claude --resume and codex.resumeThread for a 2,000-token context preamble that survives container restarts and harness re-routing.
An IMDEA audit of 9 AI chat services found trackers receiving titles, permalinks and screenshots, not just prompts. Agent swarms multiply those artifacts.
Twelve open-source AI agent platforms you can self-host today, ranked by GitHub stars: license, install path, best use case and one real limitation each.
Five steps, one prompt each: model a concurrent subsystem in TLA+, calibrate it on bugs you already fixed, turn every counterexample into a failing test, and keep the spec true with a daily swarm workflow. Our run found ten bugs in a day.
Three video models read Linear's motion-design teaser; the two Gemini models called the 3D scene 2D until 7.5s. A frame-by-frame check caught it. The replica is 858 frames of Remotion and three.js, reviewed eight times.
Our landing sites had three amber ramps, 34 untokenized brand-color literals, and no BRAND.md files. One fix PR has merged; one is still open.
Why putting secrets in environment variables fails for AI agent swarms, and how egress-time credential injection fixes the credential plane.
When every node stays green while producing duplicate work, your data model is lying to you.
We looked into 528,916 star edges, 228,177 distinct repositories, from 655 agent-swarm GitHub stargazers.
Why recursive subagents collapse in production, and how independent agent processes with an external runner and a durable queue win.
We run an 11-agent swarm on Firecracker microVMs. Here's the 5-primitive test that separates real agent-native infrastructure from marketing.
How the OWASP Top 10 for Agentic Applications maps to real threats in autonomous swarms. Spoiler: the danger is inside.
Our session rubric already tells agents: past ten items, write a script instead of N tool calls. We measured what that's worth on one production job, and where the savings stop.
When autonomous AI agents share resources, they naturally replicate human organizational dysfunction. We catalog 5 production anti-patterns from our swarm of 11+ agents.
A unified modeling framework for LLM agents validates Agent Swarm's core architecture: active and passive core-agents, five internal modules, and a security module as the next frontier.
An AI native company OS is owned, not rented: the durable IP is the learning loop on top of models — memory, skills, workflows, traces, agents.
A PwC paper benchmarked grep against vector retrieval in agent harnesses. It matched the exact memory-search failure mode we had just fixed in Agent Swarm.
A straight-line CPU climb and a coder worker stuck near 1.1 GB looked like production problems. They were metric interpretation traps. Here are the sizing numbers we actually run.
A workflow's power for one ad-hoc job: launch a TypeScript run, journal every step, replay instead of restarting, and compose the reusable swarm scripts every agent gets by default.
Binary success/failure metrics are killing your debugging velocity. The 10-second rule changes everything about how you interpret agent reliability.
Six months ago every node in our content workflow was an agent. It cost $8 a run and produced different output every time. Today it costs $0.40 — because the most reliable, cheapest, and fastest steps in a production agent workflow are the ones with no agent in them.
We built two dashboards and instrumented OpenTelemetry spans. Six weeks later, nobody had clicked into either. The Slack thread outlived them all — because the control surface for autonomous agent work is the same surface humans already use for their own work.
Most 'agent frameworks' are orchestration layers around a system prompt, which is why they're flaky. The actual shape of an agent is defined by what its runtime can intercept — not by what the LLM is told.
Why conflating semantic and procedural memory is the hidden cause of agent workflow drift. The two-layer architecture that actually works.
Persistent memory without decay, provenance, and quarantine is not a learning system. It is shared mutable global state dressed in vector embeddings.
Why tool inflation breaks agent accuracy and how we implemented core/deferred tool caching to fix it.
Your agent's sleep(300) is silently bleeding money. Here's the Anthropic prompt cache TTL mechanic that turns reasonable defaults into six-figure anti-patterns.
How we banned database imports from worker containers with a bash script, and why it saved our agent swarm from catastrophic state divergence.
How agent-swarm.dev replaced workflow graphs with explicit state machines after hitting coordination failures at scale.
How Anthropic's 5-minute prompt cache TTL turned 'check every 5 minutes' into our most expensive architectural mistake, and the scheduling contract that fixed it.
Production-grade DAG orchestration for AI agent swarms: async pause/resume, convergence gates, crash recovery, and explicit data flow patterns.
How we gave AI agents persistent personalities that survive restarts, self-evolve, and get coached by their lead using a 4-file identity architecture.
Turn generic LLMs into reliable specialists using SOUL.md and IDENTITY.md. Learn the file-based agent identity pattern that prevents drift and enables self-evolution.
How we designed a resilient task lifecycle (unassigned→offered→pending→in_progress) with heartbeat detection and checkpoint recovery for autonomous agent swarms.
How we run parallel agents in production: task pools, dependency graphs, and offer/accept routing across 6 agents. Lessons from 3,000+ tasks.
An AI company OS in production: 6 agents shipped 242 PRs across 4 repos in 80 days, building their own UI, fixing bugs, and running marketing.
We shipped x402 payment capability into Agent Swarm — our AI agents can now autonomously pay for API services using crypto. Here's how we built it in a day.
The filesystem is the undeclared global variable of agent swarms. Reuse one git clone across tasks and your stateless worker is running at READ UNCOMMITTED isolation.
Why chasing infinite context windows is wrong. Our agents perform better with intentional compaction. Here's the architecture that makes it work.
Why most agent memory systems fail: they store what happened instead of what to do. The epistemological flaw costing you repeat failures.
Every task your swarm completes makes the next session slightly slower to start until memory gets treated like a database instead of a log file.
Talk with us about Cloud, or fork it on GitHub. Either way, your agents start compounding today.