[{"data":1,"prerenderedAt":235},["ShallowReactive",2],{"profile":3,"writing-agentic-architecture-patterns":14},{"name":4,"role":5,"tagline":6,"location":7,"contact":8},"Sankar Vema","AI Builder & Architect of Agentic Systems","I help enterprise leaders turn AI ambition into capability that actually ships.","India · open to global advisory engagements",{"email":9,"linkedin":10,"github":11,"blog":12,"twitter":13},"sankar.vema@gmail.com","https:\u002F\u002Fwww.linkedin.com\u002Fin\u002Fsankarvema\u002F","http:\u002F\u002Fsankarvema.github.io\u002F","http:\u002F\u002Fsankarvema.blogspot.com\u002F","https:\u002F\u002Ftwitter.com\u002Fsansvema",{"id":15,"title":16,"body":17,"date":219,"description":206,"draft":220,"excerpt":221,"extension":222,"meta":223,"navigation":224,"path":225,"seo":226,"slug":227,"status":228,"stem":229,"tags":230,"__hash__":234},"writing\u002Fwriting\u002Fagentic-architecture-patterns.md","Five Patterns I Keep Reaching For When Designing Agentic Systems",{"type":18,"value":19,"toc":205},"minimark",[20,31,36,48,52,59,63,79,83,94,98,117,121,132,136,147,151,171,175,186,189],[21,22,23],"blockquote",{},[24,25,26,30],"p",{},[27,28,29],"strong",{},"Status:"," outline. Promote to draft once each pattern has at least one\nconcrete code or diagram example pulled from a real build.",[32,33,35],"h2",{"id":34},"why-this-post","Why this post",[24,37,38,39,43,44,47],{},"There's a lot of writing on what agents ",[40,41,42],"em",{},"are"," and very little on what\n",[40,45,46],{},"shipping"," one looks like. I want this post to compress what I've learned\nacross the AI Interviewer, DigiHire, the no-code platform, and the digital\ntwin builds, the patterns I keep reaching for, why, and the ones that\nsounded good in theory but never made it past the second iteration.",[32,49,51],{"id":50},"the-argument-in-one-paragraph","The argument in one paragraph",[24,53,54,55,58],{},"Production agentic systems are not built around prompts. They're built around\n",[27,56,57],{},"five primitives",": a typed contract for the agent's output, a constrained\ntool surface, a deterministic orchestrator, a transparent eval harness, and a\ngraceful interruption model. The model you pick matters less than whether\nthese five exist. If they don't, scaling the prompt makes the system worse,\nnot better.",[32,60,62],{"id":61},"pattern-1-output-as-schema-not-as-text","Pattern 1: Output as schema, not as text",[64,65,66,70,73,76],"ul",{},[67,68,69],"li",{},"Why: comparability, queryability, eval-ability all live in structured output.",[67,71,72],{},"How: schema-constrained decoding, structured outputs APIs, JSON-mode + validator + retry loop.",[67,74,75],{},"When NOT to: when the task is genuinely generative (writing, summarization),\nschema is harm.",[67,77,78],{},"Example from the AI Interviewer: rubric-aligned JSON per round, not transcripts.",[32,80,82],{"id":81},"pattern-2-tools-are-the-api-surface-treat-them-like-one","Pattern 2: Tools are the API surface, treat them like one",[64,84,85,88,91],{},[67,86,87],{},"Why: an agent with too many tools is an agent with no tools.",[67,89,90],{},"How: 5 to 9 tools, named like product features, with explicit pre- and\npostconditions in their descriptions. Version them.",[67,92,93],{},"The mistake: exposing the database schema as 40 micro-tools.",[32,95,97],{"id":96},"pattern-3-deterministic-orchestration-around-non-deterministic-reasoning","Pattern 3: Deterministic orchestration around non-deterministic reasoning",[64,99,100,111,114],{},[67,101,102,103,106,107,110],{},"Why: the LLM should choose ",[40,104,105],{},"what"," to do, not ",[40,108,109],{},"how the system runs",".",[67,112,113],{},"How: state machines, pipelines, or workflow engines on the outside;\nreasoning calls on the inside.",[67,115,116],{},"Reference: Pipecat-style pipelines in the AI Interviewer.",[32,118,120],{"id":119},"pattern-4-eval-harness-before-scale-not-after","Pattern 4: Eval harness before scale, not after",[64,122,123,126,129],{},[67,124,125],{},"Why: every model swap, prompt edit, and tool change is a silent regression\nrisk. Without an eval, you find out from users.",[67,127,128],{},"How: a fixed eval set per agent capability, golden outputs, semantic-diff\nscoring, run-on-PR.",[67,130,131],{},"The honest cost: this takes longer to set up than the agent itself. Do it\nanyway.",[32,133,135],{"id":134},"pattern-5-interruption-is-a-first-class-concern","Pattern 5: Interruption is a first-class concern",[64,137,138,141,144],{},[67,139,140],{},"Why: real users don't take turns politely. Especially in voice and chat.",[67,142,143],{},"How: barge-in handling, cancellable tool calls, partial-output replay,\nstate checkpoints.",[67,145,146],{},"Lesson from the AI Interviewer: this was the difference between \"demo\" and\n\"deploy.\"",[32,148,150],{"id":149},"patterns-ive-stopped-reaching-for","Patterns I've stopped reaching for",[64,152,153,159,165],{},[67,154,155,158],{},[27,156,157],{},"Pure ReAct loops with unlimited horizon",", impressive in benchmarks,\nunwieldy in production. Cap the steps; orchestrate the rest.",[67,160,161,164],{},[27,162,163],{},"One mega-prompt with everything in it",", readable for a week, then a\nliability forever.",[67,166,167,170],{},[27,168,169],{},"\"Let the agent decide\" as a UX choice",": users want predictability.\nAgents are an implementation detail of the product, not its surface.",[32,172,174],{"id":173},"what-this-implies-for-teams","What this implies for teams",[64,176,177,180,183],{},[67,178,179],{},"Hire (or grow) a platform engineer before the second model swap.",[67,181,182],{},"Budget for the eval harness like you'd budget for tests, because that's\nwhat it is.",[67,184,185],{},"Pick a battle-tested orchestrator before you pick a clever model.",[187,188],"hr",{},[24,190,191,194,195,200,201],{},[27,192,193],{},"Related:"," ",[196,197,199],"a",{"href":198},"\u002Fwork\u002Fai-interviewer","Real-time Multimodal AI Interviewer"," · ",[196,202,204],{"href":203},"\u002Fwork\u002Fenterprise-digital-twin","Enterprise Digital Twin",{"title":206,"searchDepth":207,"depth":207,"links":208},"",3,[209,211,212,213,214,215,216,217,218],{"id":34,"depth":210,"text":35},2,{"id":50,"depth":210,"text":51},{"id":61,"depth":210,"text":62},{"id":81,"depth":210,"text":82},{"id":96,"depth":210,"text":97},{"id":119,"depth":210,"text":120},{"id":134,"depth":210,"text":135},{"id":149,"depth":210,"text":150},{"id":173,"depth":210,"text":174},"2026-06-15",false,null,"md",{},true,"\u002Fwriting\u002Fagentic-architecture-patterns",{"title":16,"description":206},"agentic-architecture-patterns","outline","writing\u002Fagentic-architecture-patterns",[231,232,233],"build","agentic","architecture","gjjNI-1ljA8b9Dkc3JYgCLuC2_xXZGKeITIatMhk270",1790601541833]