feat(gpu): slice 4 runtime graphics diagnostics evidence contract (refs OpenCoven/psyche-build#229) - #307
Closed
CompleteDotTech wants to merge 2 commits into
Closed
Conversation
…port merge (#229) Add docs/gpu/SLICE4-DIAGNOSTICS-CONTRACT.md defining the runtime graphics evidence policy (accelerated/software/unknown/unavailable from runtime evidence only; omitted-not-placeholder unsupported fields; hosted compilation never proves physical GPU acceleration), bounded rendering/transport metrics retention and polling cadence, the debug-authorized 1/6/12/24 stress-harness boundary (harness owned by #230), and the diagnostics surface boundary (#231). Add src/gpu/slice4ReportMerge.ts (schema v1, pure): deterministic native + browser report merge with strict unknown-field rejection and typed bounded rejections, fail-closed classifyRenderer(), and boundedMetricsWindow() with explicit retention (20,000 rAF samples) and 1s minimum polling cadence constants. 37 focused unit tests cover merge determinism, the classification table, omission-not-placeholder, bounds enforcement, and unknown-field rejection.
|
@CompleteDotTech is attempting to deploy a commit to the 0xBuns Team on Vercel. A member of the Team first needs to authorize it. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Member
|
Closing as a non-executable duplicate contract slice. The canonical Slice 4 sequencing remains in the owning roadmap/issues; future work should start from current main with runtime integration and one acceptance gate. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Outcome
Slice 4 core (#229, bead
psyche-z7c.4): the runtime graphics diagnosticsevidence contract and its machine-checkable implementation — additive, no existing file touched.
docs/gpu/SLICE4-DIAGNOSTICS-CONTRACT.md— merging native platform/process facts with strictbrowser graphics evidence; bounded rendering/transport metrics; the debug-authorized
deterministic 1/6/12/24-terminal stress-harness boundary (the harness itself is [psyche-z7c.4.4] Add the debug-authorized rendering stress harness #230's
deliverable); the diagnostics surface boundary ([psyche-z7c.4.5] Expose the in-app developer GPU diagnostics surface #231's deliverable); evidence policy quoted
verbatim and enforced (accelerated/software/unknown/unavailable reported only from runtime
evidence; unsupported version/backend/adapter fields omitted — never placeholder-filled; hosted
compilation never proves physical GPU acceleration); metrics retention (20,000 rAF samples) and
polling cadence (1 s minimum) bounds.
src/gpu/slice4ReportMerge.ts— versioned schema-v1 pure TS module:mergeSlice4Reports()(deterministic native + browser merge; strict unknown-field rejection at every level; typed
bounded rejections; deep-frozen outputs; canonical key order),
classifyRenderer()(fail-closedaccelerated/software/conflicting→unknown/unavailable),
boundedMetricsWindow()(oversize input→ typed
oversizerejection, never silent truncation; sub-second polling cadences rejected).__tests__/gpuSlice4ReportMerge.test.ts— 37 focused tests: merge determinism (byte-identicalJSON, canonical key order, input-order independence), classification table (ANGLE Metal /
Direct3D / Vulkan / OpenGL hardware, SwiftShader / llvmpipe / Microsoft Basic Render Driver
software, masked and non-strict unknown, no-API unavailable, conflicting → unknown),
omission-not-placeholder, bounds enforcement, unknown-field rejection.
Refs #229 (bead
psyche-z7c.4; parent epic #228; canonical outcome gh-199).Scope and boundaries
Done here:
else.
Deliberately NOT done (owned by sibling slices — no duplication, no collisions):
psyche-z7c.4.4) owns the process-spawning harness, native steady/burst/rewrite fixture commands, scenario execution, and the launcher. This slice fixes only the
authorization boundary that harness must satisfy: debug build + startup environment
authorization, fixed fixtures only, fixed 1/6/12/24 scenario set.
psyche-z7c.4.5, currently blocked by [psyche-z7c.4.4] Add the debug-authorized rendering stress harness #230). This slicefixes only what the surface may render: present fields only (omitted fields = hidden rows, no
placeholders), prominent software fallback, controls gated on
debugBuild && stressAuthorized.not started by anyone yet as far as this slice observed). The acceleration vocabulary here is
kept identical to the matrix's so evidence maps without translation.
capability changes, no package scripts or dependency changes, no workflow changes, no barrel
edits, no generated outputs.
Blocked dependencies observed: #231 is blocked by #230 upstream; both are outside this slice. This
PR does not depend on either to land.
Risk class
Validation and evidence
All commands run from the worktree on branch
psyche/issue-229-gpu-slice4-evidence(based onorigin/mainatf323879):npx pnpm install --frozen-lockfilenpx pnpm exec vitest --run __tests__/gpuSlice4ReportMerge.test.tsnpx pnpm exec tsc --noEmitnpx pnpm exec tsc -p tsconfig.test.json --noEmitgit diff --checknpx pnpm test(full portable suite, with change)npx pnpm testbaseline (same command aftergit stash -u)Baseline comparison: the 56 full-suite failures are pre-existing and environmental (tmux/PTY- and
process-dependent suites on this host:
daemon/spawnPromptTransport.test.ts,daemon/bridge.test.ts,macosBuildChannels.test.ts,processIdentity.test.ts,runProcess.test.ts, …). My change addsexactly +37 passing tests and zero failures vs baseline.
Explicit gaps (not run here / honest gaps):
acceleratedclaim is made anywhere inthis PR; hosted CI on virtualized runners validates types/tests/fallback classification only.
scripts/agent-bootstrap/scripts/agent-checknot run (require tmux; unavailable here).specified and unit-tested at contract level only.
Working record
docs/working-records/issue-229-gpu-slice4-evidence.md— outcome, boundaries, exact commands andresults, head SHAs (
438da06deliverables; PR head is authoritative), test counts, proof gaps,rollback, and security notes.
Generated outputs
None touched:
src/utils/generated-agents-doc.ts, desktop web bundles, Xcode project/Info.plist,and
dist/**are unchanged.Security and privacy
repository contents, environment dumps, private URLs, or unredacted personal paths are
introduced by this change.
(public ANGLE/Mesa/SwiftShader formats); no host, machine, or personal data.
Review focus
docs/gpu/SLICE4-DIAGNOSTICS-CONTRACT.mdvsclassifyRenderer()— especially: strict context +masked renderer →
unknown(neveraccelerated), software markers authoritative over strictcontexts, conflicting evidence →
unknown, no usable API →unavailable.engineVersion/backend/adapter/supportingProbe/processkeys are absent (nonull/"unknown"placeholders), withunsupportedFieldsnaming missing graphics identity fields.sub-second polling cadences are rejected; error lists are bounded with an explicit suppression
marker.
Release and support impact
Additive documentation, one pure versioned module, and tests. No public command, schema,
persisted format, error, security boundary, package dependency, or workflow change. No support
matrix or roadmap change. Desktop GPU acceleration support claims remain governed by the
verification matrix (#232) and physical evidence; nothing here asserts acceleration for any
platform.
Pipeline note: upstream OpenCoven PR/issue writes are token-denied for this pipeline, so this PR
runs on the CompleteDotTech fork with real GitHub Actions CI; the branch is ready for a maintainer
one-click PR to upstream.
Refs #229