Find answers from the community

m
mwon
Offline, last seen 3 months ago
Joined September 25, 2024
m
mwon
·

OpenAI

Hi,

Quick question. I'm using OpenAIPydanticProgram, to get structured data from gpt4. How do I get from its output info about the call? I want to know, for exemple, outut and input tokens used. This is my code:

program = OpenAIPydanticProgram.from_defaults( output_cls=ListItems, llm=llm, prompt=prompt, verbose=True, ) output = program(capitulo=capitulo,posicao = posicao,exemplos = exemplos)

Can I get that kind of info from output?
3 comments
W
m