feat: add multi websearch provider

This commit is contained in:
pomelo-nwu
2025-10-24 17:16:14 +08:00
parent 5cf609c367
commit f9f6eb52dd
11 changed files with 955 additions and 4 deletions

View File

@@ -771,6 +771,7 @@ export async function loadCliConfig(
output: {
format: (argv.outputFormat ?? settings.output?.format) as OutputFormat,
},
webSearch: settings.webSearch,
});
}

View File

@@ -1055,6 +1055,25 @@ const SETTINGS_SCHEMA = {
},
},
webSearch: {
type: 'object',
label: 'Web Search',
category: 'Advanced',
requiresRestart: true,
default: undefined as
| {
provider: Array<{
type: 'tavily' | 'google' | 'dashscope';
apiKey?: string;
searchEngineId?: string;
}>;
default: string;
}
| undefined,
description: 'Configuration for web search providers.',
showInDialog: false,
},
experimental: {
type: 'object',
label: 'Experimental',