naman1102 commited on
Commit
2b5d5db
·
1 Parent(s): f5f2409

Update tools.py

Browse files
Files changed (1) hide show
  1. tools.py +5 -1
tools.py CHANGED
@@ -70,11 +70,15 @@ def create_calculator_tool() -> Graph:
70
  "operation": input_data["operation"]
71
  }
72
  }
73
-
74
  workflow = StateGraph(state_schema=CalculatorState)
 
75
  workflow.add_node("calculator", ToolNode(calculator_function))
 
76
  workflow.set_entry_point("calculator")
 
77
  workflow.set_finish_point("calculator")
 
78
  print("Calculator workflow created and compiled")
79
  return workflow.compile()
80
 
 
70
  "operation": input_data["operation"]
71
  }
72
  }
73
+ print("Calculator function defined")
74
  workflow = StateGraph(state_schema=CalculatorState)
75
+ print("Calculator workflow created")
76
  workflow.add_node("calculator", ToolNode(calculator_function))
77
+ print("Calculator tool node added")
78
  workflow.set_entry_point("calculator")
79
+ print("Calculator workflow set entry point")
80
  workflow.set_finish_point("calculator")
81
+ print("Calculator workflow set finish point")
82
  print("Calculator workflow created and compiled")
83
  return workflow.compile()
84