mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-14 01:33:48 +00:00
Register Semantic Search and document its tool ID
This commit is contained in:
2 files changed
+16
-4
No files matched your search
@@ -736,18 +736,27 @@ CONFIG["SETTINGS"] = {}
|
|||||||
|
|
||||||
-- Disable individual tools by their stable tool ID. The default is an empty set.
|
-- Disable individual tools by their stable tool ID. The default is an empty set.
|
||||||
-- Unknown IDs are safely ignored and can be deployed before a future tool is installed.
|
-- Unknown IDs are safely ignored and can be deployed before a future tool is installed.
|
||||||
|
-- semantic_search lets the model search the data sources of a chat itself. Nobody selects it:
|
||||||
|
-- it offers itself whenever a chat has data sources to search. Disabling it makes AI Studio
|
||||||
|
-- search the data sources with every message instead, the way it does for models without
|
||||||
|
-- tool usage.
|
||||||
-- CONFIG["SETTINGS"]["DataTools.DisabledToolIds"] = { "web_search" }
|
-- CONFIG["SETTINGS"]["DataTools.DisabledToolIds"] = { "web_search" }
|
||||||
|
|
||||||
-- Configure the minimum provider confidence level required for individual tools.
|
-- Configure the minimum provider confidence level required for individual tools.
|
||||||
-- Tool IDs include: web_search, read_web_page, search_confluence
|
-- Tool IDs include: web_search, read_web_page, search_confluence, semantic_search
|
||||||
-- Allowed values are: NONE, UNTRUSTED, VERY_LOW, LOW, MODERATE, MEDIUM, HIGH
|
-- Allowed values are: NONE, UNTRUSTED, VERY_LOW, LOW, MODERATE, MEDIUM, HIGH
|
||||||
-- Defaults: web_search = VERY_LOW, read_web_page = VERY_LOW, search_confluence = HIGH
|
-- Defaults: web_search = VERY_LOW, read_web_page = VERY_LOW, search_confluence = HIGH,
|
||||||
|
-- semantic_search = NONE
|
||||||
-- search_confluence always searches with a HIGH-confidence provider only, whatever value is
|
-- search_confluence always searches with a HIGH-confidence provider only, whatever value is
|
||||||
-- set here.
|
-- set here.
|
||||||
|
-- semantic_search offers a provider only the data sources whose own confidence level it meets,
|
||||||
|
-- so it needs no minimum of its own. A provider below a minimum set here has the data sources
|
||||||
|
-- searched with every message instead.
|
||||||
-- CONFIG["SETTINGS"]["DataTools.MinimumProviderConfidenceByToolId"] = {
|
-- CONFIG["SETTINGS"]["DataTools.MinimumProviderConfidenceByToolId"] = {
|
||||||
-- ["web_search"] = "VERY_LOW",
|
-- ["web_search"] = "VERY_LOW",
|
||||||
-- ["read_web_page"] = "VERY_LOW",
|
-- ["read_web_page"] = "VERY_LOW",
|
||||||
-- ["search_confluence"] = "HIGH"
|
-- ["search_confluence"] = "HIGH",
|
||||||
|
-- ["semantic_search"] = "NONE"
|
||||||
-- }
|
-- }
|
||||||
|
|
||||||
-- Configure the settings of individual tools. Keys are "<tool ID>.<field name>", values are
|
-- Configure the settings of individual tools. Keys are "<tool ID>.<field name>", values are
|
||||||
@@ -1073,7 +1082,8 @@ CONFIG["CHAT_TEMPLATES"] = {}
|
|||||||
-- -- organization switched off. A tool has to meet the confidence requirements of the
|
-- -- organization switched off. A tool has to meet the confidence requirements of the
|
||||||
-- -- provider in use, so it may stay unavailable even though this template names it.
|
-- -- provider in use, so it may stay unavailable even though this template names it.
|
||||||
-- -- Tool IDs include: web_search, read_web_page, search_confluence
|
-- -- Tool IDs include: web_search, read_web_page, search_confluence
|
||||||
-- -- Selecting search_confluence also selects read_web_page.
|
-- -- Selecting search_confluence also selects read_web_page. semantic_search cannot be
|
||||||
|
-- -- selected here: it offers itself whenever the chat has data sources to search.
|
||||||
-- ["ToolIds"] = {
|
-- ["ToolIds"] = {
|
||||||
-- "read_web_page",
|
-- "read_web_page",
|
||||||
-- },
|
-- },
|
||||||
|
|||||||
@@ -14,6 +14,7 @@ using AIStudio.Tools.Security;
|
|||||||
using AIStudio.Tools.Services;
|
using AIStudio.Tools.Services;
|
||||||
using AIStudio.Tools.ToolCallingSystem.Harness;
|
using AIStudio.Tools.ToolCallingSystem.Harness;
|
||||||
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations;
|
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations;
|
||||||
|
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.SemanticSearch;
|
||||||
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch;
|
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch;
|
||||||
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch.SearXNG;
|
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch.SearXNG;
|
||||||
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch.Staan;
|
using AIStudio.Tools.ToolCallingSystem.ToolCallingImplementations.WebSearch.Staan;
|
||||||
@@ -180,6 +181,7 @@ internal sealed class Program
|
|||||||
builder.Services.AddSingleton<IWebSearchBackend, StaanSearchBackend>();
|
builder.Services.AddSingleton<IWebSearchBackend, StaanSearchBackend>();
|
||||||
builder.Services.AddSingleton<IWebSearchBackend, TavilySearchBackend>();
|
builder.Services.AddSingleton<IWebSearchBackend, TavilySearchBackend>();
|
||||||
builder.Services.AddSingleton<IToolImplementation, WebSearchTool>();
|
builder.Services.AddSingleton<IToolImplementation, WebSearchTool>();
|
||||||
|
builder.Services.AddSingleton<IToolImplementation, SemanticSearchTool>();
|
||||||
builder.Services.AddSingleton<IToolDefinitionSource, CodeToolDefinitionSource>();
|
builder.Services.AddSingleton<IToolDefinitionSource, CodeToolDefinitionSource>();
|
||||||
builder.Services.AddSingleton<ToolRegistry>();
|
builder.Services.AddSingleton<ToolRegistry>();
|
||||||
builder.Services.AddSingleton<ToolExecutor>();
|
builder.Services.AddSingleton<ToolExecutor>();
|
||||||
|
|||||||
Reference in new issue
Block a user