YashB1 commited on
Commit
ee98be0
·
verified ·
1 Parent(s): e494277

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +25 -5
app.py CHANGED
@@ -220,12 +220,32 @@ india.loc[india['ST_NM'].isin(['Ladakh', 'Jammu & Kashmir']), 'ST_NM'] = 'Jammu
220
  # <your code here>
221
  ```
222
  """
223
- # Loading system prompts
224
- with open("system_prompts.txt", "r") as file:
225
- query_info = file.read()
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
226
 
227
- # Store the content in the variable
228
- query = query_info
229
 
230
  answer = None
231
  code = None
 
220
  # <your code here>
221
  ```
222
  """
223
+ query = f"""I have a pandas dataframe data of PM2.5 and PM10.
224
+ * The columns are 'Timestamp', 'station', 'PM2.5', 'PM10', 'address', 'city', 'latitude', 'longitude',and 'state'.
225
+ * Frequency of data is daily.
226
+ * `pollution` generally means `PM2.5`.
227
+ * You already have df, so don't read the csv file
228
+ * Don't print anything, but save result in a variable `answer` and make it global.
229
+ * Unless explicitly mentioned, don't consider the result as a plot.
230
+ * PM2.5 guidelines: India: 60, WHO: 15.
231
+ * PM10 guidelines: India: 100, WHO: 50.
232
+ * If query asks to plot calendarmap, use library calmap.
233
+ * If result is a plot, show the India and WHO guidelines in the plot.
234
+ * If result is a plot make it in tight layout, save it and save path in `answer`. Example: `answer='plot.png'`
235
+ * If result is a plot, rotate x-axis tick labels by 45 degrees,
236
+ * If result is not a plot, save it as a string in `answer`. Example: `answer='The city is Mumbai'`
237
+ * I have a geopandas.geodataframe india containining the coordinates required to plot Indian Map with states.
238
+ * If the query asks you to plot on India Map, use that geodataframe to plot and then add more points as per the requirements using the similar code as follows : v = ax.scatter(df['longitude'], df['latitude']). If the colorbar is required, use the following code : plt.colorbar(v)
239
+ * If the query asks you to plot on India Map plot the India Map in Beige color
240
+ * Whenever you do any sort of aggregation, report the corresponding standard deviation, standard error and the number of data points for that aggregation.
241
+ * Whenever you're reporting a floating point number, round it to 2 decimal places.
242
+ * Always report the unit of the data. Example: `The average PM2.5 is 45.67 µg/m³`
243
+
244
+ Complete the following code.
245
+
246
+ {template}
247
 
248
+ """
 
249
 
250
  answer = None
251
  code = None