Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -44,7 +44,11 @@ def analyze_figure_of_speech(verse):
|
|
| 44 |
if isinstance(output_json, list): # Ensure it's a list
|
| 45 |
# Extract and format only the values, skipping keys
|
| 46 |
formatted_output = "\n\n".join(
|
| 47 |
-
"
|
|
|
|
|
|
|
|
|
|
|
|
|
| 48 |
)
|
| 49 |
return formatted_output
|
| 50 |
else:
|
|
|
|
| 44 |
if isinstance(output_json, list): # Ensure it's a list
|
| 45 |
# Extract and format only the values, skipping keys
|
| 46 |
formatted_output = "\n\n".join(
|
| 47 |
+
f"{item.get('verses', '')}\n"
|
| 48 |
+
f"{item.get('figure', '')}\n"
|
| 49 |
+
f'"{item.get("phrase", "")}"\n'
|
| 50 |
+
f"{item.get('explanation', '')}"
|
| 51 |
+
for item in output_json
|
| 52 |
)
|
| 53 |
return formatted_output
|
| 54 |
else:
|