prompt-engineer
An agent skill by Jeffallan, from Jeffallan/claude-skills. Tags: anthropic, documentation, evaluation, generative, strategy.
What it does
Writes, refactors, and evaluates prompts for LLMs — 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.
Install
With the skills CLI, which installs into Claude Code, Codex, Cursor and other agents:
npx skills add Jeffallan/claude-skills --skill prompt-engineer
Or copy the skill folder into Claude Code's skills directory by hand (~/.claude/skills for every project, or .claude/skills inside one):
git clone --depth 1 https://github.com/Jeffallan/claude-skills
cp -r claude-skills/skills/prompt-engineer ~/.claude/skills/prompt-engineer
Safety box score
Grade B, low risk: 21 of 100 risk points, rated 2026-10-15. The grade rates what the skill and its scripts can reach on the machine of whoever installs it, across eight categories from shell execution to secrets access. How the score works.
This skill is a markdown-only prompt-engineering reference pack: it teaches prompt patterns, evaluation, system-prompt design, and structured output schemas. The main risks come from example code that sends prompt/test data to external LLM APIs, uses API keys in CI, and shows automation that can comment on pull requests or write evaluation artifacts if copied verbatim.
| Category | Level | Why |
|---|---|---|
| Code & shell execution | 0 (none) | No runnable scripts are shipped; the repository content is documentation and code snippets only, not native executables. |
| Network access | 1 (low) | The references include example calls to external services like `client.messages.create(...)` and OpenAI/Anthropic APIs, so adapting the patterns can send prompts and test data off-machine. |
| Filesystem reach | 1 (low) | Example evaluation code writes and reads project paths such as `results/{timestamp}_{prompt_version}/`, `prompts/`, and `evaluation/test_cases/`, but only as illustrative workflows. |
| Secrets & credentials | 1 (low) | The CI example uses `ANTHROPIC_API_KEY: ${{ secrets.ANTHROPIC_API_KEY }}` and the docs discuss API-key-backed evaluation, so careless reuse could expose or transmit sensitive prompts via keyed services. |
| Privilege & persistence | 0 (none) | There are no sudo calls, service installs, shell startup edits, or other system-level changes in the shipped files. |
| Instruction hijack surface | 1 (low) | The skill contains prompt-injection defense guidance and adversarial test strings like `Ignore all previous instructions`, but these are framed as test cases/mitigations rather than instructions to bypass safeguards. |
| Irreversible actions | 1 (low) | The GitHub Actions example can automatically run evaluations and post PR comments (`github.rest.issues.createComment(...)`), but it stays within repository-scoped automation. |
| Transparency | 0 (none) | All shipped files are readable Markdown; there are no binaries, packed blobs, or decoded-at-runtime code. |
Before installing
- Review `references/evaluation-frameworks.md` before copying any CI example; it posts PR comments and uses `secrets.ANTHROPIC_API_KEY`.
- Check every prompt/test example you adapt for secrets or customer data before sending it to external LLM APIs.
- If you plan to run the evaluation workflow, do it in a sandbox repo/account first and inspect the `results/` writes.
Rated 2026-10-15 by an automated review of 7 files from the skill's repository.
Source
- Repository
- Jeffallan/claude-skills (all skills from this repository)
- Path
- skills/prompt-engineer/SKILL.md
- Branch
- main
- Updated
- 2026-09-19
Related skills
- advisor — Advisor mode. Consult a stronger (or different) model at key checkpoints: before major decisions, when stuck on an error, and before declaring a task done.
- arena — Spawn N parallel candidates at the same task, pick a base, graft the strongest parts of the losers into it.
- expo-skill-feedback — Submit feedback on an Expo skill—or Expo itself—and control bundled anonymous usage telemetry (off by default / opt-in).
- goal-prompt — Drafts copy-paste-ready /goal commands for goal mode in Claude Code and Codex.
- guidelines-advisor — Smart contract development advisor based on Trail of Bits' best practices.
- interpreting-culture-index — Interprets Culture Index (CI) surveys, behavioral profiles, and personality assessment data.