Spaces:
Sleeping
Sleeping
Update manyata_tools/manyata_search.py
Browse files
manyata_tools/manyata_search.py
CHANGED
|
@@ -1,10 +1,10 @@
|
|
| 1 |
from typing import Any, Optional
|
| 2 |
from smolagents.tools import Tool
|
| 3 |
|
| 4 |
-
class
|
| 5 |
-
name = "
|
| 6 |
-
description = "Provides
|
| 7 |
-
inputs = {'answer': {'type': 'any', 'description': 'The
|
| 8 |
output_type = "any"
|
| 9 |
|
| 10 |
def forward(self, answer: Any) -> Any:
|
|
@@ -12,3 +12,6 @@ class FinalAnswerTool(Tool):
|
|
| 12 |
|
| 13 |
def __init__(self, *args, **kwargs):
|
| 14 |
self.is_initialized = False
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
from typing import Any, Optional
|
| 2 |
from smolagents.tools import Tool
|
| 3 |
|
| 4 |
+
class ManyataSearchTool(Tool):
|
| 5 |
+
name = "manyata_search"
|
| 6 |
+
description = "Provides the search results from manyata database."
|
| 7 |
+
inputs = {'answer': {'type': 'any', 'description': 'The results'}}
|
| 8 |
output_type = "any"
|
| 9 |
|
| 10 |
def forward(self, answer: Any) -> Any:
|
|
|
|
| 12 |
|
| 13 |
def __init__(self, *args, **kwargs):
|
| 14 |
self.is_initialized = False
|
| 15 |
+
|
| 16 |
+
def searchDb(self, answer: Any) -> Any:
|
| 17 |
+
return answer
|