We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 5911c1e + 3d19bea commit be39f6fCopy full SHA for be39f6f
browsergym/core/src/browsergym/core/action/highlevel.py
@@ -530,7 +530,7 @@ def to_tool_description(self, api="openai") -> list[dict]:
530
for tool_name, action in self.action_set.items():
531
# Parse the signature to extract parameter names and types
532
parameters = {"type": "object", "properties": {}, "required": []}
533
- signature = inspect.signature(eval(tool_name))
+ signature = inspect.signature(action)
534
for param_name, param in signature.parameters.items():
535
param_type = "string" # Default to string if type is not specified
536
if param.annotation != inspect.Parameter.empty:
0 commit comments