AI & Automation
Official siteAgentic Workflows
Designing and running AI agents that plan, call tools, and execute multi-step tasks with explicit guardrails and human oversight where it matters.
Overview
AI agents move from single-turn prompts to loops: perceive, decide, act, observe, repeat. My focus is making those loops safe and deterministic where they must be — the tool call surface, the fallback paths, and the stop conditions.
I pattern agents as orchestrations with a plan: a small, typed set of tools the model may invoke, a schema for tool calls, and a supervisor that decides between autonomous progress and a human-in-the-loop handoff. Autonomy is a per-step permission, not a global setting.
Reliability comes from the same discipline as any distributed system — retries, timeouts, idempotency, and full traceability of every decision the agent made, so an unexpected result is debuggable rather than opaque.
The loop is where agents earn their keep. The plan → act → observe cycle lets a model tackle multi-step work a single call cannot, but only if each step is bounded: a step budget, a max number of tool calls, and a clear definition of "done" so the agent terminates instead of looping.
I keep the tool surface deliberately narrow and typed. Tools are capabilities, each with an explicit contract and side effects; nothing the model can invoke is magic, and anything destructive requires an approval gate before it runs.
The supervisor pattern is my default shape: a lightweight controller decides, per step, whether to continue autonomously, ask a human, or stop. That keeps autonomy behind a policy rather than a hope, and it is what makes agentic systems safe enough to trust with real work.
Deterministic orchestration is not the enemy of agents — it is their spine. I use BPMN or n8n for the steps that must run exactly (routing, retries, timing) and let the model decide only the parts that genuinely need judgment. The agent sits inside a governed flow, not around it.
Traceability is non-negotiable. Every agent run logs its plan, each tool call with input and output, and the reason for stopping. When an agent produces something surprising, I can replay exactly what happened instead of guessing.
Cost and safety scale with autonomy, so I bound them together: a per-run budget, guardrails on tool execution, and evals that test the agent against a set of representative tasks before it is trusted in production.
How I Work With Agentic Workflows
I scope the loop before I build it. Every agent starts with a clear definition of done — what the plan is, what success looks like, and the hard stop — so the loop terminates instead of spinning.
The tool surface is small, typed, and explicit. Each tool has a contract and declared side effects, and anything destructive sits behind an approval gate rather than being callable by the model at will.
A step budget and a call limit bound every run. No agent gets infinite turns or infinite tool calls, because unbounded loops are how agentic systems burn money and drift off task.
The supervisor decides when to hand to a human. Per step, a lightweight controller judges whether to continue autonomously, ask for approval, or stop — so autonomy is a policy, not a hope.
Deterministic orchestration is the spine. I put routing, retries, and timing in BPMN or n8n, and reserve agent judgement only for the steps that genuinely need it — the agent inside a governed flow, not around it.
Traceability is non-negotiable. Every run logs its plan, each tool call with input and output, and the reason for stopping, so a surprising result is replayable rather than opaque.
Evals gate production. The agent is tested against a set of representative tasks before it is trusted, and a regression is caught in CI, not in front of a user.
Cost is bound with autonomy. A per-run budget, guardrails on execution, and alerting on runaway spend keep experimentation safe while keeping the loop genuinely useful.
When a task is single-turn and deterministic, I do not reach for an agent. The loop earns its complexity only where multi-step reasoning and tool use genuinely pay.