Skip to content

Commit 744f1a5

Browse files
assistant: make positron.assistant.filterModels more permissive (#10314)
- A follow up to #10168 / #9983, which caused all OpenAI models to be filtered out, resulting in the provider not showing up in the chat dropdown. ### QA Notes Claude and GPT models should be available by default for all providers. In particular, OpenAI should show up as a provider in chat again. Co-authored-by: Jonathan McPherson <[email protected]>
1 parent a38aac3 commit 744f1a5

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

extensions/positron-assistant/package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -308,10 +308,10 @@
308308
"positron.assistant.filterModels": {
309309
"type": "array",
310310
"default": [
311-
"Claude*",
312-
"GPT*",
313-
"anthropic/claude*",
314-
"openai/gpt*"
311+
"*Claude*",
312+
"*GPT*",
313+
"*claude*",
314+
"*gpt*"
315315
],
316316
"markdownDescription": "%configuration.filterModels.description%",
317317
"items": {

src/vs/workbench/contrib/chat/common/languageModels.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -717,6 +717,7 @@ export class LanguageModelsService implements ILanguageModelsService {
717717
const config = this._configurationService.getValue<{ filterModels: string[] }>('positron.assistant');
718718
this._logService.trace('[LM] Applying model filters:', config.filterModels);
719719
if (config.filterModels.length > 0 && !config.filterModels.some(pattern =>
720+
match(pattern, modelAndIdentifier.identifier) ||
720721
match(pattern, modelAndIdentifier.metadata.id) ||
721722
match(pattern, modelAndIdentifier.metadata.name))
722723
) {
@@ -794,7 +795,7 @@ export class LanguageModelsService implements ILanguageModelsService {
794795
this._logService.trace('[LM] Provider models resolved, firing onDidChangeProviders', vendor);
795796
this._onDidChangeProviders.fire({ added: [vendor] });
796797
this._onLanguageModelChange.fire();
797-
;
798+
;
798799
});
799800
// --- End Positron ---
800801

0 commit comments

Comments
 (0)