From a58922d579f62b77825a5ccb622fe52f7e123077 Mon Sep 17 00:00:00 2001 From: krut_ni Date: Tue, 24 Feb 2026 14:42:57 +0100 Subject: [PATCH] improved and adapted the fallback --- .../PluginSystem/Assistants/PluginAssistants.cs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/app/MindWork AI Studio/Tools/PluginSystem/Assistants/PluginAssistants.cs b/app/MindWork AI Studio/Tools/PluginSystem/Assistants/PluginAssistants.cs index 89e675d5..b5437601 100644 --- a/app/MindWork AI Studio/Tools/PluginSystem/Assistants/PluginAssistants.cs +++ b/app/MindWork AI Studio/Tools/PluginSystem/Assistants/PluginAssistants.cs @@ -42,28 +42,28 @@ public sealed class PluginAssistants(bool isInternal, LuaState state, PluginType // Ensure that the main ASSISTANT table exists and is a valid Lua table: if (!this.state.Environment["ASSISTANT"].TryRead(out var assistantTable)) { - message = TB("The ASSISTANT table does not exist or is not a valid table."); + message = TB("The ASSISTANT lua table does not exist or is not a valid table."); return false; } if (!assistantTable.TryGetValue("Title", out var assistantTitleValue) || !assistantTitleValue.TryRead(out var assistantTitle)) { - message = TB("The ASSISTANT table does not contain a valid title."); + message = TB("The provided ASSISTANT lua table does not contain a valid title."); return false; } if (!assistantTable.TryGetValue("Description", out var assistantDescriptionValue) || !assistantDescriptionValue.TryRead(out var assistantDescription)) { - message = TB("The ASSISTANT table does not contain a valid description."); + message = TB("The provided ASSISTANT lua table does not contain a valid description."); return false; } if (!assistantTable.TryGetValue("SystemPrompt", out var assistantSystemPromptValue) || !assistantSystemPromptValue.TryRead(out var assistantSystemPrompt)) { - message = TB("The ASSISTANT table does not contain a valid system prompt."); + message = TB("The provided ASSISTANT lua table does not contain a valid system prompt."); return false; } @@ -77,7 +77,7 @@ public sealed class PluginAssistants(bool isInternal, LuaState state, PluginType if (!assistantTable.TryGetValue("AllowProfiles", out var assistantAllowProfilesValue) || !assistantAllowProfilesValue.TryRead(out var assistantAllowProfiles)) { - message = TB("The ASSISTANT table does not contain a the boolean flag to control the allowance of profiles."); + message = TB("The provided ASSISTANT lua table does not contain the boolean flag to control the allowance of profiles."); return false; } @@ -90,13 +90,13 @@ public sealed class PluginAssistants(bool isInternal, LuaState state, PluginType // Ensure that the UI table exists nested in the ASSISTANT table and is a valid Lua table: if (!assistantTable.TryGetValue("UI", out var uiVal) || !uiVal.TryRead(out var uiTable)) { - message = TB("The ASSISTANT table does not contain a valid UI section."); + message = TB("The provided ASSISTANT lua table does not contain a valid UI table."); return false; } if (!this.TryReadRenderTree(uiTable, out var rootComponent)) { - message = TB("Failed to parse the UI render tree."); + message = TB("Failed to parse the UI render tree from the ASSISTANT lua table."); return false; }