Skip to content

Garry's Opinionated OpenClaw/Hermes Agent Brain

TypeScript

fix(verbs): name remember's per-item fields in the items description (#6363)

time-attack70e68d2f3602
diff --git a/scripts/structural-suites.tsv b/scripts/structural-suites.tsv
index 0e43db2df6..db453aea06 100644
--- a/scripts/structural-suites.tsv
+++ b/scripts/structural-suites.tsv
@@ -68,6 +68,7 @@ test/ci-local-empty-mounts.test.ts (file-level) 2 readFileSync
test/claude-cli-recipe.test.ts claude-cli LanguageModel — CLI too old for the provider flags 2 readFileSync
test/claude-cli-recipe.test.ts claude-cli LanguageModel — abort + error envelopes 13 readFileSync
test/claude-cli-recipe.test.ts claude-cli LanguageModel — context isolation 2 readFileSync
+test/claude-cli-recipe.test.ts claude-cli LanguageModel — output cap (#6424) 2 readFileSync
test/claude-cli-recipe.test.ts claude-cli LanguageModel — text-only round trip 4 readFileSync
test/claude-cli-recipe.test.ts claude-cli LanguageModel — tool use 17 readFileSync
test/claude-cli-recipe.test.ts claude-cli recipe registration 2 readFileSync
diff --git a/src/core/operation-manifest.generated.ts b/src/core/operation-manifest.generated.ts
index ec69c2871f..477f763714 100644
--- a/src/core/operation-manifest.generated.ts
+++ b/src/core/operation-manifest.generated.ts
@@ -48,7 +48,7 @@ export const OPERATION_MANIFEST: OperationMeta[] = [
},
"items": {
"type": "array",
- "description": "≤20 facts: [{fact, provenance}]",
+ "description": "≤20 of {fact,entity,provenance,kind,ttl,visibility}",
"items": {
"type": "object"
}
@@ -59,7 +59,7 @@ export const OPERATION_MANIFEST: OperationMeta[] = [
},
"ttl": {
"type": "string",
- "description": "\"30d\", \"12h\" or ISO 8601 time; omit = never."
+ "description": "\"30d\", \"12h\" or ISO 8601; omit = never."
},
"entity": {
"type": "string",
@@ -86,7 +86,7 @@ export const OPERATION_MANIFEST: OperationMeta[] = [
"world",
"private"
],
- "description": "world (default) or private (local CLI only)."
+ "description": "world (default) or private (local CLI)."
},
"replaces": {
"type": "string",
diff --git a/src/core/verbs.ts b/src/core/verbs.ts
index 6258eef11d..da688fa60b 100644
--- a/src/core/verbs.ts
+++ b/src/core/verbs.ts
@@ -68,7 +68,7 @@ const remember: Operation = {
fact: { type: 'string', description: 'One claim.' },
items: {
type: 'array',
- description: '≤20 facts: [{fact, provenance}]',
+ description: '≤20 of {fact,entity,provenance,kind,ttl,visibility}',
items: { type: 'object' },
},
provenance: {
@@ -78,7 +78,7 @@ const remember: Operation = {
},
ttl: {
type: 'string',
- description: '"30d", "12h" or ISO 8601 time; omit = never.',
+ description: '"30d", "12h" or ISO 8601; omit = never.',
},
entity: {
type: 'string',
@@ -95,7 +95,7 @@ const remember: Operation = {
visibility: {
type: 'string',
enum: ['world', 'private'],
- description: 'world (default) or private (local CLI only).',
+ description: 'world (default) or private (local CLI).',
},
replaces: { type: 'string', description: 'fact_id this fact replaces (same entity).', fullSurfaceOnly: true },
},
diff --git a/test/fixtures/goldens/cli/tools-json.json b/test/fixtures/goldens/cli/tools-json.json
index 789f3e490d..ecd73ad9ec 100644
--- a/test/fixtures/goldens/cli/tools-json.json
+++ b/test/fixtures/goldens/cli/tools-json.json
@@ -2,8 +2,8 @@
"golden": {
"exitCode": 0,
"stderr": "",
- "stdoutBytes": 222258,
- "stdoutSha256": "c57b5a6ee1354ed3411589becdcc087ea6d74b14101affa2869bbbb0ce20ce94",
+ "stdoutBytes": 222268,
+ "stdoutSha256": "c5f3afd4f6382a87d9d982ec0927d334dc01ca55e4d5eb8f99ed590e8b0cc704",
"toolNames": [
"remember",
"entity",
@@ -227,7 +227,7 @@
"type": "boolean"
},
"items": {
- "description": "≤20 facts: [{fact, provenance}]",
+ "description": "≤20 of {fact,entity,provenance,kind,ttl,visibility}",
"items": {
"type": "object"
},
@@ -261,11 +261,11 @@
"type": "string"
},
"ttl": {
- "description": "\"30d\", \"12h\" or ISO 8601 time; omit = never.",
+ "description": "\"30d\", \"12h\" or ISO 8601; omit = never.",
"type": "string"
},
"visibility": {
- "description": "world (default) or private (local CLI only).",
+ "description": "world (default) or private (local CLI).",
"enum": [
"world",
"private"
diff --git a/test/mcp-schema-budget.test.ts b/test/mcp-schema-budget.test.ts
index be5cea4373..a54c37b80a 100644
--- a/test/mcp-schema-budget.test.ts
+++ b/test/mcp-schema-budget.test.ts
@@ -177,6 +177,17 @@ describe('minimum guidance (DX-14)', () => {
});
}
+ test('remember items description names entity and the optional item fields on starter and full (#6363)', () => {
+ for (const surface of ['starter', 'full'] as const) {
+ const op = filterOpsForSurface(operations, surface).find(o => o.name === 'remember')!;
+ const [def] = buildToolDefs([op]);
+ const items = (def.inputSchema.properties as Record<string, { description?: string }>).items;
+ for (const field of ['fact', 'entity', 'provenance', 'kind', 'ttl', 'visibility']) {
+ expect(items.description, `${surface}: ${field}`).toContain(field);
+ }
+ }
+ });
+
test('every required input of a starter tool is declared in its schema', () => {
for (const def of buildToolDefs(operations.filter(o => STARTER_OPS.has(o.name)))) {
for (const key of def.inputSchema.required) expect(def.inputSchema.properties, `${def.name}.${key}`).toHaveProperty(key);