@erclx/canon 5.52.0 → 5.53.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/CHANGELOG.md +7 -0
- package/README.md +1 -4
- package/claude/.claude-plugin/plugin.json +1 -1
- package/claude/skills/canon-cli/SKILL.md +0 -3
- package/claude/skills/context-fold/REQUIREMENT.md +0 -1
- package/claude/skills/design-taste/references/kinds.md +0 -1
- package/claude/skills/draw-figure/REQUIREMENT.md +2 -3
- package/claude/skills/draw-figure/SKILL.md +4 -5
- package/claude/skills/draw-figure/references/figures.md +0 -1
- package/claude/skills/draw-figure/references/hand-drawn.md +1 -1
- package/claude/skills/pick-by-eye/REQUIREMENT.md +0 -1
- package/claude/skills/pick-by-eye/SKILL.md +1 -1
- package/claude/skills/teach-craft/REQUIREMENT.md +30 -0
- package/claude/skills/teach-craft/SKILL.md +39 -0
- package/claude/skills/teach-craft/references/lesson-craft.md +52 -0
- package/claude/skills/{teach-workspace → teach-craft}/references/pedagogy.md +12 -4
- package/docs/agents/audits.md +0 -1
- package/docs/target/migrations.md +10 -1
- package/docs/workflow/parallel-features.md +1 -1
- package/docs/workflow/skill-map-on-request.md +10 -22
- package/docs/workflow/skill-map.md +12 -14
- package/package.json +1 -4
- package/scripts/core/regen-web-previews.ts +2 -67
- package/src/audits/catalog.ts +0 -1
- package/src/browser/engine.ts +3 -6
- package/src/capture/render.ts +1 -1
- package/src/claude/cases/authoring.ts +0 -12
- package/src/claude/cases/misc.ts +0 -17
- package/src/claude/cases/workflow.ts +2 -38
- package/src/claude/skills-audit.ts +0 -1
- package/src/cli/help.ts +0 -7
- package/src/cli.ts +0 -6
- package/src/commands/records.ts +0 -1
- package/src/commands/serve.ts +2 -2
- package/src/design/components.ts +8 -1514
- package/src/design/css.ts +5 -6
- package/src/design/fonts.ts +3 -5
- package/src/driver/drive.ts +3 -4
- package/src/driver/steps.ts +2 -5
- package/src/inventory/walk.ts +1 -1
- package/src/markdown/scope.ts +4 -31
- package/src/records/validate.ts +4 -176
- package/src/sandbox/equivalence.ts +0 -5
- package/claude/skills/draft-and-pick/REQUIREMENT.md +0 -26
- package/claude/skills/draft-and-pick/SKILL.md +0 -11
- package/claude/skills/draft-doc/REQUIREMENT.md +0 -26
- package/claude/skills/draft-doc/SKILL.md +0 -11
- package/claude/skills/draft-figure/REQUIREMENT.md +0 -26
- package/claude/skills/draft-figure/SKILL.md +0 -11
- package/claude/skills/draft-identity/REQUIREMENT.md +0 -26
- package/claude/skills/draft-identity/SKILL.md +0 -11
- package/claude/skills/draft-ready/REQUIREMENT.md +0 -26
- package/claude/skills/draft-ready/SKILL.md +0 -11
- package/claude/skills/draft-screencast/REQUIREMENT.md +0 -26
- package/claude/skills/draft-screencast/SKILL.md +0 -11
- package/claude/skills/draft-slides/REQUIREMENT.md +0 -26
- package/claude/skills/draft-slides/SKILL.md +0 -11
- package/claude/skills/make-deck/REQUIREMENT.md +0 -36
- package/claude/skills/make-deck/SKILL.md +0 -80
- package/claude/skills/make-deck/references/deck.md +0 -183
- package/claude/skills/read-frames/REQUIREMENT.md +0 -30
- package/claude/skills/read-frames/SKILL.md +0 -55
- package/claude/skills/record-screencast/REQUIREMENT.md +0 -35
- package/claude/skills/record-screencast/SKILL.md +0 -99
- package/claude/skills/script-screencast/REQUIREMENT.md +0 -34
- package/claude/skills/script-screencast/SKILL.md +0 -70
- package/claude/skills/script-screencast/references/beats-template.md +0 -119
- package/claude/skills/teach-workspace/REQUIREMENT.md +0 -34
- package/claude/skills/teach-workspace/SKILL.md +0 -196
- package/claude/skills/teach-workspace/references/glossary.md +0 -90
- package/claude/skills/teach-workspace/references/lesson-build.md +0 -106
- package/claude/skills/teach-workspace/references/lesson-craft.md +0 -135
- package/claude/skills/teach-workspace/references/promotion-fold.md +0 -35
- package/claude/skills/teach-workspace/references/promotion.md +0 -116
- package/claude/skills/teach-workspace/references/revisit.md +0 -28
- package/claude/skills/teach-workspace/references/teach.md +0 -211
- package/claude/skills/video-craft/REQUIREMENT.md +0 -35
- package/claude/skills/video-craft/SKILL.md +0 -96
- package/claude/skills/video-craft/references/adopted.md +0 -110
- package/src/commands/demo.ts +0 -542
- package/src/commands/slides.ts +0 -184
- package/src/commands/teach.ts +0 -1401
- package/src/demo/beats.ts +0 -135
- package/src/demo/compile.ts +0 -350
- package/src/demo/container.ts +0 -219
- package/src/demo/cursors.ts +0 -55
- package/src/demo/drive.ts +0 -442
- package/src/demo/pointer.ts +0 -178
- package/src/demo/theme.ts +0 -112
- package/src/demo/timeline.ts +0 -64
- package/src/slides/convert/chart.ts +0 -165
- package/src/slides/convert/deck.ts +0 -244
- package/src/slides/convert/export.ts +0 -567
- package/src/slides/convert/master.ts +0 -198
- package/src/slides/convert/shapes.ts +0 -804
- package/src/slides/convert/svg.ts +0 -38
- package/src/slides/convert/walk.ts +0 -671
- package/src/slides/decks.ts +0 -110
- package/src/slides/open.ts +0 -18
- package/src/slides/package/fonts.ts +0 -301
- package/src/slides/package/motion.ts +0 -316
- package/src/slides/package/test-face.ts +0 -113
- package/src/teach/browser/compile.ts +0 -44
- package/src/teach/browser/dismiss.ts +0 -76
- package/src/teach/browser/focus-line.ts +0 -19
- package/src/teach/browser/glossary-filter.ts +0 -44
- package/src/teach/browser/head.ts +0 -30
- package/src/teach/browser/quiz.ts +0 -19
- package/src/teach/browser/reload.ts +0 -9
- package/src/teach/browser/sidebar.ts +0 -233
- package/src/teach/browser/theme.ts +0 -18
- package/src/teach/components/code.tsx +0 -24
- package/src/teach/components/heading.tsx +0 -11
- package/src/teach/components/list.tsx +0 -17
- package/src/teach/components/paragraph.tsx +0 -29
- package/src/teach/components/refs.tsx +0 -28
- package/src/teach/cross-references.ts +0 -78
- package/src/teach/fonts.ts +0 -16
- package/src/teach/highlight.ts +0 -71
- package/src/teach/html/jsx-dev-runtime.ts +0 -13
- package/src/teach/html/jsx-runtime.ts +0 -113
- package/src/teach/html/raw.ts +0 -28
- package/src/teach/lesson.ts +0 -178
- package/src/teach/nav.ts +0 -1337
- package/src/teach/render.ts +0 -240
- package/src/teach/workspace.ts +0 -1164
- package/src/teach/write-if-changed.ts +0 -17
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Glossary reference
|
|
3
|
-
description: Frontmatter, entry shape, ordering, and the rules deciding which terms a glossary carries
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Glossary reference
|
|
7
|
-
|
|
8
|
-
Applies to a glossary, the file holding one entry per term a body of material defines. It changes whenever the material names a concept a reader cannot look up yet, and it is revised in place rather than appended to.
|
|
9
|
-
|
|
10
|
-
## Scope
|
|
11
|
-
|
|
12
|
-
Governs a glossary at `.canon/teach/<nn>-<topic>/GLOSSARY.md` and at whatever path a surface fixes for one it holds: its frontmatter, entry shape, ordering, grouping, and the rules deciding which terms it carries.
|
|
13
|
-
|
|
14
|
-
Does not govern:
|
|
15
|
-
|
|
16
|
-
- The folder a learning workspace lays out around its glossary, and the other files in it: `teach.md`
|
|
17
|
-
- Which surface a glossary moves to once it leaves the material that produced it, which belongs to the surface driving that move
|
|
18
|
-
- Voice, rhythm, and sentence construction: the `write-human` skill
|
|
19
|
-
- Headings, punctuation, word choice, and file references: `markdown.md`
|
|
20
|
-
|
|
21
|
-
## What a working glossary looks like
|
|
22
|
-
|
|
23
|
-
A glossary works when a reader who meets a term in the material settles it here without opening the page that introduced it:
|
|
24
|
-
|
|
25
|
-
- Which word does this material use for the concept, and which words does it deliberately not use?
|
|
26
|
-
- What does the term mean, stated without leaning on the term itself?
|
|
27
|
-
- Where does the term appear, so a reader can see it used rather than only defined?
|
|
28
|
-
- Does every entry carry a term the material actually uses?
|
|
29
|
-
|
|
30
|
-
A glossary failing these is non-conforming even when it satisfies every shape rule below.
|
|
31
|
-
|
|
32
|
-
## Frontmatter
|
|
33
|
-
|
|
34
|
-
- `title` (required): names the material the terms come from, in sentence case
|
|
35
|
-
- `description` (required): one line naming what a reader gets from the entries
|
|
36
|
-
|
|
37
|
-
## Entries
|
|
38
|
-
|
|
39
|
-
- Write one entry per term, as a single bullet.
|
|
40
|
-
- Lead the bullet with the term as a bolded span, then the definition in one or two sentences.
|
|
41
|
-
- Define the term without using it. A definition that spends the term explains nothing to the reader who arrived not knowing it.
|
|
42
|
-
|
|
43
|
-
### Placement and order
|
|
44
|
-
|
|
45
|
-
Each entry points at its first use and sits where a reader would look for it.
|
|
46
|
-
|
|
47
|
-
- Name where the term first appears, so a reader can reach one use of it in context.
|
|
48
|
-
- Keep an entry to the meaning. Worked detail belongs on the page that teaches the term.
|
|
49
|
-
- Sort entries alphabetically, so a reader who knows only the word finds it without reading the file.
|
|
50
|
-
|
|
51
|
-
## Which terms it carries
|
|
52
|
-
|
|
53
|
-
- Add a term once the material has used it, never ahead of that. A glossary front-loaded with terms nothing has introduced is a syllabus rather than a reference.
|
|
54
|
-
- Pick one word per concept and use that word everywhere. A glossary carrying two words for one thing hands the reader a choice it exists to remove.
|
|
55
|
-
- List each rejected synonym as an alias to avoid inside the entry that won, so a reader arriving with the wrong word lands on the right one.
|
|
56
|
-
- Use the glossary's own terms inside other definitions. A definition reaching for a synonym of a term defined two entries down teaches the reader a word the material does not use.
|
|
57
|
-
- Revise an entry the material has moved under rather than adding a second one narrating the change.
|
|
58
|
-
|
|
59
|
-
## Grouping
|
|
60
|
-
|
|
61
|
-
- Keep a short glossary as one alphabetical list under the title. Grouping a handful of entries costs a heading per category and saves no lookup.
|
|
62
|
-
- Group a glossary long enough that one list stops helping under `##` headings by category, sorted alphabetically within each. Roughly two screens of entries is the signal.
|
|
63
|
-
- Name each category so a reader picks it from the term alone. A category a reader cannot predict makes the grouping a second thing to search.
|
|
64
|
-
- State a departure from any rule above in the file itself, naming what it departs from and why
|
|
65
|
-
- A glossary serving no single body of material is the case that produces one, since a term drawn from everywhere has no first appearance to name
|
|
66
|
-
|
|
67
|
-
## Rendered grouping
|
|
68
|
-
|
|
69
|
-
Applies to a rendered glossary page, never to the source file above, which stays the flat alphabetical list the `## Grouping` rules above govern.
|
|
70
|
-
|
|
71
|
-
- Group a rendered glossary by the lesson its own "First seen in" citation names, ordered by lesson order, under a sub-heading naming the lesson's title rather than its filename.
|
|
72
|
-
- Trail with an "Other terms" group holding any entry the citation cannot attribute to a lesson, whether it names a reference page or carries no citation
|
|
73
|
-
- Keep "Other terms" in the alphabetical order the source file already carries
|
|
74
|
-
- Keep the workspace-wide term filter matching against every group, and drop a group's own heading once filtering leaves nothing under it.
|
|
75
|
-
|
|
76
|
-
## Template
|
|
77
|
-
|
|
78
|
-
```markdown
|
|
79
|
-
---
|
|
80
|
-
title: <Material the terms come from>
|
|
81
|
-
description: <one line naming what a reader gets from these entries>
|
|
82
|
-
---
|
|
83
|
-
|
|
84
|
-
# <Material the terms come from>
|
|
85
|
-
|
|
86
|
-
<One line on which material these terms come from and when the file changes.>
|
|
87
|
-
|
|
88
|
-
- **<Term>**: <the meaning in one or two sentences, written without using the term>. Avoid <rejected synonym>. First appears in `<page or lesson>`.
|
|
89
|
-
- **<Term>**: <the meaning in one or two sentences, written without using the term>. First appears in `<page or lesson>`.
|
|
90
|
-
```
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Lesson build reference
|
|
3
|
-
description: The block list canon teach render takes and the verbs that build the lesson body, being render, nav, stylesheet, and glossary
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Lesson build reference
|
|
7
|
-
|
|
8
|
-
Mechanics rather than judgment. `lesson-craft.md` covers what a lesson should be, and this file covers how its body reaches the page through the verbs.
|
|
9
|
-
|
|
10
|
-
## The block list
|
|
11
|
-
|
|
12
|
-
`canon teach render` takes a JSON array of blocks and renders it through the same components a lesson body composes. Six types, and every structural body composes from them:
|
|
13
|
-
|
|
14
|
-
- `{"type":"heading","level":1|2,"text":"<text>"}`: an `<h1>` or `<h2>`.
|
|
15
|
-
- `{"type":"paragraph","text":"<text>","lede":true,"cites":[1]}`: a `<p>`, marked `lede` for the opening dek. `cites` adds a footnote marker per reference number, and a lede takes none.
|
|
16
|
-
- `{"type":"list","items":["<text>", ...],"ordered":true}`: a `<ul>` or, with `ordered`, an `<ol>`.
|
|
17
|
-
|
|
18
|
-
### Reference, code, and raw blocks
|
|
19
|
-
|
|
20
|
-
The other three carry sources, code, and markup the components cannot.
|
|
21
|
-
|
|
22
|
-
- `{"type":"refs","items":[{"title":"<name>","url":"<https URL>","note":"<text>"}, ...]}`: the one reference list, numbered from 1. `url` and `note` are optional, and a `url` must be http or https.
|
|
23
|
-
- `{"type":"code","lang":"ts","text":"<source>"}`: a sample highlighted at render time with no script. `lang` is optional and takes a highlight.js name or alias, and an unregistered one renders plain.
|
|
24
|
-
- `{"type":"raw","html":"<markup>"}`: the escape hatch, passed through unescaped.
|
|
25
|
-
|
|
26
|
-
### Where code and raw go
|
|
27
|
-
|
|
28
|
-
Code never travels through `raw`. A hand-written `<pre><code>` renders with no color, and `nav` never highlights markup already in a body, so it stays plain for good. A fenced block in a reference page's markdown is highlighted by `nav` on its own.
|
|
29
|
-
|
|
30
|
-
The quiz and teach-back block in `lesson-craft.md` always need `raw`, since their fixed contract is not a components concern. Give them the array's last `raw` entry, followed only by `refs`, and use `raw` nowhere the other types could carry the content.
|
|
31
|
-
|
|
32
|
-
### Citing
|
|
33
|
-
|
|
34
|
-
A claim resting on a source carries a `cites` number, and the source goes in the lesson's one `refs` block rather than the sentence.
|
|
35
|
-
|
|
36
|
-
- Draw every reference from what `canon teach resource --read` recorded, never from a lead, since a lead is a source nobody opened
|
|
37
|
-
- Render refuses a cite no reference resolves, so number the list before citing into it
|
|
38
|
-
|
|
39
|
-
## Building the lesson body
|
|
40
|
-
|
|
41
|
-
Step 4 of `teach-workspace` reads this section before writing a lesson, after the lesson verb has resolved its path and quiz order. Write the chrome as four empty marker pairs rather than composing it by hand.
|
|
42
|
-
|
|
43
|
-
- `<!-- canon:teach:style -->` and `<!-- /canon:teach:style -->` inside `<head>`
|
|
44
|
-
- `<!-- canon:teach:header -->`, `<!-- canon:teach:footnav -->`, and `<!-- canon:teach:scripts -->`, each with its own close marker, in that order in `<body>`
|
|
45
|
-
|
|
46
|
-
### Render the body
|
|
47
|
-
|
|
48
|
-
Build the authored `<h1>`, lede, body, and quiz as a JSON array of blocks, and render it through the verb rather than a component import:
|
|
49
|
-
|
|
50
|
-
```bash
|
|
51
|
-
echo '[
|
|
52
|
-
{"type":"heading","level":1,"text":"<title>"},
|
|
53
|
-
{"type":"paragraph","lede":true,"text":"<the dek>"},
|
|
54
|
-
{"type":"paragraph","text":"<a body paragraph>"},
|
|
55
|
-
{"type":"paragraph","text":"<a claim resting on a source>","cites":[1]},
|
|
56
|
-
{"type":"list","ordered":true,"items":["<step one>","<step two>"]},
|
|
57
|
-
{"type":"raw","html":"<the quiz and teach-back block composed per lesson-craft.md>"},
|
|
58
|
-
{"type":"refs","items":[{"title":"<source name>","url":"<https URL>"}]}
|
|
59
|
-
]' | canon teach render --json
|
|
60
|
-
```
|
|
61
|
-
|
|
62
|
-
`## The block list` above states each type and where `raw` belongs. Write the call's `html` field between the header's close marker and the footnav's open marker, and nothing else anywhere in the file.
|
|
63
|
-
|
|
64
|
-
### When a verb does not resolve
|
|
65
|
-
|
|
66
|
-
Every verb in this section can be missing from an installed CLI that predates it. Report that rather than proceeding silently, and never hand-compose the body, the chrome, or a palette as a fallback.
|
|
67
|
-
|
|
68
|
-
A hand-composed body is the state this section exists to end. A target holds this skill body before the verb, since a plugin skill reaches a target on merge while the CLI arrives only when a release publishes.
|
|
69
|
-
|
|
70
|
-
### Fill the chrome
|
|
71
|
-
|
|
72
|
-
Then run:
|
|
73
|
-
|
|
74
|
-
```bash
|
|
75
|
-
canon teach nav <topic> --json
|
|
76
|
-
```
|
|
77
|
-
|
|
78
|
-
It fills every marker pair from what the workspace holds on disk, and rewrites the workspace's contents page and the teach-root listing in the same run.
|
|
79
|
-
|
|
80
|
-
- The markers take the embedded stylesheet, the header with its breadcrumb and jump menus, the prev and next footer nav, and the behavior scripts
|
|
81
|
-
- It refuses a lesson missing a marker pair by name rather than guessing the boundary, so a dropped marker is caught here rather than read back as a lesson nothing links to
|
|
82
|
-
|
|
83
|
-
### Seed the stylesheet
|
|
84
|
-
|
|
85
|
-
On the first lesson in a workspace, seed the stylesheet through the verb rather than authoring a palette:
|
|
86
|
-
|
|
87
|
-
```bash
|
|
88
|
-
canon teach stylesheet <topic> --json
|
|
89
|
-
```
|
|
90
|
-
|
|
91
|
-
It writes the design tokens as custom properties and the components built on them, from the one source every rendered surface reads.
|
|
92
|
-
|
|
93
|
-
- Add lesson rules under the seed, and reach a value through its property rather than restating the hex, which is how each workspace forked the palette
|
|
94
|
-
- It refuses to overwrite, so a rerun on a workspace with its own rules is safe and reports `written` as false
|
|
95
|
-
|
|
96
|
-
### Add glossary terms
|
|
97
|
-
|
|
98
|
-
Add every term the lesson defines to `GLOSSARY.md` through the verb, which places entries alphabetically in the shape the standard fixes:
|
|
99
|
-
|
|
100
|
-
```bash
|
|
101
|
-
canon teach glossary <topic> --json \
|
|
102
|
-
--term "<term>=<definition, written without using the term>" \
|
|
103
|
-
--first-seen <the lesson or reference page this batch comes from>
|
|
104
|
-
```
|
|
105
|
-
|
|
106
|
-
`--term` repeats and one call writes the file once, which keeps a batch of terms from racing on it. A term already defined is refused, since a definition the subject has moved under is a revision of the entry rather than a second one.
|
|
@@ -1,135 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Lesson craft reference
|
|
3
|
-
description: Typography, restraint, quiz construction, and what makes a lesson worth returning to
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Lesson craft reference
|
|
7
|
-
|
|
8
|
-
Judgment rather than shape. The workspace standard fixes where a lesson sits and what it is named, and this file covers what makes one worth opening twice. The block list and the verbs that build the lesson body sit in `lesson-build.md`.
|
|
9
|
-
|
|
10
|
-
## Contents
|
|
11
|
-
|
|
12
|
-
- [One course, not a pile of pages](#one-course-not-a-pile-of-pages)
|
|
13
|
-
- [Typography](#typography)
|
|
14
|
-
- [Restraint](#restraint)
|
|
15
|
-
- [Diagrams](#diagrams)
|
|
16
|
-
- [Quiz construction](#quiz-construction)
|
|
17
|
-
- [Teach back](#teach-back)
|
|
18
|
-
- [Tokens travel with the course](#tokens-travel-with-the-course)
|
|
19
|
-
- [What makes a lesson worth returning to](#what-makes-a-lesson-worth-returning-to)
|
|
20
|
-
|
|
21
|
-
## One course, not a pile of pages
|
|
22
|
-
|
|
23
|
-
A workspace accumulates lessons over weeks. The learner reads them as one body of material, so a lesson that invents its own look reads as someone else's work.
|
|
24
|
-
|
|
25
|
-
- `canon teach nav` embeds and re-embeds the shared stylesheet into every lesson on each run, so growing that stylesheet, by promoting anything used a second time into it, is the only step left by hand.
|
|
26
|
-
- Keep the structural furniture identical across lessons: where the title sits, where the quiz sits, what a correct answer looks like
|
|
27
|
-
- Do not restate styles inside a lesson. A local override is a decision the next lesson has to either copy or contradict.
|
|
28
|
-
- Refer to another lesson in the workspace as "lesson" plus its four-digit number, such as "lesson 0003". `canon teach nav` links the mention and reports a number naming no lesson.
|
|
29
|
-
- Never hand-write a link to another lesson, the one form nav never checks
|
|
30
|
-
|
|
31
|
-
## Typography
|
|
32
|
-
|
|
33
|
-
The learner is reading, so the reading surface is the product.
|
|
34
|
-
|
|
35
|
-
- Set body text at a comfortable reading size with generous line height, and hold the measure to roughly 65 to 75 characters
|
|
36
|
-
- Use one typeface for prose and one for code, and no others
|
|
37
|
-
- Build hierarchy from size and weight rather than from color. Color that carries meaning fails for a reader who cannot see it.
|
|
38
|
-
- Give code blocks room. Cramped code is the part of a lesson a learner skips.
|
|
39
|
-
|
|
40
|
-
## Restraint
|
|
41
|
-
|
|
42
|
-
Every element competes with the material for attention.
|
|
43
|
-
|
|
44
|
-
- Cut any decoration that carries no information
|
|
45
|
-
- Use at most one accent color, reserved for the thing the learner acts on
|
|
46
|
-
- Do not animate anything the learner did not trigger
|
|
47
|
-
- Prefer whitespace over rules and boxes to separate sections
|
|
48
|
-
|
|
49
|
-
## Diagrams
|
|
50
|
-
|
|
51
|
-
Decide the figure once per lesson, before writing the body.
|
|
52
|
-
|
|
53
|
-
1. Name the one relationship, boundary, path, or before-and-after the lesson is about. A lesson about none ends here, with `Figure: none, <why it names no structure>` on the reply.
|
|
54
|
-
2. Hold it against the bar in `${CLAUDE_SKILL_DIR}/../draw-figure/references/figures.md`, which also carries the drawing rules.
|
|
55
|
-
3. Draw it through `canon:draw-figure` into a `raw` block before the quiz, never inside it or after its feedback, which breaks the stepper's gating. Report an unresolved skill rather than drawing.
|
|
56
|
-
4. Or write one line on why prose carries it better, such as a structure an earlier lesson gave.
|
|
57
|
-
|
|
58
|
-
A structure lesson takes step 3 or 4, never neither. Put the outcome on the reply's `Figure:` line, off the lesson page. Never draw to satisfy the step, or on every section (`## Restraint`).
|
|
59
|
-
|
|
60
|
-
## Quiz construction
|
|
61
|
-
|
|
62
|
-
The quiz is the retrieval, so a leak in its construction turns it into a reading test.
|
|
63
|
-
|
|
64
|
-
- Write every option to the same length, in words and in characters. A longer option reads as the considered one.
|
|
65
|
-
- Write the correct option first and let the ordering verb place it. An author varying position by hand varies it by judgment, which settles on the first slot.
|
|
66
|
-
- Make each wrong option a misconception someone actually holds. An obviously wrong option removes itself and shrinks the question.
|
|
67
|
-
- Write one feedback block per question, covering the correct option and why each distractor fails, saying why rather than whether
|
|
68
|
-
- Give feedback after the attempt, never alongside the question
|
|
69
|
-
|
|
70
|
-
One feedback block reads as an explanation where a block per option reads as four verdicts, and only the explanation names what separates a wrong option from the answer.
|
|
71
|
-
|
|
72
|
-
### The markup
|
|
73
|
-
|
|
74
|
-
The quiz shape is a contract rather than a convention. `canon teach nav` splices a stepper into the lesson that gates on exactly these class names and this nesting, so a quiz written in any other shape renders with every question on screen at once and nothing reports it.
|
|
75
|
-
|
|
76
|
-
```html
|
|
77
|
-
<div class="quiz">
|
|
78
|
-
<h2>Retrieval check</h2>
|
|
79
|
-
|
|
80
|
-
<div class="q"><p class="q-stem">1. <stem></p>
|
|
81
|
-
<label class="opt" data-k="A"><input type="radio" name="q1"><span><the option text></span></label>
|
|
82
|
-
<label class="opt" data-k="B"><input type="radio" name="q1" data-a="1"><span><the option text></span></label>
|
|
83
|
-
<div class="fb"><b>Correct: <the answer in a few words>.</b> <why each distractor fails.></div></div>
|
|
84
|
-
</div>
|
|
85
|
-
```
|
|
86
|
-
|
|
87
|
-
- Give every option in one question the same `name`, and a different `name` per question. Options sharing a name across two questions let one answer clear another.
|
|
88
|
-
- Mark the correct option with `data-a="1"` and leave the others without the attribute
|
|
89
|
-
- Carry `data-k` on the `label`, since the workspace stylesheet renders the key letter from it
|
|
90
|
-
|
|
91
|
-
### Structure and the legacy button
|
|
92
|
-
|
|
93
|
-
The nesting matters as much as the class names.
|
|
94
|
-
|
|
95
|
-
- Keep `.fb` the last child of its `.q`. The stepper reveals it as a direct child, and a feedback block nested deeper stays hidden.
|
|
96
|
-
- Put the option text in a `<span>` inside the label rather than bare beside the input, so the workspace can lay the two out
|
|
97
|
-
- Never write a `<button class="opt">` in a new lesson. That is the shape written before the stepper, and it is kept working by an injected script the presence of a button is what still triggers.
|
|
98
|
-
|
|
99
|
-
The stepper hides and shows and sets nothing else, so how a selected option looks, and whether a wrong one is marked as wrong, is the workspace stylesheet's to grow. Name the correct option in the feedback text for that reason: it is what a learner reads to find out whether they were right.
|
|
100
|
-
|
|
101
|
-
## Teach back
|
|
102
|
-
|
|
103
|
-
A quiz is recognition and a teach-back is production, which is the form retrieval practice prefers. Carry both: the quiz places the learner against options someone could hold, and the teach-back is where the learner finds out what they cannot say without help.
|
|
104
|
-
|
|
105
|
-
- Ask for an explanation to a named audience rather than for an answer. Telling a non-programmer why a lazy quantifier is not an optional one has a floor, and "explain lazy quantifiers" has none.
|
|
106
|
-
- Ask about the thing the lesson was for, not a detail beside it. A teach-back on a footnote tests attention rather than the material.
|
|
107
|
-
- Carry a self-check as a closed `<details>` listing what a complete explanation covers. A learner with no session in the room otherwise cannot grade the ask, and closed leaks nothing.
|
|
108
|
-
- Write the self-check as what the explanation has to cover rather than as the explanation itself. A model answer is read instead of produced, which turns the block back into reading.
|
|
109
|
-
|
|
110
|
-
```html
|
|
111
|
-
<div class="teach-back">
|
|
112
|
-
<h2>Explain it back</h2>
|
|
113
|
-
<p>Without looking above: <the ask, naming who it is for.></p>
|
|
114
|
-
<details><summary>What a complete explanation covers</summary>
|
|
115
|
-
<ul>
|
|
116
|
-
<li><a point the explanation has to reach></li>
|
|
117
|
-
</ul>
|
|
118
|
-
</details>
|
|
119
|
-
</div>
|
|
120
|
-
```
|
|
121
|
-
|
|
122
|
-
It needs no styles of its own beyond what the workspace already gives a section and a `<details>`.
|
|
123
|
-
|
|
124
|
-
## Tokens travel with the course
|
|
125
|
-
|
|
126
|
-
A lesson carries its own values in the shared stylesheet rather than reading a host project's. A workspace runs in any project and most carry no token record at all, so a lesson inheriting one is a lesson that renders unstyled wherever the record is absent, with nothing reporting it.
|
|
127
|
-
|
|
128
|
-
Pick values the material needs rather than values the project happens to hold. Inheriting is worth offering as something a learner asks for once, and it is the wrong default in every project that cannot answer.
|
|
129
|
-
|
|
130
|
-
## What makes a lesson worth returning to
|
|
131
|
-
|
|
132
|
-
- The worked example is complete. A learner returning for the example finds the whole thing rather than a fragment they have to reconstruct.
|
|
133
|
-
- The lesson states what it assumes. A returning reader can tell in one line whether they are in the right place.
|
|
134
|
-
- The hard part is named as the hard part. Material that flattens everything to one difficulty gives a returning reader nothing to navigate by.
|
|
135
|
-
- Nothing depends on the session it was written in. A lesson referring to what was discussed is unreadable a week later.
|
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Fold promoted pages
|
|
3
|
-
description: How teach-workspace's fold mode lands each page a teach promotion handoff carries from a branch, deletes the handoff, and reports what it landed or left unfolded
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Fold promoted pages
|
|
7
|
-
|
|
8
|
-
The fold mode of `teach-workspace`, run from a branch in a worktree. The session reads this file when the invocation asks to fold confirmed promotions in.
|
|
9
|
-
|
|
10
|
-
## Read the handoff
|
|
11
|
-
|
|
12
|
-
Derive `<slug>` per `${CLAUDE_SKILL_DIR}/../git-branch/references/slug.md`, falling back to `latest` on an empty result, and read `.canon/tmp/handoff/teach-promotion/<slug>.md` at the main worktree root.
|
|
13
|
-
|
|
14
|
-
- `teach-workspace` writes it, one H2 per destination naming the path, a source line under the heading, and the page body fenced below that
|
|
15
|
-
- Read the body out of the fence rather than off the heading level, since a reference page carries headings of its own and only the fence separates them from the next destination
|
|
16
|
-
- Stop when the file is absent, reporting `❌ No promotion handoff at .canon/tmp/handoff/teach-promotion/<slug>.md. Run the promotion step from the workspace first.`
|
|
17
|
-
|
|
18
|
-
## Land each block
|
|
19
|
-
|
|
20
|
-
Each block is a page an operator already confirmed a destination for, so this step lands it rather than judging it again. Write to the destination the heading names at `pwd` rather than the main root, since every destination is a tracked file that commits with the branch.
|
|
21
|
-
|
|
22
|
-
- A wiki page and a public doc arrive as a whole file. Write it as the block gives it, and leave the block unfolded when the destination holds a file, since overwriting another's page is not a fold.
|
|
23
|
-
- A context entry is merged into rather than created. Fold the body into the sections it belongs under, and never add an entry the catalog does not already carry.
|
|
24
|
-
|
|
25
|
-
Then delete the handoff file so a later run does not fold it twice, and regenerate the index of any folder that carries one.
|
|
26
|
-
|
|
27
|
-
## Output
|
|
28
|
-
|
|
29
|
-
One line per page landed, one naming the handoff when one was consumed, and one per block left unfolded rather than dropped.
|
|
30
|
-
|
|
31
|
-
```plaintext
|
|
32
|
-
✅ Promoted: <destination path>
|
|
33
|
-
🧹 Folded: .canon/tmp/handoff/teach-promotion/<slug>.md
|
|
34
|
-
⚠ Skipped: <destination path> already exists. Merge by hand.
|
|
35
|
-
```
|
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
# Promotion routing
|
|
2
|
-
|
|
3
|
-
Which surface a durable page from a learning workspace belongs to, and what to do when the destination does not exist yet.
|
|
4
|
-
|
|
5
|
-
## What may be promoted
|
|
6
|
-
|
|
7
|
-
Only the durable half. A reference page under `reference/` and `GLOSSARY.md` carry no learner and are ordinary reference prose about a subject, so they sort under the routing test like anything else.
|
|
8
|
-
|
|
9
|
-
A lesson is never promoted, at any age and on any request. It is generated markup worked through once, carrying a quiz and a second person, and nothing downstream cites it.
|
|
10
|
-
|
|
11
|
-
- Promoting one puts ungated markup into a corpus every other page passed a gate to enter
|
|
12
|
-
- A reference page carrying a quiz, a second person, or an instruction to the learner is a lesson wearing the wrong extension
|
|
13
|
-
- Say so, and propose rewriting that page in place before promotion rather than repairing it at the destination
|
|
14
|
-
|
|
15
|
-
## The routing test
|
|
16
|
-
|
|
17
|
-
Sort by who owns the subject, which is the test the wiki already runs. The reader's activity decided the workspace and decides nothing here.
|
|
18
|
-
|
|
19
|
-
| The page's subject | Destination |
|
|
20
|
-
| -------------------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------- |
|
|
21
|
-
| Owned by Anthropic | the project's wiki |
|
|
22
|
-
| Owned by another tool or vendor, owned by no single vendor, or written for someone consuming what this project ships | the project's public docs |
|
|
23
|
-
| How this project itself works, for the people who build it | `canon/context/<domain>.md`, or the domain's own nested `index.md` when it is already split into a folder |
|
|
24
|
-
|
|
25
|
-
A page a reader cannot sort by that question is a page whose subject has not been settled. Say which two destinations it sits between and let the operator choose, rather than picking the nearer one.
|
|
26
|
-
|
|
27
|
-
## Where the wiki sits
|
|
28
|
-
|
|
29
|
-
The folder has two spellings and a project carries whichever the project created:
|
|
30
|
-
|
|
31
|
-
- `.claude/wiki/`, the folder inside the Claude setup
|
|
32
|
-
- A folder named `wiki` at the project root
|
|
33
|
-
|
|
34
|
-
Read which one exists rather than composing either. A project carrying both keeps its pages at the root, so propose the root spelling and say the other folder is there.
|
|
35
|
-
|
|
36
|
-
### Neither spelling
|
|
37
|
-
|
|
38
|
-
A project carrying neither gets a refusal rather than a scaffold:
|
|
39
|
-
|
|
40
|
-
```plaintext
|
|
41
|
-
❌ No wiki folder. Create `.claude/wiki/` with an `index.md`, then promote again.
|
|
42
|
-
```
|
|
43
|
-
|
|
44
|
-
Creating the folder as a side effect of promoting one page hands the project a surface it never chose, and the refusal is one step from resolved.
|
|
45
|
-
|
|
46
|
-
## What a promoted page owes its destination
|
|
47
|
-
|
|
48
|
-
Each destination gates prose the workspace does not, so name what the page still needs rather than proposing a move that fails at the gate.
|
|
49
|
-
|
|
50
|
-
- A wiki page closes its intro paragraph with a sentence naming who owns the subject, and links the canonical page when one exists. A page carrying no such sentence is not ready to move.
|
|
51
|
-
- A context entry is internal narrative about one domain, so a page landing there merges into an existing entry rather than arriving as a new one.
|
|
52
|
-
- A glossary keeps the shape `glossary.md` fixes wherever it lands, and a promoted one has to state any rule it departs from.
|
|
53
|
-
|
|
54
|
-
## Anti-patterns
|
|
55
|
-
|
|
56
|
-
- **The page promoted into a new context entry.** Entries are created deliberately, so a promotion proposing one is proposing a domain rather than moving a page.
|
|
57
|
-
- **The glossary split across destinations.** Terms drawn from one subject move together or not at all, since an entry defining a term the other half uses strands both.
|
|
58
|
-
- **The workspace emptied on promotion.** Promotion copies rather than moves. The workspace stays readable to the learner who built it, and the page's later life belongs to its destination.
|
|
59
|
-
|
|
60
|
-
## Proposing and handing off
|
|
61
|
-
|
|
62
|
-
Step 6 of `teach-workspace` reads this section once the routing above has placed each page. Propose and wait. A promoted page is public prose that needs a line naming who owns its subject, which is a judgment about ownership rather than a move a session makes on its own reading. Present one block per candidate page:
|
|
63
|
-
|
|
64
|
-
```plaintext
|
|
65
|
-
reference/<slug>.md → <destination path>
|
|
66
|
-
Subject owner: <who owns it, in a few words>
|
|
67
|
-
Still owed: <what the destination expects that the page does not carry yet>
|
|
68
|
-
```
|
|
69
|
-
|
|
70
|
-
Then stop and let the operator strike, redirect, or confirm each block.
|
|
71
|
-
|
|
72
|
-
### Record the handoff
|
|
73
|
-
|
|
74
|
-
Write nothing to a destination here. One skill owns the durable writes, and two skills editing one file at one step is the failure that rule exists against.
|
|
75
|
-
|
|
76
|
-
Record each confirmed block in `.canon/tmp/handoff/teach-promotion/<slug>.md` at the main worktree root instead, appending when the file exists. Each destination takes one H2 naming its path, the source page beneath it, and the page body fenced:
|
|
77
|
-
|
|
78
|
-
````markdown
|
|
79
|
-
## <destination path>
|
|
80
|
-
|
|
81
|
-
Source: .canon/teach/<nn>-<topic>/reference/<slug>.md
|
|
82
|
-
|
|
83
|
-
```markdown
|
|
84
|
-
<the page body as it should land, with the source line the destination expects>
|
|
85
|
-
```
|
|
86
|
-
````
|
|
87
|
-
|
|
88
|
-
Derive `<slug>` per `${CLAUDE_SKILL_DIR}/../git-branch/references/slug.md`. Fall back to `latest` on an empty result.
|
|
89
|
-
|
|
90
|
-
### Why the fence
|
|
91
|
-
|
|
92
|
-
A reference page carries headings of its own, and the reader splits this file on its H2 lines. An unfenced body turns every section heading in the page into a destination naming no path.
|
|
93
|
-
|
|
94
|
-
- Open the body fence with four backticks, so a page carrying a fenced code block still closes where it should
|
|
95
|
-
- Widen both fences together if the page carries a four-backtick fence
|
|
96
|
-
|
|
97
|
-
### Why a file of its own
|
|
98
|
-
|
|
99
|
-
The routed-facts file another skill writes is deleted by whichever pass folds it, so a second producer's unread work would go with it. A sibling path costs the folding skill one more read and removes the interaction.
|
|
100
|
-
|
|
101
|
-
### Sending and reporting
|
|
102
|
-
|
|
103
|
-
An append is a whole-file operation, so send it as a heredoc, per the skill's Step 0. Then tell the operator that `/teach-workspace fold` folds the file in from a branch.
|
|
104
|
-
|
|
105
|
-
The proposal costs nothing tracked and runs anywhere. The page it describes is a tracked file, so the fold is a worktree operation and the workspace it came from is not.
|
|
106
|
-
|
|
107
|
-
### Output
|
|
108
|
-
|
|
109
|
-
A promotion pass reports this shape in place of the skill's Output block, one line per page the operator confirmed and one naming the handoff:
|
|
110
|
-
|
|
111
|
-
```plaintext
|
|
112
|
-
➡️ Promoting: .canon/teach/<nn>-<topic>/reference/<slug>.md → <destination path>
|
|
113
|
-
→ Confirmed pages wait at .canon/tmp/handoff/teach-promotion/<slug>.md. Run /teach-workspace fold from a branch to fold them in.
|
|
114
|
-
```
|
|
115
|
-
|
|
116
|
-
A pass where the operator confirmed nothing writes no handoff file and reports that alone.
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
title: Revisit schedule
|
|
3
|
-
description: How teach-workspace Step 5 writes a learning record's Revisit section, being the bullet shape, where each date and rung is copied from, the first schedule for a new item, and how a later record revises one
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Write the Revisit section
|
|
7
|
-
|
|
8
|
-
Part of Step 5 of `teach-workspace`. The session reads this file once the record's lessons, retrievals, and wrong answers are written, before restating the mission's success lines.
|
|
9
|
-
|
|
10
|
-
Then write `## Revisit`, one bullet per item, in the shape `${CLAUDE_SKILL_DIR}/references/teach.md` fixes:
|
|
11
|
-
|
|
12
|
-
```markdown
|
|
13
|
-
## Revisit
|
|
14
|
-
|
|
15
|
-
- **<what comes back up>**: due <YYYY-MM-DD>, rung <n>
|
|
16
|
-
```
|
|
17
|
-
|
|
18
|
-
## Where the date comes from
|
|
19
|
-
|
|
20
|
-
Take both the date and the rung from the `due` entry Step 1 already read. Copy `hit` for an item the learner retrieved unaided and `miss` for one they did not, with the rung stepped the same way.
|
|
21
|
-
|
|
22
|
-
- Do not compute a date from the ladder. A session told to widen a gap still picks the number by judgment, which is why the verb reports both dates.
|
|
23
|
-
- An item never scheduled has no `due` entry. Open it at rung 1, dated the day after this session, the ladder's floor and the one number this body states.
|
|
24
|
-
- Every later date for that item comes from the verb
|
|
25
|
-
|
|
26
|
-
## Writing the shape exactly
|
|
27
|
-
|
|
28
|
-
An entry outside this shape schedules nothing and nothing reports that it was skipped, so write the shape exactly. A later record naming the same item supersedes an earlier entry, so revise a schedule by writing the new bullet rather than editing the record it was set in.
|