mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-11-04 16:27:21 +00:00
Co-authored-by: Thorsten Sommer <SommerEngineering@users.noreply.github.com>
27 lines
3.5 KiB
Plaintext
27 lines
3.5 KiB
Plaintext
@using AIStudio.Settings
|
|
@inherits SettingsDialogBase
|
|
|
|
<MudDialog>
|
|
<TitleContent>
|
|
<MudText Typo="Typo.h6" Class="d-flex align-center">
|
|
<MudIcon Icon="@Icons.Material.Filled.AutoMode" Class="mr-2"/>
|
|
@T("Assistant: Assistant Builder defaults")
|
|
</MudText>
|
|
</TitleContent>
|
|
<DialogContent>
|
|
<MudPaper Class="pa-3 mb-8 border-dashed border rounded-lg">
|
|
<ConfigurationOption OptionDescription="@T("Preselect Assistant Builder options?")" LabelOn="@T("Assistant Builder options are preselected")" LabelOff="@T("No Assistant Builder options are preselected")" State="@(() => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectOptions)" StateUpdate="@(value => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectOptions = value)" OptionHelp="@T("When enabled, the Assistant Builder starts with the defaults configured below. When disabled, it uses the app-wide default provider and preselects no output language.")" IsLocked="() => ManagedConfiguration.TryGet(x => x.AssistantBuilder, x => x.PreselectOptions, out var meta) && meta.IsLocked"/>
|
|
<ConfigurationSelect OptionDescription="@T("Default output language")" Disabled="@this.DefaultsDisabled" SelectedValue="@(() => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedOutputLanguage)" Data="@ConfigurationSelectDataFactory.GetCommonLanguagesOptionalData()" SelectionUpdate="@(value => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedOutputLanguage = value)" OptionHelp="@T("The language in which the assistants you build answer.")" IsLocked="() => ManagedConfiguration.TryGet(x => x.AssistantBuilder, x => x.PreselectedOutputLanguage, out var meta) && meta.IsLocked"/>
|
|
@if (this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedOutputLanguage is CommonLanguages.OTHER)
|
|
{
|
|
<ConfigurationText OptionDescription="@T("Default custom output language")" Disabled="@this.DefaultsDisabled" Icon="@Icons.Material.Filled.Translate" Text="@(() => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedOtherOutputLanguage)" TextUpdate="@(value => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedOtherOutputLanguage = value)" IsLocked="() => ManagedConfiguration.TryGet(x => x.AssistantBuilder, x => x.PreselectedOtherOutputLanguage, out var meta) && meta.IsLocked"/>
|
|
}
|
|
<ConfigurationMinConfidenceSelection Disabled="@this.DefaultsDisabled" RestrictToGlobalMinimumConfidence="@true" SelectedValue="@(() => this.SettingsManager.ConfigurationData.AssistantBuilder.MinimumProviderConfidence)" SelectionUpdate="@(value => this.SettingsManager.ConfigurationData.AssistantBuilder.MinimumProviderConfidence = value)" IsLocked="() => ManagedConfiguration.TryGet(x => x.AssistantBuilder, x => x.MinimumProviderConfidence, out var meta) && meta.IsLocked"/>
|
|
<ConfigurationProviderSelection Component="Components.META_ASSISTANT" Data="@this.AvailableLLMProviders" Disabled="@this.DefaultsDisabled" SelectedValue="@(() => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedProvider)" SelectionUpdate="@(value => this.SettingsManager.ConfigurationData.AssistantBuilder.PreselectedProvider = value)" IsLocked="() => ManagedConfiguration.TryGet(x => x.AssistantBuilder, x => x.PreselectedProvider, out var meta) && meta.IsLocked"/>
|
|
</MudPaper>
|
|
</DialogContent>
|
|
<DialogActions>
|
|
<MudButton OnClick="@this.Close" Variant="Variant.Filled">@T("Close")</MudButton>
|
|
</DialogActions>
|
|
</MudDialog>
|