Skip to content

engine(experiment): schema, series records, evidence waits, hops, routing - #1058

Closed
leeovery wants to merge 4 commits into
mainfrom
feat/experiment-phase-engine-state
Closed

engine(experiment): schema, series records, evidence waits, hops, routing#1058
leeovery wants to merge 4 commits into
mainfrom
feat/experiment-phase-engine-state

Conversation

@leeovery

Copy link
Copy Markdown
Owner

PR1 of the experiment-phase stack (design: #1057).

  • experiment phase inserted between research and discussion for epic/feature/cross-cutting: VALID_PHASES, pipelines, routings, phase statuses (no superseded — a series is never absorbed into a sibling topic).
  • Series records: phases.experiment.items.{topic}.experiments.{E{n}} (slug/status/verdict/reason), per-topic numbering, guarded-container + leaf validation on the field surface.
  • engine experiment create|advance|approve|conclude|abandon|await (domain/experiment.cjs): the design-before-data lifecycle — approve is its own verb (the briefing freeze is never a step advance drifts past); conclude requires running + one-line --verdict; abandon is terminal from any pre-terminal status with --reason.
  • Evidence waits: awaiting_experiments on the same-topic discussion item — topic complete refuses while pending; conclude/abandon release and set reconcile_needed: "experiment"; bare topic cancel on an awaited experiment refuses naming the waiting discussion, --cascade cancels + releases in one transaction (released_wait on the response).
  • flagDownstream now walks past phases the topic never entered to flag the nearest downstream item — inserting an optional phase must not sever the research→discussion hop. Tested both ways.
  • computeNextPhase/computeTopicLifecycle/computeNextAction learn the slot (experimenting/evidence_ready, awaiting evidence routing); enum sweep (commit door, presence, roadmap flags, discovery map, epic projections' pure enumerations). Display strings beyond those are PR2.
  • Tests: new test-engine-experiment.cjs (25 tests), simulation mainlines for feature + epic (waits, refusals, releases, series continuation), derivations/fields/transactions suites extended. Conventions lint carries a named in-flight allowance until PR3 ships the process skill.

Gates: npm test 2643/2643 · npm run test:cli 5/5 · npm run typecheck clean.

🤖 Generated with Claude Code

leeovery and others added 4 commits August 30, 2026 17:22
…idence waits, hops, routing

The pipeline gains an experiment slot between research and discussion for
epic, feature, and cross-cutting. Each topic's item holds an ordered series
(experiments.E{n}: slug, status, verdict/reason) walking conceived →
designed → approved (the confirm freeze, its own verb) → running →
concluded | abandoned, driven by the new `engine experiment` family
(domain/experiment.cjs). The evidence wait (awaiting_experiments on the
same-topic discussion, written by `experiment await`) blocks discussion
conclusion engine-side, routes computeNextPhase back to the experiment
(awaiting evidence), and releases on conclude/abandon/cancel — every
release flagging the discussion's next entry via reconcile_needed.
flagDownstream now walks to the nearest downstream item so the optional
slot never swallows a hop; the map lifecycle, next actions, triage
queues, commit door, presence beats, and epic-cancel edges all join the
phase. Simulation mainlines for feature and epic plus engine suites cover
the series, the waits, and the releases.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…erbs in the usage banner

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…o the widened lifecycle set

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…hase's in-flight process skill

The commit-door, discovery-map, and presence suites pin refusal messages
that derive from the widened phase and routing vocabularies — re-pinned to
the new lists. The conventions lint's presence-cleanup check gains a
named in-flight allowance for the experiment phase: its process skill
ships in the stack's skills PR, and until it exists no prose can put a
session or a heartbeat in the phase; the entry is removed when that skill
lands, restoring the full hook requirement.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@leeovery

Copy link
Copy Markdown
Owner Author

Closed: this stack implements a superseded model of the experiment phase. The corrected design is PR #1057 (design/experiment-phase.md) — experiment as an umbrella tool spawned from research/discussion, not a peer pipeline phase. A fresh stack built against that design replaces this one. The branch is kept for salvage until the replacement lands.

@leeovery leeovery closed this Aug 31, 2026
@leeovery
leeovery deleted the feat/experiment-phase-engine-state branch September 1, 2026 17:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant