Skip to content

feat(ui): slop-band calibration card on the analytics dashboard#5128

Closed
jeffrey701 wants to merge 1 commit into
JSONbored:mainfrom
jeffrey701:feat/slop-band-calibration-card
Closed

feat(ui): slop-band calibration card on the analytics dashboard#5128
jeffrey701 wants to merge 1 commit into
JSONbored:mainfrom
jeffrey701:feat/slop-band-calibration-card

Conversation

@jeffrey701

Copy link
Copy Markdown
Contributor

What & why

Closes #2196.

Adds a self-host analytics card visualizing slop-band calibration — for each predicted slop band (clean / low / elevated / high), how many PRs the gate put there and how they actually resolved (realized merge rate). It answers "is the slop predictor well-calibrated?" — cleaner bands should merge more, higher bands less. Public-safe bands only — no raw credibility scores.

  • slop-band-calibration-card-model.tsSlopBandCalibrationReport / SlopBandCalibrationRow types + pure helpers: orderSlopBands (cleanest → highest, ignoring the payload's order), toneForSlopBand, formatMergeRate.
  • slop-band-calibration-card.tsx — a row per band: a StatusPill (band tone), predicted-count and realized-merge-rate Stats, and a MiniSparkbar of the band's outcome distribution; a graceful EmptyState when the field is absent or there are no bands.
  • Wiringapp.analytics.tsx gains an optional slopBandCalibration field and renders the card when present, so it degrades to nothing until the stats slice lands.

Tests (slop-band-calibration-card.test.tsx): the model's ordering / tone / format helpers and the card's all-bands-present, one-empty-band, and no-data arms. ui:typecheck, ui:lint, vitest, and the Vite build all pass.

Screenshots

View Before After
Self-host analytics dashboard (/app/analytics)

Captured against the local-preview analytics dashboard (?preview=1); the card appears once a slopBandCalibration slice is present on the operator-dashboard payload.

Add SlopBandCalibrationCard to the self-host analytics dashboard (JSONbored#2196):
for each predicted slop band, how many PRs the gate put there and how
they actually resolved (realized merge rate), so a maintainer can see
whether the slop predictor is well-calibrated. Public-safe bands only --
no raw credibility scores.

- slop-band-calibration-card-model.ts: SlopBandCalibrationReport /
  SlopBandCalibrationRow types + pure helpers (orderSlopBands cleanest ->
  highest, toneForSlopBand, formatMergeRate).
- slop-band-calibration-card.tsx: a row per band (StatusPill band tone +
  Stat predicted count + Stat realized merge rate + MiniSparkbar), and a
  graceful EmptyState when the field is absent / there are no bands.
- Wired into app.analytics.tsx behind an optional slopBandCalibration
  field, so it renders once the shape is present on the operator-dashboard
  payload and stays absent until then.

Vitest: model ordering / tone / format helpers + the card's
all-bands-present, one-empty-band, and no-data arms.

Closes JSONbored#2196
@jeffrey701 jeffrey701 requested a review from JSONbored as a code owner July 11, 2026 21:09
@superagent-security

Copy link
Copy Markdown
Contributor

Superagent didn't find any vulnerabilities or security issues in this PR.

@gittensory-orb gittensory-orb Bot added the gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier. label Jul 11, 2026
@gittensory-orb

gittensory-orb Bot commented Jul 11, 2026

Copy link
Copy Markdown

Caution

🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥

🛑 Gittensory review result - reject/close recommended

Review updated: 2026-07-11 21:12:45 UTC

4 files · 1 blocker · readiness 100/100 · CI failing · blocked

🛑 Suggested Action - Reject/Close

  • AI review already in progress for this PR head: Another Gittensory pass is already running the AI review for this exact PR head. This pass is skipping to avoid a duplicate LLM call.

Review summary
AI review is already running for this PR head in another Gittensory pass. Gittensory is holding this PR for manual review until that pass completes.

Nits — 1 non-blocking
  • AI review already in progress for this PR head — The gate is held for a human reviewer rather than passed automatically; it re-evaluates once the in-flight review completes or on the next update.

Why this is blocked

  • Linked issue overlaps another open PR — Review the related PRs before spending reviewer time on duplicate work.

CI checks failing

  • validate
  • validate-code
Signal Result Evidence
Code review ❌ 1 blocker No AI review summary
Linked issue ✅ Linked #2196
Related work ✅ No active overlap found No same-issue or scoped active PR overlap found.
Change scope ✅ 20/20 Low review scope from cached public metadata (1 linked issue).
Validation posture ✅ 25/25 PR body includes validation/test evidence.
Contributor workload ✅ 10/10 Author activity: 108 registered-repo PR(s), 49 merged, 20 issue(s).
Contributor context ✅ Confirmed Gittensor contributor jeffrey701; Gittensor profile; 108 PR(s), 20 issue(s).
Gate result ❌ Blocking Repo-configured hard blocker found.
Improvement ✅ Minor risk: clean · value: minor — Code changes are accompanied by test evidence.
Review context
  • Author: jeffrey701
  • Role context: outside_contributor
  • Public audience mode: oss maintainer
  • Lane context: Repository is configured for direct PR review.
  • Public profile languages: TypeScript, Clojure, JavaScript
  • Official Gittensor activity: 108 PR(s), 20 issue(s).
  • PR-specific overlap: none found.
Contributor next steps
  • Keep the PR focused and include validation evidence before maintainer review.
Signal definitions
  • Related work = same linked issue, overlapping active PRs, or title/path similarity.
  • Change scope = cached public metadata such as size labels, draft state, and review-burden hints.
  • Validation posture = whether the PR provides enough public validation/test evidence for maintainer review.
  • Contributor workload = public contributor activity and cleanup pressure, not a repo-wide quality failure.
  • Contributor context = public GitHub/Gittensor identity context; non-Gittensor status is not a blocker.
[BETA] Chat with Gittensory

Ask Gittensory a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.

  • @gittensory ask <question> answers contribution-quality Q&A with source citations and freshness.
  • @gittensory chat <question> answers in natural prose from cached decision-pack facts via local inference (maintainer/collaborator; read-only).
  • A plain-language @gittensory mention with a real question is routed to the closest matching read-only command automatically -- no exact syntax required.

Full command reference: https://gittensory.aethereal.dev/docs/gittensory-commands

Visual preview
Route Viewport Before (production) After (this PR's preview) Diff
/app/analytics desktop before /app/analytics after /app/analytics
/app/analytics mobile before /app/analytics (mobile) after /app/analytics (mobile)

Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy.

🟩 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 Gittensory, a quiet PR intelligence layer for OSS maintainers.

  • Re-run Gittensory review

@gittensory-orb

Copy link
Copy Markdown

Gittensory is closing this pull request on the maintainer's behalf (CI is failing (validate, validate-code); Linked issue overlaps another open PR; duplicate of another open PR). This is an automated maintenance action — to pursue this change, please open a new pull request with the issues resolved. Closed PRs may be analyzed later to improve review accuracy, but they are not automatically reopened or re-reviewed.

@gittensory-orb gittensory-orb Bot closed this Jul 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

gittensor:feature Gittensor-scored feature linked to a feature issue — scores a 0.25x multiplier.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(ui): slop-band calibration card on the analytics dashboard

1 participant