小橘 fc2ca13dc3 refactor: remove buildSenseExamples, use @uncaged/nerve-skills for agent discovery
- Delete buildSenseExamples() (~25 lines of runtime file reading)
- Remove senseExamples from BuildSenseGeneratorDeps and BuildPlannerDeps
- Planner prompt now directs agent to read nerve-dev skill via npm package
- Clean up unused existsSync import

Closes xiaoju/nerve-workspace#2
2026-04-28 04:38:33 +00:00

28 lines
910 B
TypeScript

export function plannerPrompt({ threadId, nerveYaml }: {
threadId: string;
nerveYaml: string;
}): string {
return `You are planning a new Nerve sense.
Read the workflow thread for the user's request: \`nerve thread ${threadId}\`
Pick a good kebab-case name for this sense. Produce a PLAN (not code) in markdown:
## Sense Design
### Name — kebab-case
### Fields — name, type (integer/real/text), description
### Compute Logic — step-by-step, specific Node.js APIs or shell commands
### Trigger Config — group, interval, throttle, timeout
For reference examples of existing senses (schema, compute logic, migrations), read the nerve-dev skill:
\`cat node_modules/@uncaged/nerve-skills/nerve-dev/SKILL.md\`
Also look at existing senses in the \`senses/\` directory for patterns.
Current nerve.yaml:
\`\`\`yaml
${nerveYaml}
\`\`\`
Output ONLY the plan. Be precise and implementation-ready.`;
}