Connect with me via the floating button
Compare reactive, deliberative, and hybrid agent designs and choose the right fit.
Most agent failures are not prompt failures. They are architecture failures. The wrong loop creates the wrong behavior, no matter how good your model is. This lesson is a practical map of the main agent architectures and the signals that tell you which one to use.
A reactive agent observes input and takes the next best action without long-term planning. It is fast, cheap, and easy to test. It is also limited when tasks require multi-step reasoning.
Best for: chat support, triage, simple tool calls.
A planner creates a multi-step plan and executes it, often with checks or revisions. It is slower and more expensive but handles complex tasks better.
Best for: research, multi-step automation, document generation.
A hybrid agent starts with a light plan and then adapts on every step. This is the most common production pattern because it balances speed and reliability.
Best for: most production agents.
The plan-execute-reflect loop is a reliable default. It introduces structure without forcing the agent into a brittle plan.
type Step = { tool: string; input: Record<string, unknown>; intent: string };
type Plan = {
goal: string;
steps: Step[];
successCriteria: string[];
};
async function planExecuteReflect(state: AgentState) {
const plan = await proposePlan(state); // model suggests 3-6 steps
for (const step of plan.steps) {
const result = await executeTool(step.tool, step.input);
state = updateState(state, step, result);
if (isGoalMet(state, result)) break;
if (shouldReplan(state, result)) {
return planExecuteReflect(state); // replan on new evidence
}
}
return state;
}
Notice the replan gate. Without it, plans become brittle and waste tokens.
Use this quick test to decide which architecture to start with:
In practice, you can start reactive and add planning when you see failures. Do not over-architect from day one.
Full access
Unlock all 10 lessons, templates, and resources for AI Agent Masterclass. $99 AUD.
If you are still unsure, score each architecture on a 1-5 scale for your use case:
Reactive wins on latency. Deliberative wins on risk. Hybrid wins on balance. This simple scoring keeps you honest and prevents gold-plating.
Some teams split the agent into two roles:
This separation helps when the executor needs deterministic behavior. The coordinator can be a model, while the executor is standard code.
async function coordinator(state: AgentState) {
return decideNextAction(state); // model decides
}
async function executor(action: Action) {
return executeTool(action.tool, action.input); // deterministic
}
Take the agent contract you wrote in Lesson 1. Decide which architecture is the best starting point and justify it in one paragraph. Include your reasoning about speed, cost, and risk.
Then define the replan condition in one sentence. Example: "If a tool result contradicts the plan or the output confidence is below 0.7, replan."
In Lesson 3, we will design tools with strict schemas and safe execution so the model can act without breaking your system.