enable lm management editor for business and enterprise#288966
enable lm management editor for business and enterprise#288966
Conversation
There was a problem hiding this comment.
Pull request overview
This PR aims to enable the language models management editor for Business and Enterprise tier users by updating preconditions and add button logic.
Changes:
- Added Business and Enterprise plan context keys to the "Manage Language Models" command preconditions
- Modified the add button enablement logic in the models widget to explicitly exclude Business and Enterprise users from adding models
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/vs/workbench/contrib/chat/browser/chatManagement/chatManagement.contribution.ts | Adds planBusiness and planEnterprise to the precondition for the "Manage Language Models" command, allowing Business and Enterprise users to open the management editor |
| src/vs/workbench/contrib/chat/browser/chatManagement/chatModelsWidget.ts | Refactors add button logic and explicitly excludes Business and Enterprise users from adding models by updating the supportsAddingModels condition |
| && entitlement !== ChatEntitlement.Available | ||
| && entitlement !== ChatEntitlement.Business | ||
| && entitlement !== ChatEntitlement.Enterprise); |
There was a problem hiding this comment.
The PR title states "enable lm management editor for business and enterprise", but this code explicitly disables the ability for Business and Enterprise users to add models. The old code allowed any user with a plan (including Business and Enterprise) to add models via hasPlan, but now Business and Enterprise are explicitly excluded from supportsAddingModels.
If this is intentional (e.g., Business/Enterprise users can view but not add models), the PR title should be clarified to reflect this nuanced behavior. If it's not intentional, the logic should be corrected to allow Business and Enterprise users to add models.
| && entitlement !== ChatEntitlement.Available | |
| && entitlement !== ChatEntitlement.Business | |
| && entitlement !== ChatEntitlement.Enterprise); | |
| && entitlement !== ChatEntitlement.Available); |
No description provided.