Skip to content

Conversation

@gr2m
Copy link
Collaborator

@gr2m gr2m commented Nov 2, 2025

Background

Most new models coming from OpenAI are reasoning now

Summary

If a model is not recognized, it is now treated as a reasoning model.
I also refactored the code so that responses and chat models are sharing the same logic.

Manual Verification

tested with openai examples

Checklist

  • Tests have been added / updated (for bug fixes / features)
  • n/a Documentation has been added / updated (for bug fixes / features)
  • A patch changeset for relevant packages has been added (for bug fixes / features - run pnpm changeset in the project root)
  • I have reviewed this pull request (self-review)

Future Work

Look into adding a flag to manually set if a model is treated as reasoning.

Related Issues

['gpt-5-nano-2025-08-07', 'true'],
['gpt-5-pro', 'true'],
['gpt-5-pro-2025-10-06', 'true'],
['new-unknown-model', 'true'],
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will shorten the list before merging, just wanted to keep it complete for review

@gr2m gr2m added bug Something isn't working ai/provider provider/openai labels Nov 3, 2025
@gr2m gr2m added the backport label Nov 3, 2025
@gr2m gr2m marked this pull request as ready for review November 3, 2025 03:29
@gr2m gr2m requested a review from a team November 3, 2025 03:29
@lgrammel
Copy link
Collaborator

lgrammel commented Nov 3, 2025

i like this solution

@lgrammel
Copy link
Collaborator

lgrammel commented Nov 3, 2025

it changes the defaults for unknown models, so it might be a breaking change for folks who use the openai provider with a different baseurl and provider (instead of openaicompat) for historical reasons. might be good to keep ai sdk 6 only and mention in the migration guide

@gr2m gr2m removed the backport label Nov 3, 2025
@gr2m gr2m merged commit 348fd10 into main Nov 3, 2025
21 checks passed
@gr2m gr2m deleted the openai-reasoning-defaults branch November 3, 2025 22:42
@gr2m gr2m mentioned this pull request Nov 3, 2025
20 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants