rgbkrk / genai

What if GPT could help you notebook?
BSD 3-Clause "New" or "Revised" License
351 stars 36 forks source link

Bump context on pandas dataframes #52

Closed rgbkrk closed 1 year ago

rgbkrk commented 1 year ago

Generated context for Out was pretending to include only 2 rows and 2 columns in Markdown format. That should be bigger but not as big as what it was actually sending (the whole dataframe).

This bumps it up to 5 rows, 20 columns at most by sampling.

Example output sent for context:

request_detail date_closed request_subcategory state city request_category case_id date_opened case_status object_type
744 Storm Problem nan Storm CA Berkeley Streets, Utilities, and Transportation 121000886045 2021-10-24T18:27:00.000 Open Property
193 Commercial Foodware Ordinance 2020-02-19T17:03:00.000 Commercial CA Berkeley Refuse and Recycling 121000751641 2020-02-18T13:47:00.000 Closed Property
580 Commercial Reminder 2019-07-30T09:42:58.000 Commercial CA Berkeley Refuse and Recycling 121000701752 2019-07-23T13:34:48.000 Closed Property
762 Commercial Missed Pickup 2019-07-30T16:05:32.000 Commercial CA Berkeley Refuse and Recycling 121000702908 2019-07-26T16:35:37.000 Closed Property
714 Illegal Dumping - City Property 2019-10-07T10:19:00.000 Clean City Program CA Berkeley Streets, Utilities, and Transportation 121000721155 2019-10-05T16:41:00.000 Closed Property