Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature Request] support new SEARCH-capable OpenAI models gpt-4o-(mini-)search-preview #6403

Open
DirkSchlossmacher opened this issue Mar 25, 2025 · 0 comments
Labels
enhancement New feature or request

Comments

@DirkSchlossmacher
Copy link

🥰 Feature Description

On Mar,11 2025, OpenAI introduced 2 new models that provide web search as part of chat completions API.

Developers can now get fast, up-to-date answers with clear and relevant citations from the web. In the Responses API, web search is available as a tool when using gpt-4o and gpt-4o-mini, and can be paired with other tools or function calls.

We cannot simply add these models in NextChat with /app/constant.ts:

  • because parameters frequency_penalty and presence_penalty are default parameters for OpenAI calls, but not supported yet for the below models.
  • because interface RequestPayload has props beyond the common minimum of props across all OpenAI models
    see /app/client/platforms/openai.ts
const response = await openai.responses.create({
    model: "gpt-4o",
    tools: [ { type: "web_search_preview" } ],
    input: "What was a positive news story that happened today?",
});

console.log(response.output_text);

https://platform.openai.com/docs/models/gpt-4o-mini-search-preview
GPT-4o mini Search Preview
Fast, affordable small model for web search

https://platform.openai.com/docs/models/gpt-4o-search-preview
GPT-4o Search Preview
GPT model for web search in Chat Completions

Response format
Temperature
1.00
Max tokens
2048
Stop sequences
Enter sequence and press Tab
0/4
Top P
1.00
Frequency penalty
0.00
Presence penalty
0.00

🧐 Proposed Solution

Can we please reduce the export interface RequestPayload to only cover the common minimum of props across all OpenAI models, but not more?
see /app/client/platforms/openai.ts

... and dynamically add props if needed for some models?

📝 Additional Information

No response

@DirkSchlossmacher DirkSchlossmacher added the enhancement New feature or request label Mar 25, 2025
@DirkSchlossmacher DirkSchlossmacher changed the title [Feature Request] [Feature Request] support new SEARCH-capable OpenAI models gpt-4o-(mini-)search-preview Mar 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant