Skip to content
pi-c Artifact [8d7e7e79cb]
Login

Artifact [8d7e7e79cb]

Artifact 8d7e7e79cb76968ce2c9107fd8454c166f3d7bf20766c0e0ee79027cdf4a1eca:


End-to-end conformance and nightly qualification

Status: proposed suite design, requested during S0. The scenario families below are NOT RUN: no production C harness, reference execution environment, or nightly job has been created. This plan adds a release obligation; it does not authorize a Node installation, remote runner setup, external API spending, or a schedule yet.

Goal

Maintain an executable, version-pinned set of user workflows and failure/recovery scenarios against the C candidate, Pi, and Pi Durable. Start with the first working vertical slice and expand on every feature; do not build the entire suite only at the end.

Passing means the declared scenarios satisfy their contracts within a stated platform, workload, and fault envelope. It is not an absolute proof of correctness. Independent invariants and fault injection remain necessary: matching a reference bug is not success.

Three complementary comparisons

  1. C versus Pi: coding tools, queues, sessions/context, headless clients, extensions, and terminal workflows.
  2. C versus Pi Durable: persisted admission, checkpoint/replay behavior, ownership/cancellation, sleeps/signals, document/fork state, and recovery.
  3. C versus an independent oracle: durable acknowledgement, retained records, external-effect ledger, bounded retries, authorization, resource ownership, and teardown. Reference output is evidence, not the sole source of truth.

Each case declares applicability before execution. Pi is not expected to pass durable-task tests it does not offer; Pi Durable is not expected to provide the CLI/editor. Where their semantics differ, use separate contract profiles within the same scenario family rather than forcing one implementation to match incompatible expectations. A declared unsupported reference capability is distinct from a required C feature failing or being silently skipped.

Scenario families to implement

These IDs identify families, not single happy-path tests. Each needs positive, negative, boundary, and interruption variants where relevant. Implementation stages and detailed contracts remain in the four source maps and core acceptance catalog.

Family End-to-end scenario References Main contracts
E01 Inspect a fresh coding workspace, read files, make exact edits, write a new file, run a deterministic build/test, inspect final filesystem and tool results. Pi H01–H05,P07
E02 Execute parallel calls with reversed completion, malformed/unknown/blocked calls, failures, and mixed termination flags. Pi, Durable H02,H03,D06,P07,P08
E03 Steer and follow up during generation, preflight, tool execution, retry, and compaction; prove queue ordering and settled semantics. Pi, Durable H01,H06,H08,H26,D01
E04 Abort during a real tool/process tree; verify result classification, queue recovery, bounded shutdown, and no owned descendants. Pi, Durable H07,D08,D09,D22
E05 Save/resume a session, navigate its tree, fork/clone, switch cwd by the declared API, and preserve immutable history without pretending to roll back files. Pi, Durable H10–H12,D14
E06 Discover instructions, rules, skills, templates, and configuration under trust decisions; assemble the effective context with pinned provenance. Pi H15–H19,H24,C04–C06,C10
E07 Reach context limits, compact, interrupt placement, resume, reject stale results, and preserve tool-call/result boundaries and raw history. Pi, Durable H13–H15,D15,P10,C07
E08 Switch model/provider with opaque reasoning/text/tool signatures, images, changed capabilities, usage, and cache/session identity. Pi, Durable H25,P01,P02,P11,P13,P15–P17
E09 Stream chunked text/reasoning/tool arguments, split at adversarial boundaries, truncate/drop the stream, and observe exact terminal/error behavior. Pi, Durable H08,H09,P03–P08,P12
E10 Drive print/JSON/RPC, correlate admission separately from completion, disconnect/reconnect, slow the client, and shut down on EOF/signals. Pi H08,H09,H22,H26,D19,P05
E11 Load/reload extensions, compose hook transformations/gates, handle faulty renderers, and enforce version-safe saved work. Pi, Durable where supported H20–H22,D17
E12 Discover/call MCP tools, handle naming collisions/OAuth expiry/disconnect, and exercise selected tool-search/code-mode compatibility. Pi, Durable where supported H27,H28,D10,D13,P07
E13 Drive the terminal through a real PTY: Unicode widths, paste, resize, editor recovery, images, prompts, and noninteractive fallback. Pi H07,H22,H23
E14 Archive/search/redact/rebuild/sync knowledge while execution is pending; preserve authoritative task state and keep credentials out of searchable/exported data. Independent/context; Pi export where applicable C01–C10,H29,H30
E15 Admit a keyed input, lose the response, retry across restart, exercise type/content conflicts, and reacquire settlement without duplicate work. Durable D01,D02,D04,H06
E16 Fail before/within/after an atomic commit; distinguish stored, refused-prefix, and unknown outcomes; observe strict/deferred progress accurately. Durable D03,D04,D16,D18,D21,C02,C03,C07
E17 Kill generation, preserve/lose allowed partial progress, back off, recover deferred provider handles, and exhaust retries/crash limits. Durable D05,D20,P09,P14
E18 Interrupt unsafe/safe external effects and nested calls; reconcile with an independent idempotency ledger; never infer effects from synthesized protocol messages. Durable D06,D10,D22,P12
E19 Race parent completion, child failure, abort, park, and cleanup; preserve ownership and completing/terminal boundaries across restarts. Durable D08,D09,D13,D20
E20 Sleep/park across process loss and host wakeups; deliver early/duplicate/invalid/expired signals; prove liveness after faults stop and no busy-polling requirement. Durable D07,D11–D13
E21 Upgrade/reload task/document/storage versions, block missing/newer definitions safely, interrupt migration, and recover writer ownership. Durable D17,D18,D20
E22 Observe committed views and allowed deferred progress through stalls/reconnect, pagination/gaps, read-only opens, and observer failure. Durable D16,D19,D21,P05
E23 Supply hostile workspace/archive/MCP data, invalid approvals and oversized output; verify the selected security/trust/authorization policy and safe export. Pi baseline plus independent policy H17,H29,H30,P07,C05,C09
E24 Sustain declared workload sizes, idle/wake cycles, and long histories; check bounded memory/process/disk behavior, recovery cost, and teardown. All where guarantees/workload match Operational envelope across implemented contracts

