@windyroad/retrospective 0.6.0 → 0.8.0-preview.185

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.
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "wr-retrospective",
3
- "version": "0.6.0",
3
+ "version": "0.8.0",
4
4
  "description": "Session retrospective reminders and plan review for Claude Code"
5
5
  }
package/hooks/hooks.json CHANGED
@@ -1,10 +1,33 @@
1
1
  {
2
2
  "hooks": {
3
3
  "SessionStart": [
4
- { "hooks": [{ "type": "command", "command": "${CLAUDE_PLUGIN_ROOT}/bin/check-deps.sh wr-retrospective wr-itil wr-risk-scorer" }] }
4
+ {
5
+ "hooks": [
6
+ {
7
+ "type": "command",
8
+ "command": "${CLAUDE_PLUGIN_ROOT}/bin/check-deps.sh wr-retrospective wr-itil wr-risk-scorer"
9
+ }
10
+ ]
11
+ },
12
+ {
13
+ "matcher": "startup",
14
+ "hooks": [
15
+ {
16
+ "type": "command",
17
+ "command": "${CLAUDE_PLUGIN_ROOT}/hooks/session-start-briefing.sh"
18
+ }
19
+ ]
20
+ }
5
21
  ],
6
22
  "Stop": [
7
- { "hooks": [{ "type": "command", "command": "${CLAUDE_PLUGIN_ROOT}/hooks/retrospective-reminder.sh" }] }
23
+ {
24
+ "hooks": [
25
+ {
26
+ "type": "command",
27
+ "command": "${CLAUDE_PLUGIN_ROOT}/hooks/retrospective-reminder.sh"
28
+ }
29
+ ]
30
+ }
8
31
  ]
9
32
  }
10
33
  }
