Course menuAIP-C01

Exams / AIP-C01 / Study guide / Agent reasoning patterns (ReAct, planning, Step Functions orchestration)

Agent reasoning patterns (ReAct, planning, Step Functions orchestration): AIP-C01 study notes and practice questions

What to know about Agent reasoning patterns (ReAct, planning, Step Functions orchestration) for the AIP-C01 exam, from the Implementation and Integration domain (26% of the exam guide), then 1 free question to test it. Part of the AIP-C01 study guide.

Last verified against current AWS documentation ·How we write our questions

What to know for the exam

AIP-C01 gives a task and asks which reasoning pattern fits: how much the model decides on its own, what must be auditable, and what can run in parallel. The exam rewards matching the amount of autonomy to the predictability of the process, not choosing the most advanced pattern.

Core patterns

  • ReAct loop: the model reasons about the next step, calls a tool, observes the result, and repeats until it can answer. Each thought, call and observation is added to the context. Use it when the path to the answer is unknown in advance.
  • Plan and execute: the model first writes a list of steps, then carries them out. This suits long tasks with a predictable structure. Replan only when a step fails, not after every step.
  • Reflection: the model, or a second model acting as a judge, checks a draft against stated criteria and revises it. It improves quality on high-stakes text but adds a full extra model call each time, so use it selectively.
  • Task decomposition with parallel tools: split the request into subtasks. Run independent subtasks at the same time, and run dependent subtasks in order.

Step Functions for auditable steps

When each reasoning step must be recorded, retried and reviewed, put the steps in an AWS Step Functions workflow. Each state’s input and output appear in the execution history, so you can show what the model saw and decided at each step. Use Retry and Catch for failed model or tool calls, a Choice state for branching, and a Map state to run the same subtask over many items in parallel. Express workflows suit high-volume, short runs. Standard workflows suit longer, audit-heavy processes.

Deterministic workflow or autonomous agent

A deterministic workflow fixes the order of steps, and the model fills in one step at a time, such as classify, extract, then summarize. An autonomous agent lets the model choose the next step. Pick the workflow when the process is known and must be auditable. Pick the agent loop when the next step depends on what the model has just learned.

How to choose

Scenario wording Choose
“Steps are known, and auditors need each step recorded” Step Functions workflow with model calls as states
“Open-ended goal, the path is unknown” ReAct agent loop
“Long task with a fixed structure” Plan and execute, with replanning on failure
“Output must be checked before it is returned” Reflection step or a judge model
“Several independent lookups” Parallel state or Map state

Common traps

  • An autonomous agent for a fixed process. The model may skip or reorder steps, and the run is hard to audit.
  • Reflection on every request. It doubles cost and latency. Apply it to outputs where quality matters most.
  • Trusting self-critique alone for safety-critical output. Add a deterministic check, such as a schema or guardrail.
  • Running dependent subtasks in parallel, which produces results built on missing inputs.
  • Writing one long plan and never revising it when a tool returns unexpected data.

See also Agent safeguards.

Try the 1 practice question

An insurance company's claims assistant answers adjusters' questions about open claims. It can call three internal tools: one looks up the policy, one returns payment history, and one reads the adjuster's notes. The right tool to call next often depends on what the previous tool returned, so the team cannot fix the sequence of calls in advance.

Every answer must rest only on facts returned by the tools, and the company's audit team needs a record of why each tool was called.

The team is reviewing how the agent loop should be structured.

Which agent loop design meets these requirements?

Choose one answer.

  1. A. Ask the model for a complete plan of every tool call in one response, run the calls in the planned order, and then ask the model for the final answer once all results are back.
  2. B. Call all three tools for every question in parallel, put every result into one prompt, and ask the model to write the answer in a single pass.
  3. C. Run a loop in which the model writes a reasoning step and one tool call, the application runs the call and returns the result, and the loop repeats until a final answer.
  4. D. Let the model answer each question from its training knowledge first, then call the tools only to check the answer, and rewrite the answer if a check fails.
Show the answer and explanation

Answer: C

  • A. Wrong: A fixed plan cannot change course when a result is unexpected, such as a missing policy number. The plan can record intent, but a plan made before any results exist is weaker evidence for an audit.
  • B. Wrong: Calling every tool for every question wastes calls and adds latency, and the model never decides which tool to use. The audit trail shows the same calls each time, so it does not record why a tool was chosen.
  • C. Right: This ReAct-style loop lets each tool call depend on the previous observation, and the final answer rests on returned results. Logging each reasoning step, tool call and observation gives the audit team the trace it needs.
  • D. Wrong: The model would answer before seeing any claim data, so the answer is not grounded in tool results. Checking afterward also leaves the first answer in the trace, which is confusing for an auditor.

Explanation

A ReAct-style loop alternates between reasoning, a tool call, and an observation of the tool's result, so each next step adapts to what the last tool returned. The final answer then rests only on returned facts, and every step can be logged. A fixed plan, parallel calls or answering first each break at least one of these requirements.

Study

Want more on Agent reasoning patterns (ReAct, planning, Step Functions orchestration)? The 5 full-length practice sets have 5 more Agent reasoning patterns (ReAct, planning, Step Functions orchestration) questions, 375 in all, none of them in the free exam. One payment of $14.99, no subscription. See the practice sets

Study Agent reasoning patterns (ReAct, planning, Step Functions orchestration)

More Implementation and Integration topics