self-evolve-framework 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (121) hide show
  1. package/package.json +1 -1
  2. package/template/rules/CodeGraph.mdc +0 -23
  3. package/template/rules/Svelte_5.mdc +0 -167
  4. package/template/rules/Svelte_Flow.mdc +0 -176
  5. package/template/rules/Tailwind_CSS_v4.mdc +0 -187
  6. package/template/rules/Tauri.mdc +0 -145
  7. package/template/rules/app-error-pattern.mdc +0 -65
  8. package/template/rules/invoke-safe-pattern.mdc +0 -53
  9. package/template/rules/js.mdc +0 -10
  10. package/template/rules/powershell.mdc +0 -9
  11. package/template/rules//346/227/245/345/277/227.mdc +0 -15
  12. package/template/rules//350/257/267/346/261/202.mdc +0 -49
  13. package/template/skills/caveman/SKILL.md +0 -49
  14. package/template/skills/check/SKILL.md +0 -393
  15. package/template/skills/check/agents/reviewer-architecture.md +0 -39
  16. package/template/skills/check/agents/reviewer-security.md +0 -39
  17. package/template/skills/check/references/persona-catalog.md +0 -56
  18. package/template/skills/check/references/project-context.md +0 -120
  19. package/template/skills/check/references/public-reply.md +0 -14
  20. package/template/skills/check/scripts/audit_signals.py +0 -666
  21. package/template/skills/check/scripts/run-tests.sh +0 -19
  22. package/template/skills/design/SKILL.md +0 -173
  23. package/template/skills/design/references/design-aesthetic-quality.md +0 -67
  24. package/template/skills/design/references/design-data-viz.md +0 -34
  25. package/template/skills/design/references/design-reference.md +0 -295
  26. package/template/skills/design/references/design-tokens.md +0 -45
  27. package/template/skills/design/references/design-traps.md +0 -43
  28. package/template/skills/design-an-interface/SKILL.md +0 -94
  29. package/template/skills/diagnose/SKILL.md +0 -117
  30. package/template/skills/diagnose/scripts/hitl-loop.template.sh +0 -41
  31. package/template/skills/edit-article/SKILL.md +0 -14
  32. package/template/skills/git-guardrails-claude-code/SKILL.md +0 -95
  33. package/template/skills/git-guardrails-claude-code/scripts/block-dangerous-git.sh +0 -25
  34. package/template/skills/grill-me/SKILL.md +0 -10
  35. package/template/skills/grill-with-docs/ADR-FORMAT.md +0 -47
  36. package/template/skills/grill-with-docs/CONTEXT-FORMAT.md +0 -60
  37. package/template/skills/grill-with-docs/SKILL.md +0 -88
  38. package/template/skills/handoff/SKILL.md +0 -15
  39. package/template/skills/health/SKILL.md +0 -260
  40. package/template/skills/health/agents/inspector-context.md +0 -119
  41. package/template/skills/health/agents/inspector-control.md +0 -84
  42. package/template/skills/health/agents/inspector-maintainability.md +0 -55
  43. package/template/skills/health/scripts/check-agent-context.sh +0 -5
  44. package/template/skills/health/scripts/check-doc-refs.sh +0 -8
  45. package/template/skills/health/scripts/check-maintainability.sh +0 -8
  46. package/template/skills/health/scripts/check-verifier-output.sh +0 -5
  47. package/template/skills/health/scripts/check_agent_context.py +0 -444
  48. package/template/skills/health/scripts/check_doc_refs.py +0 -110
  49. package/template/skills/health/scripts/check_maintainability.py +0 -635
  50. package/template/skills/health/scripts/check_verifier_output.py +0 -116
  51. package/template/skills/health/scripts/collect-data.sh +0 -751
  52. package/template/skills/hunt/SKILL.md +0 -232
  53. package/template/skills/hunt/references/failure-patterns.md +0 -138
  54. package/template/skills/hunt/references/ime-unicode.md +0 -58
  55. package/template/skills/hunt/references/logging-techniques.md +0 -72
  56. package/template/skills/hunt/references/rendering-debug.md +0 -34
  57. package/template/skills/improve-codebase-architecture/DEEPENING.md +0 -37
  58. package/template/skills/improve-codebase-architecture/HTML-REPORT.md +0 -123
  59. package/template/skills/improve-codebase-architecture/INTERFACE-DESIGN.md +0 -44
  60. package/template/skills/improve-codebase-architecture/LANGUAGE.md +0 -53
  61. package/template/skills/improve-codebase-architecture/SKILL.md +0 -81
  62. package/template/skills/learn/SKILL.md +0 -140
  63. package/template/skills/migrate-to-shoehorn/SKILL.md +0 -118
  64. package/template/skills/obsidian-vault/SKILL.md +0 -59
  65. package/template/skills/prototype/LOGIC.md +0 -79
  66. package/template/skills/prototype/SKILL.md +0 -30
  67. package/template/skills/prototype/UI.md +0 -112
  68. package/template/skills/qa/SKILL.md +0 -130
  69. package/template/skills/read/SKILL.md +0 -141
  70. package/template/skills/read/references/read-methods.md +0 -129
  71. package/template/skills/read/scripts/fetch.sh +0 -106
  72. package/template/skills/read/scripts/fetch_feishu.py +0 -251
  73. package/template/skills/read/scripts/fetch_local.py +0 -218
  74. package/template/skills/read/scripts/fetch_weixin.py +0 -107
  75. package/template/skills/request-refactor-plan/SKILL.md +0 -68
  76. package/template/skills/review/SKILL.md +0 -78
  77. package/template/skills/rust-auto-fix/SKILL.md +0 -94
  78. package/template/skills/scaffold-exercises/SKILL.md +0 -106
  79. package/template/skills/sdd-dev/SKILL.md +0 -114
  80. package/template/skills/setup-matt-pocock-skills/SKILL.md +0 -121
  81. package/template/skills/setup-matt-pocock-skills/domain.md +0 -51
  82. package/template/skills/setup-matt-pocock-skills/issue-tracker-github.md +0 -22
  83. package/template/skills/setup-matt-pocock-skills/issue-tracker-gitlab.md +0 -23
  84. package/template/skills/setup-matt-pocock-skills/issue-tracker-local.md +0 -19
  85. package/template/skills/setup-matt-pocock-skills/triage-labels.md +0 -15
  86. package/template/skills/setup-pre-commit/SKILL.md +0 -91
  87. package/template/skills/svelte-warnings-fix/SKILL.md +0 -94
  88. package/template/skills/tauri-nsis-installer-icon/SKILL.md +0 -92
  89. package/template/skills/tauri-nsis-installer-icon/references/tauri-nsis-schema.md +0 -71
  90. package/template/skills/tb/SKILL.md +0 -62
  91. package/template/skills/tdd/SKILL.md +0 -109
  92. package/template/skills/tdd/deep-modules.md +0 -33
  93. package/template/skills/tdd/interface-design.md +0 -31
  94. package/template/skills/tdd/mocking.md +0 -59
  95. package/template/skills/tdd/refactoring.md +0 -10
  96. package/template/skills/tdd/tests.md +0 -61
  97. package/template/skills/teach/GLOSSARY-FORMAT.md +0 -35
  98. package/template/skills/teach/LEARNING-RECORD-FORMAT.md +0 -46
  99. package/template/skills/teach/MISSION-FORMAT.md +0 -31
  100. package/template/skills/teach/RESOURCES-FORMAT.md +0 -32
  101. package/template/skills/teach/SKILL.md +0 -91
  102. package/template/skills/think/SKILL.md +0 -184
  103. package/template/skills/to-issues/SKILL.md +0 -83
  104. package/template/skills/to-prd/SKILL.md +0 -74
  105. package/template/skills/triage/AGENT-BRIEF.md +0 -168
  106. package/template/skills/triage/OUT-OF-SCOPE.md +0 -101
  107. package/template/skills/triage/SKILL.md +0 -103
  108. package/template/skills/ubiquitous-language/SKILL.md +0 -93
  109. package/template/skills/ver/SKILL.md +0 -62
  110. package/template/skills/write/SKILL.md +0 -209
  111. package/template/skills/write/references/write-en.md +0 -199
  112. package/template/skills/write/references/write-product-localization.md +0 -43
  113. package/template/skills/write/references/write-zh-bilingual.md +0 -59
  114. package/template/skills/write/references/write-zh-prose.md +0 -50
  115. package/template/skills/write/references/write-zh-release-notes.md +0 -40
  116. package/template/skills/write/references/write-zh.md +0 -721
  117. package/template/skills/write-a-skill/SKILL.md +0 -117
  118. package/template/skills/writing-beats/SKILL.md +0 -52
  119. package/template/skills/writing-fragments/SKILL.md +0 -75
  120. package/template/skills/writing-shape/SKILL.md +0 -64
  121. package/template/skills/zoom-out/SKILL.md +0 -7
