skills/prompt-generator-v2/SKILL.md
Tạo prompt KERNEL từ yêu cầu mơ hồ thành chỉ dẫn cấu trúc, dễ kiểm chứng.
npx skillsauth add hoangvantuan/claude-plugin prompt-generator-v2Install this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Generate prompts that work on the first try. The KERNEL framework ensures every prompt has a clear goal, verifiable success criteria, and explicit constraints.
Each letter is a checkpoint. Chi tiết + ví dụ before/after → kernel-framework.
| Principle | Check | Action if failing | |---|---|---| | Keep simple | Describe in one sentence? | Split into prompt chain | | Easy to verify | Stranger could verify? | Add measurable criteria | | Reproducible | Works in 30 days? | Remove temporal refs, add versions | | Narrow scope | One deliverable? | Extract goals into separate prompts | | Explicit constraints | 2-3 "do NOT" rules? | Add negative constraints | | Logical structure | Context→Task→Constraints→Format? | Restructure |
| User input | Mode | Action | |---|---|---| | Vague request ("help me write a prompt for X") | Create | Go to Step 1 | | Existing prompt provided | Improve | Run KERNEL checklist against the prompt, diagnose which principles fail, fix targeted. Skip to Step 2 |
Extract or ask (max 3 questions — skip if the request already answers them):
If the user provides a vague request, propose a draft immediately and iterate — action beats interrogation.
Transform intent into a structured prompt. Run each principle as a mental checklist using the table above. For detailed explanations, consult kernel-framework.
Use this structure. Include only relevant sections — omit what doesn't apply:
## Context
[Background information the AI needs. Keep minimal — only what's necessary to understand the task. Include domain, audience, and relevant technical context.]
## Task
[One clear, specific goal. Start with an action verb. This is the single sentence that passes the K-test.]
## Constraints
- [What to do — specific, measurable behaviors]
- Do NOT [negative constraint 1]
- Do NOT [negative constraint 2]
- [Additional bounds: length, format, libraries, scope limits]
## Output Format
[Exact structure of the expected output. Include: format (markdown, JSON, code), length bounds, sections/headers if applicable, delimiters.]
## Verification
[How to check success — specific criteria that make the E-principle concrete. Think: "I'll know this worked when..."]
Optional sections (include when they add value):
Before delivering, run this self-review:
Present the prompt in a clean code block. If the original request was complex and got split:
Always offer: "Want me to adjust the constraints, add examples, or split this differently?"
When a task is too complex for one prompt (fails N-principle), decompose into a chain. Each link:
Pattern: Task → subtask analysis → ordered chain with data flow
Example: "Build a REST API" →
Các lỗi phổ biến cần nhận diện và tránh khi generate prompt:
| Failure mode | Dấu hiệu | Sửa | |---|---|---| | Prompt quá chung | Không constraint, output có thể là bất kỳ thứ gì | Thêm scope, format, length bounds | | Over-engineering | Prompt dài hơn output mong đợi, quá nhiều rules | Cắt constraints không ảnh hưởng output quality | | Constraint mâu thuẫn | "Be concise" + "Cover everything thoroughly" | Chọn 1, bỏ kia, hoặc chia scope | | Vague virtue stacking | "Good", "helpful", "engaging", "detailed" liên tiếp | Thay bằng criteria cụ thể, đo được | | Temporal drift | "Current", "latest", "recent" không pin version | Pin version/date cụ thể | | Missing audience | Prompt không nói cho ai → tone/depth không phù hợp | Thêm audience + expertise level | | Format ambiguity | Không nói rõ output format → AI tự chọn | Thêm Output Format section tường minh |
tools
Viết/rà soát/tách user story, acceptance criteria, INVEST, epic, backlog từ requirement/PRD/bug/feature.
tools
Phân tích quyết định/vấn đề bằng Thu Giang Nguyễn Duy Cần: Thuật Tư Tưởng, Dịch Lý, Lão Trang, quân bình.
tools
Phân tích tình huống bằng Kinh Dịch: 64 quẻ, Âm Dương, Ngũ Hành, thời, biến, quân tử.
research
Tạo proposal/đề án có research, business case, technical solution. Trigger: RFP, bid, draft proposal, đề xuất dự án.