feat(llm): improve prompt when no access to web

This commit is contained in:
Elian Doran
2026-04-04 09:24:26 +03:00
parent a5cb9c7de6
commit e4a38fe277

View File

@@ -104,6 +104,13 @@ export abstract class BaseProvider implements LlmProvider {
: noToolsHint;
}
if (!config.enableWebSearch) {
const noWebSearchHint = `You do not have access to web search. If the user asks for current/real-time information, news, or anything that requires searching the web, inform them that "Web search" is disabled and they need to enable it in the chat settings (click on the model name dropdown and toggle "Web search").`;
systemPrompt = systemPrompt
? `${systemPrompt}\n\n${noWebSearchHint}`
: noWebSearchHint;
}
return systemPrompt;
}