You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/tools/definitions.ts
+81-2Lines changed: 81 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -87,6 +87,39 @@ export const TOOLS = [
87
87
required: ["confirmations"],
88
88
},
89
89
},
90
+
{
91
+
name: "reflect_scars",
92
+
description: "End-of-session scar reflection — the closing counterpart to confirm_scars. Mirrors CODA-1's [Scar Reflection] protocol. Call BEFORE session_close to provide evidence of how each surfaced scar was handled. OBEYED: concrete evidence of compliance (min 15 chars). REFUTED: why it didn't apply + what was done instead (min 30 chars). Session close uses reflections to set execution_successful accurately.",
93
+
inputSchema: {
94
+
type: "object"asconst,
95
+
properties: {
96
+
reflections: {
97
+
type: "array",
98
+
items: {
99
+
type: "object",
100
+
properties: {
101
+
scar_id: {
102
+
type: "string",
103
+
description: "UUID of the surfaced scar (from recall or session_start)",
104
+
},
105
+
outcome: {
106
+
type: "string",
107
+
enum: ["OBEYED","REFUTED"],
108
+
description: "OBEYED: followed the scar with evidence. REFUTED: scar didn't apply, explain why.",
109
+
},
110
+
evidence: {
111
+
type: "string",
112
+
description: "Concrete evidence of compliance (OBEYED, min 15 chars) or explanation of why scar didn't apply (REFUTED, min 30 chars).",
113
+
},
114
+
},
115
+
required: ["scar_id","outcome","evidence"],
116
+
},
117
+
description: "One reflection per surfaced scar.",
118
+
},
119
+
},
120
+
required: ["reflections"],
121
+
},
122
+
},
90
123
{
91
124
name: "session_start",
92
125
description: "Initialize session, detect agent, load institutional context (last session, recent decisions, open threads). Scars surface on-demand via recall(). DISPLAY: The result includes a pre-formatted 'display' field visible in the tool result. Output the display field verbatim as your response — tool results are collapsed in the CLI.",
@@ -812,6 +845,29 @@ export const TOOLS = [
812
845
required: ["confirmations"],
813
846
},
814
847
},
848
+
{
849
+
name: "gitmem-rf",
850
+
description: "gitmem-rf (reflect_scars) - End-of-session scar reflection (OBEYED/REFUTED with evidence)",
851
+
inputSchema: {
852
+
type: "object"asconst,
853
+
properties: {
854
+
reflections: {
855
+
type: "array",
856
+
items: {
857
+
type: "object",
858
+
properties: {
859
+
scar_id: {type: "string",description: "UUID of the surfaced scar"},
evidence: {type: "string",description: "Evidence (OBEYED min 15 chars, REFUTED min 30 chars)"},
862
+
},
863
+
required: ["scar_id","outcome","evidence"],
864
+
},
865
+
description: "One reflection per surfaced scar",
866
+
},
867
+
},
868
+
required: ["reflections"],
869
+
},
870
+
},
815
871
{
816
872
name: "gitmem-ss",
817
873
description: "gitmem-ss (session_start) - Initialize session with institutional context. DISPLAY: The result includes a pre-formatted 'display' field. Output the display field verbatim as your response — tool results are collapsed in the CLI.",
evidence: {type: "string",description: "Evidence of compliance or refutation"},
1583
+
},
1584
+
required: ["scar_id","outcome","evidence"],
1585
+
},
1586
+
description: "One reflection per surfaced scar",
1587
+
},
1588
+
},
1589
+
required: ["reflections"],
1590
+
},
1591
+
},
1513
1592
{
1514
1593
name: "gm-refresh",
1515
1594
description: "gm-refresh (session_refresh) - Refresh context for the active session without creating a new one. DISPLAY: The result includes a pre-formatted 'display' field. Output the display field verbatim as your response — tool results are collapsed in the CLI.",
0 commit comments