Spaces:
Sleeping
Sleeping
update openai model
Browse files- src/few_shot_funcs.py +1 -1
src/few_shot_funcs.py
CHANGED
@@ -60,7 +60,7 @@ def api_call(messages: Dict[str, str], temperature: float = 0.7, top_p: int = 1,
|
|
60 |
"""
|
61 |
A function to call the ChatAPI. Taken in a conversation, and the optional params temperature (controls randomness) and n_responses
|
62 |
"""
|
63 |
-
params = {'model': 'gpt-
|
64 |
response = openai.ChatCompletion.create(**params)
|
65 |
|
66 |
text = [response['choices'][i]['message']['content'] for i in range(n_responses)]
|
|
|
60 |
"""
|
61 |
A function to call the ChatAPI. Taken in a conversation, and the optional params temperature (controls randomness) and n_responses
|
62 |
"""
|
63 |
+
params = {'model': 'gpt-4o-mini', 'messages': messages, 'temperature': temperature, 'max_tokens': MAX_TOKENS, 'n': n_responses, 'top_p': top_p}
|
64 |
response = openai.ChatCompletion.create(**params)
|
65 |
|
66 |
text = [response['choices'][i]['message']['content'] for i in range(n_responses)]
|