MCPcopy Create free account
hub / github.com/TaskingAI/TaskingAI / to_function_message

Method to_function_message

backend/app/models/tool/tool.py:96–108  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

94 )
95
96 def to_function_message(self):
97 if self.status == 200:
98 return {
99 "role": "function",
100 "content": json.dumps(self.data),
101 "id": self.tool_call_id,
102 }
103 else:
104 return {
105 "role": "function",
106 "content": json.dumps({"status": self.status, "error": self.data}),
107 "id": self.tool_call_id,
108 }

Callers 1

run_toolsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected