@amsterdamdatalabs/enact-extensions 0.1.0 → 0.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (152) hide show
  1. package/README.md +94 -20
  2. package/dist/index.d.ts +3 -3
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +2 -2
  5. package/dist/index.js.map +1 -1
  6. package/dist/install.d.ts +89 -0
  7. package/dist/install.d.ts.map +1 -1
  8. package/dist/install.js +219 -18
  9. package/dist/install.js.map +1 -1
  10. package/dist/validate/index.d.ts +21 -0
  11. package/dist/validate/index.d.ts.map +1 -1
  12. package/dist/validate/index.js +77 -0
  13. package/dist/validate/index.js.map +1 -1
  14. package/extensions/cmux/.agents/plugin.json +37 -0
  15. package/extensions/cmux/skills/cmux/SKILL.md +82 -0
  16. package/extensions/cmux/skills/cmux/agents/openai.yaml +4 -0
  17. package/extensions/cmux/skills/cmux/references/handles-and-identify.md +35 -0
  18. package/extensions/cmux/skills/cmux/references/panes-surfaces.md +37 -0
  19. package/extensions/cmux/skills/cmux/references/trigger-flash-and-health.md +23 -0
  20. package/extensions/cmux/skills/cmux/references/windows-workspaces.md +31 -0
  21. package/extensions/cmux/skills/cmux-vm-monitor/SKILL.md +122 -0
  22. package/extensions/cmux/skills/cmux-vm-monitor/agents/openai.yaml +4 -0
  23. package/extensions/cmux/skills/cmux-vm-monitor/references/cmux-commands.md +66 -0
  24. package/extensions/cmux/skills/cmux-vm-monitor/scripts/codex_vm_monitor.sh +45 -0
  25. package/extensions/cmux/skills/cmux-workspace/SKILL.md +93 -0
  26. package/extensions/dev-state/.agents/plugin.json +35 -0
  27. package/extensions/dev-state/skills/dev-state-plan-graduation/SKILL.md +194 -0
  28. package/extensions/dev-state/skills/dev-state-plan-graduation/agents/openai.yaml +4 -0
  29. package/extensions/dev-state/skills/dev-state-plan-graduation/references/reference.md +130 -0
  30. package/extensions/devops/.agents/plugin.json +36 -0
  31. package/extensions/devops/skills/azure-devops-cli/SKILL.md +431 -0
  32. package/extensions/devops/skills/azure-devops-cli/agents/openai.yaml +4 -0
  33. package/extensions/devops/skills/ci-pipeline-strategy/SKILL.md +217 -0
  34. package/extensions/devops/skills/ci-pipeline-strategy/agents/openai.yaml +4 -0
  35. package/{plugins/net-revenue-management/.codex-plugin → extensions/net-revenue-management/.agents}/plugin.json +10 -6
  36. package/extensions/plugin-dev/.agents/plugin.json +42 -0
  37. package/extensions/plugin-dev/.mcp.json +3 -0
  38. package/extensions/plugin-dev/agents/agent-creator.md +199 -0
  39. package/extensions/plugin-dev/agents/plugin-validator.md +91 -0
  40. package/extensions/plugin-dev/agents/skill-reviewer.md +212 -0
  41. package/extensions/plugin-dev/commands/_archive/create-marketplace.md +427 -0
  42. package/extensions/plugin-dev/commands/_archive/plugin-dev-guide.md +12 -0
  43. package/extensions/plugin-dev/commands/create-plugin.md +498 -0
  44. package/extensions/plugin-dev/commands/start.md +81 -0
  45. package/extensions/plugin-dev/hooks/hooks.json +3 -0
  46. package/extensions/plugin-dev/skills/agent-development/SKILL.md +641 -0
  47. package/extensions/plugin-dev/skills/agent-development/examples/agent-creation-prompt.md +250 -0
  48. package/extensions/plugin-dev/skills/agent-development/examples/complete-agent-examples.md +461 -0
  49. package/extensions/plugin-dev/skills/agent-development/references/advanced-agent-fields.md +246 -0
  50. package/extensions/plugin-dev/skills/agent-development/references/agent-creation-system-prompt.md +216 -0
  51. package/extensions/plugin-dev/skills/agent-development/references/permission-modes-rules.md +226 -0
  52. package/extensions/plugin-dev/skills/agent-development/references/system-prompt-design.md +464 -0
  53. package/extensions/plugin-dev/skills/agent-development/references/triggering-examples.md +474 -0
  54. package/extensions/plugin-dev/skills/agent-development/scripts/create-agent-skeleton.sh +176 -0
  55. package/extensions/plugin-dev/skills/agent-development/scripts/test-agent-trigger.sh +227 -0
  56. package/extensions/plugin-dev/skills/agent-development/scripts/validate-agent.sh +227 -0
  57. package/extensions/plugin-dev/skills/command-development/SKILL.md +763 -0
  58. package/extensions/plugin-dev/skills/command-development/examples/plugin-commands.md +612 -0
  59. package/extensions/plugin-dev/skills/command-development/examples/simple-commands.md +527 -0
  60. package/extensions/plugin-dev/skills/command-development/references/advanced-workflows.md +762 -0
  61. package/extensions/plugin-dev/skills/command-development/references/documentation-patterns.md +769 -0
  62. package/extensions/plugin-dev/skills/command-development/references/frontmatter-reference.md +508 -0
  63. package/extensions/plugin-dev/skills/command-development/references/interactive-commands.md +966 -0
  64. package/extensions/plugin-dev/skills/command-development/references/marketplace-considerations.md +943 -0
  65. package/extensions/plugin-dev/skills/command-development/references/plugin-features-reference.md +637 -0
  66. package/extensions/plugin-dev/skills/command-development/references/plugin-integration.md +191 -0
  67. package/extensions/plugin-dev/skills/command-development/references/skill-tool.md +447 -0
  68. package/extensions/plugin-dev/skills/command-development/references/testing-strategies.md +723 -0
  69. package/extensions/plugin-dev/skills/command-development/scripts/check-frontmatter.sh +234 -0
  70. package/extensions/plugin-dev/skills/command-development/scripts/validate-command.sh +160 -0
  71. package/extensions/plugin-dev/skills/hook-development/SKILL.md +861 -0
  72. package/extensions/plugin-dev/skills/hook-development/examples/load-context.sh +55 -0
  73. package/extensions/plugin-dev/skills/hook-development/examples/validate-bash.sh +57 -0
  74. package/extensions/plugin-dev/skills/hook-development/examples/validate-write.sh +48 -0
  75. package/extensions/plugin-dev/skills/hook-development/references/advanced.md +871 -0
  76. package/extensions/plugin-dev/skills/hook-development/references/hook-input-schemas.md +145 -0
  77. package/extensions/plugin-dev/skills/hook-development/references/migration.md +392 -0
  78. package/extensions/plugin-dev/skills/hook-development/references/patterns.md +430 -0
  79. package/extensions/plugin-dev/skills/hook-development/scripts/README.md +181 -0
  80. package/extensions/plugin-dev/skills/hook-development/scripts/hook-linter.sh +153 -0
  81. package/extensions/plugin-dev/skills/hook-development/scripts/test-hook.sh +276 -0
  82. package/extensions/plugin-dev/skills/hook-development/scripts/validate-hook-schema.sh +159 -0
  83. package/extensions/plugin-dev/skills/mcp-integration/SKILL.md +775 -0
  84. package/extensions/plugin-dev/skills/mcp-integration/examples/http-server.json +20 -0
  85. package/extensions/plugin-dev/skills/mcp-integration/examples/sse-server.json +19 -0
  86. package/extensions/plugin-dev/skills/mcp-integration/examples/stdio-server.json +38 -0
  87. package/extensions/plugin-dev/skills/mcp-integration/examples/ws-server.json +26 -0
  88. package/extensions/plugin-dev/skills/mcp-integration/references/authentication.md +601 -0
  89. package/extensions/plugin-dev/skills/mcp-integration/references/server-discovery.md +190 -0
  90. package/extensions/plugin-dev/skills/mcp-integration/references/server-types.md +572 -0
  91. package/extensions/plugin-dev/skills/mcp-integration/references/tool-usage.md +623 -0
  92. package/extensions/plugin-dev/skills/plugin-dev-guide/SKILL.md +222 -0
  93. package/extensions/plugin-dev/skills/plugin-structure/SKILL.md +705 -0
  94. package/extensions/plugin-dev/skills/plugin-structure/examples/advanced-plugin.md +774 -0
  95. package/extensions/plugin-dev/skills/plugin-structure/examples/minimal-plugin.md +83 -0
  96. package/extensions/plugin-dev/skills/plugin-structure/examples/standard-plugin.md +611 -0
  97. package/extensions/plugin-dev/skills/plugin-structure/references/advanced-topics.md +289 -0
  98. package/extensions/plugin-dev/skills/plugin-structure/references/component-patterns.md +592 -0
  99. package/extensions/plugin-dev/skills/plugin-structure/references/github-actions.md +233 -0
  100. package/extensions/plugin-dev/skills/plugin-structure/references/headless-ci-mode.md +193 -0
  101. package/extensions/plugin-dev/skills/plugin-structure/references/manifest-reference.md +625 -0
  102. package/extensions/plugin-dev/skills/plugin-structure/references/output-styles.md +116 -0
  103. package/extensions/plugin-dev/skills/skill-development/SKILL.md +564 -0
  104. package/extensions/plugin-dev/skills/skill-development/examples/complete-skill.md +465 -0
  105. package/extensions/plugin-dev/skills/skill-development/examples/frontmatter-templates.md +167 -0
  106. package/extensions/plugin-dev/skills/skill-development/examples/minimal-skill.md +111 -0
  107. package/extensions/plugin-dev/skills/skill-development/references/advanced-frontmatter.md +225 -0
  108. package/extensions/plugin-dev/skills/skill-development/references/commands-vs-skills.md +39 -0
  109. package/extensions/plugin-dev/skills/skill-development/references/skill-creation-workflow.md +379 -0
  110. package/extensions/plugin-dev/skills/skill-development/references/skill-creator-original.md +210 -0
  111. package/package.json +8 -11
  112. package/scripts/enact-extensions.mjs +751 -16
  113. package/scripts/hooks/session-start-drift-check.mjs +58 -0
  114. package/scripts/lib/build-index.mjs +50 -0
  115. package/scripts/lib/bundle-hash.mjs +137 -0
  116. package/scripts/lib/hooks.mjs +389 -0
  117. package/scripts/lib/ledger.mjs +162 -0
  118. package/scripts/lib/list-bundles.mjs +70 -0
  119. package/scripts/lib/outdated.mjs +144 -0
  120. package/scripts/lib/provision-mcp.mjs +369 -0
  121. package/scripts/lib/resolve-bundle.mjs +121 -0
  122. package/scripts/lib/run-install.mjs +321 -39
  123. package/scripts/lib/run-uninstall.mjs +220 -0
  124. package/scripts/lib/run-update.mjs +152 -0
  125. package/scripts/lib/run-validate.mjs +12 -18
  126. package/scripts/lib/serve.mjs +454 -0
  127. package/scripts/postinstall.mjs +63 -0
  128. package/scripts/setup-enact-context.sh +2 -2
  129. package/spec/index.json +59 -0
  130. package/web/assets/README.md +111 -0
  131. package/web/assets/logo-full.png +0 -0
  132. package/web/assets/logo-slim.png +0 -0
  133. package/web/assets/tokens/base.css +45 -0
  134. package/web/assets/tokens/colors.css +248 -0
  135. package/web/assets/tokens/effects.css +24 -0
  136. package/web/assets/tokens/fonts.css +8 -0
  137. package/web/assets/tokens/index.css +18 -0
  138. package/web/assets/tokens/spacing.css +50 -0
  139. package/web/index.html +1188 -0
  140. package/.agents/plugins/marketplace.json +0 -20
  141. package/catalog/enact-context.json +0 -9
  142. package/catalog/enact-factory.json +0 -7
  143. package/catalog/enact-operator.json +0 -7
  144. package/catalog/enact-wiki.json +0 -7
  145. package/catalog/net-revenue-management.json +0 -8
  146. package/scripts/rename-supervisor-to-operator.pl +0 -66
  147. package/scripts/sync-manifests.mjs +0 -23
  148. package/scripts/validate-catalog.mjs +0 -37
  149. package/scripts/validate-plugin.mjs +0 -10
  150. /package/{plugins → extensions}/net-revenue-management/.mcp.json +0 -0
  151. /package/{plugins → extensions}/net-revenue-management/skills/net-revenue-risks/SKILL.md +0 -0
  152. /package/{plugins → extensions}/net-revenue-management/skills/net-revenue-scenario/SKILL.md +0 -0
