Fix compile: restore LoadTrainingAgent for heard RAG (0.16.1).

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Leonid Pershin
2026-08-23 23:27:07 +03:00
co-authored by Cursor
parent e1b5743795
commit f2b92e96ca
2 changed files with 12 additions and 2 deletions
+10
View File
@@ -1681,6 +1681,16 @@ public sealed class AssistentConfig
?? new JObject { ["chat"] = new JArray(), ["memory"] = new JArray() }; ?? new JObject { ["chat"] = new JArray(), ["memory"] = new JArray() };
} }
/// <summary>Heard-examples RAG knobs (legacy training-agent.json on data volume).</summary>
public JObject LoadTrainingAgent()
=> TryReadJson(Path.Combine(_overlayRoot, "training-agent.json"))
?? new JObject
{
["enabled"] = true,
["auto_link_on_approve"] = true,
["heard_quota"] = 3,
};
public List<string> ResolveEnabledSkills(string personaId, JArray clientSkills) public List<string> ResolveEnabledSkills(string personaId, JArray clientSkills)
{ {
var catalog = ListSkills(personaId); var catalog = ListSkills(personaId);
+2 -2
View File
@@ -33,7 +33,7 @@ public partial class SwarmAssistentExtension : Extension
ExtensionAuthor = "mrleo1nid"; ExtensionAuthor = "mrleo1nid";
Description = "Collaborative Krea 2 assistant: Ollama chat, persona presets, vector memory, model cards, Generate loop."; Description = "Collaborative Krea 2 assistant: Ollama chat, persona presets, vector memory, model cards, Generate loop.";
License = "MIT"; License = "MIT";
Version = "0.16.0"; Version = "0.16.1";
Tags = ["tabs", "ui", "llm", "ollama", "krea", "inpaint", "memory", "knowledge", "heard", "books"]; Tags = ["tabs", "ui", "llm", "ollama", "krea", "inpaint", "memory", "knowledge", "heard", "books"];
} }
@@ -81,7 +81,7 @@ public partial class SwarmAssistentExtension : Extension
API.RegisterAPICall(AssistentForgetUserPref, true, PermUse); API.RegisterAPICall(AssistentForgetUserPref, true, PermUse);
API.RegisterAPICall(AssistentClearUserPrefs, true, PermUse); API.RegisterAPICall(AssistentClearUserPrefs, true, PermUse);
API.RegisterAPICall(AssistentClearMemory, true, PermUse); API.RegisterAPICall(AssistentClearMemory, true, PermUse);
Logs.Init("Swarm Assistent extension loaded (0.16.0 knowledge books hub)"); Logs.Init("Swarm Assistent extension loaded (0.16.1 knowledge books hub)");
} }
int CfgInt(string key, int fallback) int CfgInt(string key, int fallback)