Fix Prompts
检测未遵循”集中契约”模式的 prompt 文件,将其规范化为指向 prompts/
Project Prompt Architecture Convention
This workspace uses a “centralized contract, distributed references” pattern for prompts:
prompts/<name>.mdis the SINGLE SOURCE OF TRUTH — contains the full prompt body (instructions, constraints, output format)..continue/prompts/<name>.prompt.md— thin reference layer with Continue frontmatter; body is@prompts/<name>.md..claude/commands/<name>.md— thin reference layer with Claude Code frontmatter; body is@prompts/<name>.md..github/prompts/<name>.prompt.md— thin reference layer for Copilot; body is@prompts/<name>.md.
No reference file should contain substantive prompt content. Each should have only frontmatter + a single @prompts/<name>.md reference line.
When invoked
- Scan the workspace for all prompt-related files:
prompts/*.md— check if these are actual contracts (full bodies) or thin references (just frontmatter +@...)..continue/prompts/*.prompt.md— check body content..claude/commands/*.md— check body content..github/prompts/*.prompt.md— check body content.- Any other platform-specific prompt/command files the user mentions.
- For each file found, classify it:
- Contract: contains substantive prompt instructions/constraints (should live in
prompts/<name>.md). - Reference: contains only frontmatter +
@prompts/<name>.mdline (correct pattern). - Duplicate: contains substantive content that belongs in a contract (needs normalization).
- Contract: contains substantive prompt instructions/constraints (should live in
- For files that are duplicates or misplaced contracts:
- Extract the substantive prompt body and place it into
prompts/<name>.md(create if new, merge if existing contract has partial content). - Rewrite the original file to be a thin reference: keep platform-specific frontmatter, replace body with
@prompts/<name>.md. - If multiple files under one platform share the same prompt intent, consolidate into a single
prompts/<name>.mdand keep only the necessary platform references.
- Extract the substantive prompt body and place it into
-
For files already following the pattern (thin references), mark them as conforming — no action needed.
- Report:
- Which files were normalized (old → new reference form).
- Which contracts were created or updated in
prompts/. - Which files already conformed.
- Any ambiguous cases where you couldn’t safely determine if content was a contract or a duplicate — flag these for the user.
<add any extra context here, leave blank to ignore>