+20
-2
@@ -45,3 +45,8 @@ #!/usr/bin/env node | ||
| properties: { | ||
| text: { type: "string", description: "The memory, as a clear standalone statement." }, | ||
| text: { | ||
| type: "string", | ||
| description: "The memory, as a clear standalone statement. Canonical field — always " + | ||
| "prefer it; `content` and `memory` are accepted as aliases for clients " + | ||
| "that send the memory under another name.", | ||
| }, | ||
| type: { | ||
@@ -100,3 +105,16 @@ type: "string", | ||
| // exactly what is wrong and what arrived, so the caller can correct itself. | ||
| const rawText = args.text; | ||
| // | ||
| // Real clients in the wild send the memory under another name — claude.ai/Cowork | ||
| // sends `content` (D-039). Accept the aliases silently and identically: a caller | ||
| // that got the field name wrong still meant to save a memory, and answering it with | ||
| // an error teaches nothing the description doesn't already say. `text` stays | ||
| // canonical and wins whenever it is usable. | ||
| const usable = (v) => typeof v === "string" && v.trim() !== ""; | ||
| const rawText = usable(args.text) | ||
| ? args.text | ||
| : usable(args.content) | ||
| ? args.content | ||
| : usable(args.memory) | ||
| ? args.memory | ||
| : args.text; | ||
| if (typeof rawText !== "string" || rawText.trim() === "") { | ||
@@ -103,0 +121,0 @@ const keys = Object.keys(args); |
+1
-1
@@ -9,2 +9,2 @@ /** | ||
| */ | ||
| export const VERSION = "0.7.3"; | ||
| export const VERSION = "0.7.4"; |
+1
-1
| { | ||
| "name": "jamgate", | ||
| "version": "0.7.3", | ||
| "version": "0.7.4", | ||
| "mcpName": "io.github.amirj4m/jamgate", | ||
@@ -5,0 +5,0 @@ "description": "A neutral, cross-agent memory quality gate for AI agents, delivered as an MCP server — a gate, not a store.", |
218663
0.48%3956
0.46%