Skip to content

feat(consolidation): add sealed scoreboard v0 - #60

Merged
softmarshmallow merged 5 commits into
mainfrom
chore/consolidation-scoreboard-v0
Jul 21, 2026
Merged

feat(consolidation): add sealed scoreboard v0#60
softmarshmallow merged 5 commits into
mainfrom
chore/consolidation-scoreboard-v0

Conversation

@softmarshmallow

Copy link
Copy Markdown
Member

Outcome

Installs the consolidation program's Phase 2 measurement instrument before any score exists. This gives both engines one Chromium-anchored, CI-checked contract for future capability grants while keeping scoring owner-sealed.

This PR:

  • enumerates a fixed 14-row direct SVG rect/path intersection corpus;
  • commits deterministic Chromium oracle inputs with source and bake provenance;
  • exposes the chassis's existing bounded Base/Sample frame composition as a callable host seam, without adding a model bridge;
  • defines per-row legacy-vs-oracle, chassis-vs-oracle, and legacy-vs-chassis cells plus explicit coverage dispositions;
  • defines create-new report/baseline contracts, per-row regression checks, and a terminal 120-second run budget;
  • adds a CI shape gate that validates the corpus and both parser/preflight seams;
  • keeps the FLIP proposal explicitly unratified.

The follow-up commit makes rejected preflight rows typed UNSUPPORTED evidence while post-accept failures remain errors, and moves every future score-producing stage behind a terminal watchdog. The final test locks the production rule configuration itself to sealed.

Governance and seal

FLIP remains open at #49. scoreboard run and scoreboard bless refuse before corpus, renderer, report, or baseline access because the production active rule is absent; CI locks that state and invokes only synthetic contract tests plus scoreboard check.

No scoreboard score was produced or inspected. No report, committed baseline, or baseline candidate exists. The committed PNGs are Chromium oracle inputs, not scores or renderer outputs.

This PR installs the instrument but does not ratify FLIP, exit Phase 2, grant general SVG capability, or flip any conformance bar. After owner ratification or revision of FLIP, the first authorized report and baseline are a separate gated step.

Captured-essence ledger

Scope inventory: the existing legacy SVG render seam; the chassis's bounded static rect/path Base/Sample composition; the fixed SVG sources; Chromium oracle inputs and bake provenance; comparison, coverage, report, baseline, regression, wall-clock budget, and CI-shape contracts.

Retained caveats: legacy rendering keeps its white-background, embedded-font, geometry-fit, and existing unsupported posture. Chassis resolution stays strict and callers retain allocation, clear color, I/O, cadence, and encoding. The comparison retains threshold-zero dify antialias classification, integer pixel counts, white background, no mask, exact source hashes, JavaScript- and network-disabled Chromium, duplicate byte-identical captures, canonical no-symlink paths, and create-new publication.

Re-home: only host composition becomes callable. Entry-point rejection is retained as typed unsupported coverage; accepted-entry failures remain errors. Corpus/oracle/parser/render/comparator/prior-baseline work is enclosed by the hard budget, while report publication remains outside the worker so partial or over-budget work cannot publish.

Deliberate drops: none. No model, schema, frozen surface, legacy behavior, general SVG entry, HTML entry, n0 XML entry, format bridge, animation-sample bridge, score, baseline, or registry decision is introduced.

The corpus is deliberately a bounded proving shell. Its exclusion ledger names local-only corpora, general SVG import, HTML, n0 XML, the frozen format, and legacy exact-time animation rather than hiding those gaps.

Gate evidence

All validation below is score-incapable:

  • cargo test --locked -p grida_dev scoreboard — 19 contract/seal tests
  • cargo run --locked -p grida_dev -- scoreboard check — 14/14 source/oracle hashes, dimensions, and both preflights; no rasterization or comparison
  • cargo test --locked -p n0 -p n0-model
  • five-crate locked cargo check
  • warnings-denied grida_dev and n0 clippy
  • Rust formatting, diff hygiene, frozen-surface, link, fixture, and OSS checks

The original instrument commits also record deterministic Chromium bake and chassis host-artifact sweeps. Those are input/host equivalence gates, not scoreboard results.

Add the fixed 14-row SVG rect/path corpus, hardened Chromium bake, callable chassis frame seam, strict report and baseline contracts, CI shape gate, and the visibly unratified FLIP proposal.

Captured-essence ledger — legacy seam: preserve the existing grida_dev SVG render path, white-background and embedded-font assumptions, geometry-fit behavior, and existing lossy unsupported posture; the legacy engine remains context, never the oracle.

Captured-essence ledger — chassis seam: rehome render-bin composition as separate explicit Base and Sample entries over the moving latest bounded rect/path proving profile; strict resolver reports remain errors and callers retain allocation, clear color, I/O, cadence, and encoding.

