Repository navigation
[Exploration] Prototype a managed Auto-tier default - #336833
Closed
Ross Wollman (rwoll) wants to merge 1 commit into
Closed
Ross Wollman (rwoll) wants to merge 1 commit into
Ross Wollman (rwoll) wants to merge 1 commit into
Conversation
Refs #336829. Keep the experimental contract isolated and preserve explicit tier choices without persisting managed defaults. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Policy export, accessibility, restoration, and live picker-update issues remain unresolved.
Get a fresh assessment by requesting another Copilot review.
Review effort: Balanced
Findings: 1
Open (3)
What changed in this PR
Prototypes a managed Auto-tier default across policy projection, chat configuration, picker UX, and Agent Host requests.
Changes:
- Adds the provisional
autoTiermanaged-setting contract. - Applies transient managed defaults without persisting them as user choices.
- Adds store, picker, projection, and Agent Host tests.
| File | Description |
|---|---|
copilotManagedSettings.ts |
Defines managed tier keys. |
copilotManagedSettings.test.ts |
Tests managed-setting projection. |
chat.shared.contribution.ts |
Registers the policy-backed setting. |
languageModels.ts |
Exposes managed-default provenance. |
chatModelConfigurationStore.ts |
Implements default overlay and lifecycle. |
chatInputPart.ts |
Excludes defaults from drafts. |
modelPickerAutoRow.ts |
Displays organization provenance. |
chatManagedAutoTier.test.ts |
Covers store and picker behavior. |
agentHostChatContribution.test.ts |
Tests Agent Host forwarding. |
💡 Configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| scope: ConfigurationScope.APPLICATION, | ||
| included: false, | ||
| description: nls.localize('chat.defaultAutoTier', "Experimental enterprise default for Auto's Optimize for preference. Users can still select a different preference."), | ||
| policy: { |
Comment on lines
+59
to
+64
| this._register(configurationService.onDidChangeConfiguration(event => { | ||
| if (event.affectsConfiguration(COPILOT_AUTO_TIER_CONFIG)) { | ||
| this._autoTierWarnings.clear(); | ||
| for (const modelId of this._overrides.keys()) { | ||
| this._onDidChange.fire(modelId); | ||
| } |
Comment on lines
+124
to
+127
| const managedDefault = tier && this._options.configurationAccess.isModelConfigurationDefaultManaged?.(this._options.autoModel.identifier, tier.key) | ||
| ? localize('chat.modelPicker.autoTierManagedDefault', "Organization default. You can choose another preference.") | ||
| : undefined; | ||
| const parts = [detail, tierDescription, managedDefault].filter(part => !!part); |
Contributor
Member
Author
|
This draft explored the rough shape of the change, but the configuration schema is still being finalized. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


Exploratory implementation, not a shipping proposal
Refs #336829. This draft sizes the managed Auto-tier default through the real model-configuration/picker/request seams. Names, lifecycle semantics, and the cross-client schema are not finalized. No reasoning/context-tier settings, model restrictions, or policy-precedence redesign are proposed here.
Validation limitation: source transpilation and targeted lint pass. The execution environment denied both focused browser and Node unit-test commands. The added tests have not run; no interactive, live-runtime, or end-to-end success is claimed. Full typecheck also remains blocked by checkout prerequisites described below.
Provisional contract
{ "autoTier": "intelligence" }ChatDefaultAutoTierinto hidden, application-scopedchat.experimental.defaultAutoTier. The consumer reads the policy value, not workspace/user values of this delivery slot.efficiency,balance,intelligence. No alias translation,fast, reasoning level, or context tier is invented.chat.defaultModel, user choices, and model eligibility, is unchanged. The tier matters only when a catalog-advertised Auto model supports it.Implemented path
Managed-settings projection → configuration policy → editor-scoped
ChatModelConfigurationStore→ Auto picker andChatWidget.getSelectedModelRequestOptions()→ existing AHPModelSelection.config.tier.The store overlays the default transiently, labels its provenance in the Auto row without disabling controls, and omits it from persisted input drafts/preferences. Selecting any tier, including the currently displayed default or schema-default Balance, becomes an explicit choice.
The existing Agent Host implementation forwards that selection as SDK
capi.autoTieron creation and through model changes. SDK 1.0.14 is already bundled; no SDK/runtime upgrade or parallel routing implementation is added. Ordinary resume deliberately preserves runtime-owned routing state; empty-history fallback uses creation semantics. This draft leaves that distinction intact.The legacy permissions bridge in
agentHostManagedSettings.tsis intentionally untouched. The bundled SDK's host-injectedManagedSettingscontract is permissions-only and rejects unknown siblings: sendingautoTierthere would be wrong. Standalone/headless host defaults and upstream managed-document acceptance remain separate work, not a faked transport success.Edge cases, evidence, and unresolved behavior
“Tests authored” below means coverage exists in this diff, not that it executed.
clear()Local is not assumed equivalent to Agent Host. Local's current extension path reads
modelConfiguration.tier, uses it in Auto routing, and includes the tier in cache compatibility. Its inline-chat resolver intentionally substitutes a surface default when the materialized tier equals Balance, unlike Agent Host. Thus a managed Balance cannot currently express the same inline behavior. No extension changes or claims of Local runtime verification are included. Automation uses another configuration store and is not covered by this widget prototype.Reasoning effort/context configuration share the same snapshot, restore, default-stripping, and persistence machinery. That coupling—not the number of settings—is the significant sizing risk. This draft deliberately does not add speculative reasoning/context policies.
Overlap inspected: existing Auto-tier support and SDK switching (#329463, #333626, #335103, #336597) are reused, not reimplemented. #329405 is a different Local settings experiment; #336533 concerns server-assigned model defaults, not managed tier selection. #327879's default-versus-lock distinction is retained.
Scope and remaining work
The small policy declaration is not the feature's cost. The prototype changes nine TypeScript files and adds 15 test cases (12 store/picker cases, two parameterized AHP cases, one projection case). Completing this is a moderate-to-large state/lifecycle integration, not a settings-only patch:
build/lib/policies/policyData.jsoncis not manually edited or regenerated in this draft. Its official exporter needs the Workbench and Agents application export paths; this checkout lacks Electron prerequisites. Generated administrative templates and final policy naming are explicit completion blockers, not shipped artifacts.Exact validation and limits
Node 24.18.0, matching
.nvmrc.Passed:
Execution denied; not retried through an alternate runner:
npm run typecheck-clientreports 374 diagnostics, including missing generated Electron typings, Electron-derived types, and sparse theme assets. There are no diagnostics in the nine changed files, but this is not a passing full typecheck. The supported prerequisite-restoration command was denied; no bypass was attempted.Dependencies were restored only after a missing-module failure, using
npm ci --ignore-scripts --registry=https://packagefeedproxy.microsoft.io/npm --no-audit --no-fundin the root andbuild. No dependency manifests were changed.