3

I'm trying to integrate openai (==0.27.6) into my system, and it works kinda fine, however, the replies I'm getting through the API are totally worse than the answers from the web interface (https://chat.openai.com/chat) .

The way I'm using it with the API (python) is:

completitions = openai.ChatCompletion.create(
    model = 'gpt-3.5-turbo',
    messages=[
        {
            'role': 'user',
            'content': prompt,
        }
    ]
)

At this version I'm not using other parameters, like temperature, however, previously with version 0.26.4 I used this:

completitions = openai.Completion.create(\
engine='text-davinci-002',
prompt=prompt,
max_tokens=4000,
n=3,
stop=None,
temperature=0.8
)

.

Do You guys have any idea how can I set the first example code to give similar answers to the web interface? There' re many parameters that can be set, however, I did not find any documentation about the used values for the web interface.

Thanks.

user2194805
  • 1,201
  • 1
  • 17
  • 35

1 Answers1

1

you're using engine='text-davinci-002' which is a variation of GPT-3, and the web portal uses GPT-3.5-turbo

  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Jun 07 '23 at 15:02