1A multi-step pipeline gives a poor result. Which step do I fix?
A critique of the final output does not say which step caused the fault. Here the critique travels backward through the pipeline. Each step gets a comment on its own contribution, its prompt is rewritten from that comment, and the pipeline runs again. A rewrite is kept only if the result is no worse.
You may need it if
- The final output is wrong and each step, read alone, looks reasonable.
- You fix the last step's prompt by hand and the same fault returns from an earlier step.
- The pipeline has several prompts and nobody knows which one to edit.
2When is there nothing to pass backward?
Use it when
- The work goes through two to five model steps, each with its own prompt, and faults are hard to attribute.
- The prompts will be reused on many inputs, so a better prompt pays more than a better single answer.
- An evaluator, a test or a metric can say concretely what is wrong with a final output.
Avoid it when
- There is one prompt and one answer. Backward critique is then ordinary critique and rewrite.
Use Reflection instead - The steps call tools or retrieve documents. The source leaves feedback through such steps as future work, and the fault is often in an action, not a prompt.
Use Reflexion instead - The rewrite must satisfy many constraints at once, such as format, length, tone and policy. Following all of them becomes unreliable.
- You need the answer now and will not reuse the pipeline. Several full reruns are a high price for one result.
What it costs
- Model calls
- about 3 x steps + 1 per iteration (30 to 40 for 3 steps and 3 iterations)
- Latency
- high
- Complexity
- high
3How does a comment on the output reach the first step?
A loop around a pipeline. The steps run forward and an evaluator criticises the final output. A gate keeps or reverts the last rewrite. Then a feedback writer walks the steps from last to first and a rewriter updates each prompt at fault. The pipeline runs again, for a fixed number of iterations.
- Step 1 of 7
The pipeline runs forward
A customer complains about a late parcel and asks when it will arrive. Three steps run with their current prompts. One lists the facts, one decides the remedy, one writes the reply. Each input and output is recorded.
- Step 2 of 7
The evaluator criticises the output
The evaluator reads the reply against the request. Its criticism: the reply offers a refund but never says when the parcel will arrive. Score 5 of 10. This is the first run, so there is nothing to revert.
- Step 3 of 7
The criticism moves one step back
The feedback writer looks at the reply step. Its prompt is fine. Its input, the decision, held no delivery date. That comment becomes the criticism of the step before, and the same question is asked there.
- Step 4 of 7
The step at fault gets its comment
The decision step only lacked the date in its own input. So the comment lands on the first step, whose prompt says to list the facts of the order. It should also list every question the customer asks.
- Step 5 of 7
The prompt is rewritten and tried
The rewriter changes the first prompt and leaves the two others alone. The pipeline runs again with the candidate prompts. The new reply gives the delivery date.
- Step 6 of 7
Kept, or reverted
The evaluator scores the new reply 8. The score did not drop, so the gate saves the rewritten prompt. Had it dropped, the previous prompts would return and the backward pass would be tried again.
- Step 7 of 7
The loop ends
The run stops when the score reaches 8 or after 3 iterations. It returns the best kept reply. The saved prompts now also ask for the customer's questions on the next complaint.
What each part does
- Task
- The request to fulfil, or an existing result to improve, which the first step then starts from.
- Pipeline steps
- Model steps run in order, each with its own prompt. Each step's input and output are recorded for the backward pass.
- Step prompts
- The texts being tuned: one prompt per step. The kept version survives the run and serves the next input.
- Evaluator
- Says in plain text what is wrong with the final output, and gives a score used only to compare two runs.
- Keep the rewrite?
- Plain code. Keeps the rewritten prompts if the score did not drop, reverts them otherwise, and counts iterations.
- Feedback writer
- Takes one step at a time, last first. Turns the criticism of its output into a comment on its prompt and a comment on its input.
- Prompt rewriter
- Rewrites the prompt of each step that received a comment, and leaves the others alone.
- Result
- The output of the best kept run, with the prompts that produced it and the score of each iteration.
- Step prompts → Pipeline steps: one prompt per step
- Pipeline steps → Evaluator: final output
- Evaluator → Keep the rewrite?: criticism and score
- Keep the rewrite? → Step prompts: kept prompts
- Keep the rewrite? → Feedback writer: iterations left
- Feedback writer → Prompt rewriter: one comment per step
- Prompt rewriter → Pipeline steps: rerun with the rewrites
- Keep the rewrite? → Result: target met or iterations spent
Where it connects
A request to fulfil, or an existing result to improve, given to the first step as material. The pipeline, its step prompts and the evaluation criteria are already configured.
When: The evaluator's score reaches the target, or the iterations are spent.
The output of the best kept run, the score of each iteration, whether the target was met, and the prompts that were kept.
One prompt per pipeline step, in its last kept version, with the previous version so that a rewrite can be reverted.
4What do I ask my assistant to set up?
The agents to launch
Step runner, one per pipeline step, two to five
Carry out your step on the input you receive, following your step prompt exactly. Return only your step's output. Do not do the work of another step and do not comment on the prompt.
Sees: Its own step prompt, the task and the output of the step before. Not the other prompts, the criticism or earlier iterations.
Evaluator
Judge the final output against the task and the criteria. List concretely what is wrong or missing, then give one score from 1 to 10. Do not rewrite the output and do not guess which step caused a fault.
Sees: The task, the criteria and the final output. Not the prompts or the intermediate outputs.
Feedback writer
One step received an input and a prompt and produced an output. You get the criticism of that output. Say what in the prompt caused it and how the prompt should change. Say separately what was wrong or missing in the input. Leave a part empty when it is not at fault. Do not rewrite anything.
Sees: One step at a time, with its prompt, its input, its output and the criticism of that output. Not the other steps.
Prompt rewriter
Rewrite the step prompt so that it answers the comment. Keep what already worked and stay general: the prompt must serve other inputs, not only this one. Return only the new prompt.
Sees: The current prompt of one step and the comment on it. Not the task's content beyond what the comment quotes.
A prompt you can paste
Works with any assistant that can launch sub-agents. It contains the agents, the procedure and the stop rule above.
You are the orchestrator of a multi-agent workflow that follows the "Textual Backpropagation" architecture. Launch every agent listed below as a separate sub-agent with its own context. Give each agent only the context stated for it. Do not do an agent's work yourself. If you cannot launch sub-agents, play each agent in a clearly separated turn and never let it use what is withheld from it. # Task [Describe your task here] # Textual Backpropagation Pass the critique backward and rewrite each step's prompt. Input: the task above. It must provide: A request to fulfil, or an existing result to improve, given to the first step as material. The pipeline, its step prompts and the evaluation criteria are already configured. If something essential is missing, ask for it before starting. Agents to launch: - Step runner (one per pipeline step, two to five): Carry out your step on the input you receive, following your step prompt exactly. Return only your step's output. Do not do the work of another step and do not comment on the prompt. Context for this agent: Its own step prompt, the task and the output of the step before. Not the other prompts, the criticism or earlier iterations. - Evaluator: Judge the final output against the task and the criteria. List concretely what is wrong or missing, then give one score from 1 to 10. Do not rewrite the output and do not guess which step caused a fault. Context for this agent: The task, the criteria and the final output. Not the prompts or the intermediate outputs. - Feedback writer: One step received an input and a prompt and produced an output. You get the criticism of that output. Say what in the prompt caused it and how the prompt should change. Say separately what was wrong or missing in the input. Leave a part empty when it is not at fault. Do not rewrite anything. Context for this agent: One step at a time, with its prompt, its input, its output and the criticism of that output. Not the other steps. - Prompt rewriter: Rewrite the step prompt so that it answers the comment. Keep what already worked and stay general: the prompt must serve other inputs, not only this one. Return only the new prompt. Context for this agent: The current prompt of one step and the comment on it. Not the task's content beyond what the comment quotes. Procedure: 1. Write the pipeline as an ordered list of steps with one prompt each. Run it on the task and record every step's input and output. 2. Launch the evaluator on the final output. Keep its criticism and its score. 3. If this run used rewritten prompts, keep them when the score did not drop and restore the previous ones when it did. 4. Launch the feedback writer on the last step with the evaluator's criticism. Pass its comment on the input to the step before as that step's criticism, and continue to the first step. 5. When one output feeds several steps, join the comments from all of them before rewriting. 6. Launch the rewriter on each prompt that received a comment, then run the pipeline again with the candidates. 7. If the prompts will serve other inputs, also run each candidate on 3 to 5 held-out examples and keep it only if they do not get worse. Stop rule: Stop when the evaluator's score reaches 8 of 10, or after 3 iterations of rewriting. Return the output of the best kept run, never that of a reverted one. Exit: - `result`, when: The evaluator's score reaches the target, or the iterations are spent. Deliver: The output of the best kept run, the score of each iteration, whether the target was met, and the prompts that were kept. # Final deliverable The final output, the score of each iteration, whether the target was met, and for each step the kept prompt next to the original.
The same thing in code
from typing import TypedDict
from langchain.chat_models import init_chat_model
from langchain_core.messages import HumanMessage, SystemMessage
from langgraph.graph import END, START, StateGraph
from pydantic import BaseModel
STEPS = { # the texts being tuned: one prompt per step, run in this order
"facts": "List the facts of the order stated in the customer's message.",
"decision": "Decide the remedy from the facts and our policy.",
"reply": "Write the reply to the customer from the decision.",
}
MAX_ITERATIONS, TARGET = 3, 8
EVALUATOR = ("Judge the final output against the task. List concretely what is wrong or missing, then give "
"one score from 1 to 10. Do not rewrite the output.")
BACKWARD = ("One step received an input and a prompt and produced an output. You get the criticism of that "
"output. Say what in the prompt caused it and how the prompt should change. Say separately what "
"was wrong or missing in the input. Leave a field empty when that part is not at fault.")
REWRITER = ("Rewrite the step prompt so that it answers the comment. Keep what already worked and stay "
"general: the prompt must serve other inputs too. Return only the new prompt.")
class Evaluation(BaseModel):
criticism: str
score: int
class Feedback(BaseModel):
on_prompt: str
on_input: str
class State(TypedDict):
task: str
candidate: dict[str, str] # prompts being tried
trace: list[tuple[str, str, str]] # step, input, output
kept: dict # prompts, trace and evaluation of the best run so far
scores: list[int]
model = init_chat_model("anthropic:claude-sonnet-5-5")
async def forward(state: State) -> dict:
trace, text = [], state["task"]
for name, prompt in state["candidate"].items():
reply = await model.ainvoke([SystemMessage(prompt), HumanMessage(f"Task: {state['task']}\n\nInput:\n{text}")])
trace.append((name, text, reply.text))
text = reply.text
return {"trace": trace}
async def evaluate(state: State) -> dict:
ask = [SystemMessage(EVALUATOR), HumanMessage(f"Task: {state['task']}\n\nFinal output:\n{state['trace'][-1][2]}")]
evaluation = Evaluation.model_validate(await model.with_structured_output(Evaluation).ainvoke(ask))
kept = state["kept"]
if not kept or evaluation.score >= kept["evaluation"].score: # the gate: keep a rewrite only if the score did not drop
kept = {"prompts": state["candidate"], "trace": state["trace"], "evaluation": evaluation}
return {"kept": kept, "scores": [*state["scores"], evaluation.score]}
async def backward(state: State) -> dict:
kept = state["kept"]
criticism, candidate = kept["evaluation"].criticism, dict(kept["prompts"])
for name, given, produced in reversed(kept["trace"]): # last step first
if not criticism:
break
ask = f"Prompt:\n{candidate[name]}\n\nInput:\n{given}\n\nOutput:\n{produced}\n\nCriticism of the output:\n{criticism}"
feedback = Feedback.model_validate(await model.with_structured_output(Feedback).ainvoke([SystemMessage(BACKWARD), HumanMessage(ask)]))
if feedback.on_prompt: # rewrite only the prompts that received a comment
rewrite = await model.ainvoke([SystemMessage(REWRITER), HumanMessage(f"Prompt:\n{candidate[name]}\n\nComment:\n{feedback.on_prompt}")])
candidate[name] = rewrite.text
criticism = feedback.on_input # becomes the criticism of the step before
return {"candidate": candidate}
def go_on(state: State) -> str:
done = state["kept"]["evaluation"].score >= TARGET or len(state["scores"]) > MAX_ITERATIONS
return END if done else "backward"
builder = StateGraph(State)
for name, node in {"forward": forward, "evaluate": evaluate, "backward": backward}.items():
builder.add_node(name, node)
builder.add_edge(START, "forward")
builder.add_edge("forward", "evaluate")
builder.add_conditional_edges("evaluate", go_on, ["backward", END])
builder.add_edge("backward", "forward")
graph = builder.compile()
async def run(task: str) -> dict:
s = await graph.ainvoke({"task": task, "candidate": dict(STEPS), "trace": [], "kept": {}, "scores": []})
kept = s["kept"] # save kept["prompts"] where the next run will load them
return {"result": kept["trace"][-1][2], "prompts": kept["prompts"], "scores": s["scores"], "target_met": kept["evaluation"].score >= TARGET}
The pipeline here is a chain. When one output feeds several steps, join their comments before rewriting. Test rewrites on held-out examples before you save them for reuse.
from typing import Any
from claude_agent_sdk import ClaudeAgentOptions, ResultMessage, query
from pydantic import BaseModel
STEPS = { # the texts being tuned: one prompt per step, run in this order
"facts": "List the facts of the order stated in the customer's message.",
"decision": "Decide the remedy from the facts and our policy.",
"reply": "Write the reply to the customer from the decision.",
}
MAX_ITERATIONS, TARGET = 3, 8
EVALUATOR = ("Judge the final output against the task. List concretely what is wrong or missing, then give "
"one score from 1 to 10. Do not rewrite the output.")
BACKWARD = ("One step received an input and a prompt and produced an output. You get the criticism of that "
"output. Say what in the prompt caused it and how the prompt should change. Say separately what "
"was wrong or missing in the input. Leave a field empty when that part is not at fault.")
REWRITER = ("Rewrite the step prompt so that it answers the comment. Keep what already worked and stay "
"general: the prompt must serve other inputs too. Return only the new prompt.")
class Evaluation(BaseModel):
criticism: str
score: int
class Feedback(BaseModel):
on_prompt: str
on_input: str
async def ask(system: str, prompt: str, schema: type[BaseModel] | None = None) -> Any:
# one fresh session per call: each role sees only what it is handed
options = ClaudeAgentOptions(
system_prompt=system,
output_format={"type": "json_schema", "schema": schema.model_json_schema()} if schema else None,
)
async for msg in query(prompt=prompt, options=options):
if isinstance(msg, ResultMessage):
return schema.model_validate(msg.structured_output) if schema else msg.result or ""
raise RuntimeError("no result")
async def forward(task: str, prompts: dict[str, str]) -> list[tuple[str, str, str]]:
trace, text = [], task
for name, prompt in prompts.items():
output: str = await ask(prompt, f"Task: {task}\n\nInput:\n{text}")
trace.append((name, text, output)) # step, input, output: kept for the backward pass
text = output
return trace
async def run(task: str) -> dict:
candidate = dict(STEPS)
prompts, trace, evaluation = candidate, await forward(task, candidate), None
scores: list[int] = []
for iteration in range(MAX_ITERATIONS + 1):
if iteration:
tried = await forward(task, candidate)
else:
tried = trace
judged: Evaluation = await ask(EVALUATOR, f"Task: {task}\n\nFinal output:\n{tried[-1][2]}", Evaluation)
scores.append(judged.score)
if evaluation is None or judged.score >= evaluation.score: # the gate: keep a rewrite only if the score did not drop
prompts, trace, evaluation = candidate, tried, judged
if evaluation.score >= TARGET or iteration == MAX_ITERATIONS:
break
# backward pass, last step first, from the best kept run
criticism, candidate = evaluation.criticism, dict(prompts)
for name, given, produced in reversed(trace):
if not criticism:
break
feedback: Feedback = await ask(
BACKWARD,
f"Prompt:\n{candidate[name]}\n\nInput:\n{given}\n\nOutput:\n{produced}\n\nCriticism of the output:\n{criticism}",
Feedback,
)
if feedback.on_prompt: # rewrite only the prompts that received a comment
candidate[name] = await ask(REWRITER, f"Prompt:\n{candidate[name]}\n\nComment:\n{feedback.on_prompt}")
criticism = feedback.on_input # becomes the criticism of the step before
assert evaluation is not None
# save `prompts` where the next run will load them
return {"result": trace[-1][2], "prompts": prompts, "scores": scores, "target_met": evaluation.score >= TARGET}
The pipeline here is a chain. When one output feeds several steps, join their comments before rewriting. Test rewrites on held-out examples before you save them for reuse.
from agents import Agent, Runner
from pydantic import BaseModel
STEPS = { # the texts being tuned: one prompt per step, run in this order
"facts": "List the facts of the order stated in the customer's message.",
"decision": "Decide the remedy from the facts and our policy.",
"reply": "Write the reply to the customer from the decision.",
}
MAX_ITERATIONS, TARGET = 3, 8
class Evaluation(BaseModel):
criticism: str
score: int
class Feedback(BaseModel):
on_prompt: str
on_input: str
evaluator = Agent(
name="Evaluator",
instructions="Judge the final output against the task. List concretely what is wrong or missing, then give "
"one score from 1 to 10. Do not rewrite the output.",
output_type=Evaluation,
)
feedback_writer = Agent(
name="Feedback writer",
instructions="One step received an input and a prompt and produced an output. You get the criticism of that "
"output. Say what in the prompt caused it and how the prompt should change. Say separately what "
"was wrong or missing in the input. Leave a field empty when that part is not at fault.",
output_type=Feedback,
)
rewriter = Agent(
name="Prompt rewriter",
instructions="Rewrite the step prompt so that it answers the comment. Keep what already worked and stay "
"general: the prompt must serve other inputs too. Return only the new prompt.",
)
async def forward(task: str, prompts: dict[str, str]) -> list[tuple[str, str, str]]:
trace, text = [], task
for name, prompt in prompts.items():
step = Agent(name=name, instructions=prompt) # the step's prompt is the variable under tuning
output = (await Runner.run(step, f"Task: {task}\n\nInput:\n{text}")).final_output_as(str)
trace.append((name, text, output)) # step, input, output: kept for the backward pass
text = output
return trace
async def run(task: str) -> dict:
candidate = dict(STEPS)
prompts, trace, evaluation = candidate, await forward(task, candidate), None
scores: list[int] = []
for iteration in range(MAX_ITERATIONS + 1):
tried = await forward(task, candidate) if iteration else trace
judged = (await Runner.run(evaluator, f"Task: {task}\n\nFinal output:\n{tried[-1][2]}")).final_output_as(Evaluation)
scores.append(judged.score)
if evaluation is None or judged.score >= evaluation.score: # the gate: keep a rewrite only if the score did not drop
prompts, trace, evaluation = candidate, tried, judged
if evaluation.score >= TARGET or iteration == MAX_ITERATIONS:
break
# backward pass, last step first, from the best kept run
criticism, candidate = evaluation.criticism, dict(prompts)
for name, given, produced in reversed(trace):
if not criticism:
break
ask = f"Prompt:\n{candidate[name]}\n\nInput:\n{given}\n\nOutput:\n{produced}\n\nCriticism of the output:\n{criticism}"
feedback = (await Runner.run(feedback_writer, ask)).final_output_as(Feedback)
if feedback.on_prompt: # rewrite only the prompts that received a comment
rewrite = await Runner.run(rewriter, f"Prompt:\n{candidate[name]}\n\nComment:\n{feedback.on_prompt}")
candidate[name] = rewrite.final_output_as(str)
criticism = feedback.on_input # becomes the criticism of the step before
assert evaluation is not None
# save `prompts` where the next run will load them
return {"result": trace[-1][2], "prompts": prompts, "scores": scores, "target_met": evaluation.score >= TARGET}
The pipeline here is a chain. When one output feeds several steps, join their comments before rewriting. Test rewrites on held-out examples before you save them for reuse.
import { anthropic } from '@ai-sdk/anthropic';
import { Output, ToolLoopAgent } from 'ai';
import { z } from 'zod';
// the texts being tuned: one prompt per step, run in this order
const STEPS: Record<string, string> = {
facts: "List the facts of the order stated in the customer's message.",
decision: 'Decide the remedy from the facts and our policy.',
reply: 'Write the reply to the customer from the decision.',
};
const MAX_ITERATIONS = 3;
const TARGET = 8;
const model = anthropic('claude-sonnet-5-5');
const evaluationSchema = z.object({ criticism: z.string(), score: z.number().int().min(1).max(10) });
type Evaluation = z.infer<typeof evaluationSchema>;
type Trace = { name: string; given: string; produced: string }[];
const evaluator = new ToolLoopAgent({
model,
instructions:
'Judge the final output against the task. List concretely what is wrong or missing, then give ' +
'one score from 1 to 10. Do not rewrite the output.',
output: Output.object({ schema: evaluationSchema }),
});
const feedbackWriter = new ToolLoopAgent({
model,
instructions:
'One step received an input and a prompt and produced an output. You get the criticism of that ' +
'output. Say what in the prompt caused it and how the prompt should change. Say separately what ' +
'was wrong or missing in the input. Leave a field empty when that part is not at fault.',
output: Output.object({ schema: z.object({ onPrompt: z.string(), onInput: z.string() }) }),
});
const rewriter = new ToolLoopAgent({
model,
instructions:
'Rewrite the step prompt so that it answers the comment. Keep what already worked and stay ' +
'general: the prompt must serve other inputs too. Return only the new prompt.',
});
async function forward(task: string, prompts: Record<string, string>): Promise<Trace> {
const trace: Trace = [];
let text = task;
for (const [name, prompt] of Object.entries(prompts)) {
// the step's prompt is the variable under tuning
const step = new ToolLoopAgent({ model, instructions: prompt });
const { text: produced } = await step.generate({ prompt: `Task: ${task}\n\nInput:\n${text}` });
trace.push({ name, given: text, produced }); // kept for the backward pass
text = produced;
}
return trace;
}
export async function run(task: string) {
let candidate = { ...STEPS };
let prompts = candidate;
let trace = await forward(task, candidate);
let evaluation: Evaluation | null = null;
const scores: number[] = [];
for (let iteration = 0; iteration <= MAX_ITERATIONS; iteration++) {
const tried = iteration ? await forward(task, candidate) : trace;
const { output: judged } = await evaluator.generate({
prompt: `Task: ${task}\n\nFinal output:\n${tried[tried.length - 1]?.produced ?? ''}`,
});
scores.push(judged.score);
// the gate: keep a rewrite only if the score did not drop
if (!evaluation || judged.score >= evaluation.score) {
prompts = candidate;
trace = tried;
evaluation = judged;
}
if (evaluation.score >= TARGET || iteration === MAX_ITERATIONS) break;
// backward pass, last step first, from the best kept run
let criticism = evaluation.criticism;
candidate = { ...prompts };
for (const { name, given, produced } of [...trace].reverse()) {
if (!criticism) break;
const { output: feedback } = await feedbackWriter.generate({
prompt: `Prompt:\n${candidate[name]}\n\nInput:\n${given}\n\nOutput:\n${produced}\n\nCriticism of the output:\n${criticism}`,
});
if (feedback.onPrompt) { // rewrite only the prompts that received a comment
const { text } = await rewriter.generate({ prompt: `Prompt:\n${candidate[name]}\n\nComment:\n${feedback.onPrompt}` });
candidate[name] = text;
}
criticism = feedback.onInput; // becomes the criticism of the step before
}
}
// save `prompts` where the next run will load them
return {
result: trace[trace.length - 1]?.produced ?? '',
prompts,
scores,
targetMet: (evaluation?.score ?? 0) >= TARGET,
};
}
The pipeline here is a chain. When one output feeds several steps, join their comments before rewriting. Test rewrites on held-out examples before you save them for reuse.
Snippets are generated when the site is built and type-checked against the SDK versions listed in the repository. Treat them as a starting skeleton.
What goes wrong
- A prompt tuned on one input drifts toward that input. Check rewrites on other examples before saving them for reuse.
- Without the keep-or-revert check, a bad rewrite becomes the base of the next one and the prompts degrade.
- An evaluator that says "could be better" gives the backward pass nothing to trace. Ask for concrete, locatable faults.
- Rewriting every prompt at each iteration hides which change helped. Rewrite only the steps that received a comment.
- Asking the rewriter to respect many constraints at once makes it drop some. Keep the constraints few.
Chain it
Its result can feed
- Chain of Verification conditional
Condition: Build the link only when A's payload is an answer rather than a document, since the verification entry accepts answers but not documents.
- Debate conditional
Condition: Build the link only when A's payload is an answer rather than a document, since the debate entry accepts answers but not documents.
- Constitutional Critique direct
Treat A's best kept output as the draft to check: test it against each rule of the constitution and fix only the rules that fail.
It can take the result of
- Planning
- Supervisor & Specialists
- Blackboard
- Episodic + Semantic Memory
- Tree of Thoughts
- Ensemble
- Metacognitive Triage
- Self-Discover
- Chain of Verification
- Self-Consistency
- STORM
- Tiered Memory
- Workflow Memory
- Handoff
- Map-Reduce
- Shared Task List
- Sleep-time Consolidation
- Graph of Thoughts
- Dynamic Agent Generation
- Recursive Agent Harness
- Tool Use
- ReAct
- Plan–Execute–Verify
- Mental Simulation
- Meta-Controller
- Graph Memory
- Agentic RAG
- Corrective RAG
- Self-RAG
- Adaptive RAG
- GraphRAG
- Debate
- Magentic Orchestration
- ReWOO
- LLMCompiler
- Code as Action
- Dual LLM
- Recursive Language Model
- LLM Cascade
- As-Needed Decomposition
- Chain of Agents
- Tool Retrieval
- Trusted Monitoring
- Recoverable Execution
- Speculative Actions