chore: instruct coder to use .default() on zod schemas for llmExtract
小橘 🍊(NEKO Team)
This commit is contained in:
parent
9f2067db7d
commit
0803a00482
@ -561,6 +561,7 @@ ${fixSection}
|
||||
## Implementation patterns (when applicable)
|
||||
- \`resolveDashScopeProvider\`, \`nerveAgentContext\`, \`readNerveYaml\`, \`cursorAgent\`, \`llmExtract\`, \`spawnSafe\`, \`formatSpawnFailure\` from \`@uncaged/nerve-workflow-utils\` as in sense-generator.
|
||||
- No dynamic \`import()\` in the new workflow code.
|
||||
- **Every zod schema passed to \`llmExtract\` MUST have \`.default()\` on all fields** (especially arrays and objects). This ensures \`dryRun\` mode returns structurally valid data instead of empty primitives. Example: \`z.array(roleSchema).default([])\`, \`z.string().default("unknown")\`.
|
||||
|
||||
## Reference workflow
|
||||
\`\`\`ts
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user