prompt-engineering

prompt-engineering is a skill for Claude Code, Codex from nimadorostkar/Claude-Skills-collection. It costs 36 tokens per session (1,326 once invoked), scanned A, original, MIT.

Guidance for writing prompts—instructions given to a language model—and improving them through examples, output rules, and testing. It also covers diagnosing why a prompt gives unreliable results.

In plain words
What is it for?
Use it to create production prompts, fix inconsistent responses, reduce prompt cost or delay, migrate prompts between models, and design structured outputs.
Why use it?
It replaces guesswork with a repeatable way to define correct answers, measure failures, and refine prompts without losing required quality.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit Use it to create production prompts, fix inconsistent responses, reduce prompt cost or delay, migrate prompts between models, and design structured outputs.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/nimadorostkar/claude-skills-collection/prompt-engineering
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add nimadorostkar/Claude-Skills-collection --skill prompt-engineering
Clone the repo
git clone --depth 1 https://github.com/nimadorostkar/Claude-Skills-collection

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for prompt-engineering

README.md
[![agentmods](https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/prompt-engineering/github.svg)](https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/prompt-engineering)
Your own site
<a href="https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/prompt-engineering"><img src="https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/prompt-engineering/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for prompt-engineering

Your own site · 80×15
<a href="https://agentmods.dev/skills/nimadorostkar/claude-skills-collection/prompt-engineering"><img src="https://agentmods.dev/badge/skills/nimadorostkar/claude-skills-collection/prompt-engineering.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 36 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,326 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00036 $0.01326
Opus 5 $0.00018 $0.00663
Sonnet 5 $0.00007 $0.00265
Haiku 4.5 $0.00004 $0.00133

Measured 12d ago against content hash 9726d8f2a0cf, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-12, from the pricing page.

Security

Grade A, and why

prompt-engineering scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/ai/prompt-engineering/SKILL.md · 123 lines

How it starts

The opening of the file, as written. The whole thing — 123 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Prompt Engineering

Purpose

Write prompts that produce the right output reliably, and diagnose the ones that do not. Prompt engineering is an empirical discipline: the model's actual behavior, measured, beats any theory about what should work.

When to Use

  • Writing a prompt for a production feature.
  • A prompt that works most of the time and fails unpredictably.
  • Reducing token cost or latency without losing quality.
  • Migrating a prompt between models.

Capabilities

  • Instruction design: role, task, constraints, and output contract.
  • Few-shot examples, and selecting the ones that teach the boundary.
  • Reasoning elicitation for tasks that need it.
  • Output formatting and structured extraction.
  • Failure diagnosis and systematic iteration.

Inputs

  • The task, and what a correct output looks like.
  • Real failure cases from the current prompt.
  • Constraints: latency, cost, and the model available.

Outputs

  • A prompt with an explicit output contract.
  • An evaluation set of inputs with expected outputs.
  • A measured success rate, before and after.

Workflow

  1. Define correct before writing the prompt — Twenty real inputs and their correct outputs. Without this, "improving" a prompt is a matter of opinion and you will optimize for the last example you looked at.
  2. State the task, the constraints, and the output shape — Be specific about what to do, what not to do, and exactly what format the answer takes.
  3. Add examples that teach the boundary — Two or three examples covering the ambiguous cases, not the obvious ones. An example of the hard case is worth ten of the easy one.
  4. Elicit reasoning only where it helps — For multi-step reasoning, ask the model to work through it before answering. For classification and extraction, it adds latency and cost without improving accuracy.
  5. Measure, change one thing, measure again — On the evaluation set. A change that improves one example and silently breaks three others is a regression that feels like progress.
  6. Handle the failure mode — Decide what happens when the model returns something unparseable, refuses, or hallucinates a field. That path will be taken.

Read the full file on GitHub · 123 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 123 lines · 36 tokens per session scan A 9726d8f2a0cf

Subscribe to this mod's changes

prompt-engineering is a skill published in the GitHub repository nimadorostkar/Claude-Skills-collection (26 stars, last pushed 24d ago), licensed MIT. It adds 36 tokens to every session and 1,326 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories

prompt-engineer

Expert prompt engineering for AI systems. Use when the user wants to write or review prompts for AI, create instructions for AI systems, build system prompts, review or improve existing prompts, optimize AI instructions, or create any form of written communication intended for AI consumption (Claude, GPT, or other…

SZoloth/skill-pack · 66 tokens

few-shot-quality-prompting

Master guide for crafting prompts that make AI models produce professional-quality code and UI consistently. Trigger whenever the user asks about prompt engineering, improving AI output quality, building system prompts, few-shot examples, making AI write better code, prompt optimization, or says "how to prompt"…

mahmoud20138/Tradecraft · 102 tokens

huashu-prompt-save

Automatically identifies the prompt type and saves it to the appropriate category (Technical / Content / Teaching / Product / General). Use when the user mentions "save prompt", "record prompt", or "organise prompts".

Biraj2004/huashu-skills-english · 49 tokens

agent-orchestration-improve-agent

Systematic improvement of existing agents through performance analysis, prompt engineering, and continuous iteration.

lingxling/awesome-skills-cn · 25 tokens

prompt-optimizer

A guide for reviewing and rewriting prompts intended for Claude, an AI assistant, including Claude Code. It focuses on making instructions clearer and more specific.

imamirezaei/Product-Team-Claude-Skills · 167 tokens

developing-genkit-js

Develop AI-powered applications using Genkit in Node.js/TypeScript. Use when the user asks about Genkit, AI agents, flows, or tools in JavaScript/TypeScript, or when encountering Genkit errors, validation issues, type errors, or API problems.

google/skills · 60 tokens