@skill-map/cli 0.25.0 → 0.26.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.
- package/dist/cli/tutorial/sm-master.md +66 -19
- package/dist/cli/tutorial/sm-tutorial.md +231 -116
- package/dist/cli.js +194 -46
- package/dist/cli.js.map +1 -1
- package/dist/index.js +22 -1
- package/dist/index.js.map +1 -1
- package/dist/kernel/index.js +22 -1
- package/dist/kernel/index.js.map +1 -1
- package/dist/ui/{chunk-BK4M46IZ.js → chunk-4GTCV7V4.js} +1 -1
- package/dist/ui/{chunk-533YMAY3.js → chunk-PY2R7LHN.js} +2 -2
- package/dist/ui/{chunk-N5FAET6D.js → chunk-Q64EKSUB.js} +1 -1
- package/dist/ui/chunk-VH5GRUT7.js +255 -0
- package/dist/ui/{chunk-RR36XBDS.js → chunk-WOLLYGGL.js} +1 -1
- package/dist/ui/index.html +2 -2
- package/dist/ui/main-CYRAD3L6.js +2 -0
- package/dist/ui/{styles-DLFC3F2G.css → styles-EGXMA46P.css} +1 -1
- package/package.json +2 -2
- package/dist/ui/chunk-O546Z3K4.js +0 -251
- package/dist/ui/main-QPX4WBVF.js +0 -2
|
@@ -51,7 +51,11 @@ must internalise before talking to the tester:
|
|
|
51
51
|
- **Language mirroring**: if the tester's first message is in
|
|
52
52
|
Spanish, run the conversation in **neutral Spanish (tú-form, not
|
|
53
53
|
rioplatense)**, e.g. `puedes`, `prueba`, `mira`, NOT `podés`,
|
|
54
|
-
`probá`, `mirá`. If in English, plain English.
|
|
54
|
+
`probá`, `mirá`. If in English, plain English. Also avoid
|
|
55
|
+
overly colloquial imperatives even when they're grammatical:
|
|
56
|
+
prefer `espera` / `aguarda` over `aguanta`, `revisa` over
|
|
57
|
+
`chequea`, `observa` / `fíjate en` over `fijate`. Casual is
|
|
58
|
+
OK; slangy is not.
|
|
55
59
|
- **Vocabulary translation (Spanish)**: same equivalences as
|
|
56
60
|
`sm-tutorial` (`kind → tipo`, `watcher → observador`, `scan` verb
|
|
57
61
|
→ `escanear`, `scan` noun → `escaneo`, `node → nodo`, `link →
|
|
@@ -118,6 +122,33 @@ must internalise before talking to the tester:
|
|
|
118
122
|
All command blocks assume the second terminal is anchored to the
|
|
119
123
|
fixture folder.
|
|
120
124
|
|
|
125
|
+
## Provider detection
|
|
126
|
+
|
|
127
|
+
Same logic as `sm-tutorial`'s §Provider detection. Recap:
|
|
128
|
+
|
|
129
|
+
| Provider | Base dir | Kinds claimed | Env-var signal |
|
|
130
|
+
|----------------|-----------------------|------------------------------|-------------------------------------------------|
|
|
131
|
+
| `claude` | `.claude/` | `agent`, `command`, `skill` | `CLAUDECODE=1` OR `AI_AGENT` starts with `claude-code` |
|
|
132
|
+
| `gemini` | `.gemini/` | `agent`, `skill` | `GEMINI_CLI=1` OR `AI_AGENT` starts with `gemini` |
|
|
133
|
+
| `agent-skills` | `.agents/skills/` | `skill` only | no formal env yet, opt-in if the tester asks |
|
|
134
|
+
|
|
135
|
+
**During pre-flight**, inspect the env, pick the provider, and
|
|
136
|
+
persist it into `master-state.yml.master.provider`. Fallback to
|
|
137
|
+
`claude` with a one-line heads-up if nothing matched (verbatim
|
|
138
|
+
fallback blockquote in `sm-tutorial`, copy it here).
|
|
139
|
+
|
|
140
|
+
**Global substitution rule**: wherever this file (or any module
|
|
141
|
+
file) says `.claude/<…>`, swap it for the detected
|
|
142
|
+
`<provider_dir>`. Skip any fixture file or step whose kind is
|
|
143
|
+
not in the provider's supported set (`gemini`: skip the
|
|
144
|
+
`master-command`-style stub if a module references one;
|
|
145
|
+
`agent-skills`: only the skill + the markdown note are valid).
|
|
146
|
+
|
|
147
|
+
**Reality check (don't mention)**: this skill ships at
|
|
148
|
+
`.claude/skills/sm-master/`, so in practice Claude Code is the
|
|
149
|
+
only host today. The detection wiring is here so mirrored skills
|
|
150
|
+
in `.gemini/skills/` / `.agents/skills/` reuse it as-is.
|
|
151
|
+
|
|
121
152
|
## Pre-flight
|
|
122
153
|
|
|
123
154
|
### 1. Verify the working directory (empty dir)
|
|
@@ -224,23 +255,26 @@ without further commentary:
|
|
|
224
255
|
|
|
225
256
|
> Quick heads-up before we start: I'm about to set up the
|
|
226
257
|
> scenario for this tutorial in your directory, that means
|
|
227
|
-
> creating a handful of files.
|
|
258
|
+
> creating a handful of files. Please wait a moment while I finish.
|
|
228
259
|
|
|
229
260
|
The fixture is **smaller than `sm-tutorial`'s** because the lessons
|
|
230
261
|
focus on plugins, settings, and slots, not on graph topology. Three
|
|
231
262
|
nodes are enough. Read `references/fixture-templates.md` for the
|
|
232
|
-
verbatim layout and file contents, then write each
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
263
|
+
verbatim layout and file contents, then write each file to the cwd
|
|
264
|
+
under the detected `<provider_dir>` (per §Provider detection).
|
|
265
|
+
**Skip files whose kind is not in the provider's supported set**:
|
|
266
|
+
on `gemini` keep agent + skill + note; on `agent-skills` keep only
|
|
267
|
+
skill + note (no agent kind there). Translate the natural-language
|
|
268
|
+
prose to the tester's language; keep paths, frontmatter keys,
|
|
269
|
+
identifiers, and link targets in English.
|
|
237
270
|
|
|
238
271
|
### 4. Generate `master-state.yml`
|
|
239
272
|
|
|
240
273
|
Read the `## State YAML` block at the bottom of
|
|
241
274
|
`references/fixture-templates.md` and write it to
|
|
242
|
-
`<cwd>/master-state.yml`. Substitute the
|
|
243
|
-
`<ISO-8601 now>`, `<output of pwd>`,
|
|
275
|
+
`<cwd>/master-state.yml`. Substitute the four placeholders:
|
|
276
|
+
`<ISO-8601 now>`, `<output of pwd>`, `<output of sm version>`,
|
|
277
|
+
and the resolved `provider` (`claude` / `gemini` / `agent-skills`).
|
|
244
278
|
|
|
245
279
|
## Menu
|
|
246
280
|
|
|
@@ -324,6 +358,12 @@ and re-render the menu.
|
|
|
324
358
|
|
|
325
359
|
## Final wrap-up
|
|
326
360
|
|
|
361
|
+
<!-- TODO(arquitecto): remove the "send findings to Pusher" flow from
|
|
362
|
+
this tutorial. It is not part of the roadmap v1 surface and the
|
|
363
|
+
Pusher hand-off should not appear in the public tester experience.
|
|
364
|
+
Strip the report-to-Pusher offer, the `sm-master-report.md`
|
|
365
|
+
template, and any closing copy that names Pusher. -->
|
|
366
|
+
|
|
327
367
|
When the tester picks option 4 or signals they are done, **offer to
|
|
328
368
|
generate a report file to send to Pusher**:
|
|
329
369
|
|
|
@@ -409,8 +449,11 @@ anything**:
|
|
|
409
449
|
> and re-invoke me from there, or delete `master-state.yml` by
|
|
410
450
|
> hand if you really want to start fresh here.
|
|
411
451
|
|
|
412
|
-
2. If the cwd matches,
|
|
413
|
-
|
|
452
|
+
2. If the cwd matches, read `master.provider` from the yaml and
|
|
453
|
+
use it to compute `<provider_dir>` plus the subset of files
|
|
454
|
+
actually created (gemini and agent-skills drop some). Show the
|
|
455
|
+
resolved list to the tester and ask for the literal
|
|
456
|
+
`yes, wipe` confirmation:
|
|
414
457
|
|
|
415
458
|
> Start over will delete these paths from `<cwd>`:
|
|
416
459
|
>
|
|
@@ -419,21 +462,25 @@ anything**:
|
|
|
419
462
|
> findings.md
|
|
420
463
|
> .skillmapignore
|
|
421
464
|
> .skill-map/
|
|
422
|
-
>
|
|
423
|
-
>
|
|
424
|
-
> .
|
|
465
|
+
> <provider_dir>/agents/master-agent.md (claude, gemini)
|
|
466
|
+
> <provider_dir>/skills/master-skill/ (all three)
|
|
467
|
+
> .skill-map/plugins/ (if any module created some)
|
|
425
468
|
> notes/ideas.md
|
|
426
|
-
> sm-master-report.md
|
|
469
|
+
> sm-master-report.md (if present)
|
|
427
470
|
> ```
|
|
428
471
|
>
|
|
429
472
|
> Type **`yes, wipe`** (exact text) to confirm. Anything else
|
|
430
473
|
> cancels.
|
|
431
474
|
|
|
475
|
+
Render the ACTUAL list (substitute `<provider_dir>` and drop
|
|
476
|
+
rows the saved provider did not create) so the tester sees real
|
|
477
|
+
paths.
|
|
478
|
+
|
|
432
479
|
3. Only on the literal `yes, wipe` reply, delete those exact
|
|
433
|
-
paths. Do NOT recursively `rm -rf`
|
|
434
|
-
directories, only the specific tutorial-owned files
|
|
435
|
-
After deletion, `rmdir` empty parents silently. Then
|
|
436
|
-
from pre-flight.
|
|
480
|
+
paths. Do NOT recursively `rm -rf` `<provider_dir>/` or
|
|
481
|
+
`notes/` as directories, only the specific tutorial-owned files
|
|
482
|
+
inside. After deletion, `rmdir` empty parents silently. Then
|
|
483
|
+
start from pre-flight.
|
|
437
484
|
|
|
438
485
|
## Edge cases
|
|
439
486
|
|
|
@@ -41,7 +41,11 @@ optional second phase (~20-30 min) covering the rest of the CLI.
|
|
|
41
41
|
NOT rioplatense. Short sentences. No unnecessary jargon. Use
|
|
42
42
|
`tú` form, not `vos` — `puedes`, `mira`, `prueba`, `crea`, NOT
|
|
43
43
|
`podés`, `mirá`, `probá`, `creá`. Avoid Argentine fillers
|
|
44
|
-
(`dale`, `bueno`, `che`, `re-`, `genial`).
|
|
44
|
+
(`dale`, `bueno`, `che`, `re-`, `genial`). Also avoid overly
|
|
45
|
+
colloquial imperatives even when they're grammatical: prefer
|
|
46
|
+
`espera` / `aguarda` over `aguanta`, `revisa` over `chequea`,
|
|
47
|
+
`observa` / `fíjate en` over `fijate`. Casual is OK; slangy is
|
|
48
|
+
not.
|
|
45
49
|
- Address the tester by name if they introduced themselves; if not,
|
|
46
50
|
the implicit second person from the verb is enough. No need to
|
|
47
51
|
invent a stand-in pronoun.
|
|
@@ -67,9 +71,9 @@ optional second phase (~20-30 min) covering the rest of the CLI.
|
|
|
67
71
|
- File paths, frontmatter keys (`name`, `description`, `event`,
|
|
68
72
|
etc.), CLI verbs (`sm init`, `sm watch`), and code identifiers
|
|
69
73
|
stay English — that's the public surface, not jargon.
|
|
70
|
-
Anti-pattern (do NOT emit): "aparecen los otros
|
|
74
|
+
Anti-pattern (do NOT emit): "aparecen los otros tres kinds",
|
|
71
75
|
"el watcher detectó el cambio", "vamos a hacer un scan ahora".
|
|
72
|
-
Correct: "aparecen los otros
|
|
76
|
+
Correct: "aparecen los otros tres tipos", "skill-map detectó
|
|
73
77
|
el cambio", "vamos a escanear ahora".
|
|
74
78
|
### Silence during backstage work
|
|
75
79
|
|
|
@@ -186,6 +190,58 @@ optional second phase (~20-30 min) covering the rest of the CLI.
|
|
|
186
190
|
11. **Never skip the level question when entering the deep-dive.**
|
|
187
191
|
The level drives modulation of every Step 8+ instruction.
|
|
188
192
|
|
|
193
|
+
## Provider detection
|
|
194
|
+
|
|
195
|
+
Skill-map ships with three built-in providers, each one walks its
|
|
196
|
+
own on-disk convention:
|
|
197
|
+
|
|
198
|
+
| Provider | Base dir | Kinds it claims | Detect via env var(s) |
|
|
199
|
+
|----------------|-----------------------|--------------------------------|------------------------------------------------|
|
|
200
|
+
| `claude` | `.claude/` | `agent`, `command`, `skill` | `CLAUDECODE=1` OR `AI_AGENT` starts with `claude-code` |
|
|
201
|
+
| `gemini` | `.gemini/` | `agent`, `skill` | `GEMINI_CLI=1` OR `AI_AGENT` starts with `gemini` (any equivalent vendor var) |
|
|
202
|
+
| `agent-skills` | `.agents/skills/` | `skill` only (vendor-neutral) | no formal env yet; treat as opt-in if the tester says so |
|
|
203
|
+
|
|
204
|
+
**Decision logic, applied silently during pre-flight**:
|
|
205
|
+
|
|
206
|
+
1. Inspect the agent's environment (`process.env` in your runtime).
|
|
207
|
+
2. If a Claude-flavoured var is present → `provider = claude`,
|
|
208
|
+
`<provider_dir> = .claude`, supported kinds = `{agent, command,
|
|
209
|
+
skill}`.
|
|
210
|
+
3. Else if a Gemini-flavoured var is present → `provider = gemini`,
|
|
211
|
+
`<provider_dir> = .gemini`, supported kinds = `{agent, skill}`.
|
|
212
|
+
4. Else → **fallback to claude** AND surface one short blockquote
|
|
213
|
+
to the tester so they can correct course:
|
|
214
|
+
|
|
215
|
+
> Heads up: I couldn't detect which agent runtime is hosting
|
|
216
|
+
> me, so I'll demo skill-map's Claude provider (`.claude/`).
|
|
217
|
+
> If you actually use Gemini or agent-skills, tell me and I
|
|
218
|
+
> swap the fixture to `.gemini/` or `.agents/skills/`.
|
|
219
|
+
|
|
220
|
+
**Reality check (do not mention to the tester unless asked)**:
|
|
221
|
+
this SKILL.md lives at `.claude/skills/sm-tutorial/SKILL.md`, so
|
|
222
|
+
in practice only Claude Code loads it today. The detection logic
|
|
223
|
+
is wired so that the day mirrored skills land at
|
|
224
|
+
`.gemini/skills/sm-tutorial/` and `.agents/skills/sm-tutorial/`,
|
|
225
|
+
they reuse this same body and the fixture follows automatically.
|
|
226
|
+
|
|
227
|
+
### Global substitution rule
|
|
228
|
+
|
|
229
|
+
The rest of this file says `.claude/<…>` as the canonical example
|
|
230
|
+
because that is the 100% case today. **Wherever you see
|
|
231
|
+
`.claude/`, swap it for the detected `<provider_dir>` when writing
|
|
232
|
+
the fixture, when showing the tester commands, when computing the
|
|
233
|
+
expected node count, and when listing files for the start-over
|
|
234
|
+
wipe.** Also: **skip any sub-step whose kind is not in the
|
|
235
|
+
provider's supported set** (e.g. on `gemini`, skip the
|
|
236
|
+
`demo-command` file in Step 3 and the `notes/todo → demo-command`
|
|
237
|
+
connector in Step 5; on `agent-skills`, skip both `demo-agent`
|
|
238
|
+
and `demo-command` and demo only the skill + the two markdown
|
|
239
|
+
notes plus the connectors that target them).
|
|
240
|
+
|
|
241
|
+
Persist `provider` into `tutorial-state.yml` (top-level
|
|
242
|
+
`provider: <id>` field) so a resumed session does not have to
|
|
243
|
+
re-detect.
|
|
244
|
+
|
|
189
245
|
## Pre-flight
|
|
190
246
|
|
|
191
247
|
### 1. Verify the working directory (empty dir)
|
|
@@ -318,7 +374,7 @@ later when they're relevant. Keep it to a single short sentence:
|
|
|
318
374
|
|
|
319
375
|
> Quick heads-up before we start: I'm about to set up the
|
|
320
376
|
> tutorial scenario in this directory — that means creating a
|
|
321
|
-
> handful of files.
|
|
377
|
+
> handful of files. Please wait a moment while I finish.
|
|
322
378
|
|
|
323
379
|
Then proceed straight to the writes below — no pause, no "ready?"
|
|
324
380
|
prompt.
|
|
@@ -326,9 +382,9 @@ prompt.
|
|
|
326
382
|
The tutorial builds the graph **progressively** across Steps 2-6
|
|
327
383
|
(the live UI block). Right now, in pre-flight, you only create
|
|
328
384
|
**one file** — a single agent — so the tester's first look at the
|
|
329
|
-
UI shows exactly one node. The other
|
|
330
|
-
|
|
331
|
-
|
|
385
|
+
UI shows exactly one node. The other three nodes (skill, command,
|
|
386
|
+
note) and the connectors between all four are added later, one
|
|
387
|
+
step at a time.
|
|
332
388
|
|
|
333
389
|
```
|
|
334
390
|
<cwd>/
|
|
@@ -384,6 +440,7 @@ tutorial:
|
|
|
384
440
|
started_at: "<ISO-8601 now>"
|
|
385
441
|
cwd: "<output of pwd>"
|
|
386
442
|
sm_version: "<output of sm version>"
|
|
443
|
+
provider: "<claude | gemini | agent-skills>" # filled from §Provider detection
|
|
387
444
|
tester:
|
|
388
445
|
level: 2 # default; only asked if they advance into the deep-dive
|
|
389
446
|
route:
|
|
@@ -403,7 +460,7 @@ short_steps:
|
|
|
403
460
|
title: "⭐ Live UI: the lone agent"
|
|
404
461
|
status: "pending"
|
|
405
462
|
- id: "3-live-kinds"
|
|
406
|
-
title: "⭐ Live UI: the other
|
|
463
|
+
title: "⭐ Live UI: the other three kinds appear"
|
|
407
464
|
status: "pending"
|
|
408
465
|
- id: "4-live-edit"
|
|
409
466
|
title: "⭐ Live UI: your first edit"
|
|
@@ -567,14 +624,23 @@ Wait for confirmation that the page loaded. Then tell the tester:
|
|
|
567
624
|
|
|
568
625
|
Wait for confirmation. Mark `2-live-boot: done`.
|
|
569
626
|
|
|
570
|
-
### Step 3 — Live UI: the other
|
|
627
|
+
### Step 3 — Live UI: the other three kinds appear (~1 min)
|
|
571
628
|
|
|
572
629
|
Leave the browser open and the terminal with `sm` running. You
|
|
573
|
-
create
|
|
630
|
+
create four more nodes **without any cross-fixture links**
|
|
574
631
|
yet — pure standalone nodes — so the tester sees four new dots pop
|
|
575
|
-
in.
|
|
576
|
-
|
|
577
|
-
|
|
632
|
+
in. Three new **kinds** show up in this step (skill, command,
|
|
633
|
+
markdown), the fourth file is a second `markdown` node that the
|
|
634
|
+
hub in Step 5 will point at via a real `references` link.
|
|
635
|
+
|
|
636
|
+
Create these four files (with `Write`), exactly in this order.
|
|
637
|
+
Per §Provider detection, **substitute `.claude/` with the
|
|
638
|
+
detected `<provider_dir>` and skip files whose kind is not in the
|
|
639
|
+
provider's supported set** (`gemini`: skip `demo-command`, three
|
|
640
|
+
new nodes land; `agent-skills`: skip both `demo-agent` and
|
|
641
|
+
`demo-command`, only the skill + the two markdown notes remain).
|
|
642
|
+
Adjust the node count, the "four new nodes" message, and the file
|
|
643
|
+
list shown to the tester in the blockquote below accordingly:
|
|
578
644
|
|
|
579
645
|
1. `.claude/skills/demo-skill/SKILL.md` (kind: skill):
|
|
580
646
|
```markdown
|
|
@@ -626,52 +692,64 @@ Create these four files (with `Write`), exactly in this order:
|
|
|
626
692
|
target file. Connectors land in the next sub-step.
|
|
627
693
|
```
|
|
628
694
|
|
|
629
|
-
3.
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
(the catch-all kind for `.md` files outside the
|
|
633
|
-
skill / agent / command folders); a dedicated `hook` kind
|
|
634
|
-
is on the roadmap:
|
|
695
|
+
3. `notes/todo.md` — classified as `kind: markdown` today
|
|
696
|
+
(the catch-all for `.md` files outside the
|
|
697
|
+
skill / agent / command folders):
|
|
635
698
|
```markdown
|
|
636
699
|
---
|
|
637
|
-
name:
|
|
700
|
+
name: Demo TODO list
|
|
638
701
|
description: |
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
idempotent: true
|
|
702
|
+
Live list of things to review in the demo. Will become the
|
|
703
|
+
hub that points to the rest of the fixture in the next
|
|
704
|
+
sub-step.
|
|
705
|
+
tags: [notes, demo]
|
|
644
706
|
---
|
|
645
707
|
|
|
646
|
-
#
|
|
647
|
-
|
|
648
|
-
Fires when a subagent terminates. Records the closure. Will get
|
|
649
|
-
wired into the rest of the fixture next.
|
|
708
|
+
# Pending
|
|
650
709
|
```
|
|
651
710
|
|
|
652
|
-
4. `notes/
|
|
653
|
-
|
|
654
|
-
is on the roadmap):
|
|
711
|
+
4. `notes/demo-guideline.md` — second `kind: markdown` node, the
|
|
712
|
+
one the hub will reach via a real markdown link in Step 5:
|
|
655
713
|
```markdown
|
|
656
714
|
---
|
|
657
|
-
name:
|
|
715
|
+
name: demo-guideline
|
|
658
716
|
description: |
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
717
|
+
Static reference notes that the rest of the demo points at.
|
|
718
|
+
Showcases a second markdown node so the demo can exercise
|
|
719
|
+
the `references` link kind without ambiguity.
|
|
662
720
|
tags: [notes, demo]
|
|
663
721
|
---
|
|
664
722
|
|
|
665
|
-
#
|
|
723
|
+
# Demo Guideline
|
|
724
|
+
|
|
725
|
+
Conventions the demo fixture follows:
|
|
726
|
+
|
|
727
|
+
- Names match the file basename.
|
|
728
|
+
- Frontmatter `description` is short and human-readable.
|
|
729
|
+
- Body stays minimal, only what's needed to teach the kind.
|
|
666
730
|
```
|
|
667
731
|
|
|
668
732
|
Tell the tester:
|
|
669
733
|
|
|
670
734
|
> Look at the browser. Four new nodes should have popped in:
|
|
671
|
-
> `demo-skill`, `demo-command`, `
|
|
672
|
-
>
|
|
673
|
-
>
|
|
674
|
-
>
|
|
735
|
+
> `demo-skill`, `demo-command`, `notes/todo`, and `demo-guideline`.
|
|
736
|
+
> Five total now, **still unconnected** — they're floating dots.
|
|
737
|
+
> The viewport auto-fits whenever a node is added or removed, so
|
|
738
|
+
> all five should be visible without panning.
|
|
739
|
+
>
|
|
740
|
+
> What I just did behind the scenes: I created four new files in
|
|
741
|
+
> your project, and the watcher picked them up on its own, that's
|
|
742
|
+
> why four new dots appeared without you running anything:
|
|
743
|
+
>
|
|
744
|
+
> ```
|
|
745
|
+
> .claude/skills/demo-skill/SKILL.md (kind: skill)
|
|
746
|
+
> .claude/commands/demo-command.md (kind: command)
|
|
747
|
+
> notes/todo.md (kind: markdown)
|
|
748
|
+
> notes/demo-guideline.md (kind: markdown)
|
|
749
|
+
> ```
|
|
750
|
+
>
|
|
751
|
+
> Same loop you'll use yourself in the next step, only this time
|
|
752
|
+
> the writes came from me.
|
|
675
753
|
>
|
|
676
754
|
> Did the four appear? Confirm so we can wire them up.
|
|
677
755
|
|
|
@@ -713,54 +791,52 @@ rule #1) before moving on. Mark `4-live-edit: done`.
|
|
|
713
791
|
|
|
714
792
|
### Step 5 — Live UI: the connectors light up (~1 min)
|
|
715
793
|
|
|
716
|
-
Now you edit
|
|
717
|
-
each
|
|
718
|
-
|
|
794
|
+
Now you edit `notes/todo.md` so it becomes the **hub** that points
|
|
795
|
+
to each of the other four nodes. Each bullet uses a syntax that
|
|
796
|
+
maps to a specific **link kind**:
|
|
719
797
|
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
```markdown
|
|
746
|
-
- [ ] Polish the
|
|
747
|
-
[demo-skill](../.claude/skills/demo-skill/SKILL.md)
|
|
748
|
-
prompt.
|
|
749
|
-
- [ ] Confirm the `event` of the
|
|
750
|
-
[demo-hook](../.claude/hooks/demo-hook.md).
|
|
751
|
-
```
|
|
798
|
+
- an `@handle` token → kind `mentions`
|
|
799
|
+
- a `/slash` token → kind `invokes`
|
|
800
|
+
- a markdown link `[text](path)` → kind `references`
|
|
801
|
+
|
|
802
|
+
Four bullets, three kinds (the `invokes` kind shows up twice
|
|
803
|
+
because both the command and the skill are addressed by slash).
|
|
804
|
+
|
|
805
|
+
Apply with `Edit` on `notes/todo.md` (do not rewrite the file).
|
|
806
|
+
Per §Provider detection, **substitute `.claude/` with the detected
|
|
807
|
+
`<provider_dir>` and drop any bullet whose target node was not
|
|
808
|
+
created in Step 3** (on `gemini` there is no command → skip the
|
|
809
|
+
`/demo-command` bullet, three connectors land; on `agent-skills`
|
|
810
|
+
there is no agent and no command → skip the `@demo-agent` and
|
|
811
|
+
`/demo-command` bullets, two connectors land).
|
|
812
|
+
|
|
813
|
+
**Edit `notes/todo.md`** — append these bullets after the
|
|
814
|
+
`# Pending` heading:
|
|
815
|
+
|
|
816
|
+
```markdown
|
|
817
|
+
- [ ] Brief @demo-agent on the rough edges.
|
|
818
|
+
- [ ] Run /demo-command before publishing.
|
|
819
|
+
- [ ] Trigger /demo-skill when the input lands.
|
|
820
|
+
- [ ] Re-read the
|
|
821
|
+
[demo-guideline](./demo-guideline.md) before shipping.
|
|
822
|
+
```
|
|
752
823
|
|
|
753
824
|
Tell the tester:
|
|
754
825
|
|
|
755
|
-
> Look at the magic again.
|
|
756
|
-
>
|
|
757
|
-
>
|
|
826
|
+
> Look at the magic again. `notes/todo` is now the hub: four
|
|
827
|
+
> arrows light up between it and the other nodes, and the UI
|
|
828
|
+
> palette colours each arrow by the link kind it carries:
|
|
758
829
|
>
|
|
759
|
-
> - `
|
|
760
|
-
> - `
|
|
761
|
-
> - `
|
|
762
|
-
> - `demo-
|
|
763
|
-
>
|
|
830
|
+
> - `notes/todo → demo-agent` (kind: `mentions`)
|
|
831
|
+
> - `notes/todo → demo-command` (kind: `invokes`)
|
|
832
|
+
> - `notes/todo → demo-skill` (kind: `invokes`)
|
|
833
|
+
> - `notes/todo → demo-guideline` (kind: `references`)
|
|
834
|
+
>
|
|
835
|
+
> The kind comes from the syntax in the bullet: an `@handle` is
|
|
836
|
+
> always a mention, a `/command` is always an invoke, a markdown
|
|
837
|
+
> link is always a reference. Four arrows, three kinds, three
|
|
838
|
+
> colours on the canvas (the two `invokes` share a colour, as you
|
|
839
|
+
> would expect).
|
|
764
840
|
>
|
|
765
841
|
> Confirm. If a connector is missing, refresh the browser and tell
|
|
766
842
|
> me.
|
|
@@ -817,12 +893,12 @@ the tester sees what their cwd holds:
|
|
|
817
893
|
> ├── .claude/
|
|
818
894
|
> │ ├── agents/demo-agent.md
|
|
819
895
|
> │ ├── commands/demo-command.md
|
|
820
|
-
> │ ├── hooks/demo-hook.md
|
|
821
896
|
> │ └── skills/demo-skill/SKILL.md
|
|
822
897
|
> ├── .skill-map/ ← project DB + settings (managed)
|
|
823
898
|
> ├── .skillmapignore ← the file we're about to edit
|
|
824
899
|
> ├── notes/
|
|
825
900
|
> │ ├── todo.md
|
|
901
|
+
> │ ├── demo-guideline.md
|
|
826
902
|
> │ └── private-credentials.md ← what we want to hide
|
|
827
903
|
> └── sm-tutorial.md ← the tutorial file you loaded
|
|
828
904
|
> ```
|
|
@@ -875,12 +951,24 @@ Mark `6-live-ignore: done`.
|
|
|
875
951
|
> UI sees it instantly. In **~10 minutes** you've already seen the
|
|
876
952
|
> full flow.
|
|
877
953
|
>
|
|
878
|
-
> ⚠️ **`.sm` files (heads-up for later)** —
|
|
879
|
-
>
|
|
880
|
-
>
|
|
881
|
-
>
|
|
882
|
-
>
|
|
883
|
-
>
|
|
954
|
+
> ⚠️ **`.sm` files (heads-up for later)** — every `.md` skill-map
|
|
955
|
+
> tracks has a sibling `.sm` file (e.g. `demo-agent.sm` next to
|
|
956
|
+
> `demo-agent.md`) that carries **all of the tool's metadata
|
|
957
|
+
> about that markdown, so your `.md` stays clean and uncluttered**.
|
|
958
|
+
> Version, history, tags, annotations, anything that does not
|
|
959
|
+
> belong in the human-authored body lives in the `.sm`. You write
|
|
960
|
+
> the `.md` for Claude or for humans, the tool writes the `.sm`.
|
|
961
|
+
> Each `sm bump` and each `sm sidecar annotate` creates or
|
|
962
|
+
> refreshes one, so you'll see them often as you use skill-map
|
|
963
|
+
> day to day. Commit them to git like any other source file.
|
|
964
|
+
>
|
|
965
|
+
> 🔀 **Multi-provider** — this demo ran with the
|
|
966
|
+
> `<provider>` provider (base dir `<provider_dir>`). Skill-map
|
|
967
|
+
> walks two other built-in conventions with identical mechanics:
|
|
968
|
+
> Gemini lives under `.gemini/` (kinds: agent + skill), and the
|
|
969
|
+
> open agent-skills standard lives under `.agents/skills/` (kind:
|
|
970
|
+
> skill). Drop a `.md` in any of those and the same watcher
|
|
971
|
+
> picks it up, the same connectors light up, the same rules run.
|
|
884
972
|
>
|
|
885
973
|
> If you want, **we can keep going deeper**: I'll walk you through
|
|
886
974
|
> the CLI verbs and flags (`list`, `graph`, `export`, `orphans`,
|
|
@@ -940,16 +1028,19 @@ conditional, e.g. "If the server from Step 2 is still up, leave it
|
|
|
940
1028
|
browser." Do not just say "start it again" — that risks a second
|
|
941
1029
|
process trying to bind the same port and confusing the tester.
|
|
942
1030
|
|
|
943
|
-
> Your turn. Edit
|
|
944
|
-
>
|
|
945
|
-
>
|
|
1031
|
+
> Your turn. Edit `notes/todo.md` with your editor of choice and
|
|
1032
|
+
> delete the bullet that contains `@demo-agent`. Save. Watch the
|
|
1033
|
+
> UI.
|
|
946
1034
|
>
|
|
947
|
-
> Expected: the `
|
|
948
|
-
> real time. The two nodes stay in the
|
|
1035
|
+
> Expected: the `notes/todo → demo-agent` connector (kind:
|
|
1036
|
+
> `mentions`) disappears in real time. The two nodes stay in the
|
|
1037
|
+
> graph; only the edge goes.
|
|
949
1038
|
|
|
950
|
-
You verify by reading
|
|
951
|
-
|
|
952
|
-
the
|
|
1039
|
+
You verify by reading `notes/todo.md` to confirm the change was
|
|
1040
|
+
applied. (On `agent-skills`, where the `@demo-agent` bullet was
|
|
1041
|
+
never created in Step 5, ask the tester to remove the only bullet
|
|
1042
|
+
they did add and watch THAT connector vanish, the lesson is the
|
|
1043
|
+
same.) Once they confirm, ask them to **Ctrl+C** the server.
|
|
953
1044
|
|
|
954
1045
|
### Step 9 — Browse CLI: list / show / check (~3 min)
|
|
955
1046
|
|
|
@@ -964,8 +1055,9 @@ sm check
|
|
|
964
1055
|
|
|
965
1056
|
Expected: you see the 5 fixture nodes listed with their kind:
|
|
966
1057
|
`demo-skill` (skill), `demo-agent` (agent), `demo-command`
|
|
967
|
-
(command),
|
|
968
|
-
|
|
1058
|
+
(command), `notes/todo` (`markdown`, the catch-all per
|
|
1059
|
+
Step 3), and `notes/demo-guideline` (`markdown` as well, the
|
|
1060
|
+
target of the hub's `references` link). `check` reads the persisted
|
|
969
1061
|
`scan_issues` table — it does NOT re-walk the filesystem. The
|
|
970
1062
|
fixture is clean (Steps 2-6 captured the latest state before
|
|
971
1063
|
Ctrl+C), so the verb prints `✓ No issues`. We will plant one in
|
|
@@ -1071,10 +1163,19 @@ the tester no plugins are installed yet and offer to skip.
|
|
|
1071
1163
|
|
|
1072
1164
|
### Step 13 — Annotations and the `.sm` consent prompt (~3 min)
|
|
1073
1165
|
|
|
1074
|
-
**Context**: skill-map
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1166
|
+
**Context**: every `.md` skill-map tracks gets a sibling
|
|
1167
|
+
**companion file** with extension `.sm` that carries **all of
|
|
1168
|
+
the tool's metadata about that markdown, so your `.md` stays
|
|
1169
|
+
clean and uncluttered**. Version, history, tags, annotations,
|
|
1170
|
+
anything that does not belong in the human-authored body lives
|
|
1171
|
+
in the `.sm`. The `.md` is content you write for Claude or
|
|
1172
|
+
humans; the `.sm` is bookkeeping the tool writes. They are
|
|
1173
|
+
ordinary source files, committed to git like everything else,
|
|
1174
|
+
and you'll encounter them often once you start working with
|
|
1175
|
+
the project.
|
|
1176
|
+
|
|
1177
|
+
The first time skill-map wants to write one in a new project it
|
|
1178
|
+
asks for your consent — it never touches your filesystem without
|
|
1078
1179
|
permission. After you say yes, the choice persists per-checkout
|
|
1079
1180
|
(gitignored) and the prompt never appears again.
|
|
1080
1181
|
|
|
@@ -1172,6 +1273,12 @@ bundle-granularity and only accepts the bundle id.
|
|
|
1172
1273
|
|
|
1173
1274
|
## Final wrap-up
|
|
1174
1275
|
|
|
1276
|
+
<!-- TODO(arquitecto): remove the "send findings to Pusher" flow from
|
|
1277
|
+
this tutorial. It is not part of the roadmap v1 surface and the
|
|
1278
|
+
Pusher hand-off should not appear in the public tester experience.
|
|
1279
|
+
Strip the report-to-Pusher offer, the `sm-tutorial-report.md`
|
|
1280
|
+
template, and any closing copy that names Pusher. -->
|
|
1281
|
+
|
|
1175
1282
|
When everything is done (demo only, or demo + deep-dive), **offer to
|
|
1176
1283
|
generate a report file to send to Pusher**:
|
|
1177
1284
|
|
|
@@ -1274,8 +1381,11 @@ anything**:
|
|
|
1274
1381
|
> re-invoke me from there, or delete `tutorial-state.yml` by
|
|
1275
1382
|
> hand if you really want to start fresh here.
|
|
1276
1383
|
|
|
1277
|
-
2. If the cwd matches,
|
|
1278
|
-
|
|
1384
|
+
2. If the cwd matches, read `tutorial.provider` from the yaml and
|
|
1385
|
+
use it to compute `<provider_dir>` (and the subset of files
|
|
1386
|
+
actually present, since gemini and agent-skills skip some). Then
|
|
1387
|
+
show the tester the exact list of paths you'll delete and ask
|
|
1388
|
+
for an explicit typed confirmation:
|
|
1279
1389
|
|
|
1280
1390
|
> Start over will delete these paths from `<cwd>`:
|
|
1281
1391
|
>
|
|
@@ -1284,11 +1394,11 @@ anything**:
|
|
|
1284
1394
|
> findings.md
|
|
1285
1395
|
> .skillmapignore
|
|
1286
1396
|
> .skill-map/
|
|
1287
|
-
>
|
|
1288
|
-
>
|
|
1289
|
-
>
|
|
1290
|
-
> .claude/skills/demo-skill/
|
|
1397
|
+
> <provider_dir>/agents/demo-agent.md (claude, gemini)
|
|
1398
|
+
> <provider_dir>/commands/demo-command.md (claude only)
|
|
1399
|
+
> <provider_dir>/skills/demo-skill/ (all three)
|
|
1291
1400
|
> notes/todo.md
|
|
1401
|
+
> notes/demo-guideline.md
|
|
1292
1402
|
> notes/private-credentials.md
|
|
1293
1403
|
> sm-tutorial-report.md (if present)
|
|
1294
1404
|
> export.* (if present)
|
|
@@ -1298,14 +1408,19 @@ anything**:
|
|
|
1298
1408
|
> Type **`yes, wipe`** (exact text) to confirm. Anything else
|
|
1299
1409
|
> cancels.
|
|
1300
1410
|
|
|
1411
|
+
Render the ACTUAL list (substituting `<provider_dir>` and
|
|
1412
|
+
dropping the rows the saved provider didn't create) so the
|
|
1413
|
+
tester sees the real paths, not the abstract placeholders.
|
|
1414
|
+
|
|
1301
1415
|
3. Only on the literal `yes, wipe` reply, delete those exact paths.
|
|
1302
|
-
Do NOT recursively `rm -rf`
|
|
1416
|
+
Do NOT recursively `rm -rf` `<provider_dir>/` or `notes/` as
|
|
1303
1417
|
directories — only the specific tutorial-owned files inside, in
|
|
1304
1418
|
case the tester has unrelated files there. After deletion, also
|
|
1305
|
-
`rmdir`
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1419
|
+
`rmdir` the per-provider subdirs that actually exist
|
|
1420
|
+
(`<provider_dir>/agents`, `<provider_dir>/commands`,
|
|
1421
|
+
`<provider_dir>/skills`), then `notes/` and `<provider_dir>/`,
|
|
1422
|
+
each one only if empty (silent failure if not). Then start
|
|
1423
|
+
everything from pre-flight.
|
|
1309
1424
|
|
|
1310
1425
|
## Edge cases
|
|
1311
1426
|
|