Captured-essence ledger — comparator and oracle: retain threshold-zero dify anti-alias classification, integer pixel counts, white background, no mask, exact hashed SVG buffers, JavaScript- and network-disabled Chromium, duplicate byte-identical captures, canonical no-symlink paths, and create-new publication.

Captured-essence ledger — rehomes and drops: rehome only callable host composition; drop no model, schema, freeze, or legacy behavior and introduce no general SVG, HTML, .grida, n0 XML, animation-sample bridge, score, baseline, or FLIP decision.

Gates: grida_dev tests 19/19; n0 and n0-model suites green; five-crate cargo check; warning-denied grida_dev and n0 clippy; scoreboard check 14/14; Chromium bake 14/14 with unchanged PNG hashes; chassis host sweep 14 fixtures and 56 artifacts byte-identical; sealed run and bless probes produced no output; Rust and TypeScript symlink probes refused; formatting, lint, workflow YAML, local links, diff, and frozen-surface checks green.
Etiology: validation collapsed per-engine entry-point rejection into whole-run failure, leaving UNSUPPORTED schema-only; cooperative deadline polls could not preempt a blocked synchronous stage. The contract now retains typed preflight dispositions and keeps durable report publication outside a terminal watchdog worker.

Captured-essence ledger: preserve strict two-engine acceptance for scoreboard check; authorized reports retain every denominator row as scored, unsupported, or error; preflight rejection is unsupported and post-accept failure remains error; the fixed budget starts before corpus, oracle, parser, renderer, comparator, and prior-baseline validation. No renderer, corpus, oracle, score, baseline, rule, model, schema, freeze surface, or existing host behavior changed; deliberate drops: none.

Gates: scoreboard tests 18/18; grida_dev tests 22/22; scoreboard check 14/14; five-crate cargo check; warning-denied grida_dev and n0 clippy; cargo fmt; diff and frozen-surface checks; OSS scan clean; seal tests green and report/baseline candidate absent.
Etiology: the seal tests proved the guard helper rejected injected unratified rules, but did not assert the production active_rule configuration itself. An accidental ratified value could therefore enable score-producing paths without failing the CI shape gate.

Lock the real configuration to None while FLIP remains unratified. No renderer, corpus, oracle, report, baseline, rule, model, schema, or frozen surface changed; no score was produced or inspected.

Gates: scoreboard tests 19/19; scoreboard check 14/14; five-crate check; warning-denied grida_dev and n0 clippy; n0 and n0-model suites; rustfmt and diff hygiene.
@vercel

vercel Bot commented Jul 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
nothing Ready Ready Preview, Comment Jul 21, 2026 7:53am

Request Review

@coderabbitai

coderabbitai Bot commented Jul 21, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: 1f163a96-4bd3-4add-8cfe-f38a3c33eff4

📥 Commits

Reviewing files that changed from the base of the PR and between cdba65c and c4a001d.

⛔ Files ignored due to path filters (29)
  • Cargo.lock is excluded by !**/*.lock
  • fixtures/scoreboard/svg-rect-path-v0/chromium/path-evenodd.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/path-opacity.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/path-solid.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/path-transform.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-opacity.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-overlap-order.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-rounded-elliptical.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-rounded-uniform.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-solid.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-transform-matrix.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-transform-rotate.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-transform-scale.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-transform-skew.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/chromium/rect-transform-translate.png is excluded by !**/*.png
  • fixtures/scoreboard/svg-rect-path-v0/svg/path-evenodd.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/path-opacity.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/path-solid.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/path-transform.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-opacity.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-overlap-order.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-rounded-elliptical.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-rounded-uniform.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-solid.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-transform-matrix.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-transform-rotate.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-transform-scale.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-transform-skew.svg is excluded by !**/*.svg
  • fixtures/scoreboard/svg-rect-path-v0/svg/rect-transform-translate.svg is excluded by !**/*.svg
📒 Files selected for processing (22)
  • .github/workflows/consolidation-gates.yml
  • crates/grida_dev/Cargo.toml
  • crates/grida_dev/README.md
  • crates/grida_dev/SCOREBOARD.md
  • crates/grida_dev/scripts/scoreboard_bake_chromium.ts
  • crates/grida_dev/src/main.rs
  • crates/grida_dev/src/reftest/compare.rs
  • crates/grida_dev/src/scoreboard/contract.rs
  • crates/grida_dev/src/scoreboard/corpus.rs
  • crates/grida_dev/src/scoreboard/mod.rs
  • crates/grida_dev/src/scoreboard/runner.rs
  • crates/n0/ANIMATION.md
  • crates/n0/README.md
  • crates/n0/src/bin/svg_animation_render.rs
  • crates/n0/src/lib.rs
  • crates/n0/src/svg_animation_frame.rs
  • crates/n0/tests/svg_animation_frame.rs
  • docs/wg/consolidation/charter.md
  • docs/wg/consolidation/flip-rule.md
  • docs/wg/consolidation/index.md
  • fixtures/scoreboard/svg-rect-path-v0/corpus.json
  • fixtures/scoreboard/svg-rect-path-v0/oracle-bake.json

