Skip to content

OpenAI o1: make temperature optional #12

@webpolis

Description

@webpolis

The new o1 model does not support setting "temperature". This property should be optional.

➜ curl https://api.openai.com/v1/chat/completions   -H "Content-Type: application/json"   -H "Authorization: Bearer $OPENAI_API_KEY"   -d '{
  "model": "o1-mini", "temperature": 0.5,
  "messages": [
    {
      "role": "user",
      "content": [
        {
          "type": "text",
          "text": "Testing"
        }
      ]
    },
    {
      "role": "assistant",
      "content": [
        {
          "type": "text",
          "text": "Hello! It looks like you'\''re testing. How can I assist you today?"
        }
      ]
    }
  ]
}'
{
  "error": {
    "message": "Unsupported value: 'temperature' does not support 0.5 with this model. Only the default (1) value is supported.",
    "type": "invalid_request_error",
    "param": "temperature",
    "code": "unsupported_value"
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions