一键导入
blueprint-good-pattern
Capture good code as a reusable example (any subject — server code, schema, UI, scripts)
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Capture good code as a reusable example (any subject — server code, schema, UI, scripts)
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Capture decisions and context from the current conversation into blueprint docs, DESIGN.md, and design trees
Record a decision or cross-cutting design rule with rationale. Triages tech vs UX vs DESIGN.md rules vs requirements into the right document type and tree.
Explain Blueprint Mode plugin and available commands. Use when the user asks about Blueprint features, how to use skills, or needs guidance on the intent-capture workflow.
Opt-in. Add design intent capture to a Blueprint repo. Scaffolds design/ux-decisions/, offers to scaffold a minimal community-format DESIGN.md if absent, and can optionally surface a small number of candidate UX decisions found in existing UI/code for the user, developer, or designer to confirm.
Create Blueprint structure from existing repo. Run multiple times to refine.
Show overview of project's Blueprint structure plus important adjacent DESIGN.md context. Use when the user asks about documented decisions, project status, or wants to see what's been captured.
| name | blueprint:good-pattern |
| description | Capture good code as a reusable example (any subject — server code, schema, UI, scripts) |
| argument-hint | [file-path or description] |
| allowed-tools | ["Glob","Grep","Read","Write","Edit","EnterPlanMode","ExitPlanMode"] |
COMMAND: Extract code as a pattern others should follow. Patterns are tree-agnostic — file everything under patterns/good/ regardless of subject (server code, database model, UI, build scripts, etc.).
patterns/good/[name].[ext]| Input | Action |
|---|---|
/good-pattern src/repos/user.ts | Read file, capture as pattern |
/good-pattern error handling in api | Search for files, ask which one |
/good-pattern | Ask for file path |
Use template from _templates/TEMPLATES.md (<!-- SECTION: good-patterns -->).
The header comment lists the decisions that motivate the pattern — ADRs (../../docs/adrs/...) for tech/architecture rationale, UX decisions (../../design/ux-decisions/...) when the pattern reflects a UX choice. Either, both, or neither — only link what genuinely applies.
/**
* [Pattern Name]
*
* USE THIS PATTERN WHEN:
* - [Situation where this applies]
*
* KEY ELEMENTS:
* 1. [Important aspect]
*
* Related decisions:
* - [ADR-NNN](../../docs/adrs/NNN-name.md) - [Why this pattern]
* - [UX-NNN](../../design/ux-decisions/NNN-name.md) - [If applicable]
*
* Source: [original file path]
*/
// --- Example Implementation ---
// ADR-NNN: [Brief reference to the decision]
[extracted code]
Pattern captured at patterns/good/[name].[ext]
Create patterns/good/ if it doesn't exist.