[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6D7BAQRT3P52939VXKT3GMS":3,"skill-same:01M6D7BAQRT3P52939VXKT3GMS":112},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":31,"publishedAt":52,"linkOnly":53,"markdownContent":54,"markdownBody":55,"frontMatter":56,"refName":57,"commitSha":58,"skillDirectory":59,"forksCount":60,"repositoryHtmlUrl":61,"repositoryHomepageUrl":6,"ownerHtmlUrl":62,"ownerBlogUrl":63,"ownerDescription":64,"updatedAt":65,"install":66,"resources":79},"01M6D7BAQRT3P52939VXKT3GMS","senior-prompt-engineer",null,"This skill should be used when the user asks to \"optimize prompts\", \"design prompt templates\", \"evaluate LLM outputs\", \"build agentic systems\", \"implement RAG\", \"create few-shot examples\", \"analyze token usage\", or \"design AI workflows\". Use for prompt engineering patterns, LLM evaluation frameworks, agent architectures, and structured output design.","oabdelmaksoud\u002FSuperClaw","oabdelmaksoud","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F50699149?v=4","01M6D5CVVN778ZCDP1WHS816SP","Omar Abdelmaksoud","01M6D5CW1RHNSKCJR85GJACBFT",2,"MIT","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002FSKILL.md",[18,23,26],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000015","视觉设计","SCENARIO","使用场景",{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000023","Skill与智能体开发",{"categoryNo":27,"categoryName":28,"taxonomyType":29,"taxonomyTypeDesc":30},"01JBSEEDCAT000000000000032","设计师","PROFESSION","适用职业",[32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51],"engineer","prompt","senior prompt engineer","prompt engineer","systems","design","frameworks","optimize","build","use","analyze","Evaluation","examples","create","engineering patterns","prompt templates","rag","workflows","implement","agentic","2026-11-10 10:12:30",false,"---\nname: senior-prompt-engineer\ndescription: This skill should be used when the user asks to \"optimize prompts\", \"design prompt templates\", \"evaluate LLM outputs\", \"build agentic systems\", \"implement RAG\", \"create few-shot examples\", \"analyze token usage\", or \"design AI workflows\". Use for prompt engineering patterns, LLM evaluation frameworks, agent architectures, and structured output design.\n---\n\n# Senior Prompt Engineer\n\nPrompt engineering patterns, LLM evaluation frameworks, and agentic system design.\n\n## Table of Contents\n\n- [Quick Start](#quick-start)\n- [Tools Overview](#tools-overview)\n  - [Prompt Optimizer](#1-prompt-optimizer)\n  - [RAG Evaluator](#2-rag-evaluator)\n  - [Agent Orchestrator](#3-agent-orchestrator)\n- [Prompt Engineering Workflows](#prompt-engineering-workflows)\n  - [Prompt Optimization Workflow](#prompt-optimization-workflow)\n  - [Few-Shot Example Design](#few-shot-example-design-workflow)\n  - [Structured Output Design](#structured-output-design-workflow)\n- [Reference Documentation](#reference-documentation)\n- [Common Patterns Quick Reference](#common-patterns-quick-reference)\n\n---\n\n## Quick Start\n\n```bash\n# Analyze and optimize a prompt file\npython scripts\u002Fprompt_optimizer.py prompts\u002Fmy_prompt.txt --analyze\n\n# Evaluate RAG retrieval quality\npython scripts\u002Frag_evaluator.py --contexts contexts.json --questions questions.json\n\n# Visualize agent workflow from definition\npython scripts\u002Fagent_orchestrator.py agent_config.yaml --visualize\n```\n\n---\n\n## Tools Overview\n\n### 1. Prompt Optimizer\n\nAnalyzes prompts for token efficiency, clarity, and structure. Generates optimized versions.\n\n**Input:** Prompt text file or string\n**Output:** Analysis report with optimization suggestions\n\n**Usage:**\n```bash\n# Analyze a prompt file\npython scripts\u002Fprompt_optimizer.py prompt.txt --analyze\n\n# Output:\n# Token count: 847\n# Estimated cost: $0.0025 (GPT-4)\n# Clarity score: 72\u002F100\n# Issues found:\n#   - Ambiguous instruction at line 3\n#   - Missing output format specification\n#   - Redundant context (lines 12-15 repeat lines 5-8)\n# Suggestions:\n#   1. Add explicit output format: \"Respond in JSON with keys: ...\"\n#   2. Remove redundant context to save 89 tokens\n#   3. Clarify \"analyze\" -> \"list the top 3 issues with severity ratings\"\n\n# Generate optimized version\npython scripts\u002Fprompt_optimizer.py prompt.txt --optimize --output optimized.txt\n\n# Count tokens for cost estimation\npython scripts\u002Fprompt_optimizer.py prompt.txt --tokens --model gpt-4\n\n# Extract and manage few-shot examples\npython scripts\u002Fprompt_optimizer.py prompt.txt --extract-examples --output examples.json\n```\n\n---\n\n### 2. RAG Evaluator\n\nEvaluates Retrieval-Augmented Generation quality by measuring context relevance and answer faithfulness.\n\n**Input:** Retrieved contexts (JSON) and questions\u002Fanswers\n**Output:** Evaluation metrics and quality report\n\n**Usage:**\n```bash\n# Evaluate retrieval quality\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json\n\n# Output:\n# === RAG Evaluation Report ===\n# Questions evaluated: 50\n#\n# Retrieval Metrics:\n#   Context Relevance: 0.78 (target: >0.80)\n#   Retrieval Precision@5: 0.72\n#   Coverage: 0.85\n#\n# Generation Metrics:\n#   Answer Faithfulness: 0.91\n#   Groundedness: 0.88\n#\n# Issues Found:\n#   - 8 questions had no relevant context in top-5\n#   - 3 answers contained information not in context\n#\n# Recommendations:\n#   1. Improve chunking strategy for technical documents\n#   2. Add metadata filtering for date-sensitive queries\n\n# Evaluate with custom metrics\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json \\\n    --metrics relevance,faithfulness,coverage\n\n# Export detailed results\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json \\\n    --output report.json --verbose\n```\n\n---\n\n### 3. Agent Orchestrator\n\nParses agent definitions and visualizes execution flows. Validates tool configurations.\n\n**Input:** Agent configuration (YAML\u002FJSON)\n**Output:** Workflow visualization, validation report\n\n**Usage:**\n```bash\n# Validate agent configuration\npython scripts\u002Fagent_orchestrator.py agent.yaml --validate\n\n# Output:\n# === Agent Validation Report ===\n# Agent: research_assistant\n# Pattern: ReAct\n#\n# Tools (4 registered):\n#   [OK] web_search - API key configured\n#   [OK] calculator - No config needed\n#   [WARN] file_reader - Missing allowed_paths\n#   [OK] summarizer - Prompt template valid\n#\n# Flow Analysis:\n#   Max depth: 5 iterations\n#   Estimated tokens\u002Frun: 2,400-4,800\n#   Potential infinite loop: No\n#\n# Recommendations:\n#   1. Add allowed_paths to file_reader for security\n#   2. Consider adding early exit condition for simple queries\n\n# Visualize agent workflow (ASCII)\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize\n\n# Output:\n# ┌─────────────────────────────────────────┐\n# │            research_assistant           │\n# │              (ReAct Pattern)            │\n# └─────────────────┬───────────────────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │   User Query    │\n#          └────────┬────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │     Think       │◄──────┐\n#          └────────┬────────┘       │\n#                   │                │\n#          ┌────────▼────────┐       │\n#          │   Select Tool   │       │\n#          └────────┬────────┘       │\n#                   │                │\n#     ┌─────────────┼─────────────┐  │\n#     ▼             ▼             ▼  │\n# [web_search] [calculator] [file_reader]\n#     │             │             │  │\n#     └─────────────┼─────────────┘  │\n#                   │                │\n#          ┌────────▼────────┐       │\n#          │    Observe      │───────┘\n#          └────────┬────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │  Final Answer   │\n#          └─────────────────┘\n\n# Export workflow as Mermaid diagram\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize --format mermaid\n```\n\n---\n\n## Prompt Engineering Workflows\n\n### Prompt Optimization Workflow\n\nUse when improving an existing prompt's performance or reducing token costs.\n\n**Step 1: Baseline current prompt**\n```bash\npython scripts\u002Fprompt_optimizer.py current_prompt.txt --analyze --output baseline.json\n```\n\n**Step 2: Identify issues**\nReview the analysis report for:\n- Token waste (redundant instructions, verbose examples)\n- Ambiguous instructions (unclear output format, vague verbs)\n- Missing constraints (no length limits, no format specification)\n\n**Step 3: Apply optimization patterns**\n| Issue | Pattern to Apply |\n|-------|------------------|\n| Ambiguous output | Add explicit format specification |\n| Too verbose | Extract to few-shot examples |\n| Inconsistent results | Add role\u002Fpersona framing |\n| Missing edge cases | Add constraint boundaries |\n\n**Step 4: Generate optimized version**\n```bash\npython scripts\u002Fprompt_optimizer.py current_prompt.txt --optimize --output optimized.txt\n```\n\n**Step 5: Compare results**\n```bash\npython scripts\u002Fprompt_optimizer.py optimized.txt --analyze --compare baseline.json\n# Shows: token reduction, clarity improvement, issues resolved\n```\n\n**Step 6: Validate with test cases**\nRun both prompts against your evaluation set and compare outputs.\n\n---\n\n### Few-Shot Example Design Workflow\n\nUse when creating examples for in-context learning.\n\n**Step 1: Define the task clearly**\n```\nTask: Extract product entities from customer reviews\nInput: Review text\nOutput: JSON with {product_name, sentiment, features_mentioned}\n```\n\n**Step 2: Select diverse examples (3-5 recommended)**\n| Example Type | Purpose |\n|--------------|---------|\n| Simple case | Shows basic pattern |\n| Edge case | Handles ambiguity |\n| Complex case | Multiple entities |\n| Negative case | What NOT to extract |\n\n**Step 3: Format consistently**\n```\nExample 1:\nInput: \"Love my new iPhone 15, the camera is amazing!\"\nOutput: {\"product_name\": \"iPhone 15\", \"sentiment\": \"positive\", \"features_mentioned\": [\"camera\"]}\n\nExample 2:\nInput: \"The laptop was okay but battery life is terrible.\"\nOutput: {\"product_name\": \"laptop\", \"sentiment\": \"mixed\", \"features_mentioned\": [\"battery life\"]}\n```\n\n**Step 4: Validate example quality**\n```bash\npython scripts\u002Fprompt_optimizer.py prompt_with_examples.txt --validate-examples\n# Checks: consistency, coverage, format alignment\n```\n\n**Step 5: Test with held-out cases**\nEnsure model generalizes beyond your examples.\n\n---\n\n### Structured Output Design Workflow\n\nUse when you need reliable JSON\u002FXML\u002Fstructured responses.\n\n**Step 1: Define schema**\n```json\n{\n  \"type\": \"object\",\n  \"properties\": {\n    \"summary\": {\"type\": \"string\", \"maxLength\": 200},\n    \"sentiment\": {\"enum\": [\"positive\", \"negative\", \"neutral\"]},\n    \"confidence\": {\"type\": \"number\", \"minimum\": 0, \"maximum\": 1}\n  },\n  \"required\": [\"summary\", \"sentiment\"]\n}\n```\n\n**Step 2: Include schema in prompt**\n```\nRespond with JSON matching this schema:\n- summary (string, max 200 chars): Brief summary of the content\n- sentiment (enum): One of \"positive\", \"negative\", \"neutral\"\n- confidence (number 0-1): Your confidence in the sentiment\n```\n\n**Step 3: Add format enforcement**\n```\nIMPORTANT: Respond ONLY with valid JSON. No markdown, no explanation.\nStart your response with { and end with }\n```\n\n**Step 4: Validate outputs**\n```bash\npython scripts\u002Fprompt_optimizer.py structured_prompt.txt --validate-schema schema.json\n```\n\n---\n\n## Reference Documentation\n\n| File | Contains | Load when user asks about |\n|------|----------|---------------------------|\n| `references\u002Fprompt_engineering_patterns.md` | 10 prompt patterns with input\u002Foutput examples | \"which pattern?\", \"few-shot\", \"chain-of-thought\", \"role prompting\" |\n| `references\u002Fllm_evaluation_frameworks.md` | Evaluation metrics, scoring methods, A\u002FB testing | \"how to evaluate?\", \"measure quality\", \"compare prompts\" |\n| `references\u002Fagentic_system_design.md` | Agent architectures (ReAct, Plan-Execute, Tool Use) | \"build agent\", \"tool calling\", \"multi-agent\" |\n\n---\n\n## Common Patterns Quick Reference\n\n| Pattern | When to Use | Example |\n|---------|-------------|---------|\n| **Zero-shot** | Simple, well-defined tasks | \"Classify this email as spam or not spam\" |\n| **Few-shot** | Complex tasks, consistent format needed | Provide 3-5 examples before the task |\n| **Chain-of-Thought** | Reasoning, math, multi-step logic | \"Think step by step...\" |\n| **Role Prompting** | Expertise needed, specific perspective | \"You are an expert tax accountant...\" |\n| **Structured Output** | Need parseable JSON\u002FXML | Include schema + format enforcement |\n\n---\n\n## Common Commands\n\n```bash\n# Prompt Analysis\npython scripts\u002Fprompt_optimizer.py prompt.txt --analyze          # Full analysis\npython scripts\u002Fprompt_optimizer.py prompt.txt --tokens           # Token count only\npython scripts\u002Fprompt_optimizer.py prompt.txt --optimize         # Generate optimized version\n\n# RAG Evaluation\npython scripts\u002Frag_evaluator.py --contexts ctx.json --questions q.json  # Evaluate\npython scripts\u002Frag_evaluator.py --contexts ctx.json --compare baseline  # Compare to baseline\n\n# Agent Development\npython scripts\u002Fagent_orchestrator.py agent.yaml --validate       # Validate config\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize      # Show workflow\npython scripts\u002Fagent_orchestrator.py agent.yaml --estimate-cost  # Token estimation\n```\n","# Senior Prompt Engineer\n\nPrompt engineering patterns, LLM evaluation frameworks, and agentic system design.\n\n## Table of Contents\n\n- [Quick Start](#quick-start)\n- [Tools Overview](#tools-overview)\n  - [Prompt Optimizer](#1-prompt-optimizer)\n  - [RAG Evaluator](#2-rag-evaluator)\n  - [Agent Orchestrator](#3-agent-orchestrator)\n- [Prompt Engineering Workflows](#prompt-engineering-workflows)\n  - [Prompt Optimization Workflow](#prompt-optimization-workflow)\n  - [Few-Shot Example Design](#few-shot-example-design-workflow)\n  - [Structured Output Design](#structured-output-design-workflow)\n- [Reference Documentation](#reference-documentation)\n- [Common Patterns Quick Reference](#common-patterns-quick-reference)\n\n---\n\n## Quick Start\n\n```bash\n# Analyze and optimize a prompt file\npython scripts\u002Fprompt_optimizer.py prompts\u002Fmy_prompt.txt --analyze\n\n# Evaluate RAG retrieval quality\npython scripts\u002Frag_evaluator.py --contexts contexts.json --questions questions.json\n\n# Visualize agent workflow from definition\npython scripts\u002Fagent_orchestrator.py agent_config.yaml --visualize\n```\n\n---\n\n## Tools Overview\n\n### 1. Prompt Optimizer\n\nAnalyzes prompts for token efficiency, clarity, and structure. Generates optimized versions.\n\n**Input:** Prompt text file or string\n**Output:** Analysis report with optimization suggestions\n\n**Usage:**\n```bash\n# Analyze a prompt file\npython scripts\u002Fprompt_optimizer.py prompt.txt --analyze\n\n# Output:\n# Token count: 847\n# Estimated cost: $0.0025 (GPT-4)\n# Clarity score: 72\u002F100\n# Issues found:\n#   - Ambiguous instruction at line 3\n#   - Missing output format specification\n#   - Redundant context (lines 12-15 repeat lines 5-8)\n# Suggestions:\n#   1. Add explicit output format: \"Respond in JSON with keys: ...\"\n#   2. Remove redundant context to save 89 tokens\n#   3. Clarify \"analyze\" -> \"list the top 3 issues with severity ratings\"\n\n# Generate optimized version\npython scripts\u002Fprompt_optimizer.py prompt.txt --optimize --output optimized.txt\n\n# Count tokens for cost estimation\npython scripts\u002Fprompt_optimizer.py prompt.txt --tokens --model gpt-4\n\n# Extract and manage few-shot examples\npython scripts\u002Fprompt_optimizer.py prompt.txt --extract-examples --output examples.json\n```\n\n---\n\n### 2. RAG Evaluator\n\nEvaluates Retrieval-Augmented Generation quality by measuring context relevance and answer faithfulness.\n\n**Input:** Retrieved contexts (JSON) and questions\u002Fanswers\n**Output:** Evaluation metrics and quality report\n\n**Usage:**\n```bash\n# Evaluate retrieval quality\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json\n\n# Output:\n# === RAG Evaluation Report ===\n# Questions evaluated: 50\n#\n# Retrieval Metrics:\n#   Context Relevance: 0.78 (target: >0.80)\n#   Retrieval Precision@5: 0.72\n#   Coverage: 0.85\n#\n# Generation Metrics:\n#   Answer Faithfulness: 0.91\n#   Groundedness: 0.88\n#\n# Issues Found:\n#   - 8 questions had no relevant context in top-5\n#   - 3 answers contained information not in context\n#\n# Recommendations:\n#   1. Improve chunking strategy for technical documents\n#   2. Add metadata filtering for date-sensitive queries\n\n# Evaluate with custom metrics\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json \\\n    --metrics relevance,faithfulness,coverage\n\n# Export detailed results\npython scripts\u002Frag_evaluator.py --contexts retrieved.json --questions eval_set.json \\\n    --output report.json --verbose\n```\n\n---\n\n### 3. Agent Orchestrator\n\nParses agent definitions and visualizes execution flows. Validates tool configurations.\n\n**Input:** Agent configuration (YAML\u002FJSON)\n**Output:** Workflow visualization, validation report\n\n**Usage:**\n```bash\n# Validate agent configuration\npython scripts\u002Fagent_orchestrator.py agent.yaml --validate\n\n# Output:\n# === Agent Validation Report ===\n# Agent: research_assistant\n# Pattern: ReAct\n#\n# Tools (4 registered):\n#   [OK] web_search - API key configured\n#   [OK] calculator - No config needed\n#   [WARN] file_reader - Missing allowed_paths\n#   [OK] summarizer - Prompt template valid\n#\n# Flow Analysis:\n#   Max depth: 5 iterations\n#   Estimated tokens\u002Frun: 2,400-4,800\n#   Potential infinite loop: No\n#\n# Recommendations:\n#   1. Add allowed_paths to file_reader for security\n#   2. Consider adding early exit condition for simple queries\n\n# Visualize agent workflow (ASCII)\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize\n\n# Output:\n# ┌─────────────────────────────────────────┐\n# │            research_assistant           │\n# │              (ReAct Pattern)            │\n# └─────────────────┬───────────────────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │   User Query    │\n#          └────────┬────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │     Think       │◄──────┐\n#          └────────┬────────┘       │\n#                   │                │\n#          ┌────────▼────────┐       │\n#          │   Select Tool   │       │\n#          └────────┬────────┘       │\n#                   │                │\n#     ┌─────────────┼─────────────┐  │\n#     ▼             ▼             ▼  │\n# [web_search] [calculator] [file_reader]\n#     │             │             │  │\n#     └─────────────┼─────────────┘  │\n#                   │                │\n#          ┌────────▼────────┐       │\n#          │    Observe      │───────┘\n#          └────────┬────────┘\n#                   │\n#          ┌────────▼────────┐\n#          │  Final Answer   │\n#          └─────────────────┘\n\n# Export workflow as Mermaid diagram\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize --format mermaid\n```\n\n---\n\n## Prompt Engineering Workflows\n\n### Prompt Optimization Workflow\n\nUse when improving an existing prompt's performance or reducing token costs.\n\n**Step 1: Baseline current prompt**\n```bash\npython scripts\u002Fprompt_optimizer.py current_prompt.txt --analyze --output baseline.json\n```\n\n**Step 2: Identify issues**\nReview the analysis report for:\n- Token waste (redundant instructions, verbose examples)\n- Ambiguous instructions (unclear output format, vague verbs)\n- Missing constraints (no length limits, no format specification)\n\n**Step 3: Apply optimization patterns**\n| Issue | Pattern to Apply |\n|-------|------------------|\n| Ambiguous output | Add explicit format specification |\n| Too verbose | Extract to few-shot examples |\n| Inconsistent results | Add role\u002Fpersona framing |\n| Missing edge cases | Add constraint boundaries |\n\n**Step 4: Generate optimized version**\n```bash\npython scripts\u002Fprompt_optimizer.py current_prompt.txt --optimize --output optimized.txt\n```\n\n**Step 5: Compare results**\n```bash\npython scripts\u002Fprompt_optimizer.py optimized.txt --analyze --compare baseline.json\n# Shows: token reduction, clarity improvement, issues resolved\n```\n\n**Step 6: Validate with test cases**\nRun both prompts against your evaluation set and compare outputs.\n\n---\n\n### Few-Shot Example Design Workflow\n\nUse when creating examples for in-context learning.\n\n**Step 1: Define the task clearly**\n```\nTask: Extract product entities from customer reviews\nInput: Review text\nOutput: JSON with {product_name, sentiment, features_mentioned}\n```\n\n**Step 2: Select diverse examples (3-5 recommended)**\n| Example Type | Purpose |\n|--------------|---------|\n| Simple case | Shows basic pattern |\n| Edge case | Handles ambiguity |\n| Complex case | Multiple entities |\n| Negative case | What NOT to extract |\n\n**Step 3: Format consistently**\n```\nExample 1:\nInput: \"Love my new iPhone 15, the camera is amazing!\"\nOutput: {\"product_name\": \"iPhone 15\", \"sentiment\": \"positive\", \"features_mentioned\": [\"camera\"]}\n\nExample 2:\nInput: \"The laptop was okay but battery life is terrible.\"\nOutput: {\"product_name\": \"laptop\", \"sentiment\": \"mixed\", \"features_mentioned\": [\"battery life\"]}\n```\n\n**Step 4: Validate example quality**\n```bash\npython scripts\u002Fprompt_optimizer.py prompt_with_examples.txt --validate-examples\n# Checks: consistency, coverage, format alignment\n```\n\n**Step 5: Test with held-out cases**\nEnsure model generalizes beyond your examples.\n\n---\n\n### Structured Output Design Workflow\n\nUse when you need reliable JSON\u002FXML\u002Fstructured responses.\n\n**Step 1: Define schema**\n```json\n{\n  \"type\": \"object\",\n  \"properties\": {\n    \"summary\": {\"type\": \"string\", \"maxLength\": 200},\n    \"sentiment\": {\"enum\": [\"positive\", \"negative\", \"neutral\"]},\n    \"confidence\": {\"type\": \"number\", \"minimum\": 0, \"maximum\": 1}\n  },\n  \"required\": [\"summary\", \"sentiment\"]\n}\n```\n\n**Step 2: Include schema in prompt**\n```\nRespond with JSON matching this schema:\n- summary (string, max 200 chars): Brief summary of the content\n- sentiment (enum): One of \"positive\", \"negative\", \"neutral\"\n- confidence (number 0-1): Your confidence in the sentiment\n```\n\n**Step 3: Add format enforcement**\n```\nIMPORTANT: Respond ONLY with valid JSON. No markdown, no explanation.\nStart your response with { and end with }\n```\n\n**Step 4: Validate outputs**\n```bash\npython scripts\u002Fprompt_optimizer.py structured_prompt.txt --validate-schema schema.json\n```\n\n---\n\n## Reference Documentation\n\n| File | Contains | Load when user asks about |\n|------|----------|---------------------------|\n| `references\u002Fprompt_engineering_patterns.md` | 10 prompt patterns with input\u002Foutput examples | \"which pattern?\", \"few-shot\", \"chain-of-thought\", \"role prompting\" |\n| `references\u002Fllm_evaluation_frameworks.md` | Evaluation metrics, scoring methods, A\u002FB testing | \"how to evaluate?\", \"measure quality\", \"compare prompts\" |\n| `references\u002Fagentic_system_design.md` | Agent architectures (ReAct, Plan-Execute, Tool Use) | \"build agent\", \"tool calling\", \"multi-agent\" |\n\n---\n\n## Common Patterns Quick Reference\n\n| Pattern | When to Use | Example |\n|---------|-------------|---------|\n| **Zero-shot** | Simple, well-defined tasks | \"Classify this email as spam or not spam\" |\n| **Few-shot** | Complex tasks, consistent format needed | Provide 3-5 examples before the task |\n| **Chain-of-Thought** | Reasoning, math, multi-step logic | \"Think step by step...\" |\n| **Role Prompting** | Expertise needed, specific perspective | \"You are an expert tax accountant...\" |\n| **Structured Output** | Need parseable JSON\u002FXML | Include schema + format enforcement |\n\n---\n\n## Common Commands\n\n```bash\n# Prompt Analysis\npython scripts\u002Fprompt_optimizer.py prompt.txt --analyze          # Full analysis\npython scripts\u002Fprompt_optimizer.py prompt.txt --tokens           # Token count only\npython scripts\u002Fprompt_optimizer.py prompt.txt --optimize         # Generate optimized version\n\n# RAG Evaluation\npython scripts\u002Frag_evaluator.py --contexts ctx.json --questions q.json  # Evaluate\npython scripts\u002Frag_evaluator.py --contexts ctx.json --compare baseline  # Compare to baseline\n\n# Agent Development\npython scripts\u002Fagent_orchestrator.py agent.yaml --validate       # Validate config\npython scripts\u002Fagent_orchestrator.py agent.yaml --visualize      # Show workflow\npython scripts\u002Fagent_orchestrator.py agent.yaml --estimate-cost  # Token estimation\n```\n",{"name":5,"description":7},"main","7b610356e36623652299fa2acb477ff821b1d920","upstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer",0,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud","https:\u002F\u002Fwww.linkedin.com\u002Fin\u002Fo-abdelmaksoud\u002F","Full-Stack Engineer | AI Systems Architect | Building autonomous multi-agent systems","2026-03-08 21:12:53",{"source":8,"skillName":5,"commands":67,"prompt":77,"zipAvailable":78},[68,71,74],{"tool":69,"command":70},"npx","npx skills add oabdelmaksoud\u002FSuperClaw --skill senior-prompt-engineer",{"tool":72,"command":73},"bunx","bunx skills add oabdelmaksoud\u002FSuperClaw --skill senior-prompt-engineer",{"tool":75,"command":76},"pnpm","pnpm dlx skills add oabdelmaksoud\u002FSuperClaw --skill senior-prompt-engineer","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002FSKILL.md",true,[80,86,90,94,100,104,108],{"path":81,"resourceType":82,"resourceTypeDesc":83,"sizeBytes":84,"sourceHtmlUrl":85},"references\u002Fagentic_system_design.md","REFERENCE","参考文档",21700,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Freferences\u002Fagentic_system_design.md",{"path":87,"resourceType":82,"resourceTypeDesc":83,"sizeBytes":88,"sourceHtmlUrl":89},"references\u002Fllm_evaluation_frameworks.md",13303,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Freferences\u002Fllm_evaluation_frameworks.md",{"path":91,"resourceType":82,"resourceTypeDesc":83,"sizeBytes":92,"sourceHtmlUrl":93},"references\u002Fprompt_engineering_patterns.md",13636,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Freferences\u002Fprompt_engineering_patterns.md",{"path":95,"resourceType":96,"resourceTypeDesc":97,"sizeBytes":98,"sourceHtmlUrl":99},"scripts\u002Fagent_orchestrator.py","SCRIPT","脚本",20488,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Fscripts\u002Fagent_orchestrator.py",{"path":101,"resourceType":96,"resourceTypeDesc":97,"sizeBytes":102,"sourceHtmlUrl":103},"scripts\u002Fnotice.py",432,"https:\u002F\u002Fgithub.com\u002Fanningcode\u002FCapybara\u002Fblob\u002Fmaster\u002FCapybara\u002Fcapybara\u002Fskills\u002Fnotice\u002Fscripts\u002Fnotice.py",{"path":105,"resourceType":96,"resourceTypeDesc":97,"sizeBytes":106,"sourceHtmlUrl":107},"scripts\u002Fprompt_optimizer.py",17862,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Fscripts\u002Fprompt_optimizer.py",{"path":109,"resourceType":96,"resourceTypeDesc":97,"sizeBytes":110,"sourceHtmlUrl":111},"scripts\u002Frag_evaluator.py",20362,"https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fclaude-skills\u002Fengineering-team\u002Fsenior-prompt-engineer\u002Fscripts\u002Frag_evaluator.py",[113,131,145,171,197,216],{"skillNo":114,"name":115,"nameZh":6,"description":116,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":117,"categories":118,"keywords":122,"publishedAt":52},"01M6D88QCPTBZVCRED0NZ1Y8K8","visa-doc-translate","Translate visa application documents (images) to English and create a bilingual PDF with original and translation","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Fvisa-doc-translate\u002FSKILL.md",[119],{"categoryNo":120,"categoryName":121,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000002","文档处理",[123,124,125,126,127,45,128,129,130],"translate","doc","visa doc translate","translation","application","images","PDF","documents",{"skillNo":132,"name":133,"nameZh":6,"description":134,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":135,"categories":136,"keywords":137,"publishedAt":52},"01M6D88NBM95T3TFM50CYYAP65","verification-loop","A comprehensive verification system for Claude Code sessions.","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Fverification-loop\u002FSKILL.md",[],[138,139,140,141,142,143,144],"verification","loop","verification loop","sessions","code","claude code sessions","system",{"skillNo":146,"name":147,"nameZh":6,"description":148,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":149,"categories":150,"keywords":158,"publishedAt":52},"01M6D88JFZ2P996GVRHJNSZSTM","tdd-workflow","Use this skill when writing new features, fixing bugs, or refactoring code. Enforces test-driven development with 80%+ coverage including unit, integration, and E2E tests.","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Ftdd-workflow\u002FSKILL.md",[151,154,155],{"categoryNo":152,"categoryName":153,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000008","测试与质量",{"categoryNo":24,"categoryName":25,"taxonomyType":21,"taxonomyTypeDesc":22},{"categoryNo":156,"categoryName":157,"taxonomyType":29,"taxonomyTypeDesc":30},"01JBSEEDCAT000000000000030","开发工程师",[159,160,161,162,163,164,142,165,41,166,167,168,169,170],"tdd","workflow","tdd workflow","e2e tests","e2e","integration","development","test","refactoring","coverage","tests","writing",{"skillNo":172,"name":173,"nameZh":6,"description":174,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":175,"categories":176,"keywords":177,"publishedAt":52},"01M6D88FTHRRSVJMXF2G7MQAK3","swiftui-patterns","SwiftUI architecture patterns, state management with @Observable, view composition, navigation, performance optimization, and modern iOS\u002FmacOS UI best practices.","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Fswiftui-patterns\u002FSKILL.md",[],[178,179,180,181,182,183,184,185,186,187,188,189,190,191,192,193,194,195,196],"patterns","swiftui","swiftui patterns","architecture","macos","performance","state management","best practices","state","ui","Optimization","ios","architecture patterns","Composition","performance optimization","view","management","swiftui architecture","navigation",{"skillNo":198,"name":199,"nameZh":6,"description":200,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":201,"categories":202,"keywords":204,"publishedAt":52},"01M6D88D527QTQT9DKHTRFN6EA","swift-protocol-di-testing","Protocol-based dependency injection for testable Swift code — mock file system, network, and external APIs using focused protocols and Swift Testing.","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Fswift-protocol-di-testing\u002FSKILL.md",[203],{"categoryNo":152,"categoryName":153,"taxonomyType":21,"taxonomyTypeDesc":22},[205,206,207,208,142,209,210,211,212,144,213,214,215],"swift protocol di testing","protocol","swift","testing","protocols","file","network","injection","dependency","swift testing","dependency injection",{"skillNo":217,"name":218,"nameZh":6,"description":219,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":220,"categories":221,"keywords":222,"publishedAt":52},"01M6D88AJW8H2QNWSW5ZY82R43","swift-concurrency-6-2","Swift 6.2 Approachable Concurrency — single-threaded by default, @concurrent for explicit background offloading, isolated conformances for main actor types.","https:\u002F\u002Fgithub.com\u002Foabdelmaksoud\u002FSuperClaw\u002Fblob\u002Fmain\u002Fupstream-sync\u002Fwork\u002Fecc\u002Fskills\u002Fswift-concurrency-6-2\u002FSKILL.md",[],[223,224,207,225,226,57],"concurrency","swift concurrency","swift concurrency 6 2","default"]