@fernado03/zoo-flow 0.1.0
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.
- package/LICENSE +21 -0
- package/README.md +326 -0
- package/bin/zoo-flow.js +358 -0
- package/package.json +44 -0
- package/templates/full/.roo/commands/caveman.md +7 -0
- package/templates/full/.roo/commands/commit-and-document.md +202 -0
- package/templates/full/.roo/commands/diagnose.md +7 -0
- package/templates/full/.roo/commands/explore.md +13 -0
- package/templates/full/.roo/commands/feature.md +24 -0
- package/templates/full/.roo/commands/fix.md +19 -0
- package/templates/full/.roo/commands/grill-me.md +7 -0
- package/templates/full/.roo/commands/grill-with-docs.md +7 -0
- package/templates/full/.roo/commands/handoff.md +8 -0
- package/templates/full/.roo/commands/improve-codebase-architecture.md +7 -0
- package/templates/full/.roo/commands/prototype.md +9 -0
- package/templates/full/.roo/commands/refactor.md +17 -0
- package/templates/full/.roo/commands/setup-matt-pocock-skills.md +7 -0
- package/templates/full/.roo/commands/tdd.md +9 -0
- package/templates/full/.roo/commands/to-issues.md +7 -0
- package/templates/full/.roo/commands/to-prd.md +7 -0
- package/templates/full/.roo/commands/triage.md +7 -0
- package/templates/full/.roo/commands/tweak.md +9 -0
- package/templates/full/.roo/commands/update-docs.md +130 -0
- package/templates/full/.roo/commands/write-a-skill.md +7 -0
- package/templates/full/.roo/commands/zoom-out.md +7 -0
- package/templates/full/.roo/rules/00-paths.md +17 -0
- package/templates/full/.roo/rules/01-command-protocol.md +25 -0
- package/templates/full/.roo/rules/03-manual-reply-protocol.md +13 -0
- package/templates/full/.roo/rules-code-tweaker/00-scope.md +7 -0
- package/templates/full/.roo/rules-code-tweaker/01-completion.md +14 -0
- package/templates/full/.roo/rules-custom-orchestrator/00-routing.md +14 -0
- package/templates/full/.roo/rules-custom-orchestrator/01-delegation-message.md +12 -0
- package/templates/full/.roo/rules-system-architect/00-scope.md +9 -0
- package/templates/full/.roo/rules-system-architect/01-feature-prototype.md +10 -0
- package/templates/full/.roo/rules-system-architect/02-completion.md +11 -0
- package/templates/full/.roo/skills/docs/adr/0001-explicit-setup-pointer-only-for-hard-dependencies.md +18 -0
- package/templates/full/.roo/skills/engineering/README.md +12 -0
- package/templates/full/.roo/skills/engineering/diagnose/SKILL.md +73 -0
- package/templates/full/.roo/skills/engineering/diagnose/scripts/hitl-loop.template.sh +41 -0
- package/templates/full/.roo/skills/engineering/grill-with-docs/ADR-FORMAT.md +33 -0
- package/templates/full/.roo/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md +45 -0
- package/templates/full/.roo/skills/engineering/grill-with-docs/SKILL.md +32 -0
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/DEEPENING.md +24 -0
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/HTML-REPORT.md +88 -0
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/INTERFACE-DESIGN.md +45 -0
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/LANGUAGE.md +34 -0
- package/templates/full/.roo/skills/engineering/improve-codebase-architecture/SKILL.md +43 -0
- package/templates/full/.roo/skills/engineering/prototype/LOGIC.md +28 -0
- package/templates/full/.roo/skills/engineering/prototype/SKILL.md +27 -0
- package/templates/full/.roo/skills/engineering/prototype/UI.md +53 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/SKILL.md +77 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/domain.md +36 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/issue-tracker-github.md +21 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/issue-tracker-gitlab.md +23 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/issue-tracker-local.md +20 -0
- package/templates/full/.roo/skills/engineering/setup-matt-pocock-skills/triage-labels.md +11 -0
- package/templates/full/.roo/skills/engineering/tdd/SKILL.md +52 -0
- package/templates/full/.roo/skills/engineering/tdd/deep-modules.md +9 -0
- package/templates/full/.roo/skills/engineering/tdd/interface-design.md +6 -0
- package/templates/full/.roo/skills/engineering/tdd/mocking.md +17 -0
- package/templates/full/.roo/skills/engineering/tdd/refactoring.md +9 -0
- package/templates/full/.roo/skills/engineering/tdd/tests.md +12 -0
- package/templates/full/.roo/skills/engineering/to-issues/SKILL.md +45 -0
- package/templates/full/.roo/skills/engineering/to-prd/SKILL.md +58 -0
- package/templates/full/.roo/skills/engineering/triage/AGENT-BRIEF.md +43 -0
- package/templates/full/.roo/skills/engineering/triage/OUT-OF-SCOPE.md +37 -0
- package/templates/full/.roo/skills/engineering/triage/SKILL.md +79 -0
- package/templates/full/.roo/skills/engineering/tweak/SKILL.md +17 -0
- package/templates/full/.roo/skills/engineering/zoom-out/SKILL.md +7 -0
- package/templates/full/.roo/skills/in-progress/README.md +8 -0
- package/templates/full/.roo/skills/in-progress/review/SKILL.md +39 -0
- package/templates/full/.roo/skills/in-progress/writing-beats/SKILL.md +32 -0
- package/templates/full/.roo/skills/in-progress/writing-fragments/SKILL.md +45 -0
- package/templates/full/.roo/skills/in-progress/writing-shape/SKILL.md +50 -0
- package/templates/full/.roo/skills/misc/README.md +6 -0
- package/templates/full/.roo/skills/misc/git-guardrails-claude-code/SKILL.md +64 -0
- package/templates/full/.roo/skills/misc/git-guardrails-claude-code/scripts/block-dangerous-git.sh +25 -0
- package/templates/full/.roo/skills/misc/migrate-to-shoehorn/SKILL.md +37 -0
- package/templates/full/.roo/skills/misc/scaffold-exercises/SKILL.md +61 -0
- package/templates/full/.roo/skills/misc/setup-pre-commit/SKILL.md +62 -0
- package/templates/full/.roo/skills/personal/README.md +6 -0
- package/templates/full/.roo/skills/personal/edit-article/SKILL.md +13 -0
- package/templates/full/.roo/skills/personal/obsidian-vault/SKILL.md +39 -0
- package/templates/full/.roo/skills/productivity/README.md +6 -0
- package/templates/full/.roo/skills/productivity/caveman/SKILL.md +28 -0
- package/templates/full/.roo/skills/productivity/grill-me/SKILL.md +13 -0
- package/templates/full/.roo/skills/productivity/handoff/SKILL.md +14 -0
- package/templates/full/.roo/skills/productivity/write-a-skill/SKILL.md +52 -0
- package/templates/full/.roomodes +47 -0
|
@@ -0,0 +1,39 @@
|
|
|
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
|
+
Issue tracker should exist; run `/setup-matt-pocock-skills` if `docs/agents/issue-tracker.md` missing.
|
|
9
|
+
|
|
10
|
+
## 1. Fixed point
|
|
11
|
+
|
|
12
|
+
1. Use user-supplied commit/branch/tag/`main`/`HEAD~N` exactly.
|
|
13
|
+
2. If missing, ask: `Review against what — a branch, a commit, or main?`
|
|
14
|
+
3. Diff: `git diff {fixed-point}...HEAD`.
|
|
15
|
+
4. Commits: `git log {fixed-point}..HEAD --oneline`.
|
|
16
|
+
|
|
17
|
+
## 2. Spec
|
|
18
|
+
|
|
19
|
+
Order:
|
|
20
|
+
1. Issue refs in commits (`#123`, `Closes #45`, GitLab refs); fetch via `docs/agents/issue-tracker.md`.
|
|
21
|
+
2. User path.
|
|
22
|
+
3. Matching PRD/spec under `docs/`, `specs/`, `.scratch/`.
|
|
23
|
+
4. If none, ask. If no spec, skip Spec axis with `no spec available`.
|
|
24
|
+
|
|
25
|
+
## 3. Standards
|
|
26
|
+
|
|
27
|
+
Collect: `CLAUDE.md`, `AGENTS.md`, `CONTRIBUTING.md`, context docs, `docs/adr/`, `.editorconfig`, `eslint.config.*`, `biome.json`, Prettier config, `tsconfig.json`, `STYLE.md`, `STANDARDS.md`, `STYLEGUIDE.md`, similar.
|
|
28
|
+
|
|
29
|
+
## 4. Parallel sub-agents
|
|
30
|
+
|
|
31
|
+
Standards prompt: diff command; commits; standards files; report documented-standard violations per file/hunk; cite standard; hard vs judgement; skip tooling-enforced; under 400 words.
|
|
32
|
+
|
|
33
|
+
Spec prompt: diff command; commits; spec path/content; report missing/partial requirements, scope creep, wrong-looking implementation; quote spec line; under 400 words.
|
|
34
|
+
|
|
35
|
+
## 5. Aggregate
|
|
36
|
+
|
|
37
|
+
1. Present `## Standards` and `## Spec` separately.
|
|
38
|
+
2. DO NOT merge/rerank axes.
|
|
39
|
+
3. End with counts per axis + worst issue.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: writing-beats
|
|
3
|
+
description: Shape an article as a journey of beats, choose-your-own-adventure style. The user picks a starting beat from the raw material, you write only that beat, then offer options for where to pivot next, beat by beat, until the article reaches a natural end. Use when the user has raw material and wants to assemble it as a narrative rather than an argument.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Writing Beats
|
|
7
|
+
|
|
8
|
+
## Setup
|
|
9
|
+
|
|
10
|
+
1. Read raw markdown fully.
|
|
11
|
+
2. If article output path missing, ask once.
|
|
12
|
+
3. Never edit raw material.
|
|
13
|
+
4. Re-read article before every write.
|
|
14
|
+
|
|
15
|
+
## Loop
|
|
16
|
+
|
|
17
|
+
1. Offer 2–3 starting beats from raw material.
|
|
18
|
+
2. Preview likely next pivots for each.
|
|
19
|
+
3. User picks.
|
|
20
|
+
4. Write only selected beat to article.
|
|
21
|
+
5. Re-read article.
|
|
22
|
+
6. Offer 2–3 next beats from current ending.
|
|
23
|
+
7. Loop until natural end.
|
|
24
|
+
|
|
25
|
+
## Rules
|
|
26
|
+
|
|
27
|
+
- Beat = one move: scene/point/question/aside/twist.
|
|
28
|
+
- Size to need: sentence, paragraph, or short vignette.
|
|
29
|
+
- If needs headings/5 paragraphs, split.
|
|
30
|
+
- Pull/paraphrase/split/merge raw fragments.
|
|
31
|
+
- Leave unused raw material.
|
|
32
|
+
- Rewrite/go back → edit specific beat; preserve rest.
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: writing-fragments
|
|
3
|
+
description: Grilling session that mines the user for fragments — heterogeneous nuggets of writing (claims, vignettes, sharp sentences, half-thoughts) — and appends them to a single document as raw material for a future article. Use when the user wants to develop ideas before imposing structure, or mentions "fragments", "ideate", or "raw material" for writing.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Writing Fragments
|
|
7
|
+
|
|
8
|
+
## Setup
|
|
9
|
+
|
|
10
|
+
1. Capture fragments from initial prompt onward.
|
|
11
|
+
2. If output path missing, ask once.
|
|
12
|
+
3. First write: one H1 working title; no metadata/TOC/date.
|
|
13
|
+
4. Re-read file before every write.
|
|
14
|
+
5. Append only unless user requests specific edit.
|
|
15
|
+
|
|
16
|
+
## Fragment forms
|
|
17
|
+
|
|
18
|
+
- Sharp sentence.
|
|
19
|
+
- Claim + one-line reason.
|
|
20
|
+
- Vignette/scenario/analogy/code snippet.
|
|
21
|
+
- Half-thought.
|
|
22
|
+
- Quote/dialogue.
|
|
23
|
+
- Observation cluster.
|
|
24
|
+
- Complaint/confession/punchline.
|
|
25
|
+
|
|
26
|
+
## File format
|
|
27
|
+
|
|
28
|
+
```markdown
|
|
29
|
+
# Working title
|
|
30
|
+
|
|
31
|
+
Fragment one.
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
Fragment two.
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Rules:
|
|
39
|
+
- Separate fragments with `---`.
|
|
40
|
+
- No body headings/tags.
|
|
41
|
+
- Order = capture order.
|
|
42
|
+
- Append silently; mention briefly.
|
|
43
|
+
- Preserve user edits.
|
|
44
|
+
- Support `cut last`, `rewrite`, `merge` immediately.
|
|
45
|
+
- DO NOT impose outline/structure.
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: writing-shape
|
|
3
|
+
description: Take a markdown file of raw material and shape it into an article through a conversational session — drafting candidate openings, growing the piece paragraph by paragraph, arguing about format (lists, tables, callouts, quotes) at each step. Use when the user has a pile of notes, fragments, or a rough draft and wants help turning it into something publishable.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Writing Shape
|
|
7
|
+
|
|
8
|
+
## Setup
|
|
9
|
+
|
|
10
|
+
1. Read raw markdown fully.
|
|
11
|
+
2. Treat raw file read-only.
|
|
12
|
+
3. If article path missing, ask once.
|
|
13
|
+
4. Re-read article before every write.
|
|
14
|
+
|
|
15
|
+
## Loop
|
|
16
|
+
|
|
17
|
+
1. Draft 2–3 openings with different thesis/angle.
|
|
18
|
+
2. User picks or composes hybrid.
|
|
19
|
+
3. Opening defines article path.
|
|
20
|
+
4. Ask what reader needs next.
|
|
21
|
+
5. Pull from raw material.
|
|
22
|
+
6. Argue format: prose/list/table/callout/quote/code.
|
|
23
|
+
7. Append agreed block immediately.
|
|
24
|
+
8. Repeat until article done.
|
|
25
|
+
|
|
26
|
+
## Pressure tests
|
|
27
|
+
|
|
28
|
+
- What does this paragraph do that previous didn't?
|
|
29
|
+
- If cut, what breaks?
|
|
30
|
+
- Prose/list/table/callout? Why?
|
|
31
|
+
- Sentence doing two jobs? Split or pick one.
|
|
32
|
+
- Opening promised X; current draft drifted to Y?
|
|
33
|
+
|
|
34
|
+
## Format rules
|
|
35
|
+
|
|
36
|
+
- Prose carries argument.
|
|
37
|
+
- List only for parallel items.
|
|
38
|
+
- Callout for derailing tips/warnings/asides.
|
|
39
|
+
- Table when same fields repeat 3+ times.
|
|
40
|
+
- Quote when exact wording matters.
|
|
41
|
+
- Code block for multi-line/runnable/illustrative; inline code for single token.
|
|
42
|
+
|
|
43
|
+
## Rules
|
|
44
|
+
|
|
45
|
+
- Mine pile; do not follow as script.
|
|
46
|
+
- Paraphrase/split/merge fragments.
|
|
47
|
+
- If pile lacks needed example/info, ask user or cut section.
|
|
48
|
+
- Preserve user edits.
|
|
49
|
+
- Edit specific paragraph in place when requested.
|
|
50
|
+
- DO NOT publish or add unsolicited frontmatter.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Misc
|
|
2
|
+
|
|
3
|
+
- **[git-guardrails-claude-code](./git-guardrails-claude-code/SKILL.md)** — Block dangerous git cmds in Claude Code.
|
|
4
|
+
- **[migrate-to-shoehorn](./migrate-to-shoehorn/SKILL.md)** — Replace test `as` assertions with shoehorn helpers.
|
|
5
|
+
- **[scaffold-exercises](./scaffold-exercises/SKILL.md)** — Create exercise dirs passing lint.
|
|
6
|
+
- **[setup-pre-commit](./setup-pre-commit/SKILL.md)** — Add Husky + lint-staged + Prettier checks.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: git-guardrails-claude-code
|
|
3
|
+
description: Set up Claude Code hooks to block dangerous git commands (push, reset --hard, clean, branch -D, etc.) before they execute. Use when user wants to prevent destructive git operations, add git safety hooks, or block git push/reset in Claude Code.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Setup Git Guardrails
|
|
7
|
+
|
|
8
|
+
Block patterns: `git push`, `git reset --hard`, `git clean -f`, `git clean -fd`, `git branch -D`, `git checkout .`, `git restore .`, `push --force`, `reset --hard`.
|
|
9
|
+
|
|
10
|
+
## Process
|
|
11
|
+
|
|
12
|
+
1. Ask scope: Project `.claude/settings.json` or Global `~/.claude/settings.json`.
|
|
13
|
+
2. Copy `scripts/block-dangerous-git.sh` to `.claude/hooks/block-dangerous-git.sh` in selected scope.
|
|
14
|
+
3. Run `chmod +x {script}`.
|
|
15
|
+
4. Merge hook into settings; DO NOT overwrite existing settings.
|
|
16
|
+
|
|
17
|
+
Project settings:
|
|
18
|
+
|
|
19
|
+
```json
|
|
20
|
+
{
|
|
21
|
+
"hooks": {
|
|
22
|
+
"PreToolUse": [
|
|
23
|
+
{
|
|
24
|
+
"matcher": "Bash",
|
|
25
|
+
"hooks": [
|
|
26
|
+
{
|
|
27
|
+
"type": "command",
|
|
28
|
+
"command": "\"$CLAUDE_PROJECT_DIR\"/.claude/hooks/block-dangerous-git.sh"
|
|
29
|
+
}
|
|
30
|
+
]
|
|
31
|
+
}
|
|
32
|
+
]
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
Global settings:
|
|
38
|
+
|
|
39
|
+
```json
|
|
40
|
+
{
|
|
41
|
+
"hooks": {
|
|
42
|
+
"PreToolUse": [
|
|
43
|
+
{
|
|
44
|
+
"matcher": "Bash",
|
|
45
|
+
"hooks": [
|
|
46
|
+
{
|
|
47
|
+
"type": "command",
|
|
48
|
+
"command": "~/.claude/hooks/block-dangerous-git.sh"
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
]
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
5. Ask pattern customisation.
|
|
58
|
+
6. Verify:
|
|
59
|
+
|
|
60
|
+
```bash
|
|
61
|
+
echo '{"tool_input":{"command":"git push origin main"}}' | {path-to-script}
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Expected: exit 2 + `BLOCKED` stderr.
|
package/templates/full/.roo/skills/misc/git-guardrails-claude-code/scripts/block-dangerous-git.sh
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
#!/bin/bash
|
|
2
|
+
|
|
3
|
+
INPUT=$(cat)
|
|
4
|
+
COMMAND=$(echo "$INPUT" | jq -r '.tool_input.command')
|
|
5
|
+
|
|
6
|
+
DANGEROUS_PATTERNS=(
|
|
7
|
+
"git push"
|
|
8
|
+
"git reset --hard"
|
|
9
|
+
"git clean -fd"
|
|
10
|
+
"git clean -f"
|
|
11
|
+
"git branch -D"
|
|
12
|
+
"git checkout \."
|
|
13
|
+
"git restore \."
|
|
14
|
+
"push --force"
|
|
15
|
+
"reset --hard"
|
|
16
|
+
)
|
|
17
|
+
|
|
18
|
+
for pattern in "${DANGEROUS_PATTERNS[@]}"; do
|
|
19
|
+
if echo "$COMMAND" | grep -qE "$pattern"; then
|
|
20
|
+
echo "BLOCKED: '$COMMAND' matches dangerous pattern '$pattern'. The user has prevented you from doing this." >&2
|
|
21
|
+
exit 2
|
|
22
|
+
fi
|
|
23
|
+
done
|
|
24
|
+
|
|
25
|
+
exit 0
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: migrate-to-shoehorn
|
|
3
|
+
description: Migrate test files from `as` type assertions to @total-typescript/shoehorn. Use when user mentions shoehorn, wants to replace `as` in tests, or needs partial test data.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Migrate to Shoehorn
|
|
7
|
+
|
|
8
|
+
RULE: Test code only. Never production.
|
|
9
|
+
|
|
10
|
+
## Install
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
npm i @total-typescript/shoehorn
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## Mapping
|
|
17
|
+
|
|
18
|
+
- `as Type` → `fromPartial()`.
|
|
19
|
+
- `as unknown as Type` → `fromAny()`.
|
|
20
|
+
- `fromPartial()` = partial data that should type-check.
|
|
21
|
+
- `fromAny()` = intentionally wrong data.
|
|
22
|
+
- `fromExact()` = full object now, partial later.
|
|
23
|
+
|
|
24
|
+
## Workflow
|
|
25
|
+
|
|
26
|
+
1. Ask target test files/use cases if missing.
|
|
27
|
+
2. Install dependency.
|
|
28
|
+
3. Find assertions:
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
grep -r " as [A-Z]" --include="*.test.ts" --include="*.spec.ts"
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
4. Replace `as Type` with `fromPartial()`.
|
|
35
|
+
5. Replace `as unknown as Type` with `fromAny()`.
|
|
36
|
+
6. Add imports.
|
|
37
|
+
7. Run type check.
|
|
@@ -0,0 +1,61 @@
|
|
|
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
|
+
Goal: create exercise dirs passing `pnpm ai-hero-cli internal lint`, then commit.
|
|
9
|
+
|
|
10
|
+
## Naming
|
|
11
|
+
|
|
12
|
+
- Sections: `exercises/XX-section-name/`.
|
|
13
|
+
- Exercises: `XX.YY-exercise-name/` inside section.
|
|
14
|
+
- Lowercase dash-case.
|
|
15
|
+
|
|
16
|
+
## Variants
|
|
17
|
+
|
|
18
|
+
Each exercise needs ≥1: `problem/`, `solution/`, `explainer/`. Default stub: `explainer/` unless plan says otherwise.
|
|
19
|
+
|
|
20
|
+
## Required files
|
|
21
|
+
|
|
22
|
+
- Each variant folder: non-empty `readme.md`.
|
|
23
|
+
- Minimal readme:
|
|
24
|
+
|
|
25
|
+
```md
|
|
26
|
+
# Exercise Title
|
|
27
|
+
|
|
28
|
+
Description here
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
- If folder has code, `main.ts` >1 line required.
|
|
32
|
+
- Readme-only stubs allowed.
|
|
33
|
+
|
|
34
|
+
## Workflow
|
|
35
|
+
|
|
36
|
+
1. Parse plan into sections/exercises/variants.
|
|
37
|
+
2. `mkdir -p` dirs.
|
|
38
|
+
3. Create readme stubs.
|
|
39
|
+
4. Run `pnpm ai-hero-cli internal lint`.
|
|
40
|
+
5. Fix until pass.
|
|
41
|
+
6. Moves/renames: use `git mv`, not `mv`.
|
|
42
|
+
7. Commit with `git commit`.
|
|
43
|
+
|
|
44
|
+
## Lint constraints
|
|
45
|
+
|
|
46
|
+
- Exercise has subfolder.
|
|
47
|
+
- At least one of `problem/`, `explainer/`, `explainer.1/` exists.
|
|
48
|
+
- Primary readme exists and non-empty.
|
|
49
|
+
- No `.gitkeep`.
|
|
50
|
+
- No `speaker-notes.md`.
|
|
51
|
+
- No broken links.
|
|
52
|
+
- No `pnpm run exercise` in readmes.
|
|
53
|
+
- `main.ts` required only when code present.
|
|
54
|
+
|
|
55
|
+
## Example
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
mkdir -p exercises/05-memory-skill-building/05.01-introduction-to-memory/explainer
|
|
59
|
+
mkdir -p exercises/05-memory-skill-building/05.02-short-term-memory/{explainer,problem,solution}
|
|
60
|
+
mkdir -p exercises/05-memory-skill-building/05.03-long-term-memory/explainer
|
|
61
|
+
```
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: setup-pre-commit
|
|
3
|
+
description: Set up Husky pre-commit hooks with lint-staged (Prettier), type checking, and tests in the current repo. Use when user wants to add pre-commit hooks, set up Husky, configure lint-staged, or add commit-time formatting/typechecking/testing.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Setup Pre-Commit Hooks
|
|
7
|
+
|
|
8
|
+
Creates Husky pre-commit, lint-staged Prettier, optional typecheck/test.
|
|
9
|
+
|
|
10
|
+
## Process
|
|
11
|
+
|
|
12
|
+
1. Detect package manager: `package-lock.json`→npm; `pnpm-lock.yaml`→pnpm; `yarn.lock`→yarn; `bun.lockb`→bun; default npm.
|
|
13
|
+
2. Install dev deps, adapting package manager:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
npm i -D husky lint-staged prettier
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
3. Init Husky:
|
|
20
|
+
|
|
21
|
+
```bash
|
|
22
|
+
npx husky init
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
4. Write `.husky/pre-commit`, adapting package manager; omit missing scripts and tell user:
|
|
26
|
+
|
|
27
|
+
```text
|
|
28
|
+
npx lint-staged
|
|
29
|
+
npm run typecheck
|
|
30
|
+
npm run test
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
5. Create `.lintstagedrc`:
|
|
34
|
+
|
|
35
|
+
```json
|
|
36
|
+
{
|
|
37
|
+
"*": "prettier --ignore-unknown --write"
|
|
38
|
+
}
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
6. Create `.prettierrc` only if no Prettier config:
|
|
42
|
+
|
|
43
|
+
```json
|
|
44
|
+
{
|
|
45
|
+
"useTabs": false,
|
|
46
|
+
"tabWidth": 2,
|
|
47
|
+
"printWidth": 80,
|
|
48
|
+
"singleQuote": false,
|
|
49
|
+
"trailingComma": "es5",
|
|
50
|
+
"semi": true,
|
|
51
|
+
"arrowParens": "always"
|
|
52
|
+
}
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
7. Verify: executable `.husky/pre-commit`; `.lintstagedrc`; `prepare` script = `husky`; Prettier config; `npx lint-staged`.
|
|
56
|
+
8. Commit:
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
git commit -m "Add pre-commit hooks (husky + lint-staged + prettier)"
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
RULE: Wait for explicit user approval before commit if current mode requires HITL.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: edit-article
|
|
3
|
+
description: Edit and improve articles by restructuring sections, improving clarity, and tightening prose. Use when user wants to edit, revise, or improve an article draft.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Edit Article
|
|
7
|
+
|
|
8
|
+
1. Divide article by headings.
|
|
9
|
+
2. Identify main point per section.
|
|
10
|
+
3. Reorder sections/content so dependencies flow first.
|
|
11
|
+
4. Confirm section plan with user.
|
|
12
|
+
5. Rewrite each section for clarity/coherence/flow.
|
|
13
|
+
6. Max 240 chars per paragraph.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: obsidian-vault
|
|
3
|
+
description: Search, create, and manage notes in the Obsidian vault with wikilinks and index notes. Use when user wants to find, create, or organize notes in Obsidian.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Obsidian Vault
|
|
7
|
+
|
|
8
|
+
## Vault path
|
|
9
|
+
|
|
10
|
+
1. Use `$OBSIDIAN_VAULT_PATH`.
|
|
11
|
+
2. If unset, STOP and ask absolute vault path.
|
|
12
|
+
|
|
13
|
+
## Naming
|
|
14
|
+
|
|
15
|
+
- Index notes aggregate related topics: `Ralph Wiggum Index.md`.
|
|
16
|
+
- Title Case filenames.
|
|
17
|
+
- No folders for org; use wikilinks/index notes.
|
|
18
|
+
|
|
19
|
+
## Linking
|
|
20
|
+
|
|
21
|
+
- Use `[[wikilinks]]`.
|
|
22
|
+
- Add related/dependency links at bottom.
|
|
23
|
+
- Index notes = wikilink lists.
|
|
24
|
+
|
|
25
|
+
## Commands
|
|
26
|
+
|
|
27
|
+
```bash
|
|
28
|
+
find "/mnt/d/Obsidian Vault/AI Research/" -name "*.md" | grep -i "keyword"
|
|
29
|
+
grep -rl "keyword" "/mnt/d/Obsidian Vault/AI Research/" --include="*.md"
|
|
30
|
+
grep -rl "\\[\\[Note Title\\]\\]" "/mnt/d/Obsidian Vault/AI Research/"
|
|
31
|
+
find "/mnt/d/Obsidian Vault/AI Research/" -name "*Index*"
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Create note
|
|
35
|
+
|
|
36
|
+
1. Title Case filename.
|
|
37
|
+
2. Write one learning unit.
|
|
38
|
+
3. Add related wikilinks at bottom.
|
|
39
|
+
4. If numbered sequence, use hierarchy.
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
# Productivity
|
|
2
|
+
|
|
3
|
+
- **[caveman](./caveman/SKILL.md)** — Ultra-compressed communication mode.
|
|
4
|
+
- **[grill-me](./grill-me/SKILL.md)** — Relentless plan/design interview.
|
|
5
|
+
- **[handoff](./handoff/SKILL.md)** — Save compact handoff doc in temp dir.
|
|
6
|
+
- **[write-a-skill](./write-a-skill/SKILL.md)** — Create skill structure/docs/scripts.
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: caveman
|
|
3
|
+
description: >
|
|
4
|
+
Ultra-compressed communication mode. Cuts token usage ~75% by dropping
|
|
5
|
+
filler, articles, and pleasantries while keeping full technical accuracy.
|
|
6
|
+
Use when user says "caveman mode", "talk like caveman", "use caveman",
|
|
7
|
+
"less tokens", "be brief", or invokes /caveman.
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
# Caveman
|
|
11
|
+
|
|
12
|
+
ACTIVE until user says stop/normal mode.
|
|
13
|
+
|
|
14
|
+
Rules:
|
|
15
|
+
- Drop articles/filler/pleasantries/hedging.
|
|
16
|
+
- Keep technical accuracy + exact terms.
|
|
17
|
+
- Fragments OK.
|
|
18
|
+
- Use short synonyms.
|
|
19
|
+
- Abbrev: DB/auth/config/req/res/fn/impl.
|
|
20
|
+
- Use arrows for causality.
|
|
21
|
+
- Code blocks unchanged.
|
|
22
|
+
- Quote errors exact.
|
|
23
|
+
|
|
24
|
+
Pattern: `[thing] [action] [reason]. [next step].`
|
|
25
|
+
|
|
26
|
+
Auto-clarity:
|
|
27
|
+
- Use normal clarity briefly for security warnings/irreversible actions/risky multi-step/repeated clarification.
|
|
28
|
+
- Resume caveman after.
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: grill-me
|
|
3
|
+
description: Interview the user relentlessly about a plan or design until reaching shared understanding, resolving each branch of the decision tree. Use when user wants to stress-test a plan, get grilled on their design, or mentions "grill me".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Grill Me
|
|
7
|
+
|
|
8
|
+
1. Interview plan/design until shared understanding.
|
|
9
|
+
2. Walk design tree branch-by-branch.
|
|
10
|
+
3. Resolve dependency order between decisions.
|
|
11
|
+
4. Ask one question at a time.
|
|
12
|
+
5. Include recommended answer.
|
|
13
|
+
6. Inspect code instead of asking when code can answer.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: handoff
|
|
3
|
+
description: Compact the current conversation into a handoff document for another agent to pick up.
|
|
4
|
+
argument-hint: "What will the next session be used for?"
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Handoff
|
|
8
|
+
|
|
9
|
+
1. Write handoff for fresh agent.
|
|
10
|
+
2. Save in OS temp dir, not workspace.
|
|
11
|
+
3. Tailor to user args.
|
|
12
|
+
4. Include suggested skills section.
|
|
13
|
+
5. Reference artifacts by path/URL; do not duplicate.
|
|
14
|
+
6. Redact secrets/API keys/passwords/PII.
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: write-a-skill
|
|
3
|
+
description: Create new agent skills with proper structure, progressive disclosure, and bundled resources. Use when user wants to create, write, or build a new skill.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# Write A Skill
|
|
7
|
+
|
|
8
|
+
## Process
|
|
9
|
+
|
|
10
|
+
1. Gather: task/domain; use cases/triggers; scripts needed; references.
|
|
11
|
+
2. Draft: concise `SKILL.md`; reference files if `SKILL.md` >100 lines or distinct domains; scripts for deterministic repeated ops.
|
|
12
|
+
3. Review with user.
|
|
13
|
+
4. Revise.
|
|
14
|
+
|
|
15
|
+
## Structure
|
|
16
|
+
|
|
17
|
+
```text
|
|
18
|
+
skill-name/
|
|
19
|
+
├── SKILL.md
|
|
20
|
+
├── REFERENCE.md
|
|
21
|
+
├── EXAMPLES.md
|
|
22
|
+
└── scripts/
|
|
23
|
+
└── helper.js
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Frontmatter
|
|
27
|
+
|
|
28
|
+
```md
|
|
29
|
+
---
|
|
30
|
+
name: skill-name
|
|
31
|
+
description: Brief description. Use when [specific triggers].
|
|
32
|
+
---
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
Description rules:
|
|
36
|
+
- Max 1024 chars.
|
|
37
|
+
- Third person.
|
|
38
|
+
- First sentence = capability.
|
|
39
|
+
- Second sentence = `Use when ...` triggers.
|
|
40
|
+
|
|
41
|
+
## Scripts
|
|
42
|
+
|
|
43
|
+
Add when: deterministic op; repeated code; explicit error handling needed.
|
|
44
|
+
|
|
45
|
+
## Review checklist
|
|
46
|
+
|
|
47
|
+
- [ ] Description has triggers.
|
|
48
|
+
- [ ] `SKILL.md` under 100 lines.
|
|
49
|
+
- [ ] No time-sensitive info.
|
|
50
|
+
- [ ] Terminology consistent.
|
|
51
|
+
- [ ] Examples concrete.
|
|
52
|
+
- [ ] References one level deep.
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
{
|
|
2
|
+
"customModes": [
|
|
3
|
+
{
|
|
4
|
+
"slug": "code-tweaker",
|
|
5
|
+
"name": "⚡ Code Tweaker",
|
|
6
|
+
"roleDefinition": "You are an Execution Specialist. You implement, test, update docs, prototype, and commit when explicitly approved.",
|
|
7
|
+
"whenToUse": "Use for direct implementation, CSS/UI changes, TDD loops, documentation updates, runnable prototypes, known fixes, and local commits.",
|
|
8
|
+
"description": "Fast execution for tweaks, TDD, docs, prototypes, and approved commits.",
|
|
9
|
+
"customInstructions": "Use `.roo/rules-code-tweaker/` for mode-specific behavior.\n\nPermitted commands: /tweak, /tdd, /update-docs, /commit-and-document, /prototype.\n\nFollow `.roo/rules/01-command-protocol.md` to load and execute commands. Follow `.roo/rules/00-paths.md` for path safety. Follow `.roo/rules/03-manual-reply-protocol.md` when asking the user to choose, approve, or continue.\n\nIf assigned any other command, stop and report the routing error.",
|
|
10
|
+
"groups": [
|
|
11
|
+
"read",
|
|
12
|
+
"edit",
|
|
13
|
+
"command",
|
|
14
|
+
"mcp"
|
|
15
|
+
]
|
|
16
|
+
},
|
|
17
|
+
{
|
|
18
|
+
"slug": "system-architect",
|
|
19
|
+
"name": "🏗️ System Architect",
|
|
20
|
+
"roleDefinition": "You are a System Architect. You plan, diagnose, explore, triage, and design. You do NOT write implementation code.",
|
|
21
|
+
"whenToUse": "Use for complex debugging (/fix), feature planning (/feature), architecture changes (/refactor), issue triage (/triage), and codebase exploration (/explore).",
|
|
22
|
+
"description": "Planning, diagnosis, refactor design, exploration, and triage.",
|
|
23
|
+
"customInstructions": "Use `.roo/rules-system-architect/` for mode-specific behavior.\n\nPermitted commands: /feature, /fix, /refactor, /explore, /triage.\n\nFollow `.roo/rules/01-command-protocol.md` to load and execute commands. Follow `.roo/rules/00-paths.md` for path safety. Follow `.roo/rules/03-manual-reply-protocol.md` when asking the user to choose, approve, or continue.\n\nIf assigned any other command, stop and report the routing error.",
|
|
24
|
+
"groups": [
|
|
25
|
+
"command",
|
|
26
|
+
"mcp",
|
|
27
|
+
"read",
|
|
28
|
+
[
|
|
29
|
+
"edit",
|
|
30
|
+
{
|
|
31
|
+
"fileRegex": "(.*\\.md$|^\\.scratch/.*|^docs/.*)",
|
|
32
|
+
"description": "Markdown files, .scratch/, and docs/ directories only"
|
|
33
|
+
}
|
|
34
|
+
]
|
|
35
|
+
]
|
|
36
|
+
},
|
|
37
|
+
{
|
|
38
|
+
"slug": "custom-orchestrator",
|
|
39
|
+
"name": "🪃 Custom Orchestrator",
|
|
40
|
+
"roleDefinition": "You are a PM and router. You choose workflows and delegate subtasks. You NEVER inspect implementation files, write code, or use switch_mode.",
|
|
41
|
+
"whenToUse": "Use for initial task planning, choosing slash commands, routing work, or discussing workflow.",
|
|
42
|
+
"description": "Router that consults, delegates, and waits for user direction.",
|
|
43
|
+
"customInstructions": "Use `.roo/rules-custom-orchestrator/` for mode-specific behavior.\n\nRoute only these commands:\n\n- /tweak, /tdd, /update-docs, /commit-and-document, /prototype -> code-tweaker\n- /fix, /feature, /refactor, /explore, /triage -> system-architect\n\nUse `new_task` only. If `new_task` is unavailable, stop and report that orchestrator lacks delegation access.\n\nFollow `.roo/rules/03-manual-reply-protocol.md` when offering workflow choices.",
|
|
44
|
+
"groups": []
|
|
45
|
+
}
|
|
46
|
+
]
|
|
47
|
+
}
|