Spaces:
Sleeping
Sleeping
mchinea
commited on
Commit
·
e182059
1
Parent(s):
751494a
update tools
Browse files
tools.py
CHANGED
|
@@ -31,13 +31,13 @@ def web_search(query: str) -> ToolMessage:
|
|
| 31 |
|
| 32 |
@tool
|
| 33 |
def search_tool(query: str) -> str:
|
| 34 |
-
"""Search in Google and returns an string with title, link, and snippet for the top
|
| 35 |
Args:
|
| 36 |
query: str
|
| 37 |
Returns:
|
| 38 |
-
Title, link, and snippet for the top
|
| 39 |
"""
|
| 40 |
-
searcher = GoogleSerperAPIWrapper(k=
|
| 41 |
retries = 3
|
| 42 |
result = ""
|
| 43 |
while retries > 0:
|
|
|
|
| 31 |
|
| 32 |
@tool
|
| 33 |
def search_tool(query: str) -> str:
|
| 34 |
+
"""Search in Google and returns an string with title, link, and snippet for the top 5 results.
|
| 35 |
Args:
|
| 36 |
query: str
|
| 37 |
Returns:
|
| 38 |
+
Title, link, and snippet for the top 5 results
|
| 39 |
"""
|
| 40 |
+
searcher = GoogleSerperAPIWrapper(k=5)
|
| 41 |
retries = 3
|
| 42 |
result = ""
|
| 43 |
while retries > 0:
|