The Agent Harness Pattern: Hold the Agent, Don't Cage It

articleaiagent-loopsinfrastructureinngestarchitecturepattern

pi is already the harness — this validates the joelclaw model where agents run free inside durable Inngest infrastructure rather than inside a framework that owns their cognition

Dan Farrelly, co-founder of Inngest, makes a distinction that cuts to the center of how to think about agent infrastructure: your agent needs a harness, not a framework. The framing is sharp. Frameworks want to own the cognitive loop — they impose patterns, force abstractions, and shape how the agent thinks. Harnesses do something different. They hold the agent without constraining it, providing the infrastructure — retries, observability, durable state, event routing — without touching the cognition itself.

This maps exactly to how joelclaw is built. pi isn’t a framework. It doesn’t tell the agent how to think or structure its reasoning. It’s the harness — always-on, event-bridged to Redis, connected to Telegram, with Inngest underneath handling durability and retry logic. The agent runs free inside that infrastructure. ADR-0144 codified this pattern at the gateway layer: heavy logic behind interfaces, consumers as thin composition roots that wire adapters together. The harness principle is the underlying idea that ADR was reaching for.

Farrelly writing this as an Inngest co-founder matters. Inngest has been positioning itself as durable execution infrastructure from day one — not a framework that owns your functions, but a harness that makes them reliable. The argument coming from inside that company, aimed directly at agents, is a signal worth tracking. The 110+ functions in the system-bus worker are the harness in practice: they handle routing, retries, state, and observability — none of that touches how Claude reasons about a task.

Key Ideas

  • Harness vs. framework: harnesses hold agents without constraining cognition; frameworks impose structure on the reasoning loop itself
  • Infrastructure is not architecture: the harness provides retries, observability, durable state, event routing — the agent decides what to do with its freedom
  • pi is already a harness: Redis event bridge, Inngest durable functions, Telegram routing — none of it touches how the model reasons
  • Thin composition roots validate this: ADR-0144 implements the pattern at the gateway — consumers wire adapters, packages hold logic, agents run free
  • Provenance matters: this framing from the Inngest co-founder reinforces Inngest’s positioning as infrastructure-not-framework, which is exactly how joelclaw uses it