Let tool results restrict a chat to self-hosted providers

This commit is contained in:
Thorsten Sommer committed 2026-09-24 15:07:39 +02:00
1 parent e9460a9cde
commit 4617aa5230
9 files changed
+209 -52

No files matched your search

@@ -223,17 +223,19 @@ public sealed class ToolCallingLoop(ILogger<ToolCallingLoop> logger) : IToolCall
}
toolCallCount++;
var (toolContent, trace, requiredProviderConfidence, sources) = await context.ToolExecutor.ExecuteAsync(
var (toolContent, trace, requiredProviderConfidence, requiredDataSecurity, sources) = await context.ToolExecutor.ExecuteAsync(
call.CallId,
call.ToolName,
call.ArgumentsJson,
context.RunnableTools,
context.Provider,
context.ChatThread,
toolCallCount,
token);
toolResultCharacterCount += toolContent.Length;
context.ChatThread.RequireProviderConfidence(requiredProviderConfidence);
context.ChatThread.RequireDataSecurity(requiredDataSecurity);
toolSources.MergeSources(sources);
await context.AddToolInvocationAsync(trace);