Agent-Files automatisch beim Erstellen anlegen (IDENTITY.md + SOUL.md), Migration-Vorlagen entfernt
This commit is contained in:
1 parent
3fba628bd2
commit
96af4a3421
5 files changed
+55
-69
No files matched your search
@@ -9,15 +9,20 @@ public static class SystemPromptBuilder
|
||||
public static string Build(AgentRecord agent, SessionRecord session, IEnumerable<MessageRecord> markedMessages = null, MemoryService memoryService = null, string agentMemoryDir = null, string dataDir = null)
|
||||
{
|
||||
var parts = new List<string>();
|
||||
parts.Add($"Du bist {agent.Name}.");
|
||||
|
||||
// IDENTITY.md - Wer bin ich
|
||||
// IDENTITY.md - Wer bin ich (ersetzt "Du bist {Name}.")
|
||||
var hasIdentity = false;
|
||||
if (memoryService != null && !string.IsNullOrWhiteSpace(agent.AgentId))
|
||||
{
|
||||
var identity = memoryService.ReadMemoryFile(agent.AgentId, "IDENTITY.md");
|
||||
if (!string.IsNullOrEmpty(identity))
|
||||
{
|
||||
parts.Add(identity);
|
||||
hasIdentity = true;
|
||||
}
|
||||
}
|
||||
if (!hasIdentity)
|
||||
parts.Add($"Du bist {agent.Name}.");
|
||||
|
||||
// SOUL.md - Persönlichkeit + Regeln
|
||||
if (memoryService != null && !string.IsNullOrWhiteSpace(agent.AgentId))
|
||||
|
||||
Reference in new issue
Block a user