microsoft / microsoft/vscode

Allow runSubagent model param to differentiate same-name models across BYOK groups (vendor/group/id)

Open
#333,355 2 comments 1 reaction 1 assignee Claimed by @vritant24 View on GitHub
feature-request model-byok
Dominant language
TypeScript
Stars
193k
Forks
42.4k
PR merge metrics
PR metrics pending

Description

Problem: When multiple BYOK groups share the `customendpoint` vendor and use the same model display name (e.g. GLM 5.3 Flash in both a Cline group and an openrouter group), the runSubagent tool's model parameter cannot target a specific copy.

for example, to run a subagent you have to say.. run a subagent with model 'GLM 5.3 Flash (customendpoint' .. this is the format expected

Because BYOK can have groups, if same model is available via 2 different groups, currently the subagent tool cannot choose the correct one, and ends up using the first one it finds (apparently)

Where the code lives (seemingly)

- src/vs/workbench/contrib/chat/common/tools/builtinTools/runSubagentTool.ts — model param accepts only "Name (Vendor)"; resolved via lookupLanguageModelByQualifiedName(). No way to pass a group or internal id.
- src/vs/workbench/contrib/chat/common/languageModels.ts — lookupLanguageModelByQualifiedName() returns the first _modelCache match; matchesQualifiedName() only compares name + vendor. With N groups sharing vendor: customendpoint, the winner is silent first-match by chatLanguageModels.json file order.

Proposal

Allow the subagent model param (or prompt files) to accept an unambiguous identifier — `//`

For example being able to use:

hey run a subagent using the model `'GLM 5.3 Flash (customendpoint/openrouter/z-ai/glm-5.3-flash)'`

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.