Paperbag commited on
Commit
efd70d5
·
1 Parent(s): 8e56b06

Add docstring to get_image_file function in agent.py to clarify its purpose and usage.

Browse files
Files changed (1) hide show
  1. agent.py +13 -1
agent.py CHANGED
@@ -51,7 +51,19 @@ def web_search(keywords: str, max_results:int = 5) -> str:
51
 
52
  @tool
53
  def get_image_file(task_id):
 
 
 
 
 
 
 
 
 
 
 
54
  pass
 
55
 
56
 
57
  class AgentState(TypedDict):
@@ -81,7 +93,7 @@ def read_message(state: AgentState) -> AgentState:
81
  # return {"messages": messages + [response]}
82
 
83
  # Augment the LLM with tools
84
- tools = [web_search]
85
  tools_by_name = {tool.name: tool for tool in tools}
86
  model_with_tools = model.bind_tools(tools)
87
 
 
51
 
52
  @tool
53
  def get_image_file(task_id):
54
+ """
55
+ Get the image file from the question
56
+ Use cases:
57
+ - Extract Image from the question
58
+
59
+ Args:
60
+ task_id: the task_id of the question
61
+
62
+ Returns:
63
+ Image file result
64
+ """
65
  pass
66
+ return ''
67
 
68
 
69
  class AgentState(TypedDict):
 
93
  # return {"messages": messages + [response]}
94
 
95
  # Augment the LLM with tools
96
+ tools = [web_search,get_image_file]
97
  tools_by_name = {tool.name: tool for tool in tools}
98
  model_with_tools = model.bind_tools(tools)
99