feat(ui): add verify-this-review walkthrough and measured per-rule accuracy on the fairness report#8254
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
…ccuracy on the fairness report Adds the public reproducibility walkthrough doc (export corpus snapshot, verify checksum, replay scorer, compare against published numbers, with an honest attestation-boundary callout) and renders the measured accuracy per rule section on the fairness report from the public stats rulePrecision block: decided cases, precision with the insufficient-data null state (never 0%), reversal counts, and the corpus-checksum freeze point linking to the walkthrough. Closes JSONbored#8231
|
Tip ✅ LoopOver review result - approve/merge recommendedReview updated: 2026-07-23 15:10:40 UTC
Review summary Nits — 5 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy. Scroll preview
A short scroll-through clip (desktop) — click either thumbnail to open the full animation. Evidence for scroll-linked behavior a single screenshot can't show. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|


Summary
content/docs/verify-this-review.mdx: export the checksummed backtest corpus snapshot (scripts/backtest-corpus-export.ts,--remoteand--pgvariants), verify the checksum viabuildBacktestCorpusManifest, replay the scorer withscoreBacktest+buildConfidenceThresholdClassifier, and compare against the published numbers — with an honest closing callout that replay proves the numbers are real computations over a real corpus but does NOT prove the live gate ran that exact code (the attestation boundary, deliberately left to Research: is TEE hardware attestation necessary, or does a reproducible-backtest checksum approach cover the real threat? #8136/Research: survey viable TEE/confidential-compute options on Cloudflare Workers/Containers #8137)./v1/public/statsrulePrecisionblock (public-stats: measured per-rule precision endpoint (aggregates only, sanitizer-invariant) #8230): per-rule decided-case counts and precision, reversal-derived numbers, the insufficient data null state (a below-floorprecision: nullis rendered as the words, never as 0%), and the reproducibility freeze point showing the latest persisted backtest run's corpus checksum, linking to the new walkthrough.rulePrecisionis typed as optional onPublicStatsand the section hides entirely when the field is absent (older deployed API) or has no rows — deployment skew can never throw.Closes #8231
Scope
type(scope): short summaryConventional Commit format, for examplefix(api): restore profile access checks.CONTRIBUTING.mdand does not reintroduce GitHub Pages, VitePress,site/, orCNAME.Closes #123) — a linked open issue is required for every contributor PR.Validation
git diff --checknpm run actionlintnpm run typechecknpm run test:coveragelocally;codecov/patchrequires ≥99% coverage of the lines AND branches you changed (aim for 100% on your diff so CI variance does not fail near the threshold). Global coverage is a non-blocking trend with a loose 90% backstop, not the gate.npm run test:workersnpm run build:mcpnpm run test:mcp-packnpm run ui:openapi:checknpm run ui:lintnpm run ui:typechecknpm run ui:buildnpm audit --audit-level=moderateIf any required check was skipped, explain why:
apps/loopover-ui/**(docs MDX + fairness-report UI + its vitest suite).actionlint(no workflow changes),test:coverage/test:workers(no backend/root source or test changes),build:mcp/test:mcp-pack(no MCP changes),ui:openapi:check(no OpenAPI/route changes), andnpm audit(no dependency changes) are not exercised by this change.ui:lint,ui:typecheck,ui:build, and the UI vitest suite (fairness-report-page.test.tsx, 8/8 passing, including the new rulePrecision render/null-state/absent-field cases) all pass locally.Safety
UI Evidencesection below with JPG/JPEG or PNG screenshots arranged as organized, captioned, clickable thumbnails. SVG screenshots are not used as review evidence. Review-only screenshots or recordings are not committed to the repository.UI Evidence
Every viewport × theme combination, each row a labeled before/after pair. Before = current
main; After = this branch. loopover-ui is a dark-mode-only build (the theme toggle was removed), so the Light rows show what a light-theme-preference (prefers-color-scheme: light) visitor sees — the same dark rendering, captured under that preference honestly rather than relabeled.Before for the fairness page is the page as
mainrenders it (no per-rule section — the same view a deployed API without therulePrecisionblock produces, which is also this PR's pinned hide-the-section fallback); before for the docs route is the real 404 (/docs/verify-this-reviewdoes not exist onmain).Notes
/v1/public/statsfetch; there is no mock or demo fallback in shipped code. Because the currently deployed API predates therulePrecisionblock (public-stats: measured per-rule precision endpoint (aggregates only, sanitizer-invariant) #8230 merged but not yet deployed), the screenshots were captured on a local dev server with a representative response payload injected at the network layer so the new section is visible; the absent-field screenshotless state is exactly the current production behavior and is pinned by a regression test (section hidden, no throw).null-below-floor semantics in the doc mirrorscoreBacktest's implemented behavior; the doc deliberately stops at the reproducibility line and defers runtime attestation to the explicitly-scoped decisions in Research: is TEE hardware attestation necessary, or does a reproducible-backtest checksum approach cover the real threat? #8136/Research: survey viable TEE/confidential-compute options on Cloudflare Workers/Containers #8137, as the issue requires.