diff --git a/app/MindWork AI Studio/Components/Pages/Agenda/AssistantAgenda.razor.cs b/app/MindWork AI Studio/Components/Pages/Agenda/AssistantAgenda.razor.cs index 55e59d77..ba679070 100644 --- a/app/MindWork AI Studio/Components/Pages/Agenda/AssistantAgenda.razor.cs +++ b/app/MindWork AI Studio/Components/Pages/Agenda/AssistantAgenda.razor.cs @@ -117,7 +117,38 @@ public partial class AssistantAgenda : AssistantBaseCore private string inputWhoIsPresenting = string.Empty; private readonly List contentLines = []; - + + #region Overrides of ComponentBase + + protected override async Task OnInitializedAsync() + { + if (this.SettingsManager.ConfigurationData.Agenda.PreselectOptions) + { + this.inputTopic = this.SettingsManager.ConfigurationData.Agenda.PreselectTopic; + this.inputName = this.SettingsManager.ConfigurationData.Agenda.PreselectName; + this.inputDuration = this.SettingsManager.ConfigurationData.Agenda.PreselectDuration; + this.inputStartTime = this.SettingsManager.ConfigurationData.Agenda.PreselectStartTime; + this.inputObjective = this.SettingsManager.ConfigurationData.Agenda.PreselectObjective; + this.inputModerator = this.SettingsManager.ConfigurationData.Agenda.PreselectModerator; + this.selectedTargetLanguage = this.SettingsManager.ConfigurationData.Agenda.PreselectedTargetLanguage; + this.customTargetLanguage = this.SettingsManager.ConfigurationData.Agenda.PreselectedOtherLanguage; + this.introduceParticipants = this.SettingsManager.ConfigurationData.Agenda.PreselectIntroduceParticipants; + this.isMeetingVirtual = this.SettingsManager.ConfigurationData.Agenda.PreselectIsMeetingVirtual; + this.inputLocation = this.SettingsManager.ConfigurationData.Agenda.PreselectLocation; + this.goingToDinner = this.SettingsManager.ConfigurationData.Agenda.PreselectJointDinner; + this.doingSocialActivity = this.SettingsManager.ConfigurationData.Agenda.PreselectSocialActivity; + this.needToArriveAndDepart = this.SettingsManager.ConfigurationData.Agenda.PreselectArriveAndDepart; + this.durationLunchBreak = this.SettingsManager.ConfigurationData.Agenda.PreselectLunchTime; + this.durationBreaks = this.SettingsManager.ConfigurationData.Agenda.PreselectBreakTime; + this.activeParticipation = this.SettingsManager.ConfigurationData.Agenda.PreselectActiveParticipation; + this.numberParticipants = this.SettingsManager.ConfigurationData.Agenda.PreselectNumberParticipants; + this.providerSettings = this.SettingsManager.ConfigurationData.Providers.FirstOrDefault(x => x.Id == this.SettingsManager.ConfigurationData.Agenda.PreselectedProvider); + } + + await base.OnInitializedAsync(); + } + + #endregion private void OnContentChanged(string content) { diff --git a/app/MindWork AI Studio/Components/Pages/Settings.razor b/app/MindWork AI Studio/Components/Pages/Settings.razor index d6025b21..30341e1f 100644 --- a/app/MindWork AI Studio/Components/Pages/Settings.razor +++ b/app/MindWork AI Studio/Components/Pages/Settings.razor @@ -138,8 +138,36 @@ + Agenda Options + + + + + + + + + + + + + + + + + + + + + @if (this.SettingsManager.ConfigurationData.Agenda.PreselectedTargetLanguage is CommonLanguages.OTHER) + { + + } + + + LLM Agent Options - + Text Content Cleaner Agent diff --git a/app/MindWork AI Studio/Settings/ConfigurationSelectData.cs b/app/MindWork AI Studio/Settings/ConfigurationSelectData.cs index 95269f52..e802a7f7 100644 --- a/app/MindWork AI Studio/Settings/ConfigurationSelectData.cs +++ b/app/MindWork AI Studio/Settings/ConfigurationSelectData.cs @@ -1,3 +1,4 @@ +using AIStudio.Components.Pages.Agenda; using AIStudio.Components.Pages.Coding; using AIStudio.Components.Pages.IconFinder; using AIStudio.Components.Pages.TextSummarizer; @@ -72,6 +73,15 @@ public static class ConfigurationSelectDataFactory yield return new(language.Name(), language); } + public static IEnumerable> GetCommonLanguagesTranslationData() + { + foreach (var language in Enum.GetValues()) + if(language is CommonLanguages.AS_IS) + yield return new("Not yet specified", language); + else + yield return new(language.Name(), language); + } + public static IEnumerable> GetCommonCodingLanguagesData() { foreach (var language in Enum.GetValues()) @@ -83,4 +93,10 @@ public static class ConfigurationSelectDataFactory foreach (var complexity in Enum.GetValues()) yield return new(complexity.Name(), complexity); } + + public static IEnumerable> GetNumberParticipantsData() + { + foreach (var number in Enum.GetValues()) + yield return new(number.Name(), number); + } } \ No newline at end of file diff --git a/app/MindWork AI Studio/Settings/DataModel/Data.cs b/app/MindWork AI Studio/Settings/DataModel/Data.cs index 3d811a56..36c5c324 100644 --- a/app/MindWork AI Studio/Settings/DataModel/Data.cs +++ b/app/MindWork AI Studio/Settings/DataModel/Data.cs @@ -36,4 +36,6 @@ public sealed class Data public DataTextSummarizer TextSummarizer { get; init; } = new(); public DataTextContentCleaner TextContentCleaner { get; init; } = new(); + + public DataAgenda Agenda { get; init; } = new(); } \ No newline at end of file diff --git a/app/MindWork AI Studio/Settings/DataModel/DataAgenda.cs b/app/MindWork AI Studio/Settings/DataModel/DataAgenda.cs new file mode 100644 index 00000000..4ab8ae7c --- /dev/null +++ b/app/MindWork AI Studio/Settings/DataModel/DataAgenda.cs @@ -0,0 +1,59 @@ +using AIStudio.Components.Pages.Agenda; +using AIStudio.Tools; + +namespace AIStudio.Settings.DataModel; + +public sealed class DataAgenda +{ + /// + /// Preselect any agenda options? + /// + public bool PreselectOptions { get; set; } + + public string PreselectName { get; set; } = string.Empty; + + public string PreselectTopic { get; set; } = string.Empty; + + public string PreselectObjective { get; set; } = string.Empty; + + public string PreselectModerator { get; set; } = string.Empty; + + public string PreselectDuration { get; set; } = string.Empty; + + public string PreselectStartTime { get; set; } = string.Empty; + + public bool PreselectIntroduceParticipants { get; set; } + + public NumberParticipants PreselectNumberParticipants { get; set; } = NumberParticipants.NOT_SPECIFIED; + + public bool PreselectActiveParticipation { get; set; } + + public bool PreselectIsMeetingVirtual { get; set; } = true; + + public string PreselectLocation { get; set; } = string.Empty; + + public bool PreselectJointDinner { get; set; } + + public bool PreselectSocialActivity { get; set; } + + public bool PreselectArriveAndDepart { get; set; } + + public int PreselectLunchTime { get; set; } + + public int PreselectBreakTime { get; set; } + + /// + /// Preselect the target language? + /// + public CommonLanguages PreselectedTargetLanguage { get; set; } + + /// + /// Preselect any other language? + /// + public string PreselectedOtherLanguage { get; set; } = string.Empty; + + /// + /// Preselect a agenda provider? + /// + public string PreselectedProvider { get; set; } = string.Empty; +} \ No newline at end of file