{"data":{"slug":"discovered-af52748d4848c40d7c23b0934ec8495c2f23d522298c335c","title":"Prompt Engineer","summary":"Writes, refactors, and evaluates prompts for LLMs \u2014 generating optimized prompt templates, structured output schemas, evaluation rubrics, and test suites. Use when designing prompts for new LLM applications, refactoring existing prompts for better accuracy or token efficiency, implementing chain-of-thought or few-shot learning, creating system prompts with personas and guardrails, building JSON\/function-calling schemas, or developing prompt evaluation frameworks to measure and improve model performance.","url":"https:\/\/skillshunter.net\/skills\/discovered-af52748d4848c40d7c23b0934ec8495c2f23d522298c335c","json_url":"https:\/\/skillshunter.net\/api\/public\/v1\/skills\/discovered-af52748d4848c40d7c23b0934ec8495c2f23d522298c335c","markdown_url":"https:\/\/skillshunter.net\/skills\/discovered-af52748d4848c40d7c23b0934ec8495c2f23d522298c335c.md","download_url":"https:\/\/skillshunter.net\/skills\/discovered-af52748d4848c40d7c23b0934ec8495c2f23d522298c335c\/download","category":{"slug":"software-development","name":"Software & Development"},"editor_note":"Before deploying prompts, ensure systematic evaluation on test cases and validate structured outputs against schemas. If accuracy is below 80% on the test set, identify failure patterns such as ambiguous instructions or missing examples before iterating.","instructions":"---\nname: prompt-engineer\ndescription: Writes, refactors, and evaluates prompts for LLMs \u2014 generating optimized prompt templates, structured output schemas, evaluation rubrics, and test suites. Use when designing prompts for new LLM applications, refactoring existing prompts for better accuracy or token efficiency, implementing chain-of-thought or few-shot learning, creating system prompts with personas and guardrails, building JSON\/function-calling schemas, or developing prompt evaluation frameworks to measure and improve model performance.\nlicense: MIT\nmetadata:\n  author: https:\/\/github.com\/Jeffallan\n  company: https:\/\/synergetic.solutions\n  version: \"1.2.0\"\n  domain: data-ml\n  triggers: prompt engineering, prompt optimization, chain-of-thought, few-shot learning, prompt testing, LLM prompts, prompt evaluation, system prompts, structured outputs, prompt design, context management, lost-in-the-middle, context degradation, token optimization, attention budget\n  role: expert\n  scope: design\n  output-format: document\n  related-skills: test-master, rag-architect, debugging-wizard\n---\n\n# Prompt Engineer\n\nExpert prompt engineer specializing in designing, optimizing, and evaluating prompts that maximize LLM performance across diverse use cases.\n\n## When to Use This Skill\n\n- Designing prompts for new LLM applications\n- Optimizing existing prompts for better accuracy or efficiency\n- Implementing chain-of-thought or few-shot learning\n- Creating system prompts with personas and guardrails\n- Building structured output schemas (JSON mode, function calling)\n- Developing prompt evaluation and testing frameworks\n- Debugging inconsistent or poor-quality LLM outputs\n- Migrating prompts between different models or providers\n\n## Core Workflow\n\n1. **Understand requirements** \u2014 Define task, success criteria, constraints, and edge cases\n2. **Design initial prompt** \u2014 Choose pattern (zero-shot, few-shot, CoT), write clear instructions\n3. **Test and evaluate** \u2014 Run diverse test cases, measure quality metrics\n   - **Validation checkpoint:** If accuracy < 80% on the test set, identify failure patterns before iterating (e.g., ambiguous instructions, missing examples, edge case gaps)\n4. **Iterate and optimize** \u2014 Make one change at a time; refine based on failures, reduce tokens, improve reliability\n5. **Document and deploy** \u2014 Version prompts, document behavior, monitor production\n\n## Reference Guide\n\nLoad detailed guidance based on context:\n\n| Topic | Reference | Load When |\n|-------|-----------|-----------|\n| Prompt Patterns | `references\/prompt-patterns.md` | Zero-shot, few-shot, chain-of-thought, ReAct |\n| Optimization | `references\/prompt-optimization.md` | Iterative refinement, A\/B testing, token reduction |\n| Evaluation | `references\/evaluation-frameworks.md` | Metrics, test suites, automated evaluation |\n| Structured Outputs | `references\/structured-outputs.md` | JSON mode, function calling, schema design |\n| System Prompts | `references\/system-prompts.md` | Persona design, guardrails, injection defense |\n| Context Management | `references\/context-management.md` | Attention budget, degradation patterns, context optimization |\n\n## Prompt Examples\n\n### Zero-shot vs. Few-shot\n\n**Zero-shot (baseline):**\n```\nClassify the sentiment of the following review as Positive, Negative, or Neutral.\n\nReview: {{review}}\nSentiment:\n```\n\n**Few-shot (improved reliability):**\n```\nClassify the sentiment of the following review as Positive, Negative, or Neutral.\n\nReview: \"The battery life is incredible, lasts all day.\"\nSentiment: Positive\n\nReview: \"Stopped working after two weeks. Very disappointed.\"\nSentiment: Negative\n\nReview: \"It arrived on time and matches the description.\"\nSentiment: Neutral\n\nReview: {{review}}\nSentiment:\n```\n\n### Before\/After Optimization\n\n**Before (vague, inconsistent outputs):**\n```\nSummarize this document.\n\n{{document}}\n```\n\n**After (structured, token-efficient):**\n```\nSummarize the document below in exactly 3 bullet points. Each bullet must be one sentence and start with an action verb. Do not include opinions or information not present in the document.\n\nDocument:\n{{document}}\n\nSummary:\n```\n\n## Constraints\n\n### MUST DO\n- Test prompts with diverse, realistic inputs including edge cases\n- Measure performance with quantitative metrics (accuracy, consistency)\n- Version prompts and track changes systematically\n- Document expected behavior and known limitations\n- Use few-shot examples that match target distribution\n- Validate structured outputs against schemas\n- Consider token costs and latency in design\n- Test across model versions before production deployment\n\n### MUST NOT DO\n- Deploy prompts without systematic evaluation on test cases\n- Use few-shot examples that contradict instructions\n- Ignore model-specific capabilities and limitations\n- Skip edge case testing (empty inputs, unusual formats)\n- Make multiple changes simultaneously when debugging\n- Hardcode sensitive data in prompts or examples\n- Assume prompts transfer perfectly between models\n- Neglect monitoring for prompt degradation in production\n\n## Output Templates\n\nWhen delivering prompt work, provide:\n1. Final prompt with clear sections (role, task, constraints, format)\n2. Test cases and evaluation results\n3. Usage instructions (temperature, max tokens, model version)\n4. Performance metrics and comparison with baselines\n5. Known limitations and edge cases\n\n## Coverage Note\n\nReference files cover major prompting techniques (zero-shot, few-shot, CoT, ReAct, tree-of-thoughts), structured output patterns (JSON mode, function calling), context management (attention budgets, degradation mitigation, optimization), and model-specific guidance for GPT-4, Claude, and Gemini families. Consult the relevant reference before designing for a specific model or pattern.\n\nMaintained by [@jeffallan](https:\/\/github.com\/jeffallan), Principal Consultant at [Synergetic Solutions](https:\/\/synergetic.solutions)\n\n[Documentation](https:\/\/jeffallan.github.io\/claude-skills\/skills\/data-ml\/prompt-engineer\/)\n","use_cases":["Designing prompts for new LLM applications","Optimizing existing prompts for better accuracy or efficiency","Implementing chain-of-thought or few-shot learning","Creating system prompts with personas and guardrails","Building structured output schemas (JSON mode, function calling)","Developing prompt evaluation and testing frameworks"],"limitations":[],"compatibility":[],"setup_tip":null,"sample_input":null,"sample_output":null,"source_url":"https:\/\/github.com\/Jeffallan\/claude-skills\/blob\/a8be463010e2ca23afe00ea00773aea7128e8971\/plugin\/skills\/prompt-engineer\/SKILL.md","source_commit":"a8be463010e2ca23afe00ea00773aea7128e8971","license":null,"version":null,"listing_approved_at":"2026-11-29","created_at":"2026-11-28T18:47:43.000000Z","updated_at":"2026-11-29T10:53:27.000000Z","seo_title":"Prompt Engineer for LLM Applications","seo_description":"Optimize and evaluate prompts for large language models with structured output schemas, evaluation rubrics, and test suites. Ideal for designing, refining, and deployingL","seo_keywords":["prompt engineering","LLM prompt design","structured output schemas","few-shot learning","chain-of-thought prompts","prompt evaluation frameworks"]}}