I call chatGPT from Python using openai_client.beta.chat.completions.parse(...,response_format=FoodDiaryEntry)
It spits back a giant response comprising of 750 tokens, pasted here. I’m only interested in response.choices[0].message.parsed
, which is a more modest 300 tokens. While having all the extra junk doesn’t hurt the code, it does hurt my wallet.
Is there a way to just get the parsed message?