AutoCommit: Bool → Dropdown (mention/enforce/forbid), leerer System-Prompt fix

This commit is contained in:
Meleki committed 2026-03-02 09:41:26 +01:00
1 parent 7410a18755
commit 40bab457d9
10 files changed
+52 -27

No files matched your search

+2 -2
View File
@@ -54,7 +54,7 @@ public static class AgentEndpoint
Model = body.TryGetProperty("model", out var m) ? m.GetString() ?? "sonnet" : "sonnet",
ToolChoice = body.TryGetProperty("toolChoice", out var tc) ? tc.GetString() ?? "any" : "any",
CustomCommands = customCommands,
AutoCommit = body.TryGetProperty("autoCommit", out var ac) && ac.GetBoolean(),
AutoCommit = body.TryGetProperty("autoCommit", out var ac) ? ac.GetString() ?? "" : "",
UseSoul = !body.TryGetProperty("useSoul", out var us) || us.GetBoolean(),
UseIdentity = !body.TryGetProperty("useIdentity", out var ui) || ui.GetBoolean(),
UseUserInfo = !body.TryGetProperty("useUserInfo", out var uu) || uu.GetBoolean(),
@@ -83,7 +83,7 @@ public static class AgentEndpoint
if (body.TryGetProperty("toolChoice", out var tc)) agent.ToolChoice = tc.GetString();
if (body.TryGetProperty("customCommands", out var cc))
agent.CustomCommands = cc.ValueKind == JsonValueKind.Null ? null : cc.GetRawText();
if (body.TryGetProperty("autoCommit", out var ac)) agent.AutoCommit = ac.GetBoolean();
if (body.TryGetProperty("autoCommit", out var ac)) agent.AutoCommit = ac.GetString() ?? "";
if (body.TryGetProperty("useSoul", out var us)) agent.UseSoul = us.GetBoolean();
if (body.TryGetProperty("useIdentity", out var ui)) agent.UseIdentity = ui.GetBoolean();
if (body.TryGetProperty("useUserInfo", out var uu)) agent.UseUserInfo = uu.GetBoolean();