mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-17 02:18:00 +00:00
List the preselected data sources that cannot be used right now
This commit is contained in:
5 files changed
+46
-22
No files matched your search
@@ -67,13 +67,6 @@
|
|||||||
<MudTextSwitch Label="@T("AI-based data validation")" Value="@this.aiBasedValidation" LabelOn="@T("Yes, let the AI validate & filter the retrieved data.")" LabelOff="@T("No, use all data retrieved from the data sources.")" ValueChanged="@this.ValidationModeChanged"/>
|
<MudTextSwitch Label="@T("AI-based data validation")" Value="@this.aiBasedValidation" LabelOn="@T("Yes, let the AI validate & filter the retrieved data.")" LabelOff="@T("No, use all data retrieved from the data sources.")" ValueChanged="@this.ValidationModeChanged"/>
|
||||||
}
|
}
|
||||||
|
|
||||||
@if (!this.aiBasedSourceSelection && this.GetUnavailablePreselectedDataSourceNames().Length > 0)
|
|
||||||
{
|
|
||||||
<MudText Typo="Typo.body2" Color="Color.Warning" Class="mb-3">
|
|
||||||
@T("These data sources are preselected, but cannot be used right now, either due to data privacy or confidence-level requirements, or because they are unavailable:") @this.GetUnavailablePreselectedDataSourceNames()
|
|
||||||
</MudText>
|
|
||||||
}
|
|
||||||
|
|
||||||
@switch (this.aiBasedSourceSelection)
|
@switch (this.aiBasedSourceSelection)
|
||||||
{
|
{
|
||||||
case true when this.availableDataSources.Count == 0:
|
case true when this.availableDataSources.Count == 0:
|
||||||
@@ -172,11 +165,24 @@
|
|||||||
</MudExpansionPanels>
|
</MudExpansionPanels>
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@if (!this.aiBasedSourceSelection && this.GetUnavailablePreselectedDataSources().Count > 0)
|
||||||
|
{
|
||||||
|
<MudJustifiedText Typo="Typo.body2" Color="Color.Warning">
|
||||||
|
@T("These data sources are preselected, but cannot be used right now, either due to data privacy or confidence-level requirements, or because they are unavailable:")
|
||||||
|
</MudJustifiedText>
|
||||||
|
<ul class="unavailable-data-sources mb-3 mt-1">
|
||||||
|
@foreach (var source in this.GetUnavailablePreselectedDataSources())
|
||||||
|
{
|
||||||
|
<li>@source.Name</li>
|
||||||
|
}
|
||||||
|
</ul>
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</MudCardContent>
|
</MudCardContent>
|
||||||
<MudCardActions>
|
<MudCardActions>
|
||||||
<MudButton Variant="Variant.Filled" OnClick="@(() => this.HideDataSourceSelection())">
|
<MudButton Variant="Variant.Filled" OnClick="@this.HideDataSourceSelection">
|
||||||
@T("Close")
|
@T("Close")
|
||||||
</MudButton>
|
</MudButton>
|
||||||
</MudCardActions>
|
</MudCardActions>
|
||||||
|
|||||||
@@ -183,19 +183,19 @@ public partial class DataSourceSelection : MSGComponentBase
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Names the preselected data sources which the filters removed.
|
/// Collects the preselected data sources which the filters removed.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <remarks>
|
/// <remarks>
|
||||||
/// This list shows what survived the filters, while the preselection keeps what the user asked
|
/// The list of available sources shows what survived the filters, while the preselection keeps
|
||||||
/// for. Without this, a preselected source which cannot be used right now is simply missing
|
/// what the user asked for. Without this, a preselected source which cannot be used right now
|
||||||
/// from the list, and nothing says so. Preselected ids without a configured source are left
|
/// is simply missing from that list, and nothing says so. Preselected ids without a configured
|
||||||
/// out: that source is gone, not unavailable.
|
/// source are left out: that source is gone, not unavailable.
|
||||||
/// </remarks>
|
/// </remarks>
|
||||||
/// <returns>The names of the unusable preselected data sources, or an empty string when there are none.</returns>
|
/// <returns>The unusable preselected data sources, or an empty list when there are none.</returns>
|
||||||
private string GetUnavailablePreselectedDataSourceNames()
|
private IReadOnlyList<IDataSource> GetUnavailablePreselectedDataSources()
|
||||||
{
|
{
|
||||||
var availableDataSourceIds = this.availableDataSources.Select(ds => ds.Id).ToHashSet(StringComparer.Ordinal);
|
var availableDataSourceIds = this.availableDataSources.Select(ds => ds.Id).ToHashSet(StringComparer.Ordinal);
|
||||||
return string.Join(", ", this.GetDataSourcesFromConfiguredIds().Where(ds => !availableDataSourceIds.Contains(ds.Id)).Select(ds => ds.Name));
|
return this.GetDataSourcesFromConfiguredIds().Where(ds => !availableDataSourceIds.Contains(ds.Id)).ToList();
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task LoadAndApplyFilters()
|
private async Task LoadAndApplyFilters()
|
||||||
|
|||||||
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
* A plain list renders without markers and without indentation here: something in the global
|
||||||
|
* styles takes both off. This is an enumeration of names and wants to read as one, so it states
|
||||||
|
* marker, indentation and spacing itself. MudBlazor's Markdown styles fight the same fight for
|
||||||
|
* their own lists, and need an !important on the display to win it -- hence the one below.
|
||||||
|
*/
|
||||||
|
.unavailable-data-sources {
|
||||||
|
max-height: 10em;
|
||||||
|
overflow-y: auto;
|
||||||
|
overflow-wrap: anywhere;
|
||||||
|
margin-top: 0;
|
||||||
|
padding-left: 1.5em;
|
||||||
|
list-style: disc outside;
|
||||||
|
}
|
||||||
|
|
||||||
|
.unavailable-data-sources li {
|
||||||
|
display: list-item !important;
|
||||||
|
}
|
||||||
+3
-3
@@ -3903,6 +3903,9 @@ UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T168406579"] = "KI-a
|
|||||||
-- AI-based data validation
|
-- AI-based data validation
|
||||||
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1744745490"] = "KI-gestützte Datenvalidierung"
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1744745490"] = "KI-gestützte Datenvalidierung"
|
||||||
|
|
||||||
|
-- These data sources are preselected, but cannot be used right now, either due to data privacy or confidence-level requirements, or because they are unavailable:
|
||||||
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1852534051"] = "Diese Datenquellen sind vorausgewählt, können derzeit jedoch nicht verwendet werden – entweder aufgrund von Datenschutz- oder Vertrauensanforderungen oder weil sie nicht verfügbar sind:"
|
||||||
|
|
||||||
-- Yes, I want to use data sources.
|
-- Yes, I want to use data sources.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1975014927"] = "Ja, ich möchte Datenquellen verwenden."
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1975014927"] = "Ja, ich möchte Datenquellen verwenden."
|
||||||
|
|
||||||
@@ -11589,9 +11592,6 @@ UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCS
|
|||||||
-- Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources.
|
-- Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCSELWITHDYNHEUR::T648937779"] = "Wählt automatisch die passenden Datenquellen basierend auf der letzten Eingabe aus. Wendet am Ende eine heuristische Reduzierung an, um die Anzahl der Datenquellen zu verringern."
|
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCSELWITHDYNHEUR::T648937779"] = "Wählt automatisch die passenden Datenquellen basierend auf der letzten Eingabe aus. Wendet am Ende eine heuristische Reduzierung an, um die Anzahl der Datenquellen zu verringern."
|
||||||
|
|
||||||
-- None of your selected data sources could be used. This answer was created without them.
|
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T2995829558"] = "Keine Ihrer ausgewählten Datenquellen konnte verwendet werden. Diese Antwort wurde ohne sie erstellt."
|
|
||||||
|
|
||||||
-- This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context.
|
-- This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T3047786484"] = "Dieser RAG-Prozess filtert Datenquellen, wählt automatisch passende Quellen aus, ermöglicht optional die manuelle Auswahl von Quellen, ruft Daten ab und überprüft den Abrufkontext automatisch."
|
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T3047786484"] = "Dieser RAG-Prozess filtert Datenquellen, wählt automatisch passende Quellen aus, ermöglicht optional die manuelle Auswahl von Quellen, ruft Daten ab und überprüft den Abrufkontext automatisch."
|
||||||
|
|
||||||
|
|||||||
+3
-3
@@ -3903,6 +3903,9 @@ UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T168406579"] = "AI-S
|
|||||||
-- AI-based data validation
|
-- AI-based data validation
|
||||||
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1744745490"] = "AI-based data validation"
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1744745490"] = "AI-based data validation"
|
||||||
|
|
||||||
|
-- These data sources are preselected, but cannot be used right now, either due to data privacy or confidence-level requirements, or because they are unavailable:
|
||||||
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1852534051"] = "These data sources are preselected, but cannot be used right now, either due to data privacy or confidence-level requirements, or because they are unavailable:"
|
||||||
|
|
||||||
-- Yes, I want to use data sources.
|
-- Yes, I want to use data sources.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1975014927"] = "Yes, I want to use data sources."
|
UI_TEXT_CONTENT["AISTUDIO::COMPONENTS::DATASOURCESELECTION::T1975014927"] = "Yes, I want to use data sources."
|
||||||
|
|
||||||
@@ -11589,9 +11592,6 @@ UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCS
|
|||||||
-- Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources.
|
-- Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCSELWITHDYNHEUR::T648937779"] = "Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources."
|
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::DATASOURCESELECTIONPROCESSES::AGENTICSRCSELWITHDYNHEUR::T648937779"] = "Automatically selects the appropriate data sources based on the last prompt. Applies a heuristic reduction at the end to reduce the number of data sources."
|
||||||
|
|
||||||
-- None of your selected data sources could be used. This answer was created without them.
|
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T2995829558"] = "None of your selected data sources could be used. This answer was created without them."
|
|
||||||
|
|
||||||
-- This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context.
|
-- This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context.
|
||||||
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T3047786484"] = "This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context."
|
UI_TEXT_CONTENT["AISTUDIO::TOOLS::RAG::RAGPROCESSES::AISRCSELWITHRETCTXVAL::T3047786484"] = "This RAG process filters data sources, automatically selects appropriate sources, optionally allows manual source selection, retrieves data, and automatically validates the retrieval context."
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user