@lean-agent/skills 0.0.1 → 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/package.json +7 -2
- package/skills/architect/SKILL.md +108 -0
- package/skills/teamlead/SKILL.md +74 -0
- package/skills/vision/SKILL.md +38 -0
- package/workflows/kickoff/WORKFLOW.md +56 -0
package/package.json
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lean-agent/skills",
|
|
3
|
-
"version": "0.0
|
|
3
|
+
"version": "0.1.0",
|
|
4
4
|
"description": "Starter catalog of portable skills for the lean-agent framework. Works with Claude Code, Cursor, Windsurf, and VS Code.",
|
|
5
5
|
"files": [
|
|
6
6
|
"skills/**/*",
|
|
7
|
+
"workflows/**/*",
|
|
7
8
|
"README.md",
|
|
8
9
|
"LICENSE"
|
|
9
10
|
],
|
|
@@ -26,7 +27,11 @@
|
|
|
26
27
|
"cursor",
|
|
27
28
|
"windsurf",
|
|
28
29
|
"copilot",
|
|
29
|
-
"challenger"
|
|
30
|
+
"challenger",
|
|
31
|
+
"workflows",
|
|
32
|
+
"architect",
|
|
33
|
+
"teamlead",
|
|
34
|
+
"vision"
|
|
30
35
|
],
|
|
31
36
|
"publishConfig": {
|
|
32
37
|
"access": "public"
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: architect
|
|
3
|
+
description: Turn a vision into architecture decisions and a sequenced implementation plan. Thinks big, starts small — makes architecture calls that scale, then sequences work into vertical slices. Use when user wants to plan how to build something, needs an implementation strategy, or mentions "architect" or "plan this".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Before anything else, silently scout the project:
|
|
7
|
+
|
|
8
|
+
1. List the top-level directory and scan for existing source code, configs, docs, and any prior `PLAN.md`.
|
|
9
|
+
2. Look for output from a previous `vision` session — a vision statement, README description, or any artifact that captures what's being built and why.
|
|
10
|
+
3. If a `PLAN.md` already exists, read it. Ask the user: "There's an existing plan — should I revise it or start fresh?"
|
|
11
|
+
|
|
12
|
+
If you found vision context, reflect it back in one sentence to confirm alignment, then move straight to architecture. Do NOT re-interview about what they're building — that's vision's job.
|
|
13
|
+
|
|
14
|
+
If no prior context exists, ask the essential scoping questions yourself — but stay focused on what's needed for architecture, not a full vision exercise:
|
|
15
|
+
- What are you building?
|
|
16
|
+
- Who is it for?
|
|
17
|
+
- What does "done" look like?
|
|
18
|
+
|
|
19
|
+
Then move to architecture.
|
|
20
|
+
|
|
21
|
+
## Architecture phase
|
|
22
|
+
|
|
23
|
+
Understand the full scope first. Ask: "What's the biggest this could become?" Do not shrink the vision. Architecture decisions should support the full ambition, not just the first slice.
|
|
24
|
+
|
|
25
|
+
Work through the key architecture decisions one at a time. For each decision, state your recommendation and why — then let the user push back. Cover only what's relevant to this project. Common decisions include:
|
|
26
|
+
|
|
27
|
+
- Project structure and module boundaries
|
|
28
|
+
- Data model and storage
|
|
29
|
+
- API design and protocols
|
|
30
|
+
- Auth and access control
|
|
31
|
+
- Key libraries, frameworks, or platforms
|
|
32
|
+
- Deployment and infrastructure
|
|
33
|
+
- Integration points and external dependencies
|
|
34
|
+
|
|
35
|
+
Do NOT present menus of options. State a concrete take: "I'd go with X because Y — does that track?" Move on when the user agrees or provides an alternative.
|
|
36
|
+
|
|
37
|
+
Skip decisions that aren't relevant yet. If the project is a CLI tool, don't ask about auth. Stay lean.
|
|
38
|
+
|
|
39
|
+
## Sequencing phase
|
|
40
|
+
|
|
41
|
+
Once architecture is resolved, decompose the work into vertical slices — each one a thin, complete path through the system that can be built and verified independently.
|
|
42
|
+
|
|
43
|
+
Rules for slices:
|
|
44
|
+
- Each slice is small enough for one AI coding session
|
|
45
|
+
- Each slice is shippable and testable on its own
|
|
46
|
+
- Order by dependency — each slice builds on the last
|
|
47
|
+
- The first slice is the tracer bullet: the thinnest possible path that proves the core architecture works end-to-end
|
|
48
|
+
|
|
49
|
+
For each slice, state:
|
|
50
|
+
- What it does (one sentence)
|
|
51
|
+
- What files/modules it touches
|
|
52
|
+
- How to verify it works
|
|
53
|
+
|
|
54
|
+
## Depth check
|
|
55
|
+
|
|
56
|
+
After presenting the slices, ask: "Is this the right level of detail, or do you want implementation-ready depth — the kind you could hand to a developer and walk away?"
|
|
57
|
+
|
|
58
|
+
If the user wants implementation-ready depth, expand each slice into concrete tasks:
|
|
59
|
+
- Exact files to create or modify
|
|
60
|
+
- Function signatures, data models, key logic
|
|
61
|
+
- Dependencies between tasks within the slice
|
|
62
|
+
- Acceptance criteria — how to verify each task is done correctly
|
|
63
|
+
|
|
64
|
+
Include all technical detail — every decision, every tradeoff, every non-obvious choice. The plan should stand on its own without needing a follow-up conversation.
|
|
65
|
+
|
|
66
|
+
The number of slices and the depth within each is driven by the project, not a template. Do not force a fixed number of phases.
|
|
67
|
+
|
|
68
|
+
## Output
|
|
69
|
+
|
|
70
|
+
When the user confirms the plan, write it to `PLAN.md` in the project root using this format:
|
|
71
|
+
|
|
72
|
+
```markdown
|
|
73
|
+
# Plan
|
|
74
|
+
|
|
75
|
+
> One-line summary of what we're building.
|
|
76
|
+
|
|
77
|
+
## Architecture Decisions
|
|
78
|
+
|
|
79
|
+
- **[Topic]**: [Decision] — [why]
|
|
80
|
+
- ...
|
|
81
|
+
|
|
82
|
+
## Slices
|
|
83
|
+
|
|
84
|
+
### 1. [Tracer bullet] [Name]
|
|
85
|
+
[What it does]
|
|
86
|
+
- Touches: [files/modules]
|
|
87
|
+
- Verify: [how to confirm it works]
|
|
88
|
+
|
|
89
|
+
### 2. [Name]
|
|
90
|
+
...
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
For implementation-ready depth, expand each slice:
|
|
94
|
+
|
|
95
|
+
```markdown
|
|
96
|
+
### 1. [Tracer bullet] [Name]
|
|
97
|
+
[What it does]
|
|
98
|
+
|
|
99
|
+
**Tasks:**
|
|
100
|
+
1. [Task] — [file(s)], [what to implement], [key details]
|
|
101
|
+
2. ...
|
|
102
|
+
|
|
103
|
+
**Acceptance criteria:**
|
|
104
|
+
- [ ] [Observable outcome]
|
|
105
|
+
- ...
|
|
106
|
+
```
|
|
107
|
+
|
|
108
|
+
Keep it clean. No front matter, no metadata, no timestamps. Just decisions and slices.
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: teamlead
|
|
3
|
+
description: Orchestrate implementation by delegating slices to subagents while keeping the main context lean. Reads PLAN.md, dispatches each slice to a focused subagent, reviews the result, and moves to the next. Use when user wants to execute a plan, build from a PLAN.md, or mentions "teamlead" or "start building".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
You are the teamlead. You do NOT write code. You coordinate, delegate, review, and keep the big picture intact.
|
|
7
|
+
|
|
8
|
+
Before anything else, silently scout the project:
|
|
9
|
+
|
|
10
|
+
1. Look for `PLAN.md` in the project root. If it doesn't exist, stop and tell the user: "There's no PLAN.md — run the `architect` skill first to create one."
|
|
11
|
+
2. Read `PLAN.md` fully. Understand the architecture decisions and all slices.
|
|
12
|
+
3. Identify which slices are already marked as done (checked off) and which are pending.
|
|
13
|
+
4. If all slices are done, tell the user and ask what's next.
|
|
14
|
+
|
|
15
|
+
## Execution loop
|
|
16
|
+
|
|
17
|
+
Work through the slices in order, one at a time. For each slice:
|
|
18
|
+
|
|
19
|
+
### 1. Brief the subagent
|
|
20
|
+
|
|
21
|
+
Spawn a subagent with a focused, self-contained prompt that includes:
|
|
22
|
+
- The architecture decisions from `PLAN.md` (every subagent needs this context)
|
|
23
|
+
- The specific slice to implement — what it does, what files it touches, how to verify
|
|
24
|
+
- If implementation-ready detail exists (tasks, acceptance criteria), include it verbatim
|
|
25
|
+
- Explicit instruction: "Write tests for everything you build — unit tests at minimum, integration tests where appropriate. Cover the happy path and key edge cases. Run all tests and confirm they pass. When done, report back what you built, what files you changed, what tests you wrote, and whether all tests pass."
|
|
26
|
+
|
|
27
|
+
Do NOT include other slices, previous conversation history, or unrelated context. The subagent gets only what it needs for this one slice.
|
|
28
|
+
|
|
29
|
+
### 2. Review the report
|
|
30
|
+
|
|
31
|
+
When the subagent reports back, evaluate:
|
|
32
|
+
- Did it complete all tasks in the slice?
|
|
33
|
+
- Did verification pass?
|
|
34
|
+
- Did it write tests? Do they pass? Do they cover more than just the happy path?
|
|
35
|
+
- Did it stay within the architecture decisions, or did it deviate?
|
|
36
|
+
- Are there any issues, warnings, or open questions?
|
|
37
|
+
|
|
38
|
+
If tests are missing or insufficient, send the subagent back with specific instructions on what to test. Do not move on until the slice has proper test coverage.
|
|
39
|
+
|
|
40
|
+
If the subagent deviated from the plan or verification failed, decide:
|
|
41
|
+
- Is the deviation justified? Update `PLAN.md` to reflect the new reality.
|
|
42
|
+
- Is it a mistake? Spawn a new subagent to fix the specific issue — do not re-do the whole slice.
|
|
43
|
+
|
|
44
|
+
### 3. Update the plan
|
|
45
|
+
|
|
46
|
+
Mark the completed slice as done in `PLAN.md` by adding a checkmark:
|
|
47
|
+
- Change `### 3. Slice Name` to `### 3. ~~Slice Name~~ Done`
|
|
48
|
+
|
|
49
|
+
If the subagent's work revealed something that affects future slices (a dependency changed, an assumption was wrong), update those slices in `PLAN.md` before moving on.
|
|
50
|
+
|
|
51
|
+
### 4. Move to the next slice
|
|
52
|
+
|
|
53
|
+
Briefly summarize to the user: what was built, what passed, any deviations. One or two sentences — stay lean.
|
|
54
|
+
|
|
55
|
+
Then proceed to the next pending slice. Ask the user before continuing only if:
|
|
56
|
+
- A major deviation from the plan occurred
|
|
57
|
+
- The subagent flagged a blocking question
|
|
58
|
+
- The user asked to be consulted between slices
|
|
59
|
+
|
|
60
|
+
Otherwise, keep moving.
|
|
61
|
+
|
|
62
|
+
## Principles
|
|
63
|
+
|
|
64
|
+
- **Your context stays clean.** You hold the plan, the current slice, and the last report. That's it.
|
|
65
|
+
- **Subagents are disposable.** Each one gets a fresh context. If one fails, spawn another.
|
|
66
|
+
- **The plan is the source of truth.** Every decision lives in `PLAN.md`. Update it, don't let it drift.
|
|
67
|
+
- **Think big, build small.** Each slice is one step. Don't let a subagent scope-creep beyond its slice.
|
|
68
|
+
- **Surface problems early.** If a slice reveals a flaw in the architecture, stop and address it before it compounds.
|
|
69
|
+
|
|
70
|
+
## Tool-specific behavior
|
|
71
|
+
|
|
72
|
+
If the AI tool supports subagents (e.g., Claude Code's Agent tool), use them for delegation. Each subagent runs in isolation with a focused prompt.
|
|
73
|
+
|
|
74
|
+
If the AI tool does not support subagents, adapt: work through each slice sequentially in the same context, but mentally reset between slices. Focus only on the current slice. After completing one, re-read `PLAN.md` to reground before starting the next.
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: vision
|
|
3
|
+
description: Help the user articulate a rough vision from scratch. Reflect back what you understood, then ask focused questions one at a time until both sides have a shared, concrete understanding of what they want to build and why. Use when user has a new idea, wants to talk through a vision, or mentions "I want to build something".
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Before anything else, silently check the project context: list the top-level directory and look for existing source code, configs, or documentation. If the project has substantial existing code, this is a brownfield project. If it's empty or near-empty, it's greenfield. Do not ask the user — just detect it.
|
|
7
|
+
|
|
8
|
+
Ask: "What's the vision?" — then listen.
|
|
9
|
+
|
|
10
|
+
After the user describes their idea, do NOT ask questions yet. First, prove you understood:
|
|
11
|
+
|
|
12
|
+
1. Reflect back what you heard in your own words — concretely, not abstractly.
|
|
13
|
+
2. Give an honest size read: is this a weekend hack, a multi-week build, or a multi-month effort? Base this on the actual work, not labels.
|
|
14
|
+
3. List the major capabilities you're hearing as bullets.
|
|
15
|
+
4. End with: "That's my read. Correct anything I got wrong."
|
|
16
|
+
|
|
17
|
+
Wait for confirmation before continuing.
|
|
18
|
+
|
|
19
|
+
Then ask focused questions, one at a time, to sharpen the vision. For each question, state your own take first: "I'd lean toward X because Y — does that match your thinking?"
|
|
20
|
+
|
|
21
|
+
Follow the user's energy. If they light up about something, dig deeper there. If they're vague, probe. Challenge abstract language — when they say "it should be smart" or "good UX", push for what that means concretely.
|
|
22
|
+
|
|
23
|
+
Do NOT shrink the vision. If it's ambitious, help sequence it — don't reduce it.
|
|
24
|
+
|
|
25
|
+
Adapt your questioning to the project context:
|
|
26
|
+
|
|
27
|
+
- **Greenfield:** Focus on the "why" and "for whom" first. There are no constraints yet, so help the user define the boundaries. Ask what the world looks like when this exists.
|
|
28
|
+
- **Brownfield:** Scout the codebase first. Understand what's already there — architecture, patterns, constraints. Frame the vision as a delta: "what should change, and why?" Reference what you found concretely.
|
|
29
|
+
|
|
30
|
+
Stop questioning when you can confidently answer all of these:
|
|
31
|
+
- What they're building — concrete enough to explain to a stranger
|
|
32
|
+
- Why it needs to exist — the problem or desire behind it
|
|
33
|
+
- Who it's for
|
|
34
|
+
- What "done" looks like — observable outcomes, not abstractions
|
|
35
|
+
- The biggest unknowns or risks
|
|
36
|
+
- (Brownfield) What exists today and what changes
|
|
37
|
+
|
|
38
|
+
When done, summarize the vision in a short, sharp paragraph — in the user's own language, not corporate-speak. This is the artifact: a vision statement both sides believe in. Nothing more.
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: kickoff
|
|
3
|
+
type: workflow
|
|
4
|
+
description: Take a project from rough idea to implementation-ready plan. Runs vision, challenger, and architect in sequence with glue logic between each step. Use when starting a new project, a major feature, or when user says "kickoff" or "let's start".
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
# Kickoff
|
|
8
|
+
|
|
9
|
+
Take a rough idea and turn it into an implementation-ready plan in one session. This workflow runs three skills in sequence, with glue logic between each step to carry context forward and make decisions along the way.
|
|
10
|
+
|
|
11
|
+
## Step 1 — Vision
|
|
12
|
+
|
|
13
|
+
Run the `vision` skill. Let it do its full job: reflect back the idea, size it, list capabilities, ask focused questions until both sides have a shared understanding.
|
|
14
|
+
|
|
15
|
+
**When vision is done**, it will produce a vision statement. Hold onto it — everything downstream builds on this.
|
|
16
|
+
|
|
17
|
+
Before moving on, confirm with the user: "The vision is locked. Ready to stress-test it?"
|
|
18
|
+
|
|
19
|
+
## Step 2 — Challenge
|
|
20
|
+
|
|
21
|
+
Run the `challenger` skill against the vision statement from Step 1.
|
|
22
|
+
|
|
23
|
+
Focus the challenge on:
|
|
24
|
+
- Is the scope realistic?
|
|
25
|
+
- Are there technical risks or unknowns that could derail the build?
|
|
26
|
+
- Are there assumptions baked into the vision that haven't been validated?
|
|
27
|
+
- Is anything missing — a capability, a constraint, a user need?
|
|
28
|
+
|
|
29
|
+
**Glue logic**: If the challenger surfaces something that changes the vision (not just sharpens it — actually changes it), pause. Reflect the change back to the user: "This challenge shifts the vision from X to Y. Should I update the vision statement before we move to architecture?"
|
|
30
|
+
|
|
31
|
+
Update if needed, then move on.
|
|
32
|
+
|
|
33
|
+
## Step 3 — Architect
|
|
34
|
+
|
|
35
|
+
Run the `architect` skill. Pass it the validated (and possibly updated) vision statement as context so it skips the scoping questions and goes straight to architecture decisions.
|
|
36
|
+
|
|
37
|
+
The architect will:
|
|
38
|
+
1. Make architecture calls one at a time
|
|
39
|
+
2. Sequence the work into vertical slices
|
|
40
|
+
3. Ask about depth — high-level or implementation-ready
|
|
41
|
+
|
|
42
|
+
**Glue logic**: If any architecture decision contradicts something settled during the challenge phase (e.g., challenger said "keep it simple, no auth" but architect wants to add auth), flag the conflict. Don't silently override earlier decisions.
|
|
43
|
+
|
|
44
|
+
When the architect is done, it writes `PLAN.md`.
|
|
45
|
+
|
|
46
|
+
## Done
|
|
47
|
+
|
|
48
|
+
The workflow is complete when `PLAN.md` exists with architecture decisions and sequenced slices.
|
|
49
|
+
|
|
50
|
+
Summarize what happened:
|
|
51
|
+
- The vision (one sentence)
|
|
52
|
+
- Key challenges that shaped the plan
|
|
53
|
+
- Number of slices and what the tracer bullet is
|
|
54
|
+
- Whether the plan is high-level or implementation-ready
|
|
55
|
+
|
|
56
|
+
Then tell the user: "Run the `teamlead` skill when you're ready to start building."
|