Agent skill
grey-haven-prompt-engineering
Master 26 documented prompt engineering principles for crafting effective LLM prompts with 400%+ quality improvement. Includes templates, anti-patterns, and quality checklists for technical, learning, creative, and research tasks. Use when writing prompts for LLMs, improving AI response quality, training on prompting, designing agent instructions, or when user mentions 'prompt engineering', 'better prompts', 'LLM quality', 'prompt templates', 'AI prompts', 'prompt principles', or 'prompt optimization'.
Install this agent skill to your Project
npx add-skill https://github.com/greyhaven-ai/claude-code-config/tree/main/grey-haven-plugins/core/skills/prompt-engineering
SKILL.md
Prompt Engineering Skill
Master 26 documented principles for crafting effective prompts that get high-quality LLM responses on the first try.
Description
This skill provides comprehensive guidance on prompt engineering principles, patterns, and templates for technical tasks, learning content, creative writing, and research. Improves first-response quality by 400%+.
What's Included
Examples (examples/)
- Technical task prompts - 5 transformations (debugging, implementation, architecture, code review, optimization)
- Learning task prompts - 4 transformations (concept explanation, tutorials, comparisons, skill paths)
- Common fixes - 10 quick patterns for immediate improvement
- Before/after comparisons - Real examples with measured improvements
Reference Guides (reference/)
- 26 principles guide - Complete reference with examples, when to use, impact metrics
- Anti-patterns - 12 common mistakes and how to fix them
- Quick reference - Principle categories and selection matrix
Templates (templates/)
- Technical templates - 5 ready-to-use formats (code, debug, architecture, review, performance)
- Learning templates - 4 educational formats (concept explanation, tutorial, comparison, skill path)
- Creative templates - Writing, brainstorming, design prompts
- Research templates - Analysis, comparison, decision frameworks
Checklists (checklists/)
- 23-point quality checklist - Verification before submission with scoring (20+ = excellent)
- Quick improvement guide - Priority fixes for weak prompts
- Category-specific checklists - Technical, learning, creative, research
Key Principles (Highlights)
Content & Clarity:
- Principle 1: No chat, concise
- Principle 2: Specify audience
- Principle 9: Direct, specific task
- Principle 21: Rich context
- Principle 25: Explicit requirements
Structure:
- Principle 3: Break down complex tasks
- Principle 8: Use delimiters (###Headers###)
- Principle 17: Specify output format
Reasoning:
- Principle 12: Request step-by-step
- Principle 19: Chain-of-thought
- Principle 20: Provide examples
Impact Metrics
| Task Type | Weak Prompt Quality | Strong Prompt Quality | Improvement |
|---|---|---|---|
| Technical (code/debug) | 40% success | 98% success | +145% |
| Learning (tutorials) | 50% completion | 90% completion | +80% |
| Creative (writing) | 45% satisfaction | 85% satisfaction | +89% |
| Research (analysis) | 35% actionable | 90% actionable | +157% |
Use This Skill When
- LLM responses are too general or incorrect
- Need to improve prompt quality before submission
- Training team members on effective prompting
- Documenting prompt patterns for reuse
- Optimizing AI-assisted workflows
Related Agents
prompt-engineer- Automated prompt analysis and improvementdocumentation-alignment-verifier- Ensure prompts match documentation- All other agents - Improved agent effectiveness with better prompts
Quick Start
# Check quality of your prompt
cat checklists/prompt-quality-checklist.md
# View examples for your task type
cat examples/technical-task-prompts.md
cat examples/learning-task-prompts.md
# Use templates
cat templates/technical-prompt-template.md
# Learn all principles
cat reference/prompt-principles-guide.md
RED-GREEN-REFACTOR for Prompts
- RED: Test your current prompt → Likely produces weak results
- GREEN: Apply principles from checklist → Improve quality
- REFACTOR: Refine with templates and examples → Achieve excellence
Skill Version: 1.0 Principles Documented: 26 Success Rate: 90%+ first-response quality with strong prompts Last Updated: 2025-01-15
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
grey-haven-tool-design
Design effective MCP tools and Claude Code integrations using the consolidation principle. Fewer, better-designed tools dramatically improve agent success rates. Use when creating MCP servers, designing tool interfaces, optimizing tool sets, or when user mentions 'tool design', 'MCP', 'fewer tools', 'tool consolidation', 'tool architecture', or 'tool optimization'.
grey-haven-documentation-alignment
6-phase verification system ensuring code matches documentation with automated alignment scoring (signature, type, behavior, error, example checks). Reduces onboarding friction 40%. Use when verifying code-docs alignment, onboarding developers, after code changes, pre-release documentation checks, or when user mentions 'docs out of sync', 'documentation verification', 'code-docs alignment', 'docs accuracy', 'documentation drift', or 'verify documentation'.
grey-haven-tdd-orchestration
Master TDD orchestration with multi-agent coordination, strict red-green-refactor enforcement, automated test generation, coverage tracking, and >90% coverage quality gates. Supports Claude Teams for parallel TDD workflows with plan approval gates, or falls back to sequential subagent coordination. Coordinates tdd-python, tdd-typescript, and test-generator agents. Use when implementing features with TDD workflow, coordinating multiple TDD agents, enforcing test-first development, orchestrating TDD teams, or when user mentions 'TDD workflow', 'test-first', 'TDD orchestration', 'multi-agent TDD', 'test coverage', or 'red-green-refactor'.
grey-haven-performance-optimization
Comprehensive performance analysis and optimization for algorithms (O(n²)→O(n)), databases (N+1 queries, indexes), React (memoization, virtual lists), bundles (code splitting), API caching, and memory leaks. 85%+ improvement rate. Use when application is slow, response times exceed SLA, high CPU/memory usage, performance budgets needed, or when user mentions 'performance', 'slow', 'optimization', 'bottleneck', 'speed up', 'latency', 'memory leak', or 'performance tuning'.
grey-haven-llm-project-development
Build LLM-powered applications and pipelines using proven methodology - task-model fit analysis, pipeline architecture, structured outputs, file-based state, and cost estimation. Use when building AI features, data processing pipelines, agents, or any LLM-integrated system. Inspired by Karpathy's methodology and production case studies.
grey-haven-tdd-typescript
TypeScript/JavaScript Test-Driven Development with Vitest, strict red-green-refactor methodology, React component testing, and comprehensive coverage patterns. Use when implementing TypeScript features with TDD, writing Vitest tests, testing React components, developing with test-first approach, or when user mentions 'TypeScript TDD', 'Vitest', 'React testing', 'JavaScript TDD', 'red-green-refactor', 'TypeScript unit tests', or 'test-driven TypeScript'.
Didn't find tool you were looking for?