luckiest-co 1.0.9 → 1.0.11
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/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +1 -1
- package/bin/install.js +46 -0
- package/commands/finish.md +27 -0
- package/commands/go.md +27 -0
- package/commands/plan.md +27 -0
- package/package.json +1 -1
- package/skills/luckiest-finish/SKILL.md +79 -0
- package/skills/luckiest-go/SKILL.md +92 -0
- package/skills/luckiest-plan/SKILL.md +98 -0
package/bin/install.js
CHANGED
|
@@ -212,6 +212,7 @@ async function syncSkills() {
|
|
|
212
212
|
console.log(` ${green}✓${reset} Removed duplicate commands/luckiest (plugin marketplace already provides them)`);
|
|
213
213
|
}
|
|
214
214
|
|
|
215
|
+
nudgeStaleInstall(globalDir);
|
|
215
216
|
nudgeUsageHook(globalDir);
|
|
216
217
|
|
|
217
218
|
const key = readSavedKey();
|
|
@@ -478,6 +479,51 @@ function nudgeUsageHook(globalClaudeDir) {
|
|
|
478
479
|
console.log(` ${dim}Skill usage tracking is off. Run ${cyan}npx luckiest-co@latest --hook${dim} to turn it on.${reset}`);
|
|
479
480
|
}
|
|
480
481
|
|
|
482
|
+
/**
|
|
483
|
+
* Numeric semver-ish compare. Returns >0 when a is newer than b.
|
|
484
|
+
* String compare would read "0.1.10" as older than "0.1.9", which is exactly
|
|
485
|
+
* the version pair this shipped on.
|
|
486
|
+
*/
|
|
487
|
+
function compareVersions(a, b) {
|
|
488
|
+
const pa = String(a).split('.').map((n) => parseInt(n, 10) || 0);
|
|
489
|
+
const pb = String(b).split('.').map((n) => parseInt(n, 10) || 0);
|
|
490
|
+
for (let i = 0; i < Math.max(pa.length, pb.length); i += 1) {
|
|
491
|
+
const diff = (pa[i] || 0) - (pb[i] || 0);
|
|
492
|
+
if (diff !== 0) return diff;
|
|
493
|
+
}
|
|
494
|
+
return 0;
|
|
495
|
+
}
|
|
496
|
+
|
|
497
|
+
function readPluginVersion(root) {
|
|
498
|
+
try {
|
|
499
|
+
return JSON.parse(fs.readFileSync(path.join(root, '.claude-plugin', 'plugin.json'), 'utf8')).version || null;
|
|
500
|
+
} catch {
|
|
501
|
+
return null;
|
|
502
|
+
}
|
|
503
|
+
}
|
|
504
|
+
|
|
505
|
+
/**
|
|
506
|
+
* Tell people when their installed copy is behind.
|
|
507
|
+
*
|
|
508
|
+
* Both update paths are pull-based, so someone who installed once can sit on an
|
|
509
|
+
* old copy indefinitely with nothing to tell them. Sync runs every session, and
|
|
510
|
+
* `npx luckiest-co@latest` always fetches the newest package, so the version
|
|
511
|
+
* this process is running from is by definition current — comparing it against
|
|
512
|
+
* the copy on disk needs no server call.
|
|
513
|
+
*
|
|
514
|
+
* Silent when current, when nothing is installed to compare against, or when
|
|
515
|
+
* the marketplace plugin is in charge (that copy updates through Claude's own
|
|
516
|
+
* plugin menu, not this installer).
|
|
517
|
+
*/
|
|
518
|
+
function nudgeStaleInstall(globalClaudeDir) {
|
|
519
|
+
if (hasMarketplacePlugin(globalClaudeDir)) return;
|
|
520
|
+
const installed = readPluginVersion(globalClaudeDir);
|
|
521
|
+
const current = readPluginVersion(path.join(__dirname, '..'));
|
|
522
|
+
if (!installed || !current) return;
|
|
523
|
+
if (compareVersions(current, installed) <= 0) return;
|
|
524
|
+
console.log(` ${dim}Your Luckiest install is ${cyan}v${installed}${dim}, latest is ${cyan}v${current}${dim}. Run ${cyan}npx luckiest-co@latest${dim} to update.${reset}`);
|
|
525
|
+
}
|
|
526
|
+
|
|
481
527
|
/**
|
|
482
528
|
* Register the PostToolUse(Skill) telemetry hook in the user's settings.json.
|
|
483
529
|
*
|
package/commands/finish.md
CHANGED
|
@@ -4,6 +4,33 @@ description: Wrap up, what shipped, what changed, what's next.
|
|
|
4
4
|
|
|
5
5
|
Read `references/vocabulary.md` first and follow it for all output in this command: plain language, no em dashes, no internal terms, one next-step recommendation at the end.
|
|
6
6
|
|
|
7
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
8
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
9
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
10
|
+
|
|
11
|
+
So, every time this command says to use AskUserQuestion:
|
|
12
|
+
|
|
13
|
+
- If the tool is available, use it exactly as written.
|
|
14
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
15
|
+
same options, and tell the user to reply with a number or type their own
|
|
16
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
17
|
+
|
|
18
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
19
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
20
|
+
and never merge several questions into one just because they are text.
|
|
21
|
+
|
|
22
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
23
|
+
"Make changes" becomes:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
Here's your plan, good to go?
|
|
27
|
+
|
|
28
|
+
1. Good to go
|
|
29
|
+
2. Make changes
|
|
30
|
+
|
|
31
|
+
Reply with a number, or tell me what to change.
|
|
32
|
+
```
|
|
33
|
+
|
|
7
34
|
## Step 1: Check that everything is done
|
|
8
35
|
|
|
9
36
|
Derive the project key as described in `references/project-key.md`. Pass this same `project` value on both luckiest plan tool calls in this command (`status` here and `finish` in Step 3), so you close this project's plan and not another one.
|
package/commands/go.md
CHANGED
|
@@ -4,6 +4,33 @@ description: Run your plan, one task at a time, checked as it goes.
|
|
|
4
4
|
|
|
5
5
|
Read `references/vocabulary.md` first and follow it for all output in this command: plain language, no em dashes, no internal terms, one next-step recommendation at the end.
|
|
6
6
|
|
|
7
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
8
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
9
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
10
|
+
|
|
11
|
+
So, every time this command says to use AskUserQuestion:
|
|
12
|
+
|
|
13
|
+
- If the tool is available, use it exactly as written.
|
|
14
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
15
|
+
same options, and tell the user to reply with a number or type their own
|
|
16
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
17
|
+
|
|
18
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
19
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
20
|
+
and never merge several questions into one just because they are text.
|
|
21
|
+
|
|
22
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
23
|
+
"Make changes" becomes:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
Here's your plan, good to go?
|
|
27
|
+
|
|
28
|
+
1. Good to go
|
|
29
|
+
2. Make changes
|
|
30
|
+
|
|
31
|
+
Reply with a number, or tell me what to change.
|
|
32
|
+
```
|
|
33
|
+
|
|
7
34
|
## Step 1: Load the plan
|
|
8
35
|
|
|
9
36
|
Derive the project key as described in `references/project-key.md`. Pass this same `project` value on every luckiest plan tool call in this command (`status`, `apply`, `verify`, `pause`), so you run this project's plan and not another one.
|
package/commands/plan.md
CHANGED
|
@@ -4,6 +4,33 @@ description: Plan your next piece of work. Guided questions, then a plan Claude
|
|
|
4
4
|
|
|
5
5
|
Read `references/vocabulary.md` first and follow it for all output in this command: plain language, no em dashes, no internal terms, one next-step recommendation at the end.
|
|
6
6
|
|
|
7
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
8
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
9
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
10
|
+
|
|
11
|
+
So, every time this command says to use AskUserQuestion:
|
|
12
|
+
|
|
13
|
+
- If the tool is available, use it exactly as written.
|
|
14
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
15
|
+
same options, and tell the user to reply with a number or type their own
|
|
16
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
17
|
+
|
|
18
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
19
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
20
|
+
and never merge several questions into one just because they are text.
|
|
21
|
+
|
|
22
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
23
|
+
"Make changes" becomes:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
Here's your plan, good to go?
|
|
27
|
+
|
|
28
|
+
1. Good to go
|
|
29
|
+
2. Make changes
|
|
30
|
+
|
|
31
|
+
Reply with a number, or tell me what to change.
|
|
32
|
+
```
|
|
33
|
+
|
|
7
34
|
## Step 1: Gather context
|
|
8
35
|
|
|
9
36
|
Check whether `.luckiest/BRIEF.md` exists in the current project. If it exists, read it and use it as context for the interview below (what they're building, who it's for, what winning looks like). If it does not exist, continue without it.
|
package/package.json
CHANGED
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: luckiest-finish
|
|
3
|
+
description: Wrap up a completed Luckiest plan: recap what shipped, close it out, award charms. Use when the user says /luckiest finish, luckiest finish, or all plan tasks are done.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Vocabulary rules for all output: plain language, no em dashes, no internal terms. Never surface internal words like PLAN, APPLY, UNIFY, skill_loop, UAT, AC, HANDOFF, DRAFT, DOING in user-visible output; say plan, go, finish, status, testing, requirements, ready for review, in progress, active, complete instead. End every response with exactly one next-step line in the form `Next: <one action>`.
|
|
7
|
+
|
|
8
|
+
Project key for luckiest MCP plan tool calls: if a shell is available, run `git config --get remote.origin.url` and normalize to `host/owner/repo` (lowercase, no `.git`); if not a git repo, use the absolute path from `pwd`. If there is no shell at all (web chat, Cowork), omit `project` entirely. Use the same value on every plan tool call this whole session.
|
|
9
|
+
|
|
10
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
11
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
12
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
13
|
+
|
|
14
|
+
So, every time this command says to use AskUserQuestion:
|
|
15
|
+
|
|
16
|
+
- If the tool is available, use it exactly as written.
|
|
17
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
18
|
+
same options, and tell the user to reply with a number or type their own
|
|
19
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
20
|
+
|
|
21
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
22
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
23
|
+
and never merge several questions into one just because they are text.
|
|
24
|
+
|
|
25
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
26
|
+
"Make changes" becomes:
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
Here's your plan, good to go?
|
|
30
|
+
|
|
31
|
+
1. Good to go
|
|
32
|
+
2. Make changes
|
|
33
|
+
|
|
34
|
+
Reply with a number, or tell me what to change.
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Step 1: Check that everything is done
|
|
38
|
+
|
|
39
|
+
Derive the project key as described in the project key rules above. Pass this same `project` value on both luckiest plan tool calls in this command (`status` here and `finish` in Step 3), so you close this project's plan and not another one.
|
|
40
|
+
|
|
41
|
+
Call the `status` tool from the luckiest MCP server with that `project` value.
|
|
42
|
+
|
|
43
|
+
If any task is still open (not complete), list those tasks for the user and stop here. Do not proceed to the rest of this command. End your response with exactly one line, nothing after it:
|
|
44
|
+
|
|
45
|
+
Next: /luckiest go
|
|
46
|
+
|
|
47
|
+
## Step 2: Compose the recap
|
|
48
|
+
|
|
49
|
+
If every task is complete, write a short recap in chat with these sections:
|
|
50
|
+
|
|
51
|
+
- **Shipped**: what got built or changed, in plain terms.
|
|
52
|
+
- **Decisions**: any notable choices made along the way and why.
|
|
53
|
+
- **Key files**: the main files touched, so the user knows where to look.
|
|
54
|
+
- **Deferred**: anything explicitly pushed off, if applicable. Say "none" if there's nothing deferred.
|
|
55
|
+
|
|
56
|
+
## Step 3: Close it out
|
|
57
|
+
|
|
58
|
+
After the recap, confirm with the AskUserQuestion tool so the user can click instead of typing. Question: "Close this out and award charms?" Options: "Close it out" and "Not yet" (keep the "Other" free-text choice available). Only continue on "Close it out"; on "Not yet", stop and end with `Next: /luckiest go` so they can keep working.
|
|
59
|
+
|
|
60
|
+
Call the `finish` tool from the luckiest MCP server with:
|
|
61
|
+
|
|
62
|
+
```
|
|
63
|
+
{ project: <the project key from Step 1>, decisions, keyFiles, deferred }
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
using the same lists from your recap. This awards Charms and archives the history automatically.
|
|
67
|
+
|
|
68
|
+
Report the Charms earned in friendly, plain terms, for example: "You earned 3 charms."
|
|
69
|
+
|
|
70
|
+
## Step 4: Wrap up
|
|
71
|
+
|
|
72
|
+
Offer the next move with the AskUserQuestion tool so the user can click instead of retyping a command. Question: "What's next?" Options (keep the "Other" free-text choice available):
|
|
73
|
+
|
|
74
|
+
- "Plan the next piece" — on this pick, start the `/luckiest plan` flow now, fresh, as if newly invoked.
|
|
75
|
+
- "See where I stand" — on this pick, run the `/luckiest home` flow now.
|
|
76
|
+
|
|
77
|
+
Whichever they click, start that flow immediately in this session so they never have to type the command themselves. If they pick "Other" or dismiss, end with exactly one line, nothing after it:
|
|
78
|
+
|
|
79
|
+
Next: /luckiest plan for the next piece, or /luckiest home to see where you stand.
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: luckiest-go
|
|
3
|
+
description: Run the active Luckiest plan, one task at a time, checked as it goes. Use when the user says /luckiest go, luckiest go, or wants to continue their staged Luckiest plan.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Vocabulary rules for all output: plain language, no em dashes, no internal terms. Never surface internal words like PLAN, APPLY, UNIFY, skill_loop, UAT, AC, HANDOFF, DRAFT, DOING in user-visible output; say plan, go, finish, status, testing, requirements, ready for review, in progress, active, complete instead. End every response with exactly one next-step line in the form `Next: <one action>`.
|
|
7
|
+
|
|
8
|
+
Project key for luckiest MCP plan tool calls: if a shell is available, run `git config --get remote.origin.url` and normalize to `host/owner/repo` (lowercase, no `.git`); if not a git repo, use the absolute path from `pwd`. If there is no shell at all (web chat, Cowork), omit `project` entirely. Use the same value on every plan tool call this whole session.
|
|
9
|
+
|
|
10
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
11
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
12
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
13
|
+
|
|
14
|
+
So, every time this command says to use AskUserQuestion:
|
|
15
|
+
|
|
16
|
+
- If the tool is available, use it exactly as written.
|
|
17
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
18
|
+
same options, and tell the user to reply with a number or type their own
|
|
19
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
20
|
+
|
|
21
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
22
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
23
|
+
and never merge several questions into one just because they are text.
|
|
24
|
+
|
|
25
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
26
|
+
"Make changes" becomes:
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
Here's your plan, good to go?
|
|
30
|
+
|
|
31
|
+
1. Good to go
|
|
32
|
+
2. Make changes
|
|
33
|
+
|
|
34
|
+
Reply with a number, or tell me what to change.
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Step 1: Load the plan
|
|
38
|
+
|
|
39
|
+
Derive the project key as described in the project key rules above. Pass this same `project` value on every luckiest plan tool call in this command (`status`, `apply`, `verify`, `pause`), so you run this project's plan and not another one.
|
|
40
|
+
|
|
41
|
+
Call the `status` tool from the luckiest MCP server with that `project` value. This is a zero-context resume, treat its result as the full picture of where things stand: don't assume anything about prior state beyond what it returns.
|
|
42
|
+
|
|
43
|
+
## Step 2: Pick how to run
|
|
44
|
+
|
|
45
|
+
Default: do all task work yourself, in this session, message by message. This is the safe, reviewable mode.
|
|
46
|
+
|
|
47
|
+
Fast mode (subagents): if the user wants tasks done faster, you may hand a ready task to a subagent instead of doing it yourself. Only do this when the user has asked to go fast, or says yes when you offer it.
|
|
48
|
+
|
|
49
|
+
Before dispatching anything, check that you can actually assign agents: confirm the Agent (or Task) tool is available in this session. If it is not, say so plainly and fall back to default mode. Never claim work was handed off to a subagent you could not launch.
|
|
50
|
+
|
|
51
|
+
When you do run in fast mode, assign work top down in this order: subagents > tasks > skills > model.
|
|
52
|
+
|
|
53
|
+
- Subagents: one subagent owns a task. Independent tasks run in parallel; tasks that depend on an earlier one wait for it.
|
|
54
|
+
- Tasks: give each subagent one ready task from `status`, turned into a tight working prompt.
|
|
55
|
+
- Skills: inside its task, the subagent invokes the task's suggested skill via the Skill tool.
|
|
56
|
+
- Model: run each subagent on the task's `model` hint from `status` (light work like haiku, heavy work like opus), so each task uses the smallest model that fits and saves tokens.
|
|
57
|
+
|
|
58
|
+
You still own Step 3's checks: read the subagent's result, hold it to the "done means..." line, and only then apply and verify.
|
|
59
|
+
|
|
60
|
+
Research subagents (looking something up, exploring the codebase) are always allowed in either mode.
|
|
61
|
+
|
|
62
|
+
## Step 3: Work through ready tasks, one at a time
|
|
63
|
+
|
|
64
|
+
Take the ready tasks one at a time, in order. For each one:
|
|
65
|
+
|
|
66
|
+
1. First, turn the task into a tight working prompt with the `luckiest-prompt-rewrite` skill, targeting whoever will do the work (yourself, or the subagent and its model from Step 2). Use that rewritten prompt to do the task. If the skill is not installed, write a clear prompt yourself and continue. Do this before every task, in both default and fast mode.
|
|
67
|
+
2. Do the work using the task's suggested skill. If that skill is installed, invoke it via the Skill tool. If it isn't installed, do the work directly without it.
|
|
68
|
+
3. Check your result against the task's "done means..." line. Don't move on until it's actually met.
|
|
69
|
+
4. If the result is something the user can try themselves (a page, a feature, a flow), ask with the AskUserQuestion tool so they can click instead of typing. Question: "Try it yourself, does it work?" Options: "Works" and "Needs fixes" (keep the "Other" free-text choice available). Wait for their answer.
|
|
70
|
+
5. On a pass, call the `apply` tool with `{ project, taskId }` for that task, then call the `verify` tool with `{ project, results: [{ taskId, pass: true }] }`. Use the same `project` from Step 1.
|
|
71
|
+
6. On a fail, fix the problem before moving on to the next task. Only call `verify` with `pass: false` for that task if the user explicitly chooses to defer the fix instead of having you fix it now.
|
|
72
|
+
|
|
73
|
+
Only move to the next ready task once the current one is applied and verified (or deferred).
|
|
74
|
+
|
|
75
|
+
After a task passes and is verified, run a quick automation check. Ask yourself: was this task repeatable, rule-based, or the kind of thing that will come up again? If yes, offer it with the AskUserQuestion tool so the user can click instead of typing. Question: "This looks worth automating. Turn it into a skill you can schedule or run as a routine?" Options: "Automate it" and "Skip" (keep the "Other" free-text choice available). Only offer, never build it without a yes. If they say yes, create the skill (with the skill-builder or skill-creator skill) and set it up to run on a schedule or as a routine. If the task was a one-off, skip the offer and move on.
|
|
76
|
+
|
|
77
|
+
## Step 4: Stop conditions
|
|
78
|
+
|
|
79
|
+
Pause and ask the user before doing any of the following, even if it seems like the obvious next step:
|
|
80
|
+
|
|
81
|
+
- Any destructive action (deleting data, dropping tables, force-pushing, overwriting files with no way back).
|
|
82
|
+
- Adding a new dependency.
|
|
83
|
+
- Any schema change.
|
|
84
|
+
|
|
85
|
+
If the session has to end before the plan is done, call the `pause` tool with `{ project, reason }` (same `project` from Step 1), a one-line reason describing where things were left.
|
|
86
|
+
|
|
87
|
+
## Step 5: Wrap up
|
|
88
|
+
|
|
89
|
+
End your response with exactly one line, nothing after it.
|
|
90
|
+
|
|
91
|
+
- If all tasks are done: `Next: /luckiest finish to wrap up.`
|
|
92
|
+
- Otherwise: `Next: <the next task title>.`
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: luckiest-plan
|
|
3
|
+
description: Plan your next piece of work with Luckiest. Guided questions, then a staged plan Claude can run. Use when the user says /luckiest plan, luckiest plan, or wants to plan work with their Luckiest tribe.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
Vocabulary rules for all output: plain language, no em dashes, no internal terms. Never surface internal words like PLAN, APPLY, UNIFY, skill_loop, UAT, AC, HANDOFF, DRAFT, DOING in user-visible output; say plan, go, finish, status, testing, requirements, ready for review, in progress, active, complete instead. End every response with exactly one next-step line in the form `Next: <one action>`.
|
|
7
|
+
|
|
8
|
+
Project key for luckiest MCP plan tool calls: if a shell is available, run `git config --get remote.origin.url` and normalize to `host/owner/repo` (lowercase, no `.git`); if not a git repo, use the absolute path from `pwd`. If there is no shell at all (web chat, Cowork), omit `project` entirely. Use the same value on every plan tool call this whole session.
|
|
9
|
+
|
|
10
|
+
Asking the user a question: this command tells you to use the AskUserQuestion tool
|
|
11
|
+
so the user can click instead of typing. That tool only exists in Claude Code. In
|
|
12
|
+
web chat and Cowork it is not there, and waiting for it will stall the command.
|
|
13
|
+
|
|
14
|
+
So, every time this command says to use AskUserQuestion:
|
|
15
|
+
|
|
16
|
+
- If the tool is available, use it exactly as written.
|
|
17
|
+
- If it is not, ask the same question in plain chat as a numbered list of the
|
|
18
|
+
same options, and tell the user to reply with a number or type their own
|
|
19
|
+
answer. Treat a typed answer the same as the "Other" free-text choice.
|
|
20
|
+
|
|
21
|
+
The options, their order, and their wording stay the same either way. Only the
|
|
22
|
+
delivery changes. Never skip a question, never answer it on the user's behalf,
|
|
23
|
+
and never merge several questions into one just because they are text.
|
|
24
|
+
|
|
25
|
+
For example, "Here's your plan, good to go?" with options "Good to go" and
|
|
26
|
+
"Make changes" becomes:
|
|
27
|
+
|
|
28
|
+
```
|
|
29
|
+
Here's your plan, good to go?
|
|
30
|
+
|
|
31
|
+
1. Good to go
|
|
32
|
+
2. Make changes
|
|
33
|
+
|
|
34
|
+
Reply with a number, or tell me what to change.
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Step 1: Gather context
|
|
38
|
+
|
|
39
|
+
Check whether `.luckiest/BRIEF.md` exists in the current project. If it exists, read it and use it as context for the interview below (what they're building, who it's for, what winning looks like). If it does not exist, continue without it.
|
|
40
|
+
|
|
41
|
+
## Step 2: Check for active work
|
|
42
|
+
|
|
43
|
+
Derive the project key as described in the project key rules above. Pass this same `project` value on every luckiest plan tool call in this command (`status` here and `plan` in Step 5), so this project gets its own plan and does not collide with another project's.
|
|
44
|
+
|
|
45
|
+
Call the `status` tool from the luckiest MCP server with that `project` value.
|
|
46
|
+
|
|
47
|
+
- If the returned state's position is active (already in progress), stop here. Tell the user a plan is already active and offer `/luckiest go` to resume it instead. Do not stage a new plan over an active one unless the user explicitly confirms they want to replace it. If they confirm, continue to Step 3.
|
|
48
|
+
- Otherwise, continue to Step 3.
|
|
49
|
+
|
|
50
|
+
## Step 3: Run the interview
|
|
51
|
+
|
|
52
|
+
Open the interview with a short line that says no plan is active and you are starting the interview.
|
|
53
|
+
|
|
54
|
+
Then ask question 1 using the AskUserQuestion tool so the user can click an answer instead of typing one. Do not put the examples in plain text for them to copy. Present them as selectable options:
|
|
55
|
+
|
|
56
|
+
1. Let's confirm what best describes the outcome you want
|
|
57
|
+
|
|
58
|
+
Build 3 to 4 options for that question. Draw them from their brief if one exists, otherwise use plausible outcomes for their project (for example: "About page rewritten to explain the full skills network, live on luckiest.co"). Keep the "Other" free-text choice available so they can still write their own outcome if none fit.
|
|
59
|
+
|
|
60
|
+
Use the picked option (or their typed answer) plus the brief, if present, to shape the plan.
|
|
61
|
+
|
|
62
|
+
Use the answer (plus the brief, if present) to shape a draft task list of 3 to 7 tasks. Each task title must be a single clean line under 200 characters, describing one piece of work. Do not append "done means" text or any acceptance-criteria text to the title.
|
|
63
|
+
|
|
64
|
+
Include non-coding work too. Marketing, content, design, research, and ops tasks belong in the plan alongside code. Never drop a task just because it is not a coding task; route it to its matching skill like any other.
|
|
65
|
+
|
|
66
|
+
For each draft task, call the `skill_router` tool from the luckiest MCP server. It returns `skills` (matching owned skills) and `who` (up to 3 tribe members who finished a similar task before). Attach the suggested skill(s) to the task, and attach `who` so the plan can carry who has done this kind of work.
|
|
67
|
+
|
|
68
|
+
For each task, state a one-line "done means..." in chat (not in the title, not stored anywhere) so the user sees what complete looks like for that task. When `who` is not empty, add a short line naming those people, for example "Done before by: **Sam**, **Alex**."
|
|
69
|
+
|
|
70
|
+
Whenever you name a skill or a person in your output, wrap it in markdown bold so it stands out, for example **Copywriting** or **Sam**. Bold the skill and person names everywhere they appear in this command, both in the draft plan and in the "done means..." and "done before by" lines.
|
|
71
|
+
|
|
72
|
+
## Step 4: Present the plan
|
|
73
|
+
|
|
74
|
+
Show the full draft plan: each task's title, its suggested skill(s), and its "done means..." line. Then ask exactly one approval question using the AskUserQuestion tool so the user can click instead of typing. Use "Here's your plan, good to go?" as the question, with these options (keep the "Other" free-text choice available for anything else):
|
|
75
|
+
|
|
76
|
+
- "Good to go" — stage the plan as shown.
|
|
77
|
+
- "Make changes" — the user wants edits before staging.
|
|
78
|
+
|
|
79
|
+
Wait for the answer.
|
|
80
|
+
|
|
81
|
+
- If the user picks "Make changes" (or types their own edit), revise the plan and ask the same approval question again.
|
|
82
|
+
- If the user picks "Good to go", continue to Step 5.
|
|
83
|
+
|
|
84
|
+
## Step 5: Stage the plan
|
|
85
|
+
|
|
86
|
+
Call the `plan` tool from the luckiest MCP server with:
|
|
87
|
+
|
|
88
|
+
```
|
|
89
|
+
{ project: <the project key from Step 2>, phase: <short phase name if any>, tasks: [{ title, skills, who }] }
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
Pass the `who` list you got from `skill_router` for each task so the plan keeps who has done this kind of work before.
|
|
93
|
+
|
|
94
|
+
Include at most 25 tasks. Each title must stay under 200 characters. Do not include acceptance criteria or "done means" text in any task field.
|
|
95
|
+
|
|
96
|
+
## Step 6: Start it
|
|
97
|
+
|
|
98
|
+
Once the plan is staged, do not make the user type the next command. Start the `/luckiest go` flow now, fresh, as if newly invoked, so the first task begins immediately in this session.
|