Deep-Dives / Architectures & Patterns
Architectures & Patterns
Reusable agent architectures — ReAct, plan-and-execute, supervisor-worker, router, reflection — and when each fits.
- The Agent Design-Pattern LandscapeWhy architecture is a reliability lever, and the five axes that compare every pattern.
- ReAct — Interleaving Reasoning and ActingThe workhorse tool loop: control flow, why interleaving wins, and the failure modes at scale.
- Plan-and-Execute — Decompose, Then RunPlanner/executor split, replanning strategies, and when the up-front plan becomes a liability.
- Reflection — Verify, Critique, ReviseSelf-refine vs Reflexion, why the external signal is everything, and when self-critique hurts.
- Search Strategies — Branching Over TrajectoriesBest-of-N, self-consistency, tree/graph-of-thought: the cost regime and the scorer dependency.
- Routing & Dispatch — Selection, Fan-out, ParallelismClassifier vs tool-call routing, parallel fan-out, and the failure modes of the routing layer.
- Tool-Use Loops & Error RecoveryThe failure taxonomy, layered recovery, error-messages-as-prompts, and side-effect durability.
- Single-Agent vs. Multi-Agent OrchestrationReal reasons to split, supervisor/worker vs hand-off, the coordination tax, and a decision framework.
- Durable Execution: LangGraph + TemporalCheckpointer-between-nodes vs Temporal-within-node — replay semantics, why LangGraph loops don't survive at 10k items, and the 'reasoning graph + durable runtime' pattern.
- Context Caching EconomicsCross-vendor cache pricing (Anthropic 1.25x write / 0.1x read; Gemini 90% off; OpenAI automatic 75-90%), TTL trade-offs, and how caching plus batch stacks to ~95% off list.
- Browser Agent Failure ModesThe six failure modes WebArena does not catch — DOM drift, screenshot ambiguity, login state, modal interruptions, rate-limit cliffs, irreversibility.
- Claude Managed Agents: ArchitectureDurable session as append-only event log, stateless harness, wake(sessionId) recovery — and what the pattern gives up.
- On-Device Agent ArchitectureLocal inference buys zero marginal cost, no network in the inner loop and offline operation — and not privacy, because the tools still egress. Split the loop five ways, escalate on a static list of action properties, and treat the device edge as a performance boundary that only looks like a security one.
- The Deterministic Boundary for Finance Agents“Deterministic AI” bundles four properties, and the three a finance process needs (replay, exact computation, rule-made decisions) come from code and records, not from the model. Place each step by what its output does, do the compounding arithmetic, and check the mistakes specific to financial data.
- Deterministic Finance Workflows in Code: Before, After & LibrariesA 406-line bank reconciliation handed to three Claude models was right 21 times in 25, and all 25 answers said the difference was 0.00. Rebuilt so code matches, computes and gates sign-off while the model proposes pairs for 12 lines, all six runs gave the same result, with tests and a measured library evaluation.