t3code icon indicating copy to clipboard operation
t3code copied to clipboard

fix(web): make sidebar project actions reachable by keyboard and screen reader

Open akj opened this issue 3 months ago • 1 comments

Summary

  • swapped the default to max reasoning effort: previously, max was normalized to OmniRoute's internal xhigh value for any model not explicitly whitelisted. This broke every new reasoning-capable model for days or weeks until a version update added it to the registry. Now max passes through to the upstream unchanged by default

  • Global model registry fallback: when a known model (e.g., kimi-k3) is routed through an unknown third-party proxy (TokenRouter, Zemux, OpenRouter, etc.), OmniRoute now scans the entire global registry to resolve the model's capabilities. This means correct reasoning effort handling, context limits, vision support, and tool calling flags are inherited without any manual dashboard override.

  • Degradation preserved: models explicitly flagged in the registry as rejecting both max and xhigh (e.g. Claude Haiku) still get downgraded to high — their highest supported tier — instead of crashing with a 400.

Related Issues

  • Closes #8057
  • Related to #9437 (previous PR, closed due to stale base ( a cut off working tree — a clean recreation for it from branch release/v3.8.50)

Validation

  • [x] Change type: routing
  • [x] Focused tests: node --import tsx/esm --test tests/unit/base-executor-sanitize-effort.test.ts — 46/48 pass (2 pre-existing failures due to migration version collision on upstream base, unrelated to this change)
  • [x] npm run typecheck: core — clean
  • [x] npm run lint — clean
  • [x] Reconciled with release/v3.8.50 tip; focused checks rerun afterward
  • [x] Production-code changes include new and updated automated tests in this PR

Tests Added Or Updated

  • tests/unit/base-executor-sanitize-effort.test.ts — updated 5 existing tests to reflect the new default (max passes through); added 5 new stress tests:
    • completely unknown model passes max through (#8057).
    • unknown model max passes through on all proxy types (#8057) — covers tokenrouter, zemux, openrouter, openai-compatible, custom-proxy
    • proxy-prefixed kimi-k3 resolves and preserves max — covers moonshotai/kimi-k3-free via TokenRouter
    • proxy-prefixed kimi-k3 xhigh maps to max (not high) — verifies graceful xhigh→max resolution for proxied models
    • Claude Haiku max degrades to high (explicitly flagged) — verifies known-limited models still degrade correctly

Coverage Notes

  • Changes are mainly in open-sse/config/providerModels.ts and open-sse/executors/base/reasoningEffort.ts
  • All changed logic has been tested by the updated test suite
  • No coverage regression expected; new tests add positive coverage for the proxy resolution path

Reviewer Notes

  • The 2 failing tests in CI (DefaultExecutor: NVIDIA GLM-5.2...) are a pre-existing migration version collision on the upstream base (version=135 has two files). They are not caused by this PR — they fail on a clean checkout of release/v3.8.50 too.

  • The getGlobalModel() richness-scoring logic in providerModels.ts prefers registry entries with more capability metadata (e.g. Moonshot's canonical kimi-k3 with supportsXHighEffort: false over a minimal stub in another provider's registry). This ensures the correct behavior is inherited even when multiple providers register the same model ID.

  • No migrations, no feature flags, no UI changes.

akj avatar Aug 06 '26 13:08 akj

[!IMPORTANT]

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 5770b0a1-8237-483c-af88-32b5f8153f2a

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • [ ] 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

coderabbitai[bot] avatar Aug 06 '26 13:08 coderabbitai[bot]

Approvability

Verdict: Approved at 302afbb

Macroscope's review found this PR approvable — This localized sidebar fix makes an existing project-settings action accessible through keyboard and screen-reader interactions while retaining mouse behavior. Its runtime impact is limited to combobox event handling, with no schema, deployment, security, billing, or product-default changes.

You can add or adjust custom eligibility rules. Learn more.

macroscopeapp[bot] avatar Aug 06 '26 13:08 macroscopeapp[bot]