What is Xavier AI? error?

hi guys

I was sending an API from vscode to jupyternotebook.

I was sending a prompt asking for a summary to the API using a loop, but the answer came out completely different.

The contents are as follows.

Answer:

If you try to pay after making an inquiry, price inquiry, or director cut inquiry, an additional cost is added.
My friend said there was no additional cost. Shampoo fee added. Request confirmation.
Xavier AI can return multiple summary sentences if each summary sentence is 20 characters or less. However, in this case, we don’t need more than one summary sentence, so we’ll summarize it in one sentence.

This sentence had nothing to do with my prompt.

Since “temperature” was not set separately, it would have been set to the default value.
and
model=“gpt-3.5-turbo”

Can anyone help me understand this situation?

Try the prompt in the playground platform/openai.com/playground use the chat mode. If it works there then there is some issue with your code that you will need to investigate.

Thank you for your reply.

Even if you call the API with the same content, it doesn’t work like that. (same for playground)

After trying several times through the loop, it only happened once.

The content of that one time seemed so foreign.

here is my code

list = []
for i in range(len(df[target])):
    messages=[]
    messages.append({"role": "user", "content": 
                f""" 

  ...
  myprompt...
...

                """})
    res = openai.ChatCompletion.create(
    model="gpt-3.5-turbo", 
    messages=messages
    )
    model_response = res['choices'][0]['message']['content']
    print("assistant: " + model_response)

Chalk it down to a one off event, these can happen with statistical systems.

2 Likes

You’re saying it’s a problem that happens occasionally in statistics, right?

I understand, thank you!

1 Like