Spaces:
Runtime error
Runtime error
| from typing import Any, Optional | |
| from smolagents.tools import Tool | |
| class FinalAnswerTool(Tool): | |
| name = "final_answer" | |
| description = "This tool sends the final answer to the user. This tool does not format the answer. Format the answer before using this tool." | |
| inputs = {'answer': {'type': 'any', 'description': 'A well formatted and short final answer to the user`s problem.'}} | |
| output_type = "string" | |
| def forward(self, answer: str) -> str: | |
| return answer | |
| def __init__(self, *args, **kwargs): | |
| self.is_initialized = False | |