Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -22,7 +22,7 @@ def my_custom_tool(arg1:str, arg2:int)-> str: #it's import to specify the return
|
|
| 22 |
@tool
|
| 23 |
def get_friends_names(name:str, maxnb: int)-> List[str]: #it's import to specify the return type
|
| 24 |
"""A tool that returns a list of friend of given person
|
| 25 |
-
if
|
| 26 |
retuns up to maxnb elements
|
| 27 |
Args:
|
| 28 |
name: name of persone whos frinds shoulod be returned
|
|
@@ -30,7 +30,7 @@ def get_friends_names(name:str, maxnb: int)-> List[str]: #it's import to specify
|
|
| 30 |
"""
|
| 31 |
|
| 32 |
if name=="Jarek":
|
| 33 |
-
return "Piotrek Jan Pawel Ania".split()
|
| 34 |
return []
|
| 35 |
|
| 36 |
|
|
|
|
| 22 |
@tool
|
| 23 |
def get_friends_names(name:str, maxnb: int)-> List[str]: #it's import to specify the return type
|
| 24 |
"""A tool that returns a list of friend of given person
|
| 25 |
+
if person is not known then returns empty list
|
| 26 |
retuns up to maxnb elements
|
| 27 |
Args:
|
| 28 |
name: name of persone whos frinds shoulod be returned
|
|
|
|
| 30 |
"""
|
| 31 |
|
| 32 |
if name=="Jarek":
|
| 33 |
+
return "Piotrek Jan Pawel Ania".split()[:maxnb]
|
| 34 |
return []
|
| 35 |
|
| 36 |
|