simpleaichat icon indicating copy to clipboard operation
simpleaichat copied to clipboard

Check raw openai response

Open arisliang opened this issue 2 years ago • 2 comments

Is it possible to check what the raw openai response is? It contains useful information, such as token usage:

"usage": {
    "completion_tokens": 17,
    "prompt_tokens": 57,
    "total_tokens": 74
  }

arisliang avatar Nov 23 '23 03:11 arisliang

The token counts are already saved as objects in the messages themselves. I don't think there is anything else useful in the raw response, unless you had something in mind.

minimaxir avatar Nov 23 '23 04:11 minimaxir

When custom output_schema is specified, response message won't include token counts. In this case, where do we see the token usage?

arisliang avatar Nov 23 '23 07:11 arisliang