Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,7 +20,7 @@ client_credentials_manager = SpotifyClientCredentials(client_id=client_id, clien
|
|
| 20 |
sp = spotipy.Spotify(client_credentials_manager=client_credentials_manager)
|
| 21 |
|
| 22 |
@tool
|
| 23 |
-
def
|
| 24 |
"""A tool that fetches the most recent album name of a given artist.
|
| 25 |
Args:
|
| 26 |
artist_name: A string representing a valid name of a song.
|
|
@@ -84,7 +84,7 @@ with open("prompts.yaml", 'r') as stream:
|
|
| 84 |
|
| 85 |
agent = CodeAgent(
|
| 86 |
model=model,
|
| 87 |
-
tools=[final_answer,
|
| 88 |
max_steps=6,
|
| 89 |
verbosity_level=1,
|
| 90 |
grammar=None,
|
|
|
|
| 20 |
sp = spotipy.Spotify(client_credentials_manager=client_credentials_manager)
|
| 21 |
|
| 22 |
@tool
|
| 23 |
+
def get_most_recent_album_name(artist_name: str) -> str:
|
| 24 |
"""A tool that fetches the most recent album name of a given artist.
|
| 25 |
Args:
|
| 26 |
artist_name: A string representing a valid name of a song.
|
|
|
|
| 84 |
|
| 85 |
agent = CodeAgent(
|
| 86 |
model=model,
|
| 87 |
+
tools=[final_answer, get_most_recent_album_name], ## add your tools here (don't remove final answer)
|
| 88 |
max_steps=6,
|
| 89 |
verbosity_level=1,
|
| 90 |
grammar=None,
|