@@ -1,68 +0,0 @@
1
- ---
2
- name: request-refactor-plan
3
- description: Create a detailed refactor plan with tiny commits via user interview, then file it as a GitHub issue. Use when user wants to plan a refactor, create a refactoring RFC, or break a refactor into safe incremental steps.
4
- ---
5
-
6
- This skill will be invoked when the user wants to create a refactor request. You should go through the steps below. You may skip steps if you don't consider them necessary.
7
-
8
- 1. Ask the user for a long, detailed description of the problem they want to solve and any potential ideas for solutions.
9
-
10
- 2. Explore the repo to verify their assertions and understand the current state of the codebase.
11
-
12
- 3. Ask whether they have considered other options, and present other options to them.
13
-
14
- 4. Interview the user about the implementation. Be extremely detailed and thorough.
15
-
16
- 5. Hammer out the exact scope of the implementation. Work out what you plan to change and what you plan not to change.
17
-
18
- 6. Look in the codebase to check for test coverage of this area of the codebase. If there is insufficient test coverage, ask the user what their plans for testing are.
19
-
20
- 7. Break the implementation into a plan of tiny commits. Remember Martin Fowler's advice to "make each refactoring step as small as possible, so that you can always see the program working."
21
-
22
- 8. Create a GitHub issue with the refactor plan. Use the following template for the issue description:
23
-
24
- <refactor-plan-template>
25
-
26
- ## Problem Statement
27
-
28
- The problem that the developer is facing, from the developer's perspective.
29
-
30
- ## Solution
31
-
32
- The solution to the problem, from the developer's perspective.
33
-
34
- ## Commits
35
-
36
- A LONG, detailed implementation plan. Write the plan in plain English, breaking down the implementation into the tiniest commits possible. Each commit should leave the codebase in a working state.
37
-
38
- ## Decision Document
39
-
40
- A list of implementation decisions that were made. This can include:
41
-
42
- - The modules that will be built/modified
43
- - The interfaces of those modules that will be modified
44
- - Technical clarifications from the developer
45
- - Architectural decisions
46
- - Schema changes
47
- - API contracts
48
- - Specific interactions
49
-
50
- Do NOT include specific file paths or code snippets. They may end up being outdated very quickly.
51
-
52
- ## Testing Decisions
53
-
54
- A list of testing decisions that were made. Include:
55
-
56
- - A description of what makes a good test (only test external behavior, not implementation details)
57
- - Which modules will be tested
58
- - Prior art for the tests (i.e. similar types of tests in the codebase)
59
-
60
- ## Out of Scope
61
-
62
- A description of the things that are out of scope for this refactor.
63
-
64
- ## Further Notes (optional)
65
-
66
- Any further notes about the refactor.
67
-
68
- </refactor-plan-template>
@@ -1,78 +0,0 @@
1
- ---
2
- name: review
3
- description: Review the changes since a fixed point (commit, branch, tag, or merge-base) along two axes — Standards (does the code follow this repo's documented coding standards?) and Spec (does the code match what the originating issue/PRD asked for?). Runs both reviews in parallel sub-agents and reports them side by side. Use when the user wants to review a branch, a PR, work-in-progress changes, or asks to "review since X".
4
- ---
5
-
6
- # Review
7
-
8
- Two-axis review of the diff between `HEAD` and a fixed point the user supplies:
9
-
10
- - **Standards** — does the code conform to this repo's documented coding standards?
11
- - **Spec** — does the code faithfully implement the originating issue / PRD / spec?
12
-
13
- Both axes run as **parallel sub-agents** so they don't pollute each other's context, then this skill aggregates their findings.
14
-
15
- The issue tracker should have been provided to you — run `/setup-matt-pocock-skills` if `docs/agents/issue-tracker.md` is missing.
16
-
17
- ## Process
18
-
19
- ### 1. Pin the fixed point
20
-
21
- Whatever the user said is the fixed point — a commit SHA, branch name, tag, `main`, `HEAD~5`, etc. Don't be opinionated; pass it through. If they didn't specify one, ask: "Review against what — a branch, a commit, or `main`?" Don't proceed until you have it.
22
-
23
- Capture the diff command once: `git diff <fixed-point>...HEAD` (three-dot, so the comparison is against the merge-base). Also note the list of commits via `git log <fixed-point>..HEAD --oneline`.
24
-
25
- ### 2. Identify the spec source
26
-
27
- Look for the originating spec, in this order:
28
-
29
- 1. Issue references in the commit messages (`#123`, `Closes #45`, GitLab `!67`, etc.) — fetch via the workflow in `docs/agents/issue-tracker.md`.
30
- 2. A path the user passed as an argument.
31
- 3. A PRD/spec file under `docs/`, `specs/`, or `.scratch/` matching the branch name or feature.
32
- 4. If nothing is found, ask the user where the spec is. If they say there isn't one, the **Spec** sub-agent will skip and report "no spec available".
33
-
34
- ### 3. Identify the standards sources
35
-
36
- Anything in the repo that documents how code should be written. Common locations:
37
-
38
- - `CLAUDE.md`, `AGENTS.md`
39
- - `CONTRIBUTING.md`
40
- - `CONTEXT.md`, `CONTEXT-MAP.md`, per-context `CONTEXT.md` files
41
- - `docs/adr/` (architectural decisions are standards)
42
- - `.editorconfig`, `eslint.config.*`, `biome.json`, `prettier.config.*`, `tsconfig.json` (machine-enforced standards — note them but don't re-check what tooling already checks)
43
- - Any `STYLE.md`, `STANDARDS.md`, `STYLEGUIDE.md`, or similar at the repo root or under `docs/`
44
-
45
- Collect the list of files. The **Standards** sub-agent will read them.
46
-
47
- ### 4. Spawn both sub-agents in parallel
48
-
49
- Send a single message with two `Agent` tool calls. Use the `general-purpose` subagent for both.
50
-
51
- **Standards sub-agent prompt** — include:
52
-
53
- - The full diff command and commit list.
54
- - The list of standards-source files you found in step 3.
55
- - The brief: "Read the standards docs. Then read the diff. Report — per file/hunk where relevant — every place the diff violates a documented standard. Cite the standard (file + the rule). Distinguish hard violations from judgement calls. Skip anything tooling enforces. Under 400 words."
56
-
57
- **Spec sub-agent prompt** — include:
58
-
59
- - The diff command and commit list.
60
- - The path or fetched contents of the spec.
61
- - The brief: "Read the spec. Then read the diff. Report: (a) requirements the spec asked for that are missing or partial; (b) behaviour in the diff that wasn't asked for (scope creep); (c) requirements that look implemented but where the implementation looks wrong. Quote the spec line for each finding. Under 400 words."
62
-
63
- If the spec is missing, skip the Spec sub-agent and note this in the final report.
64
-
65
- ### 5. Aggregate
66
-
67
- Present the two reports under `## Standards` and `## Spec` headings, verbatim or lightly cleaned. Do **not** merge or rerank findings — the two axes are deliberately separate so the user can see them independently.
68
-
69
- End with a one-line summary: total findings per axis, and the worst single issue (if any) flagged.
70
-
71
- ## Why two axes
72
-
73
- A change can pass one axis and fail the other:
74
-
75
- - Code that follows every standard but implements the wrong thing → **Standards pass, Spec fail.**
76
- - Code that does exactly what the issue asked but breaks the project's conventions → **Spec pass, Standards fail.**
77
-
78
- Reporting them separately stops one axis from masking the other.
@@ -1,94 +0,0 @@
1
- ---
2
- name: fix:rust-auto
3
- description: Read Rust plugin (rust-analyzer) diagnostics from the IDE and automatically fix detected issues. Use when the user mentions Rust errors, type mismatches, cargo check failures, compiler warnings, rust-analyzer problems, or asks to fix Rust compilation issues in the src-tauri directory.
4
- ---
5
-
6
- # Rust Auto-Fix
7
-
8
- ## Diagnostics collection (dual channel)
9
-
10
- 1. **Fast path** — `read_lints(paths="d:/code/sheetflow/src-tauri")` 读 IDE 实时诊断
11
- 2. **Confirmation** — `cd d:/code/sheetflow/src-tauri && cargo check 2>&1` 获取编译器真实输出
12
-
13
- ## Categorize
14
-
15
- 按严重程度分组:
16
-
17
- - **Config/Macro errors** — `proc macro panicked`(非代码问题)
18
- - **Code errors** — type mismatches, borrow checker, missing items
19
- - **Warnings** — unused imports, unnecessary `mut`, dead code
20
- - **Hints** — cargo fix suggestions
21
-
22
- ## Fix workflow
23
-
24
- ### Phase A: Auto-fix warnings with `cargo fix`
25
-
26
- 先跑 `cargo fix` 自动处理可修复的 warning,大幅减少手动工作:
27
-
28
- ```
29
- cd d:/code/sheetflow/src-tauri && cargo fix --lib -p sheetflow --allow-dirty 2>&1
30
- ```
31
-
32
- 完成后 re-check 确认剩余警告。
33
-
34
- ### Phase B: Handle config/macro errors
35
-
36
- `proc macro panicked` 通常是外部原因,不是 Rust 代码问题:
37
-
38
- | 错误信息 | 非代码原因 | 处理方式 |
39
- |----------|-----------|---------|
40
- | `frontendDist` 路径不存在 | 前端未构建 | `npm run build` 创建 `build/` |
41
- | `identifier` 格式错误 | `tauri.conf.json` 配置 | 手动检查配置文件 |
42
- | 其他 macro panic | 依赖版本或配置 | 优先检查外部因素再怀疑代码 |
43
-
44
- 当确认是前端构建问题时,可以调用 `svelte-warnings-fix` 协作修复。
45
-
46
- ### Phase C: Fix code errors (one category at a time)
47
-
48
- 按优先级批量处理同类错误,同类修复完再 rescan:
49
-
50
- 1. **Type mismatches** — `expected X, found Y`
51
- 2. **Borrow checker** — `cannot borrow`, `cannot move`
52
- 3. **Missing items** — `not found`, `unresolved import`
53
- 4. **Other errors**
54
-
55
- 修复模式:
56
- 1. `read_file` 定位错误行
57
- 2. 理解上下文
58
- 3. `replace_in_file` 最小改动
59
- 4. 同类全部修完后 → `cargo check` 全量验证
60
-
61
- ### Phase D: Handle remaining warnings
62
-
63
- 对 `dead_code` 警告,按规则决定处理方式:
64
-
65
- | 场景 | 做法 |
66
- |------|------|
67
- | `pub struct` 公开 API 的字段 | `#[allow(dead_code)]` 保留 |
68
- | `pub struct` 公开 API 的整个 struct | `#[allow(dead_code)]` 保留 |
69
- | 私有 struct/函数,确定未用 | 删除代码 |
70
- | `pub fn` Tauri 命令参数(如 `_cache`) | 保留或用 `_` 前缀命名 |
71
- | `cache.rs` 整模块未用 | 加 `#![allow(dead_code)]` 模块级注解 |
72
-
73
- ### Phase E: Final verification
74
-
75
- ```
76
- cargo check 2>&1
77
- ```
78
-
79
- 确认零错误零警告后输出最终报告。
80
-
81
- ## Final report
82
-
83
- ```
84
- ## Rust diagnostics resolved
85
-
86
- [cargo-fix] cargo fix 自动处理: X 项
87
- [manual] 手动修复类型错误: Y 项
88
- [allow] 添加 #[allow(dead_code)]: Z 处
89
-
90
- Changes:
91
- - file.rs: cargo fix 自动处理
92
- - file.rs: 手动修复 mismatched types
93
- - file.rs: 添加 #[allow(dead_code)]
94
- ```
@@ -1,106 +0,0 @@
1
- ---
2
- name: scaffold-exercises
3
- description: Create exercise directory structures with sections, problems, solutions, and explainers that pass linting. Use when user wants to scaffold exercises, create exercise stubs, or set up a new course section.
4
- ---
5
-
6
- # Scaffold Exercises
7
-
8
- Create exercise directory structures that pass `pnpm ai-hero-cli internal lint`, then commit with `git commit`.
9
-
10
- ## Directory naming
11
-
12
- - **Sections**: `XX-section-name/` inside `exercises/` (e.g., `01-retrieval-skill-building`)
13
- - **Exercises**: `XX.YY-exercise-name/` inside a section (e.g., `01.03-retrieval-with-bm25`)
14
- - Section number = `XX`, exercise number = `XX.YY`
15
- - Names are dash-case (lowercase, hyphens)
16
-
17
- ## Exercise variants
18
-
19
- Each exercise needs at least one of these subfolders:
20
-
21
- - `problem/` - student workspace with TODOs
22
- - `solution/` - reference implementation
23
- - `explainer/` - conceptual material, no TODOs
24
-
25
- When stubbing, default to `explainer/` unless the plan specifies otherwise.
26
-
27
- ## Required files
28
-
29
- Each subfolder (`problem/`, `solution/`, `explainer/`) needs a `readme.md` that:
30
-
31
- - Is **not empty** (must have real content, even a single title line works)
32
- - Has no broken links
33
-
34
- When stubbing, create a minimal readme with a title and a description:
35
-
36
- ```md
37
- # Exercise Title
38
-
39
- Description here
40
- ```
41
-
42
- If the subfolder has code, it also needs a `main.ts` (>1 line). But for stubs, a readme-only exercise is fine.
43
-
44
- ## Workflow
45
-
46
- 1. **Parse the plan** - extract section names, exercise names, and variant types
47
- 2. **Create directories** - `mkdir -p` for each path
48
- 3. **Create stub readmes** - one `readme.md` per variant folder with a title
49
- 4. **Run lint** - `pnpm ai-hero-cli internal lint` to validate
50
- 5. **Fix any errors** - iterate until lint passes
51
-
52
- ## Lint rules summary
53
-
54
- The linter (`pnpm ai-hero-cli internal lint`) checks:
55
-
56
- - Each exercise has subfolders (`problem/`, `solution/`, `explainer/`)
57
- - At least one of `problem/`, `explainer/`, or `explainer.1/` exists
58
- - `readme.md` exists and is non-empty in the primary subfolder
59
- - No `.gitkeep` files
60
- - No `speaker-notes.md` files
61
- - No broken links in readmes
62
- - No `pnpm run exercise` commands in readmes
63
- - `main.ts` required per subfolder unless it's readme-only
64
-
65
- ## Moving/renaming exercises
66
-
67
- When renumbering or moving exercises:
68
-
69
- 1. Use `git mv` (not `mv`) to rename directories - preserves git history
70
- 2. Update the numeric prefix to maintain order
71
- 3. Re-run lint after moves
72
-
73
- Example:
74
-
75
- ```bash
76
- git mv exercises/01-retrieval/01.03-embeddings exercises/01-retrieval/01.04-embeddings
77
- ```
78
-
79
- ## Example: stubbing from a plan
80
-
81
- Given a plan like:
82
-
83
- ```
84
- Section 05: Memory Skill Building
85
- - 05.01 Introduction to Memory
86
- - 05.02 Short-term Memory (explainer + problem + solution)
87
- - 05.03 Long-term Memory
88
- ```
89
-
90
- Create:
91
-
92
- ```bash
93
- mkdir -p exercises/05-memory-skill-building/05.01-introduction-to-memory/explainer
94
- mkdir -p exercises/05-memory-skill-building/05.02-short-term-memory/{explainer,problem,solution}
95
- mkdir -p exercises/05-memory-skill-building/05.03-long-term-memory/explainer
96
- ```
97
-
98
- Then create readme stubs:
99
-
100
- ```
101
- exercises/05-memory-skill-building/05.01-introduction-to-memory/explainer/readme.md -> "# Introduction to Memory"
102
- exercises/05-memory-skill-building/05.02-short-term-memory/explainer/readme.md -> "# Short-term Memory"
103
- exercises/05-memory-skill-building/05.02-short-term-memory/problem/readme.md -> "# Short-term Memory"
104
- exercises/05-memory-skill-building/05.02-short-term-memory/solution/readme.md -> "# Short-term Memory"
105
- exercises/05-memory-skill-building/05.03-long-term-memory/explainer/readme.md -> "# Long-term Memory"
106
- ```
@@ -1,114 +0,0 @@
1
- ---
2
- name: sdd-dev
3
- description: |
4
- Spec-Driven Development — generate code from PRD/idea via a structured DESIGN.md spec.
5
- Use when the user asks to "generate frontend code", "design a page", "create a component",
6
- "按照规范生成", or any feature request that needs both spec and implementation.
7
- ---
8
-
9
- # Spec-Driven Development (SDD)
10
-
11
- 流程:需求 → 规范(DESIGN.md)→ 审批 → 代码生成 → 自检
12
-
13
- ## Phase A: 理解输入
14
-
15
- 收集设计线索。输入可以是以下任意组合:
16
-
17
- 1. **PRD / 需求描述** — 功能列表、用户故事
18
- 2. **参考 URL** — 可访问的线上页面
19
- 3. **截图/设计稿** — 描述你看到的布局和风格
20
- 4. **品牌名称 / 关键词** — 如"工务平台"、"数据分析"
21
- 5. **已有组件库** — 如 ant-design-vue
22
-
23
- 如果输入稀疏,使用以下项目已有设计线索作为 fallback:
24
- - `:root` CSS 变量(App.vue):颜色、字体、圆角、间距
25
- - `RULES.md`:设计约束(统一风格、响应式强制、多页面一致性)
26
- - 现有页面样式作为参考
27
-
28
- **在此阶段不要生成任何代码。**
29
-
30
- ## Phase B: 输出 DESIGN.md
31
-
32
- 产出一份完整的设计规范文档,存放在 `docs/design/` 目录下,包含以下 **9 个章节**:
33
-
34
- ### 1. 色彩(Color)
35
- - 主色调、辅助色、语义色(成功/错误/警告)
36
- - 引用 `:root` 已有的 `--primary-color` / `--success-color` 等变量
37
- - 禁止引入全新的颜色体系,除非确实必要
38
-
39
- ### 2. 字体(Type)
40
- - 使用 `var(--font-sans)` 和 `var(--font-mono)`
41
- - 字号层级:`--font-size-xs/sm/base/lg/xl`
42
- - 行高、字重
43
-
44
- ### 3. 组件(Component)
45
- - 使用 ant-design-vue 组件优先
46
- - 自定义组件的样式继承 `:root` token
47
- - 每个组件的状态:默认、悬停、禁用、加载
48
-
49
- ### 4. 布局(Layout)
50
- - 使用 CSS Grid / Flexbox
51
- - 响应式断点:`820px` / `480px`
52
- - 间距使用 `var(--space-xs/sm/md/lg/xl)`
53
-
54
- ### 5. 动效(Motion)
55
- - 过渡时长:0.15s / 0.2s / 0.3s
56
- - 缓动函数:ease-in-out
57
- - 悬停效果:translateY(-2px) + box-shadow
58
-
59
- ### 6. 深度(Depth)
60
- - 阴影层级:卡片(sm)、弹窗(md)、Drawer(lg)
61
- - Z-index 层级约定
62
-
63
- ### 7. 最佳实践 & 禁止事项(Do's & Don'ts)
64
- - 做:引用 `:root` 变量、用设计 token
65
- - 不做:硬编码颜色/尺寸、在 scoped 中定义新 token
66
-
67
- ### 8. 响应式(Responsive)
68
- - 820px:侧栏折叠、2 列变 1 列
69
- - 480px:字体缩小、触控友好的点击区域(≥44px)
70
-
71
- ### 9. 无障碍(Accessibility)
72
- - 颜色对比度
73
- - 焦点可见
74
- - 语义化 HTML
75
-
76
- **将 DESIGN.md 展示给用户审批前,不允许进入 Phase C。**
77
-
78
- ## Phase C: 代码生成
79
-
80
- 严格遵循已审批的 DESIGN.md 生成代码。
81
-
82
- ### 代码质量自检清单(100 分制)
83
-
84
- | 检查项 | 分值 | 说明 |
85
- |--------|------|------|
86
- | 使用 `:root` 变量而非硬编码值 | 15 | 颜色、字体、间距、圆角必须用 var() |
87
- | 响应式布局 | 15 | 820px 和 480px 下正常 |
88
- | 组件复用 | 10 | 优先使用 ant-design-vue 已有组件 |
89
- | 语义化 HTML | 10 | 正确使用 header/main/section/nav |
90
- | CSS 使用 token | 10 | 无硬编码尺寸 |
91
- | 悬停/聚焦效果 | 10 | 所有可交互元素有视觉反馈 |
92
- | 动画过渡 | 10 | 适当使用 transition |
93
- | 无重复样式 | 10 | 无相同值重复声明 |
94
- | 命名规范 | 5 | 组件 PascalCase 等 |
95
- | 无障碍基础 | 5 | focus-visible、aria 属性 |
96
-
97
- 得分低于 70 分时必须修改。
98
-
99
- ### diff 审计(如果提供了参考 URL)
100
- 将生成代码与参考页面的截图或描述进行对比,标注差异。
101
-
102
- ## 文件产出位置
103
-
104
- ```
105
- src/pages/ — 新页面
106
- src/components/ — 新组件
107
- docs/design/ — DESIGN.md 规范文档
108
- ```
109
-
110
- ## 参考
111
-
112
- - 项目设计 token:App.vue `:root` 变量
113
- - 设计约束:`RULES.md`
114
- - 组件库:ant-design-vue(已全局注册)
@@ -1,121 +0,0 @@
1
- ---
2
- name: setup-matt-pocock-skills
3
- description: Sets up an `## Agent skills` block in AGENTS.md/CLAUDE.md and `docs/agents/` so the engineering skills know this repo's issue tracker (GitHub or local markdown), triage label vocabulary, and domain doc layout. Run before first use of `to-issues`, `to-prd`, `triage`, `diagnose`, `tdd`, `improve-codebase-architecture`, or `zoom-out` — or if those skills appear to be missing context about the issue tracker, triage labels, or domain docs.
4
- disable-model-invocation: true
5
- ---
6
-
7
- # Setup Matt Pocock's Skills
8
-
9
- Scaffold the per-repo configuration that the engineering skills assume:
10
-
11
- - **Issue tracker** — where issues live (GitHub by default; local markdown is also supported out of the box)
12
- - **Triage labels** — the strings used for the five canonical triage roles
13
- - **Domain docs** — where `CONTEXT.md` and ADRs live, and the consumer rules for reading them
14
-
15
- This is a prompt-driven skill, not a deterministic script. Explore, present what you found, confirm with the user, then write.
16
-
17
- ## Process
18
-
19
- ### 1. Explore
20
-
21
- Look at the current repo to understand its starting state. Read whatever exists; don't assume:
22
-
23
- - `git remote -v` and `.git/config` — is this a GitHub repo? Which one?
24
- - `AGENTS.md` and `CLAUDE.md` at the repo root — does either exist? Is there already an `## Agent skills` section in either?
25
- - `CONTEXT.md` and `CONTEXT-MAP.md` at the repo root
26
- - `docs/adr/` and any `src/*/docs/adr/` directories
27
- - `docs/agents/` — does this skill's prior output already exist?
28
- - `.scratch/` — sign that a local-markdown issue tracker convention is already in use
29
-
30
- ### 2. Present findings and ask
31
-
32
- Summarise what's present and what's missing. Then walk the user through the three decisions **one at a time** — present a section, get the user's answer, then move to the next. Don't dump all three at once.
33
-
34
- Assume the user does not know what these terms mean. Each section starts with a short explainer (what it is, why these skills need it, what changes if they pick differently). Then show the choices and the default.
35
-
36
- **Section A — Issue tracker.**
37
-
38
- > Explainer: The "issue tracker" is where issues live for this repo. Skills like `to-issues`, `triage`, `to-prd`, and `qa` read from and write to it — they need to know whether to call `gh issue create`, write a markdown file under `.scratch/`, or follow some other workflow you describe. Pick the place you actually track work for this repo.
39
-
40
- Default posture: these skills were designed for GitHub. If a `git remote` points at GitHub, propose that. If a `git remote` points at GitLab (`gitlab.com` or a self-hosted host), propose GitLab. Otherwise (or if the user prefers), offer:
41
-
42
- - **GitHub** — issues live in the repo's GitHub Issues (uses the `gh` CLI)
43
- - **GitLab** — issues live in the repo's GitLab Issues (uses the [`glab`](https://gitlab.com/gitlab-org/cli) CLI)
44
- - **Local markdown** — issues live as files under `.scratch/<feature>/` in this repo (good for solo projects or repos without a remote)
45
- - **Other** (Jira, Linear, etc.) — ask the user to describe the workflow in one paragraph; the skill will record it as freeform prose
46
-
47
- **Section B — Triage label vocabulary.**
48
-
49
- > Explainer: When the `triage` skill processes an incoming issue, it moves it through a state machine — needs evaluation, waiting on reporter, ready for an AFK agent to pick up, ready for a human, or won't fix. To do that, it needs to apply labels (or the equivalent in your issue tracker) that match strings *you've actually configured*. If your repo already uses different label names (e.g. `bug:triage` instead of `needs-triage`), map them here so the skill applies the right ones instead of creating duplicates.
50
-
51
- The five canonical roles:
52
-
53
- - `needs-triage` — maintainer needs to evaluate
54
- - `needs-info` — waiting on reporter
55
- - `ready-for-agent` — fully specified, AFK-ready (an agent can pick it up with no human context)
56
- - `ready-for-human` — needs human implementation
57
- - `wontfix` — will not be actioned
58
-
59
- Default: each role's string equals its name. Ask the user if they want to override any. If their issue tracker has no existing labels, the defaults are fine.
60
-
61
- **Section C — Domain docs.**
62
-
63
- > Explainer: Some skills (`improve-codebase-architecture`, `diagnose`, `tdd`) read a `CONTEXT.md` file to learn the project's domain language, and `docs/adr/` for past architectural decisions. They need to know whether the repo has one global context or multiple (e.g. a monorepo with separate frontend/backend contexts) so they look in the right place.
64
-
65
- Confirm the layout:
66
-
67
- - **Single-context** — one `CONTEXT.md` + `docs/adr/` at the repo root. Most repos are this.
68
- - **Multi-context** — `CONTEXT-MAP.md` at the root pointing to per-context `CONTEXT.md` files (typically a monorepo).
69
-
70
- ### 3. Confirm and edit
71
-
72
- Show the user a draft of:
73
-
74
- - The `## Agent skills` block to add to whichever of `CLAUDE.md` / `AGENTS.md` is being edited (see step 4 for selection rules)
75
- - The contents of `docs/agents/issue-tracker.md`, `docs/agents/triage-labels.md`, `docs/agents/domain.md`
76
-
77
- Let them edit before writing.
78
-
79
- ### 4. Write
80
-
81
- **Pick the file to edit:**
82
-
83
- - If `CLAUDE.md` exists, edit it.
84
- - Else if `AGENTS.md` exists, edit it.
85
- - If neither exists, ask the user which one to create — don't pick for them.
86
-
87
- Never create `AGENTS.md` when `CLAUDE.md` already exists (or vice versa) — always edit the one that's already there.
88
-
89
- If an `## Agent skills` block already exists in the chosen file, update its contents in-place rather than appending a duplicate. Don't overwrite user edits to the surrounding sections.
90
-
91
- The block:
92
-
93
- ```markdown
94
- ## Agent skills
95
-
96
- ### Issue tracker
97
-
98
- [one-line summary of where issues are tracked]. See `docs/agents/issue-tracker.md`.
99
-
100
- ### Triage labels
101
-
102
- [one-line summary of the label vocabulary]. See `docs/agents/triage-labels.md`.
103
-
104
- ### Domain docs
105
-
106
- [one-line summary of layout — "single-context" or "multi-context"]. See `docs/agents/domain.md`.
107
- ```
108
-
109
- Then write the three docs files using the seed templates in this skill folder as a starting point:
110
-
111
- - [issue-tracker-github.md](./issue-tracker-github.md) — GitHub issue tracker
112
- - [issue-tracker-gitlab.md](./issue-tracker-gitlab.md) — GitLab issue tracker
113
- - [issue-tracker-local.md](./issue-tracker-local.md) — local-markdown issue tracker
114
- - [triage-labels.md](./triage-labels.md) — label mapping
115
- - [domain.md](./domain.md) — domain doc consumer rules + layout
116
-
117
- For "other" issue trackers, write `docs/agents/issue-tracker.md` from scratch using the user's description.
118
-
119
- ### 5. Done
120
-
121
- Tell the user the setup is complete and which engineering skills will now read from these files. Mention they can edit `docs/agents/*.md` directly later — re-running this skill is only necessary if they want to switch issue trackers or restart from scratch.
@@ -1,51 +0,0 @@
1
- # Domain Docs
2
-
3
- How the engineering skills should consume this repo's domain documentation when exploring the codebase.
4
-
5
- ## Before exploring, read these
6
-
7
- - **`CONTEXT.md`** at the repo root, or
8
- - **`CONTEXT-MAP.md`** at the repo root if it exists — it points at one `CONTEXT.md` per context. Read each one relevant to the topic.
9
- - **`docs/adr/`** — read ADRs that touch the area you're about to work in. In multi-context repos, also check `src/<context>/docs/adr/` for context-scoped decisions.
10
-
11
- If any of these files don't exist, **proceed silently**. Don't flag their absence; don't suggest creating them upfront. The producer skill (`/grill-with-docs`) creates them lazily when terms or decisions actually get resolved.
12
-
13
- ## File structure
14
-
15
- Single-context repo (most repos):
16
-
17
- ```
18
- /
19
- ├── CONTEXT.md
20
- ├── docs/adr/
21
- │ ├── 0001-event-sourced-orders.md
22
- │ └── 0002-postgres-for-write-model.md
23
- └── src/
24
- ```
25
-
26
- Multi-context repo (presence of `CONTEXT-MAP.md` at the root):
27
-
28
- ```
29
- /
30
- ├── CONTEXT-MAP.md
31
- ├── docs/adr/ ← system-wide decisions
32
- └── src/
33
- ├── ordering/
34
- │ ├── CONTEXT.md
35
- │ └── docs/adr/ ← context-specific decisions
36
- └── billing/
37
- ├── CONTEXT.md
38
- └── docs/adr/
39
- ```
40
-
41
- ## Use the glossary's vocabulary
42
-
43
- When your output names a domain concept (in an issue title, a refactor proposal, a hypothesis, a test name), use the term as defined in `CONTEXT.md`. Don't drift to synonyms the glossary explicitly avoids.
44
-
45
- If the concept you need isn't in the glossary yet, that's a signal — either you're inventing language the project doesn't use (reconsider) or there's a real gap (note it for `/grill-with-docs`).
46
-
47
- ## Flag ADR conflicts
48
-
49
- If your output contradicts an existing ADR, surface it explicitly rather than silently overriding:
50
-
51
- > _Contradicts ADR-0007 (event-sourced orders) — but worth reopening because…_
@@ -1,22 +0,0 @@
1
- # Issue tracker: GitHub
2
-
3
- Issues and PRDs for this repo live as GitHub issues. Use the `gh` CLI for all operations.
4
-
5
- ## Conventions
6
-
7
- - **Create an issue**: `gh issue create --title "..." --body "..."`. Use a heredoc for multi-line bodies.
8
- - **Read an issue**: `gh issue view <number> --comments`, filtering comments by `jq` and also fetching labels.
9
- - **List issues**: `gh issue list --state open --json number,title,body,labels,comments --jq '[.[] | {number, title, body, labels: [.labels[].name], comments: [.comments[].body]}]'` with appropriate `--label` and `--state` filters.
10
- - **Comment on an issue**: `gh issue comment <number> --body "..."`
11
- - **Apply / remove labels**: `gh issue edit <number> --add-label "..."` / `--remove-label "..."`
12
- - **Close**: `gh issue close <number> --comment "..."`
13
-
14
- Infer the repo from `git remote -v` — `gh` does this automatically when run inside a clone.
15
-
16
- ## When a skill says "publish to the issue tracker"
17
-
18
- Create a GitHub issue.
19
-
20
- ## When a skill says "fetch the relevant ticket"
21
-
22
- Run `gh issue view <number> --comments`.