naman1102 commited on
Commit
4cc8521
·
1 Parent(s): 84345bd

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -115,7 +115,10 @@ def tool_node(state: AgentState) -> AgentState:
115
  global tool_counter
116
  if tool_counter >= 5:
117
  # If we've already run 5 tools, do nothing
118
- return {}
 
 
 
119
 
120
  tool_counter += 1
121
 
 
115
  global tool_counter
116
  if tool_counter >= 5:
117
  # If we've already run 5 tools, do nothing
118
+ return {
119
+ "messages": state["messages"],
120
+ "final_answer": state.get("final_answer", "No interim answer available.")
121
+ }
122
 
123
  tool_counter += 1
124