Walkthrough

Changes

Consolidation tooling and gates

Layer / File(s) Summary
SVG animation frame adapter
crates/n0/src/svg_animation_frame.rs, crates/n0/src/bin/svg_animation_render.rs, crates/n0/tests/svg_animation_frame.rs, crates/n0/src/lib.rs, crates/n0/README.md, crates/n0/ANIMATION.md
Adds explicit Base/Sample SVG animation rendering APIs, structured resolver errors, migrated offline rendering, and adapter tests and documentation.
Scoreboard contracts and corpus validation
crates/grida_dev/src/scoreboard/contract.rs, crates/grida_dev/src/scoreboard/corpus.rs, crates/grida_dev/src/reftest/compare.rs, fixtures/scoreboard/..., crates/grida_dev/Cargo.toml
Defines report/baseline schemas, coverage and regression rules, pixel-count comparison results, fixed corpus validation, oracle manifest checks, and required dependencies.
Scoreboard rendering and CLI workflow
crates/grida_dev/src/scoreboard/runner.rs, crates/grida_dev/src/scoreboard/mod.rs, crates/grida_dev/src/main.rs, crates/grida_dev/README.md, crates/grida_dev/SCOREBOARD.md
Runs bounded deterministic legacy/chassis comparisons and exposes sealed check, run, and bless commands with guarded persistence and baseline handling.
Chromium oracle baking
crates/grida_dev/scripts/scoreboard_bake_chromium.ts
Adds deterministic Chromium capture with path safety, SVG restrictions, hash verification, staged publication, and cleanup.
Conformance rule documentation
docs/wg/consolidation/flip-rule.md, docs/wg/consolidation/index.md, docs/wg/consolidation/charter.md
Documents the unratified FLIP proposal and updates consolidation charter references and evidence requirements.
Scoreboard CI gate
.github/workflows/consolidation-gates.yml
Adds the engine-scoped scoreboard preflight job and includes its result in final gate enforcement.

Estimated code review effort: 5 (Critical) | ~120 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CI
  participant ScoreboardCLI
  participant CorpusValidator
  participant LegacyEngine
  participant ChassisEngine
  participant ReportWriter
  CI->>ScoreboardCLI: run scoreboard check/preflight
  ScoreboardCLI->>CorpusValidator: validate corpus and oracle
  CorpusValidator-->>ScoreboardCLI: ValidatedCorpus
  ScoreboardCLI->>LegacyEngine: render fixtures twice
  ScoreboardCLI->>ChassisEngine: render fixtures twice
  LegacyEngine-->>ScoreboardCLI: engine cells and PNGs
  ChassisEngine-->>ScoreboardCLI: engine cells and PNGs
  ScoreboardCLI->>ReportWriter: validate and write report
  ReportWriter-->>CI: scoreboard gate result
Loading

Possibly related issues

  • Issue 49 — The PR adds the scoreboard and documents the unratified FLIP rule covering thresholds, coverage, oracle identity, and gating requirements.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/consolidation-scoreboard-v0

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Etiology: the new and amended Markdown tables had not been normalized by the repository formatter, so the Node workflow stopped at pnpm fmt:check before its downstream steps.

Format only the three branch-owned Markdown files; prose and contracts are unchanged.

Gates: pnpm fmt:check; oxlint --deny-warnings; www type-check; reftest type-check, build, and 51-test suite. The local Next production build stalled without diagnostics during Turbopack optimization and was stopped; remote Ubuntu CI remains the build gate.
Etiology: the scoreboard-shape job compiled the graphics stack under Cargo test, then cargo run selected the dev profile and began a second cold native build. The 30-minute job envelope cancelled that build before the corpus preflight could execute.

Run the CLI preflight under the already-built test profile. This preserves both required checks and the hard job timeout; it changes no renderer, corpus, rule, report, baseline, or score behavior.

Captured essence: synthetic contract tests and the real scoreboard check command both remain mandatory. Deliberate drops: none.

Gate evidence: pnpm fmt:check; cargo test --locked -p grida_dev scoreboard (19 passed); cargo run --locked --profile test -p grida_dev -- scoreboard check (14/14 preflight); git diff --check.
@softmarshmallow
softmarshmallow marked this pull request as ready for review July 21, 2026 08:28
@softmarshmallow
softmarshmallow merged commit 58902b2 into main Jul 21, 2026
14 of 15 checks passed
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