Case contract and independent evidence

Every case records:

Normalize only irrelevant differences such as generated identifiers or explicitly uncontrolled timestamps. Preserve ordering, types, error classes, admission versus settlement, state transitions, and external effects. Do not strip differences until a failing comparison becomes green.

The independent oracle must not call candidate recovery predicates or use reference output to invent expected results. Use metamorphic checks too: an uninterrupted workflow and an interrupted/resumed one must agree where the contract requires it, with explicit exceptions for retry attempts, unknown outcomes, usage, and deferred progress.

Deterministic default; live integrations separate

Use a fake provider that speaks the actual selected wire protocol and supplies scripted responses/tool calls. Inject connection drops, partial frames, retry hints, invalid arguments, length limits, and deferred results without paid model requests. Keep an independent effect service/ledger outside the candidate's process so a candidate restart cannot erase evidence of a remote effect.

Give each implementation its own fresh workspace and database. Scrub inherited credentials and expose only synthetic fixtures and allowlisted environment values. Bind fake services locally with owned ports/sockets, their own deadlines, and teardown records. Never run against a real user's coding workspace or archive.

Real-provider/MCP smoke tests remain separately authorized, budgeted, and reported; fake-provider conformance cannot prove every live service's authentication, signature, policy, or network behavior.

Nightly and release gates

Tier When Requirement
Fast conformance Each relevant change Implemented-stage scenarios plus every saved regression; deterministic fault points and strict evidence validation.
Full nightly Once the runner is approved and available All scenarios required for the current implemented stage, real subprocess crashes/restarts, seeded fault combinations, resource accounting, and verified teardown.
Extended campaigns Bounded scheduled jobs Additional seeds, longer histories, parser fuzz/corpus growth, and Fil-C/native variants within explicit time/disk budgets.
Release Exact packaged binary Every release-required scenario and platform profile passes; explicit reviewed deviations; representative performance and storage qualification; no unresolved cleanup or correctness blocker.

A future feature remains NOT RUN until implemented; it is not a passing skip. During development, a nightly can pass its current-stage tier while the release remains NOT READY. Required case counts and applicability profiles are versioned so the denominator cannot shrink silently. A missing required runner/tool is GATED and blocks the tier; timeout, incorrect result, or failed teardown is FAIL.

Every new feature or contract change must add/update its scenarios, oracle, fault variants, and evidence mapping in the same change. A bug fix must add the captured counterexample. Removing/deferring a case or changing its expected behavior requires a reviewed reason, not a baseline-refresh shortcut.

Reference pinning and drift

Setup/teardown and pending decisions

Executing Pi/Pi Durable requires a development-only Node environment and adapters. That is not a Node dependency in the shipped C harness. Select/pin the environment from the reviewed reference package requirements, inspect code/dependency changes, and approve the setup/teardown before enabling it. Do not execute new unreviewed upstream revisions unsandboxed or run dependency install scripts implicitly.

Runner location, CI schedule, platform matrix, artifact retention/privacy, reference adapter interface, credential policy, and resource budgets need a concrete reviewed design. No nightly Cron/CI job is enabled by this document. The Hetzner setup remains subject to its separate lifecycle review.

Every run must have bounded work, manifest-owned resources, off-host evidence where applicable, and idempotent verified cleanup. Losing SSH must not leave work running indefinitely. A local signal handler alone does not satisfy the remote host-death/cleanup guarantee.