Skip to content

Allow to specify parameters in models #1009

@arnaud-thorel-of

Description

@arnaud-thorel-of

Hi Everyone,

It would be very nice to allow bodyParameters adding in openAIChat

In my case : I can't use gpt 5.1 because it asks to specify temperature: 1

const completion = await openai.chat.completions.create({

I'd like to pass informations like this (maybe it's more in the streamMessages than here :

const completion = await                       
  openai.chat.completions.create({               
    model: "gpt-4.1-mini",                       
    messages: [                                  
      { role: "system", content: prompt }        
    ],                                           
    temperature: env.OPEN_AI_TEMPERATURE,                            
    max_tokens: env.OPEN_AI_MAX_TOKENS,
  });

or maybe better, directly from the models :

"models": [
    {
      "provider": "openai-compatible",
      "baseUrl": "<base-url>",
      "model": "gpt41",
      "displayName": "Gpt 4.1",
      "token": {
        "env": "OPEN_AI_TOKEN"
      },
      "body": {
        "temperature": "1",
        "maxTokens": { "env":  "OPEN_AI_MAX_TOKENS"}
      }
    }
  ]

Thx a lot

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions