model-selection
Skill33 starsChanged 33 days agoMITView on GitHub
Implement and review desktop selection of configured models through the unified grouped ModelSelect component. Use when adding or changing model dropdowns, model filters, Commit model settings, single-model selection, multi-model selection, provider grouping, or configured-model option construction under apps/desktop.
20 other projects use a version of this.
Adopted by
Steady: 0 new projects took it in the last 4 weeks, none the 4 weeks before.thin data
Most recently taken up by
- alexandre-darmon/ai-pm-skillstheir own version, first seen Nov 15, 2026
- dvy1987/agent-loomtheir own version, first seen Nov 15, 2026
- OsamaSaa3d/production-ai-skillstheir own version, first seen Nov 15, 2026
- Walsworth-Group/physkittheir own version, first seen Nov 8, 2026
- github/squadtheir own version, first seen Nov 8, 2026
- agentstation/skillstheir own version, first seen Nov 1, 2026
Used with
Projects with it also use architectural-proposals, ci-validation-gates and 10 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
Microsoft AzureSkillarchitectural-proposals
How to write comprehensive architectural proposals that drive alignment before code is written
Also in 3 projects that use this
Microsoft AzureSkillci-validation-gates
Defensive CI/CD patterns: semver validation, token checks, retry logic, draft detection — earned from v0.8.22
Also in 3 projects that use this
- +10 more from Azure
Other versions20 projects use a version of this.
Word for word · 1
- leookun/cursor-byok★ 3.2k100% same
Edited · 0
None found.
Wrote their own version · 19
- github/gh-aw★ 5.6ksame name
- github/squad★ 3.4ksame name
- awslabs/agent-plugins★ 943same name
- Resgrid/Core★ 238same name
- nimadorostkar/Claude-Skills-collection★ 33same name
- Azure/apiops-cli★ 32same name
- han69611/math-modeling-skills★ 10same name
- yuanhao667/Skills★ 10same name
- OsamaSaa3d/production-ai-skills★ 8same name
- tstapler/dotfiles★ 8same name
9 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository7 other files it gives its agents.
- AGENTS.mdAGENTS.md
- cursor-prefix-stabilitySkill
- database-schemaSkill
- floating-uiSkill
- frontendSkill
- i18nSkill
- releaseSkill
The file
We split this skill into the rules it gives an agent
12 rules. 0 are common, 7 are distinctive, and 5 are very specific to this project.
0
Common
Most of the 16 edited versions we read keep these.
7
Distinctive
This author's own choices. Worth a look.
5
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 8
Use one presentation component for every UI that selects from already configured models:
- Very specific: line 29
Use ModelSelect when choosing one or more existing configured models.
- Very specific: line 30
Do not implement another model dropdown, reuse generic Select, or add a compatibility wrapper for configured-model selection.
- Very specific: line 31
Keep ModelSelect presentation-only.
- Very specific: line 32
Keep editable model-ID entry in Combobox.
- Distinctive: line 33
Delete replaced model-selection components, exports, styles, helpers, and compatibility paths once references are gone.
- Very specific: line 63
Commit always uses single mode and includes both configured built-in and configured plugin models.
- Distinctive: line 64
Commit settings follow the settings-card edit-state pattern: read mode shows the persisted model, Edit creates a local draft, selection …
- Distinctive: line 73
Keep supplier headers and checkbox options inside the virtualized list.
- Distinctive: line 76
Keep the trigger's open/focus border visible while the portaled menu owns focus.
- Distinctive: line 80
Search the repository for old model-selection components and zero-reference model option helpers.
- Distinctive: line 86
Follow the user's validation instruction.
“Common” is measured: kept by at least 6 in 10 of the 16 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Model Selection
Use one presentation component for every UI that selects from already configured models:
apps/desktop/src/
├── shared/ui/
│ ├── ModelSelect.tsx # Single/multiple selection behavior and grouped floating menu
│ └── ModelSelect.module.scss # Trigger, provider headers, checkbox rows, and footer
├── shared/utils/
│ └── modelProvider.ts # Built-in model provider display name
└── features/
├── home/ # Builds overview multi-select options
└── settings/ # Builds Commit single-select options and persists selection
server/src/
├── cursor/services/commit_message.rs # Validates built-in/plugin IDs and creates Commit invocation
├── provider/router.rs # Routes stable IDs to built-in or plugin providers
└── plugin/registry.rs # Resolves plugin model IDs and executes plugin streamsComponent boundary
- Use
ModelSelectwhen choosing one or more existing configured models. - Do not implement another model dropdown, reuse generic
Select, or add a compatibility wrapper for configured-model selection. - Keep
ModelSelectpresentation-only. Pages own model/plugin state, option construction, filtering, and persistence. - Keep editable model-ID entry in
Combobox; creating or editing a model identifier is input, not configured-model selection. - Delete replaced model-selection components, exports, styles, helpers, and compatibility paths once references are gone.
Option contract
Construct every ModelSelectOption with:
value: stable persisted/request identifier. Built-in models usemodel_hash; plugin models use plugin modelid.label: user-facing model display name.group: supplier display name.icon/iconSrc: model/provider icon when available.
For built-in models, derive group with modelProviderName(model). It uses the configured group_name first and the API hostname otherwise. For plugin models, use the localized provider display name.
Preserve source order within each supplier. The first occurrence of a supplier determines group order.
Modes
Single owner value: string
└── <ModelSelect mode="single"> ── choose one ── close ── persist
Multiple owner value: string[]
└── <ModelSelect mode="multiple"> ── toggle many ── remain open ── apply/filter- Both modes render classic checkbox controls in option rows.
- Single mode allows exactly one checked option and closes immediately after selection.
- Multiple mode supports toggling, clearing, selecting all, and selecting none.
- In multiple mode, every supplier header has a checkbox: unchecked means none selected, checked means all selected, and indeterminate means some selected. Toggling it selects or clears that supplier.
- Indent child model rows relative to their supplier header so hierarchy remains visible.
- Commit always uses single mode and includes both configured built-in and configured plugin models. Its
直连option has value"", belongs to theCursorgroup, and is the first option. - Commit settings follow the settings-card edit-state pattern: read mode shows the persisted model, Edit creates a local draft, selection only changes that draft, Cancel restores the persisted value, and Save persists once before returning to read mode.
- Persist the stable plugin model
idunchanged. Commit generation validates that identifier throughPluginRegistry, then letsProviderRouterdispatch it; do not query the built-in model table for plugin IDs. - Overview filtering uses multiple mode.
Floating-menu invariants
Also apply the project floating-ui and frontend skills:
- Render the menu through a body portal and position it with
@floating-ui/dom. - Keep supplier headers and checkbox options inside the virtualized list; keep multi-select bulk actions outside it.
- Close on Escape and outside pointer interaction, then restore trigger focus.
- Preserve
aria-expanded,aria-controls,aria-haspopup, listbox semantics, and multi-select semantics. - Keep the trigger's open/focus border visible while the portaled menu owns focus.
Review checklist
- Search the repository for old model-selection components and zero-reference model option helpers; delete them instead of retaining fallbacks.
- Confirm all configured-model selectors import
shared/ui/ModelSelect. - Confirm no feature implements checkbox selection, supplier grouping, portal positioning, or bulk actions independently.
- Confirm single/multiple value types cannot be mixed.
- Confirm Commit has
直连first and cannot select multiple values. - Confirm supplier labels are based on supplier identity, not request protocol type.
- Follow the user's validation instruction; when automated tests are not requested, report manual checks without running test or build commands.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

