Skip to content
Back to skills

Senior Prompt Engineer

ASecurity

Prompt engineering patterns, LLM evaluation frameworks, agentic system design, and structured output design. Optimize prompts, design few-shot examples, evaluate RAG quality, and build agent workflows.

  • 3 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added November 14, 2026
ai-agentspythongobashreacttestingapidocumentation

Works with

  • api

Security analysis

A100/100

Pro scans all 7 files and shows the line behind each finding

Scanned November 14, 2026

npx -y skills add SebastianLuser/claude-code-arcane --skill senior-prompt-engineer --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Senior Prompt Engineer?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Senior Prompt Engineer
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/sebastianluser-senior-prompt-engineer/badge)](https://www.skillsdirectory.com/skills/sebastianluser-senior-prompt-engineer)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: senior-prompt-engineer
description: "Prompt engineering patterns, LLM evaluation frameworks, agentic system design, and structured output design. Optimize prompts, design few-shot examples, evaluate RAG quality, and build agent workflows."
argument-hint: ""
category: "ai"
user-invocable: true
allowed-tools: Read, Glob, Grep, Bash, Write, Edit
---

# Senior Prompt Engineer

Prompt engineering patterns, LLM evaluation frameworks, and agentic system design. May write or edit prompt files, agent configurations, and evaluation scripts.

## Quick Start

```bash
python scripts/prompt_optimizer.py prompts/my_prompt.txt --analyze       # Analyze prompt
python scripts/rag_evaluator.py --contexts contexts.json --questions questions.json  # Evaluate RAG
python scripts/agent_orchestrator.py agent_config.yaml --visualize       # Visualize agent
```

## Tools

### 1. Prompt Optimizer

Static checks for clarity and structure, with an approximate token count (characters / 4). `--optimize` only normalizes whitespace; the real rewrite is yours.

```bash
python scripts/prompt_optimizer.py prompt.txt --analyze          # Full analysis
python scripts/prompt_optimizer.py prompt.txt --optimize         # Normalize whitespace
python scripts/prompt_optimizer.py prompt.txt --tokens           # Approximate token count
python scripts/prompt_optimizer.py prompt.txt --extract-examples --output examples.json
```

### 2. RAG Evaluator

Evaluates retrieval quality by measuring context relevance and answer faithfulness.

```bash
python scripts/rag_evaluator.py --contexts retrieved.json --questions eval_set.json
python scripts/rag_evaluator.py --contexts retrieved.json --questions eval_set.json --metrics relevance,faithfulness,coverage
python scripts/rag_evaluator.py --contexts retrieved.json --questions eval_set.json --output report.json --verbose
```

### 3. Agent Orchestrator

Parses agent definitions and visualizes execution flows. Validates tool configurations.

```bash
python scripts/agent_orchestrator.py agent.yaml --validate       # Validate config
python scripts/agent_orchestrator.py agent.yaml --visualize      # Show workflow (ASCII)
python scripts/agent_orchestrator.py agent.yaml --visualize --format mermaid  # Mermaid
python scripts/agent_orchestrator.py agent.yaml --estimate-cost --price-in 4 --price-out 20  # Tokens; dollars with your current prices (USD/Mtok)
```

## Prompt Engineering Workflows

### Prompt Optimization Workflow

1. **Baseline**: `python scripts/prompt_optimizer.py current_prompt.txt --analyze --output baseline.json`
2. **Identify issues**: Token waste, ambiguous instructions, missing constraints
3. **Apply patterns**:

| Issue | Pattern |
|-------|---------|
| Ambiguous output | Add explicit format specification |
| Too verbose | Extract to few-shot examples |
| Inconsistent results | Add 2-3 varied examples and state the success criteria |
| Missing edge cases | Add constraint boundaries |

4. **Optimize**: `python scripts/prompt_optimizer.py current_prompt.txt --optimize --output optimized.txt`
5. **Compare**: `python scripts/prompt_optimizer.py optimized.txt --analyze --compare baseline.json`
6. **Validate**: Run both prompts against evaluation set

### Few-Shot Example Design

1. Define task clearly (input format, output format)
2. Select 3-5 diverse examples: simple case, edge case, complex case, negative case
3. Format consistently
4. Check what the prompt contains: `python scripts/prompt_optimizer.py prompt_with_examples.txt --extract-examples`
5. Test with held-out cases

### Structured Output Design

1. Define JSON/XML schema with types, constraints, enums
2. Pass the schema through the API's structured outputs (`output_config.format` on Claude) so the response is guaranteed to match it; do not rely on "respond ONLY with valid JSON" in the prompt
3. Describe in the prompt what each field means, not the JSON syntax
4. Validate the parsed result against the schema in code before using it

## Reference Documentation

> See references/ for detailed patterns and examples.

| File | Contains |
|------|----------|
| `references/prompt_engineering_patterns.md` | 10 prompt patterns with I/O examples |
| `references/llm_evaluation_frameworks.md` | Evaluation metrics, scoring, A/B testing |
| `references/agentic_system_design.md` | Agent architectures (ReAct, Plan-Execute, Tool Use) |

## Common Patterns Quick Reference

| Pattern | When to Use | Example |
|---------|-------------|---------|
| **Zero-shot** | Simple, well-defined tasks | "Classify this email as spam or not spam" |
| **Few-shot** | Complex tasks, consistent format | Provide 3-5 examples before task |
| **Reasoning depth** | Reasoning, math, multi-step | Models with adaptive thinking: raise `effort`. Models without it: "Think step by step..." |
| **Role Prompting** | Expertise, specific perspective | "You are an expert tax accountant..." |
| **Structured Output** | Need parseable JSON/XML | Include schema + format enforcement |

Files in this skill

  • SKILL.md4.9 KB
  • references/agentic_system_design.md21.2 KB
  • references/llm_evaluation_frameworks.md13 KB
  • references/prompt_engineering_patterns.md13.5 KB
  • scripts/agent_orchestrator.py20.6 KB
  • scripts/prompt_optimizer.py15.9 KB
  • scripts/rag_evaluator.py19.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

View all in ai-agents →

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.