Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .claude-plugin/marketplace.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
"name": "overnight-insight-discovery",
"source": "./plugins/overnight-insight-discovery",
"description": "Overnight autonomous B-vs-C parallel insight discovery that surfaces genuinely ah-ha findings from data, with a cohort-conditional novelty gate, an observational-analysis validity gate (composition / leak / anchor-timing / marker-vs-lever), adaptive tuning, and an agent-review-panel loop.",
"version": "1.1.1"
"version": "1.2.0"
},
{
"name": "overnight-review-client-delivery",
Expand Down Expand Up @@ -46,13 +46,13 @@
"name": "schedule-poll-orchestrator-pattern",
"source": "./plugins/schedule-poll-orchestrator-pattern",
"description": "Fire-ASAP orchestrator pattern for multi-track autonomous overnight workflows on scheduled triggers \u2014 a self-rescheduling poll loop that consolidates the moment all tracks report complete, and survives a 12-20h session end. Companion safety pattern.",
"version": "1.0.0"
"version": "1.0.1"
},
{
"name": "observational-analysis-rigor",
"source": "./plugins/observational-analysis-rigor",
"description": "A validity toolkit for observational data analysis (no randomization): 31 skills covering leak-free point-in-time cohorts, composition/Simpson decomposition, event-anchor timing inversion, marker-vs-lever discipline, coverage-limited-join bias, provenance/re-derivation, and de-stale delivery to every rendered surface \u2014 the deep-dives behind overnight-insight-discovery's analytical validity gate.",
"version": "1.2.2"
"version": "1.3.0"
}
]
}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -164,6 +164,7 @@ All three plugins encode patterns from real overnight runs. `overnight-review-cl

## Version history

- **2026-08-06** — `overnight-insight-discovery` → **v1.2.0** and `schedule-poll-orchestrator-pattern` → **v1.0.1** (both manifests each + bundle `VERSION` → 1.4.0): fixes the single-root skill-path bug in two places. A skill installed as a **plugin** lives at `~/.claude/plugins/cache/<marketplace>/<plugin>/<version>/`, not at `~/.claude/skills/<name>/`, so anything that reaches a skill through the `~/.claude/skills/` root alone misses on a plugin install. **The one with teeth**: `overnight-insight-discovery`'s Phase 0.Y toolchain pre-flight decided whether the skill was installed with a single `test -f ~/.claude/skills/overnight-insight-discovery/SKILL.md`. On a plugin install that test fails, and the failure path is a tap-out with `[ENV_BLOCKER]` reporting no skill tree — a failed lookup reported as an install-state finding. It now probes all three roots (`$CLAUDE_PLUGIN_ROOT`, `~/.claude/skills/`, then the plugin cache), ranks cache hits on the **version** segment alone rather than whole-path `sort -V` (the marketplace segment sorts first, so `aaa-mkt/2.5.0` would otherwise lose to `zzz-mkt/1.0.0`), uses `find` instead of a glob (zsh's `nomatch` fails a non-matching glob before `2>/dev/null` applies), and prints "not found — tried <the three paths>" rather than anything that reads as "not installed". **The cosmetic ones**: three dead see-also links in `schedule-poll-orchestrator-pattern` pointed at `~/.claude/skills/<name>/SKILL.md` files a reader on a plugin install cannot open — now plain skill names with a GitHub URL where the source repo is known — and one `~/.claude/skills/`-rooted self-reference in `overnight-insight-discovery`'s v1.3.2 changelog entry. **Deliberately unchanged**: every `~/.claude/skills/**` mention in § "Autonomous-safe skill edits" and its Phase G summary. Those are the path patterns that fire a sensitive-file permission prompt in Claude Code, which is a fact about the prompt system and not about where this skill is installed; broadening them would break the contract they encode. `CLAUDE_PLUGIN_ROOT` alone is not the fix — it is frequently unset in the shell a step actually runs in, and it points at the running plugin's own root, so it can never reach a sibling plugin.
- **2026-08-06** — `overnight-multi-issue-implementation` → **v1.3.1** (SKILL + both manifests + bundle `VERSION`): drops an unsourceable figure from the entry below. The "never truncate a findings payload" lesson described the lost finding as sitting in a "553-line pre-registration". That was true of the document the reviewer read; five blocking findings were then fixed on the branch before it merged, roughly doubling it, and it now stands at about 1,100 lines — a figure with no vintage attached, in a document the skill's own readers cannot re-derive it from. The length was decoration; "a pre-registration that had no power statement anywhere" carries the whole point, so the count is gone rather than dated. The same audit **retracted a rate**: "about one in four" is no longer claimed, because the host repo reopened its own count (a sixth instance surfaced, and two of the five were documents written from scratch). It now reads "common enough to budget a round for, not a measured rate". Everything else checked out against the source — the six-findings/five-arrived split, the ±0.03-versus-0.17 margin behind "about five times finer", and the 269 → 314 test counts are all recorded in the run's own handoffs. This is the skill's own "a fix ships a fresh instance of the defect it repairs" rule firing on the release that introduced it.
- **2026-08-06** — `overnight-multi-issue-implementation` → **v1.3.0** (SKILL + both manifests + bundle `VERSION`, which had drifted a patch behind): seven lessons from a single overnight run of 17 items — 20 merged PRs, 4 orchestrated workflows, 91 subagents, ~11 hours. **Never `.slice()` a findings payload** (three reviewers returned six critical findings; the merging agent received five, and every visible signal still said the gate had worked — make the actor count what it received against what it answered, and keep the run journal as the recovery path). **Coordinating with sessions you do not control**: claim your intent and your file list on a shared in-repo board before you start, append rather than replace, and don't take the claim down while your PRs are open. **Amend a running orchestration through a file on disk, not the script** — editing the script changes every agent prompt and a resume then re-runs completed work instead of replaying it from cache. A **third kind of collision** neither pre-flight audit can see (the same piece of work under two names, in a live session's uncommitted tree). **Baseline numbers in your own brief go stale mid-run** — measure, never quote. **What an autonomous run may and may not decide** (an assumption is a default, not a ruling; for pre-registered questions disclose rather than compute; an un-run unit is "no result", not "inconclusive"; production changes only in the reverting direction and only on unanimous authorisation from the run's own reviewers, with anything that is not a revert still waiting for a person; merging is a separate grant from changing production). And a **verbatim line for every reviewer prompt** — "Check whether this change ships a fresh instance of the defect it repairs." — which caught five of the twenty merged PRs, every one by re-deriving a number rather than by reading the diff.
- **2026-07-17** — `overnight-multi-issue-implementation` → **v1.2.0** (SKILL + manifests, fixing a manifest-version drift): adds **Phase 0 — backlog triage + owner-ruling application** for unvalidated issue clusters (triage biased against dismissal with adversarial verification of dismissals only; owner cut-line ratification via an interactive review page; rulings baked as greppable issue comments before any build; decision-session / build-session split with a wave-ordered kickoff prompt; follow-up ruling rounds handled additively; successor-before-close sequencing). Also documents that the close-keyword issue trap fires from **docs-only planning PR bodies** ("then close #N" in a kickoff-prompt addendum closes the live tracker on merge). Extracted from a real large-backlog triage-and-rulings run. Cross-links the new [`interactive-feedback-report`](https://github.com/wan-huiyan/interactive-feedback-report) skill.
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.3.1
1.4.0
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "observational-analysis-rigor",
"description": "A validity toolkit for observational data analysis (no randomization): 31 skills covering leak-free point-in-time cohorts, composition/Simpson decomposition, event-anchor timing inversion, marker-vs-lever discipline, downstream-capacity checks, coverage-limited-join bias, provenance/re-derivation, and de-stale delivery to every rendered surface the deep-dives behind overnight-insight-discovery's analytical validity gate. One flagship 9-step protocol skill + 30 focused deep-dive skills.",
"version": "1.2.2",
"description": "A validity toolkit for observational data analysis (no randomization): 31 skills covering leak-free point-in-time cohorts, composition/Simpson decomposition, event-anchor timing inversion, marker-vs-lever discipline, downstream-capacity checks, coverage-limited-join bias, provenance/re-derivation, and de-stale delivery to every rendered surface \u2014 the deep-dives behind overnight-insight-discovery's analytical validity gate. One flagship 9-step protocol skill + 30 focused deep-dive skills.",
"version": "1.3.0",
"author": {
"name": "wan-huiyan"
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,37 @@ gradient. Clean the cohort, then decompose, then de-confound, then interpret.
When step 4/5 retires a "lift" to a null, the CHART must lead with the adjusted estimate + a CI whisker
on the no-lift line and **subordinate** the raw gap (muted, "raw · self-selected"); kill causal titles.

## When your headline is a NULL, the risk inverts — assert EXTRACTION COMPLETENESS

The nine steps above defend against a finding that is surprising but wrong. A **null**
("X does not predict Y", "the flag does not mark what the eye dislikes") fails the other
way, and steps 1-8 will not catch it: **under-extraction manufactures nulls.** Every row
your parser silently drops out of the exposed group weakens the association you are
testing, so a quiet bug reads as a clean negative — and a clean negative is exactly the
answer that stops further work.

It is not the coverage-limited *join* of step 6 (that is about a subset being
observable). It is your own extraction dropping rows it should have had.

**So before you publish a null, assert your parsed counts against the raw source**, in
code, as a test — not by eye:

assert n_parsed_exposures == raw.count("<the marker>") # e.g. 50 == 50
assert n_parsed_outcomes == raw.count("<the marker>") # e.g. 168 == 168

A real instance: a log parser lost **19 of 218** advisory lines in silence — the source
format omits a rotation clause at zero degrees, and over-budget records end on a line
naming no coordinates, so whole blocks were skipped. The totals looked plausible. Left
unchecked it would have thinned the exposed group and made an already-null result look
even cleaner.

**And step 7 earns the most on a null.** Build the second construction with the OPPOSITE
bias — deliberately over-inclusive. If a construction that over-attributes exposure still
lands on the same answer, the null is not an artifact of under-extraction in either. In
the case above, attribution by log structure gave 29 units and attribution by geometry
gave 40, agreeing on only 19 — and both returned the same headline (17% and 18% against a
20% base rate).

## Red flags — a finding about to ship as an artifact

| The brief says… | What it may actually be |
Expand All @@ -106,6 +137,7 @@ gradient. Clean the cohort, then decompose, then de-confound, then interpret.
| "The rate is Z%" | As-of when? Cumulative vs mid-cycle snapshot differ (steps 7–8). |
| "N% of the matched rows show…" | Is the unmatched fraction missing-at-random? Validate the bridge (step 6). |
| "We should get them to do X so they advance" | Associational → marker; needs an A/B to be a lever (step 5). |
| "X turned out NOT to predict Y" (a clean null) | Did your extraction drop exposed rows? Assert parsed counts against the raw source, and re-probe with an over-inclusive construction. |
| A raw effect is negative/null but "should" be positive | Simpson — control the axis, it may flip (steps 3–4). |
| "I fixed the number" (edited the text) | Did the baked chart / twin doc / cached payload update too? A caption edit doesn't regenerate the chart (step 9). |

Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "overnight-insight-discovery",
"description": "Overnight autonomous B-vs-C parallel insight discovery that surfaces genuinely ah-ha findings from data, with a cohort-conditional novelty gate, an observational-analysis validity gate (composition / leak / anchor-timing / marker-vs-lever), adaptive tuning, and an agent-review-panel loop.",
"version": "1.1.1",
"version": "1.2.0",
"author": {
"name": "wan-huiyan"
},
Expand Down
44 changes: 39 additions & 5 deletions plugins/overnight-insight-discovery/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,22 @@ description: |
exploratory-data-analysis), single-track LLM exploration (use deep-research), or work that
needs user input mid-stream.
author: wan-huiyan + Claude Code
version: 1.8.0
date: 2026-07-08
version: 1.9.0
date: 2026-08-06

# Changelog
# 1.9.0 (2026-08-06 — plugin-install path resolution)
# The Phase 0.Y toolchain pre-flight decided whether this skill was installed by
# testing one path, ~/.claude/skills/overnight-insight-discovery/SKILL.md. A plugin
# install creates no such directory — it unpacks under
# ~/.claude/plugins/cache/<marketplace>/<plugin>/<version>/ — so a healthy plugin
# install failed the check and the track tapped out with [ENV_BLOCKER] claiming there
# was no skill tree. The check now probes $CLAUDE_PLUGIN_ROOT, then ~/.claude/skills/,
# then the plugin cache (ranked on the version path segment alone, via find not a
# glob), and on a miss says "not found — tried <the three paths>" instead of anything
# that reads as proof the skill is absent. The ~/.claude/skills/** patterns in
# § "Autonomous-safe skill edits" are deliberately unchanged: those describe which
# paths fire a sensitive-file permission prompt, not where this skill lives.
# 1.8.0 (2026-07-08 — analytical VALIDITY gate)
# Adds references/observational_analysis_rigor.md — an 8-step validity protocol
# (leak-free cohort · probe outcome−anchor before an event-anchored design ·
Expand Down Expand Up @@ -761,14 +773,36 @@ Patterns that survived the first production run are canonical here.

## Version history

- **v1.9.0** (2026-08-06, plugin-install path resolution) — The Phase 0.Y
toolchain pre-flight decided whether this skill was installed by testing one
path, `~/.claude/skills/overnight-insight-discovery/SKILL.md`. A plugin
install does not create that directory — it unpacks under
`~/.claude/plugins/cache/<marketplace>/<plugin>/<version>/` — so a perfectly
healthy plugin install failed the check, and the track tapped out with
`[ENV_BLOCKER]` claiming there was no skill tree. `CLAUDE_PLUGIN_ROOT` does
not rescue this: it is often unset in the shell the check runs in, and it
points at the running plugin's own root, so it can never reach a sibling.
The check now probes all three install roots in order and, when it finds
nothing, prints "not found — tried <the three paths>" rather than anything
that reads as proof the skill is absent. Two details in the snippet look
fussy but each fixes a real defect, so do not simplify them away: it ranks
candidates on the **version** path segment alone (the marketplace segment comes first, so a
plain `sort -V` over whole paths would let `aaa-mkt/2.5.0` lose to
`zzz-mkt/1.0.0`), and it uses `find` rather than a shell glob (zsh's
`nomatch` fails a non-matching glob at expansion time, before `2>/dev/null`
can suppress anything). Also removed a `~/.claude/skills/`-rooted
self-reference from the v1.3.2 entry below. The permission-prompt path
patterns in § "Autonomous-safe skill edits" are unchanged and still name
`~/.claude/skills/**` deliberately — that section is about which paths fire
a sensitive-file dialog, not about where this skill lives.
- **v1.7.0** (2026-04-21, post-S99 pre-dispatch stall) — Added **Phase 0.X pre-dispatch confirmation gate** (`references/phase_0_predispatch_gate.md`). S99 dispatch prep hit two mid-run stalls: (1) the `schedule` skill's 1-hour cron minimum conflicted with an inherited 30-min polling spec; (2) branch-checkout question for remote agents surfaced ad-hoc. Both required user intervention at the worst possible moment (mid-dispatch). New gate runs at Phase 0 closeout, surfaces all confirmation-requiring items in ONE batched `AskUserQuestion` call, and either proceeds silently (if zero deltas) or applies user redirects before firing. Covers 5 canonical item types: dispatch-mechanism deviations · blast-radius confirmation · branch-checkout question · probe-result surprises that changed planned behaviour · skill/remote-sync status reminder. Config knob `predispatch_gate.mode: ask|skip_and_log` — skip mode records items to morning_summary §0 for CI-style unattended runs. User feedback driving v1.7: "update the overnight workflow skill so next time we don't need user intervention mid run, if we have something to confirm, ask at the beginning of the session."
- **v1.4.1** (2026-04-17, post-v2 phone-readability ask) — Added **"Phone-readable bundle"** section (Phase F addendum). Deliverables ship as client-facing HTMLs + markdown docs that are awkward to read on mobile via GitHub or Drive separately (Drive's HTML preview can't resolve relative asset paths across files). New build step emits a **single self-contained HTML** with all deliverables inline + chart PNGs base64-embedded + mobile-optimised CSS with sticky top nav. Drag-to-Drive workflow → user reads on phone. Template in project repo at `scripts/build_drive_bundle.py`. Triggered by S92 user ask "how can I easily read them on my phone". Private-repo Vercel/Netlify/Pages considered but rejected (public by default); Google Drive upload is simplest-private-path. v1.5 roadmap candidate: auto-upload bundle to IAP-protected Cloud Run for team-shared review.
- **v1.3.2** (2026-04-17, post-v2 sensitive-file-prompt block) — Added
**"Autonomous-safe skill edits" contract** for Phase G. Second production
run hit a sensitive-file permission prompt when claudeception tried to
directly edit `~/.claude/skills/overnight-insight-discovery/references/
phase_b_review_loop.md` mid-run — a dialog the autonomous overnight
session couldn't resolve until morning. New contract: during autonomous
directly edit this skill's own `references/phase_b_review_loop.md` mid-run
— a dialog the autonomous overnight session couldn't resolve until
morning. New contract: during autonomous
runs, Phase G writes proposed skill-update diffs to
`docs/overnight/<date>/skill_updates/` (project-local, no prompts) and
lists them in morning_summary §4 for batched post-run review and apply.
Expand Down
Loading
Loading