refactored confidence levels and ensured checks work

This commit is contained in:
PaulKoudelka committed 2026-08-14 12:03:16 +02:00
1 parent 786b106096
commit 88999d985c
44 files changed
+324 -335

No files matched your search

+1 -1
View File
@@ -80,7 +80,7 @@ public sealed record ChatThread
/// <summary>
/// The minimum provider confidence required by data sources used so far.
/// </summary>
public ConfidenceLevel DataComplianceLevel { get; set; } = ConfidenceLevel.NONE;
public ConfidenceLevel DataConfidenceLevel { get; set; } = ConfidenceLevel.NONE;
/// <summary>
/// The name of the chat thread. Usually generated by an AI model or manually edited by the user.
@@ -16,7 +16,7 @@ public static class ChatThreadExtensions
/// One thing which is not so obvious: after RAG was used on this thread, the entire chat
/// thread is kind of a data source by itself. Why? Because the augmentation data collected
/// from the data sources is stored in the chat thread. This means we must check if the
/// selected provider is allowed to use this thread's data security and compliance level.
/// selected provider is allowed to use this thread's data security and confidence level.
/// </remarks>
/// <param name="chatThread">The chat thread to check.</param>
/// <param name="provider">The provider to check.</param>
@@ -36,7 +36,7 @@ public static class ChatThreadExtensions
_ => ConfidenceLevel.NONE,
};
if (!providerConfidenceLevel.AllowsDataSourceComplianceLevel(chatThread.DataComplianceLevel))
if (!providerConfidenceLevel.AllowsDataSourceConfidenceLevel(chatThread.DataConfidenceLevel))
return false;
// The chat thread is available, but the data security is not specified.
+1 -1
View File
@@ -57,7 +57,7 @@ public sealed class ContentText : IContent
if(!chatThread.IsLLMProviderAllowed(provider))
{
LOGGER.LogError("The provider is not allowed for this chat thread due to data security or compliance reasons. Skipping the AI process.");
LOGGER.LogError("The provider is not allowed for this chat thread due to data security or confidence-level requirements. Skipping the AI process.");
await this.CompleteWithoutStreaming();
return chatThread;
}