okami.mom/strata
git clone https://git.nkp.pet/okami.mom/strata
2b36e8a02
main
07 · Skills
Route #/skills · File src/screens/Skills.tsx (121 lines — the smallest screen)
Reusable instruction sets the model can be given. Today it is a single list, which makes it the thinnest screen in the app and the one where "substance" is most obviously missing.
What it is today
- Header with a count pill (
3 enabled) and an "Add from folder" action. - A search field.
- One
listrowper skill — name, description, an enable toggle, and a source badge (workspace). - An empty state that distinguishes "no skills" from "no match".
- A "How skills work" explainer card at the bottom.
Where it falls short
A skill is a name and a sentence.Fixed. The disclosure existed but showed triggers — the words that activate a skill, not what it does. The host now sends the instruction text itself (bundled skills carry it; workspace skills read their ownSKILL.md, which the description had always claimed was the source without ever reading it). Verified: 364 characters of real instruction render, and no skill lacks a body.- Enabled/disabled is the only control. No ordering, no scoping to a workspace, no per-conversation activation.
- The list is flat and unsorted. No grouping by source, no indication of which fired recently.
- "Add from folder" is opaque. It gives no hint of the expected layout, file format, or where to put files.
- No feedback loop. Nothing shows whether a skill has ever been used, or which conversations it affected.
- The explainer card is a wall of prose at the bottom, below the fold on a short window, where it cannot help anyone who is confused at the top.
- The screen sits alone in the sidebar with no sibling, which makes the single flat row read as unfinished.
The plan
Substance — make a skill inspectable
A detail view per skill.Done. Read instructions opens the instruction text, with the triggers kept beneath it as a secondary detail — they answer "when does this fire", which is a different question from "what does it do".Usage evidence.Done — see the shipped note above. The triggers were decorative until this was built: nothing consulted them at runtime.- Scope control — enable per workspace, since a skill written for one project is noise in another.
Hierarchy
- Move the explainer to the top as a one-line subtitle, and put the detail in a disclosure for people who want it. Prose at the bottom cannot answer a question asked at the top.
- Group by source (
Workspace/Built in) once there is more than one source; a single flat list will not scale.
Fluidity
- Toggling a skill shows the change immediately and reconciles quietly — the optimistic update is the interaction, and a spinner on a switch is a worse switch.
- Adding a skill animates the new row in with the standard entrance, so the result of "Add from folder" is visibly connected to the action.
Motion
| Interaction | Spec |
|---|---|
| Toggle | Knob travel --st-t-control; no page movement — built |
| New skill added | st-enter, --st-t-local, 6 px |
| Detail expand | grid track 0fr → 1fr, --st-t-local |
| Search filtering | Rows fade, --st-t-control. No reflow animation |
Verification
- Assert each skill row can reveal its full instruction text.
- Shipped as
npm run flow skilluse: every skill renders a usage line, and the line isNot used yetrather than blank when it has never fired. - Assert the empty state distinguishes no skills from no match — already correct; keep it under test.
1# 07 · Skills 2 3**Route** `#/skills` · **File** `src/screens/Skills.tsx` (121 lines — the smallest screen) 4 5Reusable instruction sets the model can be given. Today it is a single list, 6which makes it the thinnest screen in the app and the one where "substance" is 7most obviously missing. 8 9## What it is today 10 11- **Header** with a count pill (`3 enabled`) and an "Add from folder" action. 12- **A search field.** 13- **One `listrow` per skill** — name, description, an enable toggle, and a source 14badge (`workspace`). 15 - **An empty state** that distinguishes "no skills" from "no match". 16- **A "How skills work" explainer card** at the bottom. 17 18## Where it falls short 19 201. ~~A skill is a name and a sentence.~~ **Fixed.** The disclosure existed but 21showed *triggers* — the words that activate a skill, not what it does. The 22host now sends the instruction text itself (bundled skills carry it; 23workspace skills read their own `SKILL.md`, which the description had always 24claimed was the source without ever reading it). Verified: 364 characters of 25real instruction render, and **no skill lacks a body**. 262. **Enabled/disabled is the only control.** No ordering, no scoping to a 27workspace, no per-conversation activation. 283. **The list is flat and unsorted.** No grouping by source, no indication of 29which fired recently. 304. **"Add from folder" is opaque.** It gives no hint of the expected layout, file 31format, or where to put files. 325. **No feedback loop.** Nothing shows whether a skill has ever been used, or 33which conversations it affected. 346. **The explainer card is a wall of prose at the bottom**, below the fold on a 35short window, where it cannot help anyone who is confused at the top. 367. **The screen sits alone in the sidebar** with no sibling, which makes the 37single flat row read as unfinished. 38 39## The plan 40 41### Substance — make a skill inspectable 421. ~~A detail view per skill.~~ **Done.** *Read instructions* opens the 43instruction text, with the triggers kept beneath it as a secondary 44detail — they answer "when does this fire", which is a different question 45from "what does it do". 462. ~~Usage evidence.~~ **Done** — see the shipped note above. The triggers were 47decorative until this was built: nothing consulted them at runtime. 483. **Scope control** — enable per workspace, since a skill written for one 49project is noise in another. 50 51### Hierarchy 524. **Move the explainer to the top as a one-line subtitle**, and put the detail 53in a disclosure for people who want it. Prose at the bottom cannot answer a 54question asked at the top. 555. **Group by source** (`Workspace` / `Built in`) once there is more than one 56source; a single flat list will not scale. 57 58### Fluidity 596. **Toggling a skill shows the change immediately** and reconciles quietly — the 60optimistic update is the interaction, and a spinner on a switch is a worse 61switch. 627. **Adding a skill animates the new row in** with the standard entrance, so the 63result of "Add from folder" is visibly connected to the action. 64 65## Motion 66 67| Interaction | Spec | 68|---|---| 69| Toggle | Knob travel `--st-t-control`; no page movement — built | 70| New skill added | `st-enter`, `--st-t-local`, 6 px | 71| Detail expand | grid track `0fr → 1fr`, `--st-t-local` | 72| Search filtering | Rows fade, `--st-t-control`. No reflow animation | 73 74## Verification 75 76- Assert each skill row can reveal its full instruction text. 77- **Shipped as `npm run flow skilluse`**: every skill renders a usage line, and 78the line is `Not used yet` rather than blank when it has never fired. 79- Assert the empty state distinguishes *no skills* from *no match* — already 80correct; keep it under test.