Post action improvements: only generate scripts for a certain list of actions (#3676)
This commit is contained in:
@@ -1229,7 +1229,7 @@ class ForgeAgent:
|
||||
}
|
||||
|
||||
results = await ActionHandler.handle_action(scraped_page, task, step, current_page, action)
|
||||
await app.AGENT_FUNCTION.post_action_execution()
|
||||
await app.AGENT_FUNCTION.post_action_execution(action)
|
||||
detailed_agent_step_output.actions_and_results[action_idx] = (
|
||||
action,
|
||||
results,
|
||||
@@ -1404,7 +1404,6 @@ class ForgeAgent:
|
||||
complete_results = await ActionHandler.handle_action(
|
||||
scraped_page, task, step, working_page, complete_action
|
||||
)
|
||||
await app.AGENT_FUNCTION.post_action_execution()
|
||||
detailed_agent_step_output.actions_and_results.append((complete_action, complete_results))
|
||||
await self.record_artifacts_after_action(task, step, browser_state, engine)
|
||||
|
||||
@@ -1424,7 +1423,7 @@ class ForgeAgent:
|
||||
extract_results = await ActionHandler.handle_action(
|
||||
scraped_page, task, step, working_page, extract_action
|
||||
)
|
||||
await app.AGENT_FUNCTION.post_action_execution()
|
||||
await app.AGENT_FUNCTION.post_action_execution(extract_action)
|
||||
detailed_agent_step_output.actions_and_results.append((extract_action, extract_results))
|
||||
|
||||
# If no action errors return the agent state and output
|
||||
|
||||
Reference in New Issue
Block a user