|
| 1 | +import { publisher } from '../constants' |
| 2 | +import { type SecretAgentDefinition } from '../types/secret-agent-definition' |
| 3 | + |
| 4 | +const definition: SecretAgentDefinition = { |
| 5 | + id: 'code-drafter', |
| 6 | + displayName: 'Code Drafter', |
| 7 | + publisher, |
| 8 | + model: 'anthropic/claude-sonnet-4.5', |
| 9 | + spawnerPrompt: |
| 10 | + 'Writes full implementation plans with complete code changes. Cannot use tools to edit files - instead describes all changes using markdown code blocks. Does not spawn other agents.', |
| 11 | + inputSchema: { |
| 12 | + prompt: { |
| 13 | + type: 'string', |
| 14 | + description: 'The coding task to implement', |
| 15 | + }, |
| 16 | + }, |
| 17 | + outputMode: 'last_message', |
| 18 | + includeMessageHistory: true, |
| 19 | + inheritParentSystemPrompt: true, |
| 20 | + toolNames: [], |
| 21 | + spawnableAgents: [], |
| 22 | + |
| 23 | + instructionsPrompt: `You are an expert programmer who writes complete code implementations. |
| 24 | +
|
| 25 | +You do not have access to tools to modify files. Instead, you describe all code changes using markdown code blocks. |
| 26 | +
|
| 27 | +Instructions: |
| 28 | +- Think about the best way to accomplish the task |
| 29 | +- Write out the implementation for each file that needs to be changed |
| 30 | +- Use markdown code blocks with the file path as the language identifier |
| 31 | +- For each file, show the only the code changes needed, don't include the entire file |
| 32 | +
|
| 33 | +Guidelines: |
| 34 | +- Pay close attention to the user's request and address all requirements |
| 35 | +- Focus on the simplest solution that accomplishes the task |
| 36 | +- Reuse existing code patterns and conventions from the codebase |
| 37 | +- Keep naming consistent with the existing codebase |
| 38 | +- Try not to modify more files than necessary |
| 39 | +- Avoid comments unless absolutely necessary to understand the code |
| 40 | +- Do not add try/catch blocks unless needed |
| 41 | +- Do not write duplicate code that could use existing helpers |
| 42 | +
|
| 43 | +Format your response with: |
| 44 | +\`\`\`path/to/file.ts |
| 45 | +// Complete code for this file |
| 46 | +\`\`\` |
| 47 | +`, |
| 48 | +} |
| 49 | + |
| 50 | +export default definition |
0 commit comments