What is a reflection?
A strategy for improving the quality of an agentic workflow by examining (reflecting on) a step's output before passing that output to the next step.
reflection explained in plain English
A strategy for improving the quality of an agentic workflow by examining (reflecting on) a step's output before passing that output to the next step. The examiner is often the same LLM that generated the response (though it could be a different LLM). How could the same LLM that generated a response be a fair judge of its own response? The "trick" is to put the LLM in a critical (reflective) mindset. This process is analogous to a writer who uses a creative mindset to write a first draft and then switches to a critical mindset to edit it. For example, imagine an agentic workflow whose first step is to create text for coffee mugs. The prompt for this step might be: You are a creative. Generate humorous, original text of less than 50 characters suitable for a coffee mug. Now imagine the following reflective prompt: You are a coffee drinker. Would you find the preceding response humorous? The workflow might then only pass text that receives a high reflection score to the next stage.
Example
Practitioners refer to reflection when building, training, or evaluating machine learning systems. It appears in research papers, product documentation, and technical discussions about AI capabilities and limitations.
People also read
- agent orchestration
The centralized management and routing of tasks across multiple sub-agents or LLM calls.
- average precision at k
A metric for summarizing a model's performance on a single prompt that generates ranked results, such as a numbered list of book recommendations.
- black box model
A model whose "reasoning" is impossible or difficult for humans to understand.
- Chain-of-Thought Prompting
Asking an AI to show its reasoning step by step before giving a final answer, which often improves accuracy on complex tasks.
- conversational coding
An iterative dialog between you and a generative AI model for the purpose of creating software.
- deterministic
A system that always returns the same output for a given input.
- direct prompting
Synonym for zero-shot prompting.
- distillation
The process of reducing the size of one model (known as the teacher) into a smaller model (known as the student) that emulates the original model's predictions as faithfully as possible.
- emergent behavior
An LLM's ability to generate responses for prompts that it was not explicitly trained on.
- factuality
Within the ML world, a property describing a model whose output is based on reality.