@@ -0,0 +1,464 @@
1
+ # System Prompt Design Patterns
2
+
3
+ Complete guide to writing effective agent system prompts that enable autonomous, high-quality operation.
4
+
5
+ ## Core Structure
6
+
7
+ Every agent system prompt should follow this proven structure:
8
+
9
+ ```markdown
10
+ You are [specific role] specializing in [specific domain].
11
+
12
+ **Your Core Responsibilities:**
13
+
14
+ 1. [Primary responsibility - the main task]
15
+ 2. [Secondary responsibility - supporting task]
16
+ 3. [Additional responsibilities as needed]
17
+
18
+ **[Task Name] Process:**
19
+
20
+ 1. [First concrete step]
21
+ 2. [Second concrete step]
22
+ 3. [Continue with clear steps]
23
+ [...]
24
+
25
+ **Quality Standards:**
26
+
27
+ - [Standard 1 with specifics]
28
+ - [Standard 2 with specifics]
29
+ - [Standard 3 with specifics]
30
+
31
+ **Output Format:**
32
+ Provide results structured as:
33
+
34
+ - [Component 1]
35
+ - [Component 2]
36
+ - [Include specific formatting requirements]
37
+
38
+ **Edge Cases:**
39
+ Handle these situations:
40
+
41
+ - [Edge case 1]: [Specific handling approach]
42
+ - [Edge case 2]: [Specific handling approach]
43
+ ```
44
+
45
+ ## Pattern 1: Analysis Agents
46
+
47
+ For agents that analyze code, PRs, or documentation:
48
+
49
+ ```markdown
50
+ You are an expert [domain] analyzer specializing in [specific analysis type].
51
+
52
+ **Your Core Responsibilities:**
53
+
54
+ 1. Thoroughly analyze [what] for [specific issues]
55
+ 2. Identify [patterns/problems/opportunities]
56
+ 3. Provide actionable recommendations
57
+
58
+ **Analysis Process:**
59
+
60
+ 1. **Gather Context**: Read [what] using available tools
61
+ 2. **Initial Scan**: Identify obvious [issues/patterns]
62
+ 3. **Deep Analysis**: Examine [specific aspects]:
63
+ - [Aspect 1]: Check for [criteria]
64
+ - [Aspect 2]: Verify [criteria]
65
+ - [Aspect 3]: Assess [criteria]
66
+ 4. **Synthesize Findings**: Group related issues
67
+ 5. **Prioritize**: Rank by [severity/impact/urgency]
68
+ 6. **Generate Report**: Format according to output template
69
+
70
+ **Quality Standards:**
71
+
72
+ - Every finding includes file:line reference
73
+ - Issues categorized by severity (critical/major/minor)
74
+ - Recommendations are specific and actionable
75
+ - Positive observations included for balance
76
+
77
+ **Output Format:**
78
+
79
+ ## Summary
80
+
81
+ [2-3 sentence overview]
82
+
83
+ ## Critical Issues
84
+
85
+ - [file:line] - [Issue description] - [Recommendation]
86
+
87
+ ## Major Issues
88
+
89
+ [...]
90
+
91
+ ## Minor Issues
92
+
93
+ [...]
94
+
95
+ ## Recommendations
96
+
97
+ [...]
98
+
99
+ **Edge Cases:**
100
+
101
+ - No issues found: Provide positive feedback and validation
102
+ - Too many issues: Group and prioritize top 10
103
+ - Unclear code: Request clarification rather than guessing
104
+ ```
105
+
106
+ ## Pattern 2: Generation Agents
107
+
108
+ For agents that create code, tests, or documentation:
109
+
110
+ ```markdown
111
+ You are an expert [domain] engineer specializing in creating high-quality [output type].
112
+
113
+ **Your Core Responsibilities:**
114
+
115
+ 1. Generate [what] that meets [quality standards]
116
+ 2. Follow [specific conventions/patterns]
117
+ 3. Ensure [correctness/completeness/clarity]
118
+
119
+ **Generation Process:**
120
+
121
+ 1. **Understand Requirements**: Analyze what needs to be created
122
+ 2. **Gather Context**: Read existing [code/docs/tests] for patterns
123
+ 3. **Design Structure**: Plan [architecture/organization/flow]
124
+ 4. **Generate Content**: Create [output] following:
125
+ - [Convention 1]
126
+ - [Convention 2]
127
+ - [Best practice 1]
128
+ 5. **Validate**: Verify [correctness/completeness]
129
+ 6. **Document**: Add comments/explanations as needed
130
+
131
+ **Quality Standards:**
132
+
133
+ - Follows project conventions (check CLAUDE.md)
134
+ - [Specific quality metric 1]
135
+ - [Specific quality metric 2]
136
+ - Includes error handling
137
+ - Well-documented and clear
138
+
139
+ **Output Format:**
140
+ Create [what] with:
141
+
142
+ - [Structure requirement 1]
143
+ - [Structure requirement 2]
144
+ - Clear, descriptive naming
145
+ - Comprehensive coverage
146
+
147
+ **Edge Cases:**
148
+
149
+ - Insufficient context: Ask user for clarification
150
+ - Conflicting patterns: Follow most recent/explicit pattern
151
+ - Complex requirements: Break into smaller pieces
152
+ ```
153
+
154
+ ## Pattern 3: Validation Agents
155
+
156
+ For agents that validate, check, or verify:
157
+
158
+ ```markdown
159
+ You are an expert [domain] validator specializing in ensuring [quality aspect].
160
+
161
+ **Your Core Responsibilities:**
162
+
163
+ 1. Validate [what] against [criteria]
164
+ 2. Identify violations and issues
165
+ 3. Provide clear pass/fail determination
166
+
167
+ **Validation Process:**
168
+
169
+ 1. **Load Criteria**: Understand validation requirements
170
+ 2. **Scan Target**: Read [what] needs validation
171
+ 3. **Check Rules**: For each rule:
172
+ - [Rule 1]: [Validation method]
173
+ - [Rule 2]: [Validation method]
174
+ 4. **Collect Violations**: Document each failure with details
175
+ 5. **Assess Severity**: Categorize issues
176
+ 6. **Determine Result**: Pass only if [criteria met]
177
+
178
+ **Quality Standards:**
179
+
180
+ - All violations include specific locations
181
+ - Severity clearly indicated
182
+ - Fix suggestions provided
183
+ - No false positives
184
+
185
+ **Output Format:**
186
+
187
+ ## Validation Result: [PASS/FAIL]
188
+
189
+ ## Summary
190
+
191
+ [Overall assessment]
192
+
193
+ ## Violations Found: [count]
194
+
195
+ ### Critical ([count])
196
+
197
+ - [Location]: [Issue] - [Fix]
198
+
199
+ ### Warnings ([count])
200
+
201
+ - [Location]: [Issue] - [Fix]
202
+
203
+ ## Recommendations
204
+
205
+ [How to fix violations]
206
+
207
+ **Edge Cases:**
208
+
209
+ - No violations: Confirm validation passed
210
+ - Too many violations: Group by type, show top 20
211
+ - Ambiguous rules: Document uncertainty, request clarification
212
+ ```
213
+
214
+ ## Pattern 4: Orchestration Agents
215
+
216
+ For agents that coordinate multiple tools or steps:
217
+
218
+ ```markdown
219
+ You are an expert [domain] orchestrator specializing in coordinating [complex workflow].
220
+
221
+ **Your Core Responsibilities:**
222
+
223
+ 1. Coordinate [multi-step process]
224
+ 2. Manage [resources/tools/dependencies]
225
+ 3. Ensure [successful completion/integration]
226
+
227
+ **Orchestration Process:**
228
+
229
+ 1. **Plan**: Understand full workflow and dependencies
230
+ 2. **Prepare**: Set up prerequisites
231
+ 3. **Execute Phases**:
232
+ - Phase 1: [What] using [tools]
233
+ - Phase 2: [What] using [tools]
234
+ - Phase 3: [What] using [tools]
235
+ 4. **Monitor**: Track progress and handle failures
236
+ 5. **Verify**: Confirm successful completion
237
+ 6. **Report**: Provide comprehensive summary
238
+
239
+ **Quality Standards:**
240
+
241
+ - Each phase completes successfully
242
+ - Errors handled gracefully
243
+ - Progress reported to user
244
+ - Final state verified
245
+
246
+ **Output Format:**
247
+
248
+ ## Workflow Execution Report
249
+
250
+ ### Completed Phases
251
+
252
+ - [Phase]: [Result]
253
+
254
+ ### Results
255
+
256
+ - [Output 1]
257
+ - [Output 2]
258
+
259
+ ### Next Steps
260
+
261
+ [If applicable]
262
+
263
+ **Edge Cases:**
264
+
265
+ - Phase failure: Attempt retry, then report and stop
266
+ - Missing dependencies: Request from user
267
+ - Timeout: Report partial completion
268
+ ```
269
+
270
+ ## Writing Style Guidelines
271
+
272
+ ### Tone and Voice
273
+
274
+ **Use second person (addressing the agent):**
275
+
276
+ ```
277
+ ✅ You are responsible for...
278
+ ✅ You will analyze...
279
+ ✅ Your process should...
280
+
281
+ ❌ The agent is responsible for...
282
+ ❌ This agent will analyze...
283
+ ❌ I will analyze...
284
+ ```
285
+
286
+ ### Clarity and Specificity
287
+
288
+ **Be specific, not vague:**
289
+
290
+ ```
291
+ ✅ Check for SQL injection by examining all database queries for parameterization
292
+ ❌ Look for security issues
293
+
294
+ ✅ Provide file:line references for each finding
295
+ ❌ Show where issues are
296
+
297
+ ✅ Categorize as critical (security), major (bugs), or minor (style)
298
+ ❌ Rate the severity of issues
299
+ ```
300
+
301
+ ### Actionable Instructions
302
+
303
+ **Give concrete steps:**
304
+
305
+ ```
306
+ ✅ Read the file using the Read tool, then search for patterns using Grep
307
+ ❌ Analyze the code
308
+
309
+ ✅ Generate test file at test/path/to/file.test.ts
310
+ ❌ Create tests
311
+ ```
312
+
313
+ ## Common Pitfalls
314
+
315
+ ### ❌ Vague Responsibilities
316
+
317
+ ```markdown
318
+ **Your Core Responsibilities:**
319
+
320
+ 1. Help the user with their code
321
+ 2. Provide assistance
322
+ 3. Be helpful
323
+ ```
324
+
325
+ **Why bad:** Not specific enough to guide behavior.
326
+
327
+ ### ✅ Specific Responsibilities
328
+
329
+ ```markdown
330
+ **Your Core Responsibilities:**
331
+
332
+ 1. Analyze TypeScript code for type safety issues
333
+ 2. Identify missing type annotations and improper 'any' usage
334
+ 3. Recommend specific type improvements with examples
335
+ ```
336
+
337
+ ### ❌ Missing Process Steps
338
+
339
+ ```markdown
340
+ Analyze the code and provide feedback.
341
+ ```
342
+
343
+ **Why bad:** Agent doesn't know HOW to analyze.
344
+
345
+ ### ✅ Clear Process
346
+
347
+ ```markdown
348
+ **Analysis Process:**
349
+
350
+ 1. Read code files using Read tool
351
+ 2. Scan for type annotations on all functions
352
+ 3. Check for 'any' type usage
353
+ 4. Verify generic type parameters
354
+ 5. List findings with file:line references
355
+ ```
356
+
357
+ ### ❌ Undefined Output
358
+
359
+ ```markdown
360
+ Provide a report.
361
+ ```
362
+
363
+ **Why bad:** Agent doesn't know what format to use.
364
+
365
+ ### ✅ Defined Output Format
366
+
367
+ ```markdown
368
+ **Output Format:**
369
+
370
+ ## Type Safety Report
371
+
372
+ ### Summary
373
+
374
+ [Overview of findings]
375
+
376
+ ### Issues Found
377
+
378
+ - `file.ts:42` - Missing return type on `processData`
379
+ - `utils.ts:15` - Unsafe 'any' usage in parameter
380
+
381
+ ### Recommendations
382
+
383
+ [Specific fixes with examples]
384
+ ```
385
+
386
+ ## Length Guidelines
387
+
388
+ ### Minimum Viable Agent
389
+
390
+ **~500 words minimum:**
391
+
392
+ - Role description
393
+ - 3 core responsibilities
394
+ - 5-step process
395
+ - Output format
396
+
397
+ ### Standard Agent
398
+
399
+ **~1,000-2,000 words:**
400
+
401
+ - Detailed role and expertise
402
+ - 5-8 responsibilities
403
+ - 8-12 process steps
404
+ - Quality standards
405
+ - Output format
406
+ - 3-5 edge cases
407
+
408
+ ### Comprehensive Agent
409
+
410
+ **~2,000-5,000 words:**
411
+
412
+ - Complete role with background
413
+ - Comprehensive responsibilities
414
+ - Detailed multi-phase process
415
+ - Extensive quality standards
416
+ - Multiple output formats
417
+ - Many edge cases
418
+ - Examples within system prompt
419
+
420
+ **Avoid > 10,000 words:** Too long, diminishing returns.
421
+
422
+ ## Testing System Prompts
423
+
424
+ ### Test Completeness
425
+
426
+ Can the agent handle these based on system prompt alone?
427
+
428
+ - [ ] Typical task execution
429
+ - [ ] Edge cases mentioned
430
+ - [ ] Error scenarios
431
+ - [ ] Unclear requirements
432
+ - [ ] Large/complex inputs
433
+ - [ ] Empty/missing inputs
434
+
435
+ ### Test Clarity
436
+
437
+ Read the system prompt and ask:
438
+
439
+ - Can another developer understand what this agent does?
440
+ - Are process steps clear and actionable?
441
+ - Is output format unambiguous?
442
+ - Are quality standards measurable?
443
+
444
+ ### Iterate Based on Results
445
+
446
+ After testing agent:
447
+
448
+ 1. Identify where it struggled
449
+ 2. Add missing guidance to system prompt
450
+ 3. Clarify ambiguous instructions
451
+ 4. Add process steps for edge cases
452
+ 5. Re-test
453
+
454
+ ## Conclusion
455
+
456
+ Effective system prompts are:
457
+
458
+ - **Specific**: Clear about what and how
459
+ - **Structured**: Organized with clear sections
460
+ - **Complete**: Covers normal and edge cases
461
+ - **Actionable**: Provides concrete steps
462
+ - **Testable**: Defines measurable standards
463
+
464
+ Use the patterns above as templates, customize for your domain, and iterate based on agent performance.