Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

Prompt Engineering Skill

БесплатноБез исполняемых скриптовНе проверен

Craft effective prompts that get the best results from language models.

diegosouzapwот diegosouzapw★ 68 звёзд на GitHub

Об этом скилле

Prompt Engineering Skill

Craft effective prompts that get the best results from language models.

Core Principle

Prompts are programming for probabilistic systems. Clear instructions, good examples, and structured output formats dramatically improve results.

Prompt Anatomy

┌─────────────────────────────────────────┐
│ SYSTEM PROMPT (Role & Constraints)      │
│ "You are a senior code reviewer..."     │
├─────────────────────────────────────────┤
│ CONTEXT (Background Information)        │
│ "The codebase uses TypeScript..."       │
├─────────────────────────────────────────┤
│ EXAMPLES (Few-Shot Learning)            │
│ Input: X → Output: Y                    │
├─────────────────────────────────────────┤
│ TASK (What to Do)                       │
│ "Review this pull request for..."       │
├─────────────────────────────────────────┤
│ FORMAT (Output Structure)               │
│ "Respond in JSON with fields..."        │
└─────────────────────────────────────────┘

Prompting Techniques

Zero-Shot

Direct instruction without examples:

Classify this customer feedback as positive, negative, or neutral:
"The product arrived late but works great."

Best for: Simple, well-defined tasks the model understands.

Few-Shot

Provide examples to demonstrate the pattern:

Classify customer feedback:

Input: "Love it! Best purchase ever!"
Output: positive

Input: "Broken on arrival. Waste of money."
Output: negative

Input: "The product arrived late but works great."
Output: ?

Best for: Nuanced tasks, custom formats, domain-specific patterns.

Chain-of-Thought (CoT)

Ask the model to think step-by-step:

Solve this problem. Think through it step by step before giving your answer.

A store has 45 apples. They sell 12 in the morning and receive a shipment of 30.
How many apples do they have?

Let's think step by step:
1. Start with 45 apples
2. Sell 12: 45 - 12 = 33
3. Receive 30: 33 + 30 = 63

Answer: 63 apples

Best for: Math, logic, multi-step reasoning, complex analysis.

Self-Consistency

Generate multiple reasoning paths, take majority vote:

Solve this problem 3 different ways, then give your final answer based on
which approach gives the most consistent result.

Best for: High-stakes decisions, reducing hallucination.

ReAct (Reason + Act)

Interleave reasoning with tool use:

Question: What is the population of the capital of France?

Thought: I need to find the capital of France, then look up its population.
Action: search("capital of France")
Observation: Paris is the capital of France.
Thought: Now I need the population of Paris.
Action: search("population of Paris")
Observation: Paris has approximately 2.1 million people in the city proper.
Answer: The population of Paris, the capital of France, is about 2.1 million.

Best for: Tasks requiring external information, tool-using agents.

System Prompt Patterns

Role Definition

You are a senior software architect with 15 years of experience in distributed
systems. You prioritize scalability, maintainability, and cost-effectiveness.

Constraint Setting

Rules:
- Never suggest deprecated APIs
- Always consider security implications
- If unsure, say "I'm not certain" rather than guessing
- Keep responses under 500 words unless asked for detail

Output Format Specification

Respond in this exact JSON format:
{
  "summary": "one-line summary",
  "severity": "low|medium|high|critical",
  "suggestions": ["list", "of", "improvements"],
  "code_example": "if applicable"
}

Persona + Audience

You are explaining to a junior developer who knows Python but is new to
async programming. Use analogies and avoid jargon.

Anti-Patterns to Avoid

Anti-Pattern Problem Better Approach
Vague instructions "Make it better" "Improve readability by adding comments"
Conflicting rules "Be concise but thorough" Prioritize: "Be concise. Add detail only if asked"
Assuming knowledge "Use the standard format" Explicitly define the format
No error handling Model may hallucinate "If you don't know, say so"
Overloading 10 tasks in one prompt Break into focused prompts

Prompt Templates

Code Review

You are a thorough code reviewer. Review this code for:
1. Bugs and potential runtime errors
2. Security vulnerabilities
3. Performance issues
4. Readability and maintainability

For each issue found:
- Quote the problematic code
- Explain the problem
- Suggest a fix

Code to review:

Summarization

Summarize this document in 3 parts:
1. **TL;DR** (1 sentence)
2. **Key Points** (3-5 bullets)
3. **Action Items** (if any)

Preserve technical accuracy. If something is ambiguous, note it.

Document:

Data Extraction

Extract the following information from the text. Return JSON.
If a field is not found, use null.

{
  "person
Полный SKILL.md на GitHub

Установить Prompt Engineering Skill в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

metadata.json

FAQ

Что делает скилл Prompt Engineering Skill?

Craft effective prompts that get the best results from language models.

Как установить скилл Prompt Engineering Skill?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл Prompt Engineering Skill запускает скрипты?

Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.

Похожие скиллы

Сравнить Prompt Engineering Skill с