AgentSkillsCN

prompt

当您被要求撰写或优化 AI 提示、指令或系统消息时,可使用此技能。

SKILL.md
--- frontmatter
name: prompt
description: Use when asked about writing or improving AI prompts, instructions, or system messages.
user-invocable: false

Prompt Writing

MANDATORY: Write prompts clear, specific, token-efficient from the start

Core Principles

NEVER write:

  • Filler: very, really, just, simply, basically, actually, essentially
  • Redundant phrases: "in order to" (use "to"), "due to the fact that" (use "because"), "at this point in time" (use "now")
  • Politeness: "please", "thank you", "if you don't mind"
  • Hedging: "might", "could", "possibly" (unless uncertainty critical)
  • Motivational text: "this will help", "to ensure quality"
  • Meta-commentary: "it's important to note", "keep in mind"
  • Obvious explanations: "this is because", "the reason is"
  • Verbose preambles: "for example", "that is", "and so on"
  • Obvious connectors: "This means that", "It is important that"
  • Stylistic formatting: bold, italic (unless critical)
  • Emojis, decorative chars
  • Periods at bullet ends
  • Brittle if-else logic (hardcoded edge cases)
  • Vague assumptions (assuming shared context)
  • Instructions that don't change behavior

ALWAYS write:

  • Terse imperatives: "Always" not "You should always"
  • Bullets not paragraphs (group by logical category)
  • Concise conditionals: "When" not "In cases where"
  • One representative example not multiple
  • Short phrases over long
  • Active voice: "Check syntax" not "Syntax should be checked"
  • Arrows for mappings: "X → Y" not "If X then Y"
  • Simple words: "use" not "utilize"
  • Exact technical terms, commands, paths, numbers, limits
  • Specific context (no vague assumptions)
  • Clear heuristics not brittle if-else
  • Distinctions preserved: "must" vs "should", "always" vs "prefer"
  • Natural spacing (NEVER symbols for words: no "&", "w/", "b/c")

Structure

Opening:

  • Role/context when needed: "You are X"
  • State objective in first sentence
  • Imperative mood: "Analyze", "Generate", "Explain"

Body:

  • Headers (##) for major sections
  • Bullets when unordered, numbers when sequential
  • One instruction per bullet
  • Most critical rules first
  • Code blocks for examples, syntax, templates

Required Elements

Always specify:

  • Output format: JSON, markdown, code, plain text
  • Constraints: length, style, technical requirements
  • Edge cases: empty input, invalid input, edge conditions
  • Examples: input/output when complex

Anti-patterns

  • Vague objectives: "help me with X"
  • Missing constraints: "summarize" without length/format
  • No output format specified
  • Long paragraphs instead of bullets
  • Implicit assumptions about context
  • Ambiguous language allowing multiple interpretations
  • Over-engineering edge cases that can't happen