OpenAI
O1 Preview
openai/o1-preview
The OpenAI o1 Preview models are designed to spend more time thinking before responding, improving their ability to reason through complex tasks in science, coding, and math. The first model of this series is now available in ChatGPT and the API, with regular updates expected.
Context Window
128,000
Max Output Tokens
32,768
Using O1 Preview with Python API
Using O1 Preview with OpenAI compatible API
import openai
client = openai.Client(
api_key= '{your_api_key}',
base_url="https://api.model.box/v1",
)
response = client.chat.completions.create(
model="openai/o1-preview",
messages: [
{
role: 'user',
content:
'introduce your self',
},
]
)
print(response)