MCPcopy Create free account
hub / github.com/Paper2Poster/Paper2Poster / __call__

Method __call__

camel/toolkits/function_tool.py:385–399  ·  view source on GitHub ↗
(self, *args: Any, **kwargs: Any)

Source from the content-addressed store, hash-verified

383 )
384
385 def __call__(self, *args: Any, **kwargs: Any) -> Any:
386 if self.synthesize_output:
387 result = self.synthesize_execution_output(args, kwargs)
388 return result
389 else:
390 # Pass the extracted arguments to the indicated function
391 try:
392 result = self.func(*args, **kwargs)
393 return result
394 except Exception as e:
395 raise ValueError(
396 f"Execution of function {self.func.__name__} failed with "
397 f"arguments {args} and {kwargs}. "
398 f"Error: {e}"
399 )
400
401 @staticmethod
402 def validate_openai_tool_schema(

Callers

nothing calls this directly

Calls 1

Tested by

no test coverage detected