Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -211,27 +211,24 @@ def generate_text(df, country, theme):
|
|
211 |
Summarize the adverse growth for {theme} in {country}. Highlight any increase or decrease compared to previous years and include the cumulative result.
|
212 |
"""
|
213 |
prompt = f"""
|
214 |
-
Here is an example of
|
215 |
|
216 |
-
|
217 |
-
Country: France
|
218 |
Adverse 2020: -0.427975
|
219 |
Adverse 2021: -1.987167
|
220 |
Adverse 2022: -1.195906
|
221 |
Adverse Cumulative: -3.573762
|
222 |
|
223 |
Summary:
|
224 |
-
In the adverse scenario, the growth for GDP in France
|
225 |
|
226 |
Now summarize the following data for {theme} in {country}:
|
227 |
{row_str}
|
228 |
|
229 |
-
The theme is {theme}.
|
230 |
-
-
|
231 |
-
-
|
232 |
-
-
|
233 |
-
|
234 |
-
Ensure the summary reflects the changes in the values clearly.
|
235 |
"""
|
236 |
|
237 |
|
|
|
211 |
Summarize the adverse growth for {theme} in {country}. Highlight any increase or decrease compared to previous years and include the cumulative result.
|
212 |
"""
|
213 |
prompt = f"""
|
214 |
+
Here is an example of a summary:
|
215 |
|
216 |
+
For France (GDP):
|
|
|
217 |
Adverse 2020: -0.427975
|
218 |
Adverse 2021: -1.987167
|
219 |
Adverse 2022: -1.195906
|
220 |
Adverse Cumulative: -3.573762
|
221 |
|
222 |
Summary:
|
223 |
+
In the adverse scenario, the growth for GDP in France was -0.427975% in 2020, worsened to -1.987167% in 2021, and slightly improved to -1.195906% in 2022. The cumulative adverse growth is -3.573762%.
|
224 |
|
225 |
Now summarize the following data for {theme} in {country}:
|
226 |
{row_str}
|
227 |
|
228 |
+
The theme is {theme}. Please:
|
229 |
+
- Describe how the values changed each year.
|
230 |
+
- Mention the cumulative result if available.
|
231 |
+
- Use terms like 'increase' or 'decrease' based on the trends.
|
|
|
|
|
232 |
"""
|
233 |
|
234 |
|