Spaces:
Sleeping
Sleeping
Update app.py
Browse filesFixing the over-indent error
app.py
CHANGED
|
@@ -7,7 +7,7 @@ from tools.final_answer import FinalAnswerTool
|
|
| 7 |
|
| 8 |
from Gradio_UI import GradioUI
|
| 9 |
|
| 10 |
-
# Below is
|
| 11 |
@tool
|
| 12 |
def get_bookbrain()-> str:
|
| 13 |
#Keep this format for the description / args / args description but feel free to modify the tool
|
|
@@ -37,7 +37,7 @@ def get_bookbrain()-> str:
|
|
| 37 |
f"Title: {title}\nAuthor: {author}\nTopics: {topics}\nSummary: {summary}"
|
| 38 |
)
|
| 39 |
|
| 40 |
-
|
| 41 |
except Exception as e:
|
| 42 |
return f"Failed to fetch books from BookBrain due to: {str(e)}"
|
| 43 |
|
|
|
|
| 7 |
|
| 8 |
from Gradio_UI import GradioUI
|
| 9 |
|
| 10 |
+
# Below is a tool that gets a list of books from an app I built on Replit
|
| 11 |
@tool
|
| 12 |
def get_bookbrain()-> str:
|
| 13 |
#Keep this format for the description / args / args description but feel free to modify the tool
|
|
|
|
| 37 |
f"Title: {title}\nAuthor: {author}\nTopics: {topics}\nSummary: {summary}"
|
| 38 |
)
|
| 39 |
|
| 40 |
+
return "\n\n---\n\n".join(books_str_list) if books_str_list else "No books found."
|
| 41 |
except Exception as e:
|
| 42 |
return f"Failed to fetch books from BookBrain due to: {str(e)}"
|
| 43 |
|