rgbkrk / genai

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

Trim down reprs #22

Closed rgbkrk closed 1 year ago

rgbkrk commented 1 year ago

We should make sure to set pandas display options to something reasonable when using the get_historical_context, because this blows up huge pretty quick

def craft_output_message(output):
    return {
        "content": repr(output),
        "role": "system",
    }

We should always try to keep this under a certain length as well as do any processing in advance for known useful objects.