From 1b3d8d3c08f7d0170623760cab34bfd7d9c9d202 Mon Sep 17 00:00:00 2001 From: Thorsten Sommer Date: Sun, 5 Jan 2025 13:01:04 +0100 Subject: [PATCH] Factored agent content cleaner --- .../SettingsPanelAgentContentCleaner.razor | 10 ++++++++++ .../SettingsPanelAgentContentCleaner.razor.cs | 14 ++++++++++++++ app/MindWork AI Studio/Pages/Settings.razor | 12 ++---------- 3 files changed, 26 insertions(+), 10 deletions(-) create mode 100644 app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor create mode 100644 app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor.cs diff --git a/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor b/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor new file mode 100644 index 00000000..1bcd0b38 --- /dev/null +++ b/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor @@ -0,0 +1,10 @@ + + + + Use Case: this agent is used to clean up text content. It extracts the main content, removes advertisements and other irrelevant things, + and attempts to convert relative links into absolute links so that they can be used. + + + + + \ No newline at end of file diff --git a/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor.cs b/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor.cs new file mode 100644 index 00000000..d597f243 --- /dev/null +++ b/app/MindWork AI Studio/Components/Settings/SettingsPanelAgentContentCleaner.razor.cs @@ -0,0 +1,14 @@ +using AIStudio.Settings; + +using Microsoft.AspNetCore.Components; + +namespace AIStudio.Components.Settings; + +public partial class SettingsPanelAgentContentCleaner : ComponentBase +{ + [Parameter] + public Func>> AvailableLLMProvidersFunc { get; set; } = () => []; + + [Inject] + private SettingsManager SettingsManager { get; init; } = null!; +} \ No newline at end of file diff --git a/app/MindWork AI Studio/Pages/Settings.razor b/app/MindWork AI Studio/Pages/Settings.razor index 27e762ec..5ee7f5d9 100644 --- a/app/MindWork AI Studio/Pages/Settings.razor +++ b/app/MindWork AI Studio/Pages/Settings.razor @@ -4,6 +4,7 @@ @using AIStudio.Provider @using AIStudio.Settings @using AIStudio.Settings.DataModel +@using AIStudio.Components.Settings @using Host = AIStudio.Provider.SelfHosted.Host Settings @@ -531,15 +532,6 @@ - - - - Use Case: this agent is used to clean up text content. It extracts the main content, removes advertisements and other irrelevant things, - and attempts to convert relative links into absolute links so that they can be used. - - - - - + \ No newline at end of file