open_ai: Use responses API for all models#54910
Merged
Conversation
bennetbo
commented
Apr 27, 2026
| pub fn uses_responses_api(&self) -> bool { | ||
| match self { | ||
| Self::Custom { | ||
| supports_chat_completions, |
Member
Author
There was a problem hiding this comment.
We should probably rename this to use_chat_completions or something, but we need a settings migration for that, so I left it as is for now so we can cherry-pick this to Preview/Stable
benbrandt
approved these changes
Apr 27, 2026
Member
Author
|
/cherry-pick preview |
Member
Author
|
/cherry-pick stable |
This was referenced Apr 27, 2026
zed-zippy Bot
added a commit
that referenced
this pull request
Apr 27, 2026
…eview) (#54990) Cherry-pick of #54910 to preview ---- From the [docs](https://developers.openai.com/api/docs/guides/migrate-to-responses#responses-benefits): > Better performance: Using reasoning models, like GPT-5, with Responses will result in better model intelligence when compared to Chat Completions. Our internal evals reveal a 3% improvement in SWE-bench with same prompt and setup. Agentic by default: The Responses API is an agentic loop, allowing the model to call multiple tools, like web_search, image_generation, file_search, code_interpreter, remote MCP servers, as well as your own custom functions, within the span of one API request. Lower costs: Results in lower costs due to improved cache utilization (40% to 80% improvement when compared to Chat Completions in internal tests). Stateful context: Use store: true to maintain state from turn to turn, preserving reasoning and tool context from turn-to-turn. Flexible inputs: Pass a string with input or a list of messages; use instructions for system-level guidance. Encrypted reasoning: Opt-out of statefulness while still benefiting from advanced reasoning. Future-proof: Future-proofed for upcoming models. Self-Review Checklist: - [x] I've reviewed my own diff for quality, security, and reliability - [x] Unsafe blocks (if any) have justifying comments - [x] The content is consistent with the [UI/UX checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) - [ ] Tests cover the new/changed behavior - [x] Performance impact has been considered and is acceptable Closes #ISSUE Release Notes: - Always use Responses API for OpenAI models Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
tomhoule
pushed a commit
that referenced
this pull request
Apr 27, 2026
From the [docs](https://developers.openai.com/api/docs/guides/migrate-to-responses#responses-benefits): > Better performance: Using reasoning models, like GPT-5, with Responses will result in better model intelligence when compared to Chat Completions. Our internal evals reveal a 3% improvement in SWE-bench with same prompt and setup. Agentic by default: The Responses API is an agentic loop, allowing the model to call multiple tools, like web_search, image_generation, file_search, code_interpreter, remote MCP servers, as well as your own custom functions, within the span of one API request. Lower costs: Results in lower costs due to improved cache utilization (40% to 80% improvement when compared to Chat Completions in internal tests). Stateful context: Use store: true to maintain state from turn to turn, preserving reasoning and tool context from turn-to-turn. Flexible inputs: Pass a string with input or a list of messages; use instructions for system-level guidance. Encrypted reasoning: Opt-out of statefulness while still benefiting from advanced reasoning. Future-proof: Future-proofed for upcoming models. Self-Review Checklist: - [x] I've reviewed my own diff for quality, security, and reliability - [x] Unsafe blocks (if any) have justifying comments - [x] The content is consistent with the [UI/UX checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist) - [ ] Tests cover the new/changed behavior - [x] Performance impact has been considered and is acceptable Closes #ISSUE Release Notes: - Always use Responses API for OpenAI models
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
From the docs:
Self-Review Checklist:
Closes #ISSUE
Release Notes: