This commit is contained in:
+11
-1
@@ -57,8 +57,15 @@ class AIPlanner(Planner):
|
||||
return [
|
||||
PlannedStep(
|
||||
action=decision.tool_name,
|
||||
description=f"AI planner: {decision.tool_name}({decision.arguments})",
|
||||
description=(
|
||||
f"AI planner: {decision.purpose}"
|
||||
if decision.purpose
|
||||
else f"AI planner: {decision.tool_name}({decision.arguments})"
|
||||
),
|
||||
args=dict(decision.arguments),
|
||||
expected_text=decision.expected_outcome,
|
||||
purpose=decision.purpose,
|
||||
expected_outcome=decision.expected_outcome,
|
||||
prompt=decision.user_prompt or user_prompt,
|
||||
rationale=decision.text_output,
|
||||
thinking=decision.thinking,
|
||||
@@ -78,7 +85,10 @@ def _history_summary(world: "WorldState | None") -> list[dict[str, Any]]:
|
||||
{
|
||||
"page": event.page,
|
||||
"action": event.action,
|
||||
"arguments": dict(event.arguments),
|
||||
"rationale": event.rationale,
|
||||
"purpose": event.purpose,
|
||||
"expected_outcome": event.expected_outcome,
|
||||
"success": event.success,
|
||||
}
|
||||
for event in world.history
|
||||
|
||||
Reference in New Issue
Block a user