loading
loading
The agent looks back at what it just did, decides whether it worked, and adjusts before continuing.
After an action or a failed attempt, the agent feeds the result (and any error) back into itself and reasons about what went wrong, producing a corrected next step. This closes the loop between acting and learning within a single task, which is what lets agents recover from a tool error instead of blindly repeating it. Example: a coding agent runs the tests, sees three fail, reflects on the stack traces, and patches the specific bug rather than rewriting everything.
Plainly
Think of Reflection as a simple recipe for doing the work better. The agent looks back at what it just did, decides whether it worked, and adjusts before continuing.
In practice
Use it when you need a repeatable method instead of guessing from vibes. In practice, define the owner, input, output, and failure mode before you rely on it.