Skip to main content

Parameters

ParameterTypeDefaultDescription
tool_namestr-The exact name of the tool to be called for this step
parametersDict[str, Any]{}The dictionary of parameters to pass to the tool
descriptionOptional[str]NoneOptional description of what this step accomplishes

Functions

No specific functions - Single tool call in a high-level plan.

title: AnalysisResult sidebarTitle: AnalysisResult

Parameters

ParameterTypeDefaultDescription
evaluationstr-Detailed reasoning and evaluation of the last tool’s result
next_actionLiteral['continue_plan', 'revise_plan', 'final_answer']-Agent directive for the orchestrator: continue, revise, or finalize
reasoningOptional[str]NoneAdditional reasoning for the chosen next action

Functions

No specific functions - Structured output of an automated analysis step.

title: Thought sidebarTitle: Thought

Parameters

ParameterTypeDefaultDescription
reasoningstr-Detailed explanation of understanding and strategy
planList[PlanStep]-Step-by-step execution plan of tool calls
criticismstr-Self-critique identifying potential flaws or ambiguities
actionLiteral['execute_plan', 'request_clarification']'execute_plan'Next action: execute the plan or request clarification
clarification_neededOptional[str]NoneSpecific clarification needed if action is ‘request_clarification’

Functions

No specific functions - Initial structured thinking process for the AI agent.

title: ExecutionResult sidebarTitle: ExecutionResult

Parameters

ParameterTypeDefaultDescription
successbool-Whether the plan execution was successful
final_resultAny-The final synthesized result
execution_historyList[Dict[str, Any]][]History of all tool executions
total_stepsint-Total number of steps executed
revisionsint0Number of plan revisions made

Functions

No specific functions - Result of executing an orchestrated plan.

title: plan_and_execute sidebarTitle: plan_and_execute

Functions

plan_and_execute

Master tool for complex tasks. Executes multi-step plans sequentially. Parameters:
  • thought (Thought): Structured thought object with reasoning, plan, and criticism
Returns:
  • str: Placeholder string - actual execution handled by orchestrator


title: Orchestrator sidebarTitle: Orchestrator

Parameters

ParameterTypeDefaultDescription
agent_instanceAny-The agent instance
taskTask-The task to execute
wrapped_toolsDict[str, Callable]-Dictionary of wrapped tools
is_reasoning_enabledbool-Whether reasoning is enabled
original_user_requeststr-The original user request
execution_historystr-Orchestrator’s execution history
program_counterint0Current step in the plan
pending_planList[PlanStep][]The current plan to execute
revision_countint0Number of plan revisions made
all_toolsDict[str, Callable]-All available tools except plan_and_execute

Functions

execute

Main entry point for orchestrator execution. Parameters:
  • thought (Thought): The initial thought and plan
Returns:
  • Any: The final result of execution

_execute_single_step

Execute a single tool step from the plan. Parameters:
  • step (PlanStep): The step to execute
Returns:
  • Any: The result of the step execution

_inject_analysis

Inject mandatory analysis step after tool execution. Returns:
  • AnalysisResult: The analysis result

_handle_reasoning_step

Handle reasoning injection after tool execution. Parameters:
  • tool_name (str): Name of the tool that was executed
  • result (Any): Result of the tool execution
Returns:
  • bool: Whether to continue execution

_request_plan_revision

Request revised plan based on execution history.

_synthesize_final_answer

Synthesize final answer based on execution history. Returns:
  • Any: The final synthesized answer
I