diff --git a/commands/teach.md b/commands/teach.md new file mode 100644 index 0000000..57a23a8 --- /dev/null +++ b/commands/teach.md @@ -0,0 +1,6 @@ +--- +description: Teach the user a new skill or concept over multiple sessions, using the current directory as a stateful teaching workspace. +arguments: [{ name: "topic", description: "What you'd like to learn about. If omitted, the agent will interview you to define the mission.", required: false }] +--- + +Load the `teach` skill and follow its instructions. diff --git a/upstream/.claude-plugin/plugin.json b/upstream/.claude-plugin/plugin.json index 1e37f63..304870a 100644 --- a/upstream/.claude-plugin/plugin.json +++ b/upstream/.claude-plugin/plugin.json @@ -14,6 +14,7 @@ "./skills/productivity/caveman", "./skills/productivity/grill-me", "./skills/productivity/handoff", + "./skills/productivity/teach", "./skills/productivity/write-a-skill" ] } diff --git a/upstream/README.md b/upstream/README.md index 2f4a38d..3011cde 100644 --- a/upstream/README.md +++ b/upstream/README.md @@ -164,6 +164,7 @@ General workflow tools, not code-specific. - **[caveman](./skills/productivity/caveman/SKILL.md)** — Ultra-compressed communication mode. Cuts token usage ~75% by dropping filler while keeping full technical accuracy. - **[grill-me](./skills/productivity/grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved. - **[handoff](./skills/productivity/handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work. +- **[teach](./skills/productivity/teach/SKILL.md)** — Teach the user a new skill or concept over multiple sessions, using the current directory as a stateful teaching workspace. - **[write-a-skill](./skills/productivity/write-a-skill/SKILL.md)** — Create new skills with proper structure, progressive disclosure, and bundled resources. ### Misc diff --git a/upstream/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md b/upstream/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md index 0830255..eaf2a18 100644 --- a/upstream/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md +++ b/upstream/skills/engineering/grill-with-docs/CONTEXT-FORMAT.md @@ -24,13 +24,10 @@ _Avoid_: Client, buyer, account ## Rules -- **Be opinionated.** When multiple words exist for the same concept, pick the best one and list the others as aliases to avoid. -- **Flag conflicts explicitly.** If a term is used ambiguously, call it out in "Flagged ambiguities" with a clear resolution. +- **Be opinionated.** When multiple words exist for the same concept, pick the best one and list the others under `_Avoid_`. - **Keep definitions tight.** One or two sentences max. Define what it IS, not what it does. -- **Show relationships.** Use bold term names and express cardinality where obvious. - **Only include terms specific to this project's context.** General programming concepts (timeouts, error types, utility patterns) don't belong even if the project uses them extensively. Before adding a term, ask: is this a concept unique to this context, or a general programming concept? Only the former belongs. - **Group terms under subheadings** when natural clusters emerge. If all terms belong to a single cohesive area, a flat list is fine. -- **Write an example dialogue.** A conversation between a dev and a domain expert that demonstrates how the terms interact naturally and clarifies boundaries between related concepts. ## Single vs multi-context repos diff --git a/upstream/skills/engineering/to-prd/SKILL.md b/upstream/skills/engineering/to-prd/SKILL.md index 47a01d4..ee758fd 100644 --- a/upstream/skills/engineering/to-prd/SKILL.md +++ b/upstream/skills/engineering/to-prd/SKILL.md @@ -11,11 +11,9 @@ The issue tracker and triage label vocabulary should have been provided to you 1. Explore the repo to understand the current state of the codebase, if you haven't already. Use the project's domain glossary vocabulary throughout the PRD, and respect any ADRs in the area you're touching. -2. Sketch out the major modules you will need to build or modify to complete the implementation. Actively look for opportunities to extract deep modules that can be tested in isolation. +2. Sketch out the seams at which you're going to test the feature. Existing seams should be preferred to new ones. Use the highest seam possible. If new seams are needed, propose them at the highest point you can. -A deep module (as opposed to a shallow module) is one which encapsulates a lot of functionality in a simple, testable interface which rarely changes. - -Check with the user that these modules match their expectations. Check with the user which modules they want tests written for. +Check with the user that these seams match their expectations. 3. Write the PRD using the template below, then publish it to the project issue tracker. Apply the `ready-for-agent` triage label - no need for additional triage. diff --git a/upstream/skills/productivity/README.md b/upstream/skills/productivity/README.md index 3a5b951..23a506e 100644 --- a/upstream/skills/productivity/README.md +++ b/upstream/skills/productivity/README.md @@ -5,4 +5,5 @@ General workflow tools, not code-specific. - **[caveman](./caveman/SKILL.md)** — Ultra-compressed communication mode. Cuts token usage ~75% by dropping filler while keeping full technical accuracy. - **[grill-me](./grill-me/SKILL.md)** — Get relentlessly interviewed about a plan or design until every branch of the decision tree is resolved. - **[handoff](./handoff/SKILL.md)** — Compact the current conversation into a handoff document so another agent can continue the work. +- **[teach](./teach/SKILL.md)** — Teach the user a new skill or concept over multiple sessions, using the current directory as a stateful teaching workspace. - **[write-a-skill](./write-a-skill/SKILL.md)** — Create new skills with proper structure, progressive disclosure, and bundled resources. diff --git a/upstream/skills/productivity/teach/GLOSSARY-FORMAT.md b/upstream/skills/productivity/teach/GLOSSARY-FORMAT.md new file mode 100644 index 0000000..9cae84c --- /dev/null +++ b/upstream/skills/productivity/teach/GLOSSARY-FORMAT.md @@ -0,0 +1,35 @@ +# GLOSSARY.md Format + +`GLOSSARY.md` is the canonical language for this teaching workspace. All explainers, exercises, and learning records should adhere to its terminology. Building it is itself part of learning: compressing a concept into a tight definition is evidence the user understands it. + +## Structure + +```md +# {Topic} Glossary + +{One or two sentence description of the topic this glossary covers.} + +## Terms + +**Hypertrophy**: +Muscle growth driven by mechanical tension and metabolic stress over repeated training sessions. +_Avoid_: Bulking, getting big + +**Progressive overload**: +Systematically increasing the demand on a muscle over time — via load, volume, or intensity. +_Avoid_: Pushing harder, levelling up + +**RPE (Rate of Perceived Exertion)**: +A 1–10 self-rating of how hard a set felt, where 10 is failure and 8 means two reps left in the tank. +_Avoid_: Effort score, intensity rating +``` + +## Rules + +- **Add a term only when the user understands it.** The glossary is a record of compressed knowledge, not a dictionary the user reads to learn. If the user has just been introduced to a concept, wait until they can use it correctly before promoting it here. +- **Be opinionated.** When several words exist for the same concept, pick the best one and list the rest as aliases to avoid. This is how language compresses. +- **Keep definitions tight.** One or two sentences. Define what the term IS, not what it does or how to do it. +- **Use the glossary's own terms inside definitions.** Once a term is in the glossary, prefer it everywhere — including inside other definitions. This is what makes complex terms easier to grasp later. +- **Group under subheadings** when natural clusters emerge (e.g. `## Anatomy`, `## Programming`). A flat list is fine when terms cohere. +- **Flag ambiguities explicitly.** If a term is used loosely in the wider field, note the resolution: "In this workspace, 'set' always means a working set — warm-ups are tracked separately." +- **Revise as understanding deepens.** A definition the user wrote in week one may be wrong by week six. Update in place; do not leave stale entries. diff --git a/upstream/skills/productivity/teach/LEARNING-RECORD-FORMAT.md b/upstream/skills/productivity/teach/LEARNING-RECORD-FORMAT.md new file mode 100644 index 0000000..2faa7c9 --- /dev/null +++ b/upstream/skills/productivity/teach/LEARNING-RECORD-FORMAT.md @@ -0,0 +1,46 @@ +# Learning Record Format + +Learning records live in `./learning-records/` and use sequential numbering: `0001-slug.md`, `0002-slug.md`, etc. Create the directory lazily — only when the first record is written. + +They are the teaching equivalent of ADRs: they capture non-obvious lessons, key insights, and stated prior knowledge that will steer future sessions. They are used to calculate the zone of proximal development. + +## Template + +```md +# {Short title of what was learned or established} + +{1-3 sentences: what was learned (or what prior knowledge was established), and why it matters for future sessions.} +``` + +That is the whole format. A learning record can be a single paragraph. The value is recording _that_ this is now known and _why_ it changes what to teach next — not in filling out sections. + +## Optional sections + +Only include these when they add genuine value. Most records won't need them. + +- **Status** frontmatter (`active | superseded by LR-NNNN`) — useful when an earlier understanding turns out to be wrong and is replaced. +- **Evidence** — how the user demonstrated the understanding (a question answered, an exercise completed, prior experience cited). Useful when the claim might be revisited. +- **Implications** — what this unlocks or rules out for future sessions. Worth recording when non-obvious. + +## Numbering + +Scan `./learning-records/` for the highest existing number and increment by one. + +## When to write a learning record + +Write one when any of these is true: + +1. **The user demonstrated genuine understanding of something non-trivial** — not just exposure, but evidence they can use the concept correctly. This sets a new floor for what to teach next. +2. **The user disclosed prior knowledge** — "I already know X." Record it so future sessions don't re-teach it. Also record the _depth_ claimed. +3. **A misconception was corrected** — the user previously believed something wrong and now sees why. These are high-value: they predict future stumbling blocks for related topics. +4. **The mission shifted in response to learning** — the user discovered they cared about something different than they thought. Cross-link to [[MISSION.md]] and update it. + +### What does _not_ qualify + +- Material that was merely covered. Coverage is not learning. Wait for evidence. +- Anything already captured tersely in [[GLOSSARY.md]] as a term definition. Don't duplicate. +- Session-by-session activity logs. Learning records are not a journal — they are decision-grade insights. + +## Supersession + +When a later record contradicts an earlier one (the user's understanding deepened or corrected), mark the old record `Status: superseded by LR-NNNN` rather than deleting it. The history of how understanding evolved is itself useful signal. diff --git a/upstream/skills/productivity/teach/MISSION-FORMAT.md b/upstream/skills/productivity/teach/MISSION-FORMAT.md new file mode 100644 index 0000000..5dac184 --- /dev/null +++ b/upstream/skills/productivity/teach/MISSION-FORMAT.md @@ -0,0 +1,31 @@ +# MISSION.md Format + +`MISSION.md` lives at the workspace root. It captures the _reason_ the user is learning this topic. Every teaching decision — what to teach next, which resources to surface, which exercises to design — should trace back to this document. + +## Template + +```md +# Mission: {Topic} + +## Why +{1-3 sentences. The concrete real-world goal the user is chasing. What changes in their life or work when they have this skill? Avoid abstract framings like "to understand X" — push for the underlying outcome.} + +## Success looks like +- {A specific, observable thing the user will be able to do} +- {Another specific thing} +- {…} + +## Constraints +- {Time, budget, prior commitments, learning preferences, anything that bounds the approach} + +## Out of scope +- {Adjacent topics the user explicitly does not want to chase right now — protects the zone of proximal development} +``` + +## Rules + +- **One mission per workspace.** If the user wants to learn two unrelated things, that is two workspaces. +- **Concrete over abstract.** "Run a half marathon by October" beats "get fitter." "Ship a Rust CLI to my team" beats "learn Rust." +- **Push back on vagueness.** If the user cannot articulate why, interview them before writing anything. A bad mission is worse than no mission. +- **Revise when reality shifts.** Missions change. When the user's goal moves, update this file — don't leave a stale mission steering future sessions. +- **Keep it short.** If `MISSION.md` runs past a screen, it has stopped being a compass and started being a plan. diff --git a/upstream/skills/productivity/teach/RESOURCES-FORMAT.md b/upstream/skills/productivity/teach/RESOURCES-FORMAT.md new file mode 100644 index 0000000..c94aac6 --- /dev/null +++ b/upstream/skills/productivity/teach/RESOURCES-FORMAT.md @@ -0,0 +1,32 @@ +# RESOURCES.md Format + +`RESOURCES.md` is the curated set of trusted sources for this topic. Knowledge for explainers should be drawn from here, not from parametric guesses. Wisdom comes from the communities listed here. + +## Structure + +```md +# {Topic} Resources + +## Knowledge + +- [Book: _The Science and Practice of Strength Training_ — Zatsiorsky & Kraemer](https://example.com) + Foundational text on programming and adaptation. Use for: anything to do with periodisation, recovery, intensity zones. +- [Article: "How Much Should I Train?" — Greg Nuckols (Stronger By Science)](https://example.com) + Evidence-based review of volume landmarks. Use for: weekly set targets per muscle group. + +## Wisdom (Communities) + +- [r/weightroom](https://reddit.com/r/weightroom) + High-signal subreddit, moderated against bro-science. Use for: programme critique, plateau troubleshooting. +- Local: Tuesday strength class at {gym name} + Use for: real-time coaching feedback on lifts. +``` + +## Rules + +- **High-trust only.** Prefer primary sources, recognised experts, peer-reviewed work, and communities with strong moderation. If a resource is marketing dressed as education, leave it out. +- **Annotate every entry.** A bare link is useless in three months. Add one line: what it covers and when to reach for it. +- **Group by Knowledge / Wisdom.** Mirrors the philosophy in [SKILL.md](./SKILL.md). It is fine for a resource to appear in only one group. +- **Surface gaps explicitly.** If no good resource exists for an area the mission needs, write a `## Gaps` section listing what is missing. This drives future search. +- **Prune ruthlessly.** A resource that turned out to be wrong, shallow, or off-mission should be removed, not buried. Better five sharp sources than thirty mediocre ones. +- **Record community preferences.** If the user has opted out of joining communities, note it here so future sessions don't keep proposing them. diff --git a/upstream/skills/productivity/teach/SKILL.md b/upstream/skills/productivity/teach/SKILL.md new file mode 100644 index 0000000..2fad9a3 --- /dev/null +++ b/upstream/skills/productivity/teach/SKILL.md @@ -0,0 +1,131 @@ +--- +name: teach +description: Teach the user a new skill or concept, within this workspace. +disable-model-invocation: true +argument-hint: "What would you like to learn about?" +--- + +The user has asked you to teach them something. This is a stateful request - they intend to learn the topic over multiple sessions. + +## Teaching Workspace + +Treat the current directory as a teaching workspace. The state of their learning is captured in this directory in several files: + +- `MISSION.md`: A document capturing the _reason_ the user is interested in the topic. This should be used to ground all teaching. Use the format in [MISSION-FORMAT.md](./MISSION-FORMAT.md). +- `./reference/*.html`: A directory of reference materials. These are the compressed learnings from the lessons - cheat sheets, reference algorithms, syntax, yoga poses, glossaries. They are the raw units of learning. They should be beautiful documents which print out well, and are designed for quick reference. +- `RESOURCES.md`: A list of resources which can be explored to ground your teaching in contextual knowledge, or to acquire knowledge and wisdom. Use the format in [RESOURCES-FORMAT.md](./RESOURCES-FORMAT.md). +- `./learning-records/*.md`: A directory of learning records, which capture what the user has learned. These are loosely equivalent to architectural decision records in software development - they capture non-obvious lessons and key insights that may need to be revised later, or drive future sessions. These should be used to calculate the zone of proximal development. They are titled `0001-.md`, where the number increments each time. Use the format in [LEARNING-RECORD-FORMAT.md](./LEARNING-RECORD-FORMAT.md). +- `./lessons/*.html`: A directory of lessons. A **lesson** is a single, self-contained HTML output that teaches one tightly-scoped thing tied to the mission. This is the primary unit of teaching in this workspace. +- `NOTES.md`: A scratchpad for you to jot down user preferences, or working notes. + +## Philosophy + +To learn at a deep level, the user needs three things: + +- **Knowledge**, captured from high-quality, high-trust resources +- **Skills**, acquired through highly-relevant interactive lessons devised by you, based on the knowledge +- **Wisdom**, which comes from interacting with other learners and practitioners + +Before the `RESOURCES.md` is well-populated, your focus should be to find high-quality resources which will help the user acquire knowledge. Never trust your parametric knowledge. + +Some topics may require more skills than knowledge. Learning more about theoretical physics might be more knowledge-based. For yoga, more skills-based. + +### Fluency vs Storage Strength + +You should be careful to split between two types of learning: + +- **Fluency strength**: in-the-moment retrieval of knowledge +- **Storage strength**: long-term retention of knowledge + +Fluency can give the user an illusory sense of mastery, but storage strength is the real goal. Try to design lessons which build long-term retention by desirable difficulty: + +- Using retrieval practice (recall from memory) +- Spacing (distributing practice over time) +- Interleaving (mixing up different but related topics in practice - for skills practice only) + +## Lessons + +A lesson is the main thing you produce — the unit in which knowledge and skills reach the user. Each lesson is one self-contained HTML file, saved to `./lessons/` and titled `0001-.html` where the number increments each time. + +A lesson should be **beautiful** — clean, readable typography and layout — since the user will return to these later to review. Think Tufte. + +The lesson should be short, and completable very quickly. Learners' working memory is very small, and we need to stay within it. But each lesson should give the user a single tangible win that they can build on. It should be directly tied to the mission, and should be in the user's zone of proximal development. + +If possible, open the lesson file for the user by running a CLI command. + +Each lesson should link via HTML anchors to other lessons and reference documents. + +Each lesson should recommend a primary source for the user to read or watch. This should be the most high-quality, high-trust resource you found on the topic. + +Each lesson should contain a reminder to ask followup questions to the agent. The agent is their teacher, and can assist with anything that's unclear. + +## The Mission + +Every lesson should be tied into the mission - the reason that the user is interested in learning about the topic. + +If the user is unclear about the mission, or the `MISSION.md` is not populated, your first job should be to question the user on why they want to learn this. + +Failing to understand the mission will mean knowledge acquisition is not grounded in real-world goals. Lessons will feel too abstract. You will have no way of judging what the user should do next. + +Missions may change as the user develops more skills and knowledge. This is normal - make sure to update the `MISSION.md` and add a learning record to capture the change. Confirm with the user before changing the mission. + +## Zone Of Proximal Development + +Each lesson, the user should always feel as if they are being challenged 'just enough'. + +The user may specify an exact thing they want to learn. If they don't, figure out their zone of proximal development by: + +- Reading their `learning-records` +- Figuring out the right thing to teach them based on their mission +- Teach the most relevant thing that fits in their zone of proximal development + +## Knowledge + +Lessons should be designed around a skill the user is going to learn. The knowledge in the lesson should be only what's required to acquire that skill. You teach the knowledge first, then get the user to practice the skills via an interactive feedback loop. + +Knowledge should first be gathered from trusted resources. Use `RESOURCES.md` to keep track of them. Lessons should be littered with citations - links to external resources to back up any claim made. This increases the trustworthiness of the lesson. + +For acquiring knowledge, difficulty is the enemy. It eats working memory you need for understanding. + +## Skills + +If knowledge is all about acquisition, skills are about durability and flexibility. Make the knowledge stick. + +For skill acquisition, difficulty is the tool. Effortful retrieval is what builds storage strength. Skills should be taught through interactive lessons. There are several tools at your disposal: + +- Interactive lessons, using quizzes and light in-browser tasks +- Lessons which guide the user through a list of real-world steps to take (for instance, yoga poses) + +Each of these should be based on a **feedback loop**, where the user receives feedback on their performance. This feedback loop should be as tight as possible, giving feedback immediately - and ideally automatically. + +For quizzes, each answer should be exactly the same number of words (and characters, if possible). Don't give the user any clues about the answer through formatting. + +## Acquiring Wisdom + +Wisdom comes from true real-world interaction - testing your skills outside the learning environment. + +When the user asks a question that appears to require wisdom, your default posture should be to attempt to answer - but to ultimately delegate to a **community**. + +A community is a place (online or offline) where the user can test their skills in the real world. This might be a forum, a subreddit, a real-world class (budget permitting) or a local interest group. + +You should attempt to find high-reputation communities the user can join. If the user expresses a preference that they don't want to join a community, respect it. + +## Reference Documents + +While creating lessons, you should also create reference documents. Lessons can reference these documents - they are useful for tracking raw units of knowledge useful across lessons. + +Lessons will rarely be revisited later - reference documents will be. They should be the compressed essence of the lesson, in a format designed for quick reference. + +Some learning topics lend themselves to reference: + +- Syntax and code snippets for programming +- Algorithms and flowcharts for processes +- Yoga poses and sequences for yoga +- Exercises and routines for fitness +- Glossaries for any topic with its own nomenclature + +Glossaries, in particular, are an essential reference. Once one is created, it should be adhered to in every lesson. + +## `NOTES.md` + +The user will sometimes express preferences of how they want to be taught, or things you should keep in mind. This is the place to record those preferences, so you can refer back to them when designing lessons or working with the user.