Skip to content

feat(gui): add suggested combos to the existing workspace - #8914

Merged
lidge-jun merged 28 commits into
devfrom
lane2/carry-8739-suggested-combos
Nov 19, 2026
Merged

lidge-jun merged 28 commits into
devfrom
lane2/carry-8739-suggested-combos

Conversation

@lidge-jun

@lidge-jun lidge-jun commented Nov 18, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Carries the suggested-combos part of feat(gui): Combos overview with suggested combos, provider exclusion and a latest-per-family filter #8739 per the owner's November 15 decision, originally based on 79a85fc97aa18a016b36965515d33f615b77a8c6 and now merged with dev at 9646ad3e4b. The existing Combos workspace now includes Generate, Add to combo, and browser-local dismissals.

  • Exclude providers filters both creation and extension suggestions. The dashboard-only GET and PUT endpoints persist comboSuggestionExcludedProviders in config.json. Existing targets stay in place.

  • Carries applicable review fixes for metered targets, generated ID length, distinct provider/model targets, exclusion state on proxy changes, and unsaved edits. Scope excludes the overview and Advanced navigation changes, the row editor, and Latest per family.

  • Every suggestion can incur paid credits or usage. Generate requires explicit consent to save, and Add to combo requires stored consent. The dashboard-only save route checks consent and exclusions under the config lock and marks every added target as metered.

Consistency contract

The server is authoritative. src/server/management/combo-suggestion-routes.ts enforces the dashboard session, explicit Generate consent, stored consent for Add to combo, provider exclusions under the persisted-config lock, and metered: true on every suggested target. Dashboard gating is advisory: the workspace can briefly offer an action the server then refuses (for example after a remount, or after a change from another tab or the CLI). The server answers 409, and the workspace recovers by re-reading the suggestion policy and combos and showing a message. Client-side staleness windows are accepted as long as the server cannot be bypassed, so this PR adds no further client race hardening. The contract is documented in structure/dashboard-and-usage.md, structure/gui-and-management-api.md, and the English and Spanish combo guides.

Verification

Run on head 9c597f3f8b:

  • The create consent regression and unchecked draft checkbox regression failed at 6dd143e31b and passed after the fix.
  • 189 server and CLI tests passed across suggestion routes and consent, combo target updates, workspace data, and CLI parity.
  • 105 guard tests passed with --isolate: core/Lab boundary, file-size ratchet, test layout, test-layout tooling, and Spanish localization.
  • 53 GUI tests passed across combo suggestions and locale parity. React Doctor 0.9.11 reported no issues in changed scope at warning threshold.
  • Typecheck, structure check, privacy scan, git diff --check, GUI lint, i18n lint, GUI build, and docs-site build passed.
  • NOT RUN: full suites and cross-platform validation. Independent security review is pending.

Generate draft with unchecked paid-target consent and Save combo disabled

Checklist

  • Scope stays focused and avoids unrelated cleanup.
  • Docs or release notes were updated when needed.
  • Security-sensitive changes were reviewed for secrets, auth, and unsafe defaults. Metered consent behavior has focused regression coverage. Independent review is pending.

Co-authored-by: Andrew (agent) wsy1731095638@gmail.com

Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
@coderabbitai

coderabbitai Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

Caution

Review failed

The pull request is closed.

  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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

@github-actions

github-actions Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Contributor

✅ Deterministic PR hygiene checks passed.

lidge-jun and others added 24 commits November 19, 2026 00:35
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
…tions

Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Re-read persisted policy after every exclusion write outcome and keep
suggestion actions gated until the read succeeds.

Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
lidge-jun and others added 2 commits November 19, 2026 10:34
The dashboard-session denial test covered only the raw admin token. Add
enrolled and resumed remembered-admin sessions, which derive from the admin
token, and assert 403 with config.json unchanged for the exclusion PUT and
both suggestion saves (append, create) plus the policy read.

Co-authored-by: Andrew (agent) <wsy1731095638@gmail.com>
@lidge-jun
lidge-jun marked this pull request as ready for review November 19, 2026 02:19
@lidge-jun
lidge-jun requested a review from Ingwannu as a code owner November 19, 2026 02:19
@lidge-jun
lidge-jun merged commit 1d25776 into dev Nov 19, 2026
35 checks passed
@lidge-jun
lidge-jun deleted the lane2/carry-8739-suggested-combos branch November 19, 2026 02:19
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 19, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-19T02:23:36.081682Z 16f9410 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@lidge-jun

Copy link
Copy Markdown
Owner Author

Maintainer integration record: squash-merged on exact head 16f9410 with all 33 required checks green, same-reviewer approval (F28 confirm), and assert-mergeable-review.sh --maintainer-integration OK. Union guards on the merge result with dev da66d3a passed (typecheck; file-size ratchet, test layout, Spanish localization, core/Lab boundary, structure, skill surface: 177 pass; preset/capability count tests: 278 pass). Files also changed on dev since the merge base (merged cleanly): all 11 gui/src/i18n locale files, scripts/test-layout/layout.json, tests/fixtures/test-layout-expected.json, src/config/schema/config-schema.ts, src/server/auth-cors.ts, structure/config.md, structure/dashboard-and-usage.md, structure/providers-and-adapters.md.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 16f9410023

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +92 to +96
const family = (window.label ?? "").toLowerCase().split(/[\s(]/)[0];
const matches = window.modelId
? window.modelId.toLowerCase() === model.toLowerCase()
: !family || window.labelKey !== undefined || model.toLowerCase().startsWith(family);
return matches && window.percent !== undefined ? [window.percent] : [];

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P2 Badge Match quota windows by scope rather than display-label prefixes

For providers with account-wide custom quota windows, this predicate discards valid quota measurements because their display labels do not start with the model name. For example, fetchMinimaxQuota in src/providers/quota/vendor-probes-key.ts emits Coding Plan 5-hour and Coding Plan weekly; neither matches a MiniMax-* model, so the suggestion receives no remaining percentage despite having fresh quota data. Consequently, same-tier suggestions retain catalog order instead of quota order and can put an exhausted provider ahead of an available one. Distinguish account-wide windows from explicitly model-scoped windows rather than inferring scope from arbitrary display labels.

Useful? React with 👍 / 👎.

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

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant