I can't for the life of me figure this out: GPT-4 getting "stuck" on certain response types

I’ve found this to be a curious issue with all text generation API’s - davinci, 3.5 turbo, GPT-4, etc. The issue is this:

When the API’s are “born” (AKA fresh API key or trained model), and the temperature is set to say, 1, then they all start out by answering similar prompts with pretty original and unique responses each time. However, the more often I use the API’s, the less original their responses become. It’s almost like API’s seem to “remember” how they answered a similar prompt, and follow suit when asked the prompt again. It’s like they’re substituting actually coming up with unique responses for the memory of how they answered previous responses (no “assistant” functions are being used to cause this to happen by the way, this happens with my custom trained gpt-3 davinci model as well).

I’ll give you an example:

Whether it be a custom trained davinci model or a 3.5 or gpt-4 model, let’s say in the prompt I ask it to tell me a joke and run the prompt 10 separate times, one after another. The API will then tell me 10 jokes, all unique except for, let’s say, two. For the sake of this example, let’s say the two similar responses are both jokes about superheros. I’ll then ask the API to tell me 10 more jokes, and this time 3 are about superheros. Then I’ll run the experiment again and 4 out of the 10 jokes are about superheros. Then again again I’ll run the experiment, and before you know it, all 10 jokes are about superheros. I’ll then switch the prompt around to say “tell me something funny story” instead of “tell me a joke” and guess what the funny story is about? superheros!

My only guess is that OpenAI saves on processing power by having the API’s “remember” responses it gave in the past and choose the most likely response given the similar prompt. However, this cascading effect completely ruins the uniqueness of responses overtime, even when the temperature setting is set quite high.

Has anyone else had trouble with this??


Hmm…I get what you are experiencing. Before I used chatcompletions I sorta experienced the same thing as if the API held a bit of context state of its own; probably to help carry the conversation before chatcompletions and message arrays with roles were available. The following chat was with text-davinci-003:

Here it repeated its own assertions until I interjected. However, for the API to do this well without a message array and roles is impressive. If I didn’t know any better, I’d think the chatbot knew everything I was saying from one individual prompt to the next.

If this is the case

I wonder if saying “forget everything I have said in the past” or “ignore previous responses” or similar would help

It’s common in chatgpt. Maybe you want to try it with the API too

I experienced similar issue when tweaking the required output format. Sometimes it returned the previous iteration even though it wasn’t included in the prompt

I already have “forget all instructions before this prompt” but i’ll try other iterations. Thanks!

Did you come up with any strategy to get unstuck?

I often run into this problem, especially with coding snippets that have some error and when GPT-4 i trying to fix it, the pattern is often like

AI: Here is the corrected version of the code

User: We already tried that and it have us error X.

AI: I apologize for the confusion. You are correct. In order to fix this we need to … Here is the corrected version of code:

User: That is the same as what you gave me a minute ago…

and so on.

Starting a new conversation often helps, but sometimes, the context is necessary to for understanding the problem/requirements, and one is rarely inclined to summarize these manually…