Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,6 +20,7 @@ DEFAULT_API_URL = "https://agents-course-unit4-scoring.hf.space"
|
|
| 20 |
class CurrentTimeTool(Tool):
|
| 21 |
def __init__(self):
|
| 22 |
super().__init__()
|
|
|
|
| 23 |
self.description = "Fetches the current local time in a specified timezone. Input should be a timezone string like 'America/New_York'."
|
| 24 |
|
| 25 |
def __call__(self, timezone: str) -> str:
|
|
@@ -34,6 +35,7 @@ class CurrentTimeTool(Tool):
|
|
| 34 |
class WikipediaTool(Tool):
|
| 35 |
def __init__(self):
|
| 36 |
super().__init__()
|
|
|
|
| 37 |
self.description = "Searches Wikipedia for information. Input should be a search query. Optional parameter 'sentences' (default 2) controls summary length."
|
| 38 |
|
| 39 |
def __call__(self, query: str, sentences: int = 2) -> str:
|
|
|
|
| 20 |
class CurrentTimeTool(Tool):
|
| 21 |
def __init__(self):
|
| 22 |
super().__init__()
|
| 23 |
+
self.name="gettime"
|
| 24 |
self.description = "Fetches the current local time in a specified timezone. Input should be a timezone string like 'America/New_York'."
|
| 25 |
|
| 26 |
def __call__(self, timezone: str) -> str:
|
|
|
|
| 35 |
class WikipediaTool(Tool):
|
| 36 |
def __init__(self):
|
| 37 |
super().__init__()
|
| 38 |
+
self.name="searchwiki"
|
| 39 |
self.description = "Searches Wikipedia for information. Input should be a search query. Optional parameter 'sentences' (default 2) controls summary length."
|
| 40 |
|
| 41 |
def __call__(self, query: str, sentences: int = 2) -> str:
|