Spaces:
Sleeping
Sleeping
Update tools/tool_base.py
Browse files- tools/tool_base.py +6 -10
tools/tool_base.py
CHANGED
|
@@ -1,12 +1,8 @@
|
|
| 1 |
class BaseTool:
|
| 2 |
-
name: str
|
| 3 |
-
description: str
|
|
|
|
|
|
|
| 4 |
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
def forward(self, **kwargs):
|
| 9 |
-
raise NotImplementedError("Each tool must implement a `forward` method.")
|
| 10 |
-
|
| 11 |
-
def __call__(self, **kwargs):
|
| 12 |
-
return self.forward(**kwargs)
|
|
|
|
| 1 |
class BaseTool:
|
| 2 |
+
name: str
|
| 3 |
+
description: str
|
| 4 |
+
inputs: dict
|
| 5 |
+
output_type: str
|
| 6 |
|
| 7 |
+
def forward(self, *args, **kwargs):
|
| 8 |
+
raise NotImplementedError("Each tool must implement the forward method.")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|