Skip to content

fix(combos): inherit model_context_overrides onto effort-suffixed targets (#12475) - #12926

Merged
diegosouzapw merged 2 commits into
diegosouzapw:release/v3.8.51from
HouMinXi:fix/effort-suffix-context-override
Sep 7, 2026
Merged

diegosouzapw merged 2 commits into
diegosouzapw:release/v3.8.51from
HouMinXi:fix/effort-suffix-context-override

Conversation

@HouMinXi

@HouMinXi HouMinXi commented Sep 7, 2026

Copy link
Copy Markdown
Contributor

Summary

Effort-suffixed combo members (GLM-5.3-high, GLM-5.3-Flash-xhigh, GLM-5.2-high) never inherited the base model's model_context_overrides row. The compat filter then used the static catalog and inverted priority order on large requests.

Maintainer confirmed the chokepoint: resolveContextOverrideVerdict() (open-sse/services/combo/contextOverrideGate.ts).

Fixes #12475

Fix

Exact override first. If missing, strip a trailing effort tier (longest-first so -xhigh is not eaten by -high) and look up the base id.

GLM-5.3-high inherits GLM-5.3. An explicit GLM-5.3-high row still wins. Spec entry glm-5.2-high (1M) no longer shadows a smaller persisted base override.

Does not change getResolvedModelContextOverride / capability resolution — that path still has no effort inheritance (existing test).

Tests

tests/unit/combo-effort-suffix-context-override-12475.test.ts — 5/5.

Injection: drop the inherit lookup → 4 fail / 1 pass (exact-row case). Restore → 5/5.

Sibling: combo-context-window-filter + model-context-override-readpath 21/21.

Not in this PR

  • Catalog /v1/models effort_tiers vs provider-advertised set (issue observation 2).
  • Pre-compression estimate in the filter (issue observation 1).
  • getContextOverride capability path (kept exact-match).

⚠️ base-red inherited

Same Fast Quality Gates / glm arity / changelog-integrity fingerprints as sibling OPEN PRs on release/v3.8.51. This diff does not touch those files.

…gets

resolveContextOverrideVerdict looked up the exact variant id
(GLM-5.3-high). Overrides are stored on the base id (GLM-5.3), so the
compat filter fell through to the static catalog and inverted priority
order on large requests (diegosouzapw#12475).

Exact variant rows still win. Suffix match is longest-first so -xhigh
is not eaten by -high.

Signed-off-by: Minxi Hou <houminxi@gmail.com>
Signed-off-by: Minxi Hou <houminxi@gmail.com>
@diegosouzapw
diegosouzapw merged commit e8a9117 into diegosouzapw:release/v3.8.51 Sep 7, 2026
8 of 16 checks passed
@HouMinXi
HouMinXi deleted the fix/effort-suffix-context-override branch September 7, 2026 13:27
muhamadgalihsaputra pushed a commit to niyatna/NiyatnaRoute that referenced this pull request Sep 27, 2026
…gets (diegosouzapw#12475) (diegosouzapw#12926)

Validado numa worktree combinada com as 16 PRs desta leva sobre `release/v3.8.51`: typecheck:core limpo, check-file-size e check-changelog-integrity OK, complexity 2788/3218 e cognitive 1261/1437 (ambos sob a baseline), ESLint 0 erros nos 152 arquivos alterados, 771 testes unitários focados, 49 de integração e a suíte vitest:ui completa (2149) verdes.

A busca do sufixo mais longo primeiro (`-xhigh` antes de `-high`) é o detalhe que faz a herança funcionar em vez de quase-funcionar. Manter `getResolvedModelContextOverride` fora do escopo, com o teste existente registrando que aquele caminho continua sem herança, deixa a fronteira explícita.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(backend): effort-suffixed combo targets don't inherit model context overrides

2 participants