@@ -0,0 +1,29 @@
1
+ #!/bin/bash
2
+ # wr-retrospective — SessionStart hook (P100 slice 2, ADR-040)
3
+ # Surfaces the "Critical Points" roll-up from docs/briefing/README.md at session start.
4
+ # Fires only on matcher="startup" per hooks.json; silent no-op if briefing tree is absent.
5
+
6
+ set -euo pipefail
7
+
8
+ BRIEFING_README="${CLAUDE_PROJECT_DIR:-.}/docs/briefing/README.md"
9
+
10
+ # No briefing tree yet (adopter hasn't run /wr-retrospective:run-retro) — silent exit.
11
+ [ -f "$BRIEFING_README" ] || exit 0
12
+
13
+ # Extract everything under "## Critical Points (Session-Start Surface)" up to (but not
14
+ # including) the next level-2 heading.
15
+ CRITICAL_POINTS=$(awk '
16
+ /^## Critical Points \(Session-Start Surface\)/ { in_section=1; next }
17
+ in_section && /^## / { exit }
18
+ in_section { print }
19
+ ' "$BRIEFING_README")
20
+
21
+ # Section missing (e.g. older briefing README format) — silent exit.
22
+ [ -n "$CRITICAL_POINTS" ] || exit 0
23
+
24
+ cat <<EOF
25
+ CROSS-SESSION BRIEFING — critical points (source: docs/briefing/README.md).
26
+ Read that file for the full topic index + per-topic files when context warrants.
27
+
28
+ $CRITICAL_POINTS
29
+ EOF
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@windyroad/retrospective",
3
- "version": "0.6.0",
3
+ "version": "0.8.0-preview.185",
4
4
  "description": "Session retrospectives that update briefings and create problem tickets",
5
5
  "bin": {
6
6
  "windyroad-retrospective": "./bin/install.mjs"
@@ -12,7 +12,7 @@ Reflect on the current session, update the project briefing, and create problem
12
12
 
13
13
  ### 1. Read the current briefing
14
14
 
15
- Read `docs/BRIEFING.md` to understand what previous sessions already captured.
15
+ Read `docs/briefing/README.md` — the per-topic index, Critical Points summary, and per-file hooks. Then read each topic file referenced in the Topic Index (`docs/briefing/<topic>.md`) to understand what previous sessions captured under each heading. During the P100 transition window the legacy single-file `docs/BRIEFING.md` may still exist as a stub pointer; it is read-only until P100 slice 2 retires it.
16
16
 
17
17
  ### 2. Reflect on this session
18
18
 
@@ -100,19 +100,26 @@ The shape mirrors P068's Step 4a Verification-close housekeeping: glob / evidenc
100
100
  - **Step 4 (problem-ticket creation)** — Step 2b feeds Step 4. A detection surfaced in Step 2b that the user accepts becomes a Step 4 creation or update via the manage-problem delegation. Step 4b's Stage 1 two-stage codification flow (P075) applies to pipeline-instability tickets the same way it applies to Step 2 reflection tickets — the detection IS the codify-worthy observation.
101
101
  - **ADR-027 compatibility note**: when ADR-027's Step-0 auto-delegation lands on run-retro, Step 2b's evidence scan is load-bearing on main-agent session context that a delegated subagent does not automatically inherit. The migration path mirrors Step 4a's: either (a) run Step 2b in the main-agent context BEFORE Step-0 delegation to the subagent, or (b) include an explicit session-activity summary (tool invocations, commits, skill calls observed in main-agent context) in the Step-0 delegation prompt. Option (a) is preferred to keep the evidence scan close to the observed activity.
102
102
 
103
- ### 3. Update BRIEFING.md
103
+ ### 3. Update the briefing tree
104
104
 
105
- Edit `docs/BRIEFING.md`:
105
+ Edit `docs/briefing/<topic>.md` files — each topic file is per-subject (`hooks-and-gates.md`, `releases-and-ci.md`, `governance-workflow.md`, `afk-subprocess.md`, `plugin-distribution.md`, `agent-interaction-patterns.md`). Select the topic file whose scope matches the learning; if no file fits, add a new topic file under `docs/briefing/` and update `docs/briefing/README.md`'s Topic Index accordingly.
106
106
 
107
- - **Add** new learnings to the appropriate section ("What You Need to Know" or "What Will Surprise You")
107
+ For each accepted learning:
108
+
109
+ - **Add** new entries to the matching topic file under the right section ("What You Need to Know" or "What Will Surprise You"). If the learning spans topics, pick the file whose fix-path is most concrete and cross-reference from the other topic file.
108
110
  - **Remove** stale items that are no longer true. A learning is stale when:
109
111
  - The issue has been fixed (e.g., "CI doesn't test v2" after v2 tests are added)
110
112
  - It's now documented elsewhere (e.g., in an ADR, CLAUDE.md, or README)
111
113
  - The codebase has changed enough that it's no longer relevant
112
- - **Update** items where the details have changed
113
- - Keep the file concise — under 2000 tokens. Each item should be 1-2 lines.
114
+ - **Update** items where the details have changed.
115
+ - Keep each topic file naturally bounded per-topic files replace the legacy under-2000-token budget on a single file. If a topic file grows past ~20 entries, consider splitting further.
116
+
117
+ After editing topic files, update `docs/briefing/README.md`:
118
+
119
+ - Refresh per-file summaries in the Topic Index if the topic file's character changed.
120
+ - Promote an entry into the Critical Points section only when it is genuinely among the highest-value rules of the session (the session-start surface is small and curated — adding there is a user-interactive decision per the helpfulness rating slice 2 will add).
114
121
 
115
- Use the AskUserQuestion tool to confirm any removals: "I'd like to remove [item] from BRIEFING.md because [reason]. Is this correct?"
122
+ Use the AskUserQuestion tool to confirm any removals: "I would like to remove [item] from `docs/briefing/<topic>.md` because [reason]. Is this correct?"
116
123
 
117
124
  ### 4. Create or update problem tickets
118
125
 
@@ -246,10 +253,11 @@ Present a summary to the user:
246
253
  ```
247
254
  ## Session Retrospective
248
255
 
249
- ### BRIEFING.md Changes
250
- - Added: [items added]
256
+ ### Briefing Changes
257
+ - Added: [items added — cite `docs/briefing/<topic>.md` per entry]
251
258
  - Removed: [items removed with reasons]
252
259
  - Updated: [items modified]
260
+ - README index refreshed: [per-file summaries or Critical Points changes]
253
261
 
254
262
  ### Problems Created/Updated
255
263
  - [problem ticket]: [summary]