diff --git a/src/vector/self-improvement.ts b/src/vector/self-improvement.ts index ea03207..bc5fc66 100644 --- a/src/vector/self-improvement.ts +++ b/src/vector/self-improvement.ts @@ -713,6 +713,10 @@ activity tracking token (\`pact_\`) minted. Visible on the Foundation dashboard. mnemonic: z.string().describe("15 or 24-word BIP39 mnemonic for the wallet"), agentDid: z.string().describe("Agent DID (hex)"), proposalTxHash: z.string().describe("TX hash of the proposal UTxO to critique"), + // Note: a bare .default() without .optional() is reported as *required* by the + // SDK's isSchemaOptional() under zod/v4 (it returned optional under v3). That + // helper is only used for server.prompt() argument listing, which this codebase + // does not use — harmless for server.tool(), but relevant if prompts are added. proposalOutputIndex: z.number().default(0).describe("Output index of the proposal UTxO"), critiqueDocument: z.string().optional().describe("Full critique document as JSON string. Uploaded to IPFS via Filebase; hash and CID computed automatically."), critiqueHash: z.string().optional().describe("blake2b_256 hash of critique document (64 hex chars). Required if critiqueDocument is not provided."), diff --git a/test/smoke/tool-inventory.test.ts b/test/smoke/tool-inventory.test.ts index 4f045cf..3d67c60 100644 --- a/test/smoke/tool-inventory.test.ts +++ b/test/smoke/tool-inventory.test.ts @@ -92,7 +92,7 @@ describe('tool inventory smoke test', () => { const added = actualNames.filter((name) => !EXPECTED_TOOLS.includes(name)); const removed = EXPECTED_TOOLS.filter((name) => !actualNames.includes(name)); - assert.deepEqual( + assert.deepStrictEqual( actualNames, EXPECTED_TOOLS, 'Tool inventory drifted from the checked-in snapshot in test/smoke/tool-inventory.test.ts.\n' + @@ -109,7 +109,7 @@ describe('tool schema snapshot', () => { const missingFromSnapshot = actualNames.filter((name) => !snapshotNames.includes(name)); const staleInSnapshot = snapshotNames.filter((name) => !actualNames.includes(name)); - assert.deepEqual( + assert.deepStrictEqual( snapshotNames, actualNames, 'test/smoke/tool-schemas.snapshot.json keys do not match the live tool set.\n' + @@ -119,7 +119,7 @@ describe('tool schema snapshot', () => { ); }); - // One assertion per tool (rather than a single deepEqual over the whole + // One assertion per tool (rather than a single deepStrictEqual over the whole // 23-tool map) so a failure names the specific tool and shows a readable // diff of just that tool's schema, instead of "objects differ" over an // unreadable combined structure. @@ -130,7 +130,7 @@ describe('tool schema snapshot', () => { live, `Tool "${toolName}" is in the snapshot but was not returned by the live server's listTools().` ); - assert.deepEqual( + assert.deepStrictEqual( live.inputSchema, schemaSnapshot[toolName], `inputSchema for "${toolName}" differs from the checked-in snapshot in test/smoke/tool-schemas.snapshot.json.\n` +