Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions packages/models/src/models/openai.ts
Original file line number Diff line number Diff line change
Expand Up @@ -773,10 +773,10 @@ export const openaiModels = [
{
test: "skip",
providerId: "azure",
stability: "unstable" as const,
modelName: "gpt-5",
inputPrice: 1.25 / 1e6,
outputPrice: 10.0 / 1e6,
discount: 0.3,
cachedInputPrice: 0.125 / 1e6,
Comment on lines 774 to 780
Copy link

Copilot AI Mar 29, 2026

Choose a reason for hiding this comment

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

PR title indicates removing the unstable stability flag for Azure mappings, but this change only removes it for the GPT-5 / GPT-5-mini / GPT-5-nano Azure entries. There are still multiple Azure mappings in this file that set stability: "unstable" (e.g. around openai.ts:1138, 1249, 1297, 1566, 1615, 1664). If the intent is to stop treating Azure as unstable, please remove/update those remaining flags as well (or adjust the PR title/scope to match).

Copilot uses AI. Check for mistakes.
Comment on lines +779 to 780
Copy link

Copilot AI Mar 29, 2026

Choose a reason for hiding this comment

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

discount is placed inconsistently relative to the other pricing fields in the Azure GPT-5 mappings (e.g. here it appears before cachedInputPrice, while elsewhere in this file discounts typically come after cachedInputPrice). Please reorder fields consistently (keep pricing-related fields grouped in the same order) to reduce maintenance mistakes when updating prices later.

Suggested change
discount: 0.3,
cachedInputPrice: 0.125 / 1e6,
cachedInputPrice: 0.125 / 1e6,
discount: 0.3,

Copilot uses AI. Check for mistakes.
requestPrice: 0,
contextSize: 400000,
Expand Down Expand Up @@ -839,11 +839,11 @@ export const openaiModels = [
{
test: "skip",
providerId: "azure",
stability: "unstable" as const,
modelName: "gpt-5-mini",
inputPrice: 0.25 / 1e6,
outputPrice: 2 / 1e6,
cachedInputPrice: 0.025 / 1e6,
discount: 0.3,
requestPrice: 0,
Comment on lines 840 to 847
Copy link

Copilot AI Mar 29, 2026

Choose a reason for hiding this comment

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

This hunk introduces discount: 0.3 for the Azure mappings while also removing stability. That changes effective pricing used by provider/model selection (discount affects cheapest-provider logic), which is a behavior change beyond "remove unstable stability flag". If Azure pricing should remain identical to OpenAI, drop the discount; otherwise please document/justify the Azure discount (and consider applying it consistently across all Azure mappings for this family).

Copilot uses AI. Check for mistakes.
contextSize: 400000,
maxOutput: 128000,
Expand Down Expand Up @@ -905,8 +905,8 @@ export const openaiModels = [
{
test: "skip",
providerId: "azure",
stability: "unstable" as const,
modelName: "gpt-5-nano",
discount: 0.3,
inputPrice: 0.05 / 1e6,
outputPrice: 0.4 / 1e6,
cachedInputPrice: 0.005 / 1e6,
Comment on lines +909 to 912
Copy link

Copilot AI Mar 29, 2026

Choose a reason for hiding this comment

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

In this Azure mapping, discount is inserted before inputPrice (unlike other entries where discount is grouped with the pricing fields, typically after cachedInputPrice). Please keep a consistent field ordering for pricing attributes to avoid overlooking discount when updating token prices.

Suggested change
discount: 0.3,
inputPrice: 0.05 / 1e6,
outputPrice: 0.4 / 1e6,
cachedInputPrice: 0.005 / 1e6,
inputPrice: 0.05 / 1e6,
outputPrice: 0.4 / 1e6,
cachedInputPrice: 0.005 / 1e6,
discount: 0.3,

Copilot uses AI. Check for mistakes.
Expand Down
Loading