skill存档

Credit-Killing Patterns Reference

37 patterns that waste tokens and cause re-prompts. Read this file when the user pastes a bad prompt and asks you to fix it, or when diagnosing why a prompt is underperforming.


Task Patterns

#PatternBad ExampleFixed
1Vague task verb”help me with my code""Refactor getUserData() to use async/await and handle null returns”
2Two tasks in one prompt”explain AND rewrite this function”Split into two prompts: explain first, rewrite second
3No success criteria”make it better""Done when the function passes existing unit tests and handles null input without throwing”
4Over-permissive agent”do whatever it takes”Explicit allowed actions list + explicit forbidden actions list
5Emotional task description”it’s totally broken, fix everything""Throws uncaught TypeError on line 43 when user is null”
6Build-the-whole-thing”build my entire app”Break into Prompt 1 (scaffold), Prompt 2 (core feature), Prompt 3 (polish)
7Implicit reference”now add the other thing we discussed”Always restate the full task — never reference “the thing we discussed”

Context Patterns

#PatternBad ExampleFixed
8Assumed prior knowledge”continue where we left off”Include Memory Block with all prior decisions
9No project context”write a cover letter""PM role at B2B fintech, 2yr SWE experience transitioning to product, shipped 3 features as tech lead”
10Forgotten stackNew prompt contradicts prior tech choiceAlways include Memory Block with established stack
11Hallucination invite”what do experts say about X?""Cite only sources you are certain of. If uncertain, say so explicitly rather than guessing.”
12Undefined audience”write something for users""Non-technical B2B buyers, no coding knowledge, decision-maker level”
13No mention of prior failures(blank)“I already tried X and it didn’t work because Y. Do not suggest X.”

Format Patterns

#PatternBad ExampleFixed
14Missing output format”explain this concept""3 bullet points, each under 20 words, with a one-sentence summary at top”
15Implicit length”write a summary""Write a summary in exactly 3 sentences”
16No role assignment(blank)“You are a senior backend engineer specializing in Node.js and PostgreSQL”
17Vague aesthetic adjectives”make it look professional""Monochrome palette, 16px base font, 24px line height, no decorative elements”
18No negative prompts for image AI”a portrait of a woman”Add: “no watermark, no blur, no extra fingers, no distortion, no text overlay”
19Prose prompt for MidjourneyFull descriptive sentence”subject, style, mood, lighting, composition, —ar 16:9 —v 6”

Scope Patterns

#PatternBad ExampleFixed
20No scope boundary”fix my app""Fix only the login form validation in src/auth.js. Touch nothing else.”
21No stack constraints”build a React component""React 18, TypeScript strict, no external libraries, Tailwind only”
22No stop condition for agents”build the whole feature”Explicit stop conditions + ✅ checkpoint output after each step
23No file path for IDE AI”update the login function""Update handleLogin() in src/pages/Login.tsx only”
24Wrong template for toolGPT-style prose prompt used in CursorAdapt to File-Scope Template (Template G)
25Pasting entire codebaseFull repo context every promptScope to only the relevant function and file

Reasoning Patterns

#PatternBad ExampleFixed
26No CoT for logic task”which approach is better?""Think through both approaches step by step before recommending”
27Adding CoT to reasoning models”think step by step” sent to o1/o3Remove it — reasoning models think internally, CoT instructions degrade output
28Expecting inter-session memory”you already know my project”Always re-provide the Memory Block in every new session
29Contradicting prior workNew prompt ignores earlier architectureInclude Memory Block with all established decisions
30No grounding rule for factual tasks”summarize what experts say about X""Use only information you are highly confident is accurate. Say [uncertain] if not.”

Agentic Patterns

#PatternBad ExampleFixed
31No starting state”build me a REST API""Empty Node.js project, Express installed, src/app.js exists”
32No target state”add authentication""/src/middleware/auth.js with JWT verify. POST /login and POST /register in /src/routes/auth.js
33Silent agentNo progress output”After each step output: ✅ [what was completed]“
34Unlocked filesystemNo file restrictions”Only edit files inside src/. Do not touch package.json, .env, or any config file.”
35No human review triggerAgent decides everything autonomously”Stop and ask before: deleting any file, adding any dependency, or changing the database schema”
36Vague first turn on Opus 4.7”fix the auth bug” with no scope, no files, no criteriaOpus 4.7 reads prompts literally — it no longer fills implicit context like 4.6 did. Use Template M. Front-load intent, file scope, constraints, and acceptance criteria.
37Context rot on long sessionsKeeps correcting in the same session for 60+ turnsNew task = new session. Use /rewind instead of correcting. /compact at ~50% context. Subagents for file-heavy investigation.