Update app.py
Browse files
app.py
CHANGED
@@ -86,7 +86,7 @@ def recommend_ui(partial_song_name):
|
|
86 |
if recommendations is not None:
|
87 |
# Format the recommendations for display
|
88 |
recommendations_formatted = recommendations.to_dict('records')
|
89 |
-
result = "\n".join([f"{rec['track_name']} by {rec['
|
90 |
return result
|
91 |
else:
|
92 |
return "No recommendations could be generated. Please try a different song."
|
|
|
86 |
if recommendations is not None:
|
87 |
# Format the recommendations for display
|
88 |
recommendations_formatted = recommendations.to_dict('records')
|
89 |
+
result = "\n".join([f"{rec['track_name']} by {rec['artists']} (Popularity: {rec['popularity']})" for rec in recommendations_formatted])
|
90 |
return result
|
91 |
else:
|
92 |
return "No recommendations could be generated. Please try a different song."
|