ChatGPT Can't Count Characters?

Hi @AiNewbie

Just for you, I confirmed that the OpenAI completion API method returns the usage:

"usage":{
    "prompt_tokens":8,
    "completion_tokens":8,
    "total_tokens":16}
}

Completion Response:

{
"id":"cmpl-6m19S7dblahblah1CskqR8VRqJjZj6r",
"object":"text_completion",
"created":1676902190,
"model":"text-davinci-003",
"choices":[
    { "text":"\n\nMy favorite color is blue.",
      "index":0,
      "logprobs":null,
      "finish_reason":"stop"}
    ],
"usage":{
    "prompt_tokens":8,
    "completion_tokens":8,
    "total_tokens":16}
}

Of course, this is not “characters” it is “tokens” so probably not useful, sorry.

Hope this helps.

1 Like