Skip to content

fix(core): add MiniMax-M2.7 to regional fallback lists - #5426

Open
octo-patch wants to merge 1 commit into
apache:mainfrom
octo-patch:octo/20260917-model-add-recvunvUGEt7NZ
Open

octo-patch wants to merge 1 commit into
apache:mainfrom
octo-patch:octo/20260917-model-add-recvunvUGEt7NZ

Conversation

@octo-patch

Copy link
Copy Markdown

Reason: MiniMax regional fallback model lists omit MiniMax-M2.7.

Summary

Add MiniMax-M2.7 to the global and China MiniMax fallback lists, keeping MiniMax-M3 as the default.

Verification

Passed:

  • Frozen dependency installation with npm ci.
  • Core build, targeted provider/model catalog tests, and all 846 core tests.
  • npm run lint, npm run format:check, npm run build, and npm run typecheck.
  • npx knip --workspace apps/desktop and npx knip --workspace packages/ui.

AI use

  • No generative tool made a substantive contribution
  • Generative tooling made a substantive contribution

Tool(s) and scope: Codex prepared the fallback-list edits and ran validation. This is an automated submission.

Checklist

  • Tests cover the change and fail without it
  • Lint, format, typecheck and the affected suites pass locally

Does this PR entail a change in behavior?

  • Yes — described under Summary above
  • No

@github-actions github-actions Bot added the effort/XS Under 10 readable lines label Sep 17, 2026

@Astro-Han Astro-Han left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Thanks — small, focused change. I checked the id against the metadata snapshot, both regional lists, the derived plan list, and the existing guards. No blocking issues; two nits below.

What I verified

  • Model id is correct and consistent. MiniMax-M2.7 is an exact key in the models.dev projection for both providers: packages/core/src/model-metadata.generated.ts:586 (provider MiniMax) and :595 (provider MiniMax-cn), both lifecycle: "active" with functionCalling: true, and displayName MiniMax-M2.7. The PascalCase casing matches its siblings in the same blocks (MiniMax-M2.7-highspeed, MiniMax-M3) and is deliberately not the lowercase minimax-m2.7 form used by the aggregator providers (packages/core/src/provider-registry.ts:367, :386, :412 for the Volcengine/Tencent plans). Correct for these two first-party endpoints.
  • Placement covers both regions symmetrically. MiniMax (overseas, api.minimax.io, provider-registry.ts:988-992) and MiniMax-cn (domestic, api.minimaxi.com, :1001-1005) both got the same append.
  • No list is missing. Grepping MiniMax-M3 across the tree, those two are the only hardcoded MiniMax fallback lists. The third MiniMax entry, minimax-coding-plan (provider-registry.ts:823-828), derives its offer from the snapshot via toolCallingModelIds and already yields MiniMax-M2.7, so it needs no edit — good that the PR didn't hardcode there.
  • Low blast radius. Appending keeps fallbackModels[0] === 'MiniMax-M3', which is the new-connection default and the connection-test probe (see the contract comment in packages/core/src/__tests__/provider-catalog-contract.test.ts:187-190). Stored connections, defaults, and discovery are untouched; only the offline offer grows by one row.
  • Existing guards still hold. keeps deprecated snapshot models out of fallback lists (provider-catalog-contract.test.ts:206-217) is satisfied since the id is active, not deprecated.

Nits (non-blocking)

  • MiniMax-cn:MiniMax-M2.7 has no pricing row. The generated table has MiniMax:MiniMax-M2.7 (packages/runtime/src/telemetry/model-pricing.generated.ts:401) but zero MiniMax-cn:* keys; the only China-endpoint row is the hand-written supplement MiniMax-cn:MiniMax-M3 at packages/runtime/src/telemetry/builtin-pricing.ts:74-79. So calls on the new China fallback model will record costBasis: 'unpriced' — a handled state, surfaced as unpricedPricingKey in apps/desktop/src/renderer/application/contracts/session-inspector/session-inspector-panel-model.ts:150 — rather than silently mispricing. Optional follow-up: add a MiniMax-cn:MiniMax-M2.7 supplement row mirroring the M3 rates, or pick it up in the next generated pricing refresh.
  • Nothing pins the new entry. The "Tests cover the change and fail without it" box is unchecked, and no test asserts MiniMax fallback contents today. There's a ready-made precedent for exactly this shape of pin — the Moonshot region test at packages/core/src/__tests__/provider-catalog-contract.test.ts:51-61 asserts fallbackModels.includes('kimi-k3'). A two-line analogue (both regions include MiniMax-M2.7, and fallbackModels[0] remains MiniMax-M3) would stop a future edit from quietly dropping it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effort/XS Under 10 readable lines

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants