$npx -y skills add specstoryai/getspecstory --skill workthreadsSpecStory Workthreads - a weekly work-thread rollup across a team's repos from SpecStory coding histories (any agent - Claude Code, Codex, Cursor, Gemini, and more). It groups the window's sessions into threads of work per project and labels each new / open / recently closed, so
| 1 | # Workthreads |
| 2 | |
| 3 | A lead needs a weekly answer across the team's repos: what work happened this week, what got |
| 4 | finished, and what is still open and needs a next step. **Workthreads** produces that **rollup** |
| 5 | from SpecStory histories - the `.specstory/history` transcripts your coding agents already write. |
| 6 | It reports **lines of work and their lifecycle** (new / open / recently closed). |
| 7 | |
| 8 | A deterministic engine (`scripts/workthreads.mjs threads`) does the retrieval, clustering, and |
| 9 | classification; **you do the synthesis** - you turn its evidence into the lead's weekly report. |
| 10 | Do not try to read raw transcripts yourself; they can be hundreds of thousands of lines. Run the |
| 11 | engine and write the rollup from its output. |
| 12 | |
| 13 | This skill is **harness-portable** (agentskills.io format). Where it names a specific tool |
| 14 | (e.g. `AskUserQuestion`), treat that as "use your harness's equivalent; fall back to plain chat." |
| 15 | |
| 16 | ## How the engine splits the work |
| 17 | |
| 18 | - The engine groups the window's beats **by project** and clusters them into **threads** (a line |
| 19 | of work that can span several sessions). It assigns each thread one lifecycle **status** relative |
| 20 | to today: |
| 21 | - **new** - first activity within the last 7 days. |
| 22 | - **open** - unresolved, still active (the open loops). |
| 23 | - **closed** - latest outcome was success and the thread has gone quiet; flagged **reverted** |
| 24 | when a beat ran a rollback command (`git revert` / `git reset --hard` / `git checkout -- ...`). |
| 25 | - Output is deterministic (stable sort, no wall-clock timestamps in the body), so two runs on the |
| 26 | same corpus are byte-identical. |
| 27 | |
| 28 | ## Default flow: the weekly rollup |
| 29 | |
| 30 | 1. **Index the corpus** into workthreads' own DB. Point at the team's repos and build/update it: |
| 31 | ```bash |
| 32 | node "${CLAUDE_SKILL_DIR}/scripts/workthreads.mjs" index --projects <parent-of-repos> --db <db> |
| 33 | # or a single tree: --scan <root> or a single history dir: --dir <dir> |
| 34 | ``` |
| 35 | |
| 36 | 2. **Run `threads` cross-project for the last 7 days** and capture the evidence: |
| 37 | ```bash |
| 38 | node "${CLAUDE_SKILL_DIR}/scripts/workthreads.mjs" threads --db <db> --days 7 # human digest |
| 39 | node "${CLAUDE_SKILL_DIR}/scripts/workthreads.mjs" threads --db <db> --days 7 --json # machine-readable |
| 40 | ``` |
| 41 | The digest prints, per project, three sections in order - **New**, **Open**, **Recently |
| 42 | closed** - each thread with its evidence refs (`path:line`), last-activity date, status, and a |
| 43 | `reverted` marker. `--json` emits an array of threads (`project`, `status`, `reverted`, the files |
| 44 | touched, last-activity date). |
| 45 | |
| 46 | 3. **Write the rollup** from that evidence, in the lead's shape: |
| 47 | - (a) a high-level result: session count and active projects in the window; |
| 48 | - (b) per-project **highlights** of completed work (the `closed` threads); |
| 49 | - (c) **open loops** - the `open` threads, unresolved or needing verification, with a suggested |
| 50 | next step each; |
| 51 | - (d) notable **rollbacks / abandoned efforts** (the `reverted` threads); |
| 52 | - (e) cite evidence refs (`path:line`) so each claim is checkable. |
| 53 | Add a caveat that **the week may still be in progress**, so `open` and `new` threads are |
| 54 | snapshots, not final outcomes. |
| 55 | |
| 56 | 4. **Save it to a dated file** so the rollup is durable and diffable week over week: |
| 57 | ``` |
| 58 | .specstory/workthreads/<YYYY>-W<week>.md |
| 59 | ``` |
| 60 | (ISO week number, e.g. `.specstory/workthreads/2026-W25.md`). Also offer `threads --out <file>` |
| 61 | to drop the raw digest beside your written summary. |
| 62 | |
| 63 | ## Guided start |
| 64 | |
| 65 | If the user just invokes the skill with no specifics, ask three short questions (use |
| 66 | `AskUserQuestion` or plain chat), then run the default flow with the answers: |
| 67 | |
| 68 | - **Scope** - which repos / parent directory holds the team's `.specstory/history` corpus? |
| 69 | - **Window** - how many days back? (default **7** for the weekly rollup; `--days N` to widen.) |
| 70 | - **Goal** - the whole **rollup**, just the **open loops**, just **recently closed**, or a quick |
| 71 | **status** line? Tailor which sections you emphasize to the answer. |
| 72 | |
| 73 | ## Conventions |
| 74 | |
| 75 | Node ESM only, zero dependencies, Node >= 22.5. No em dashes anywhere (use " - "). The engine path |
| 76 | never calls an LLM or the network; all judgment (the written |