feat(review): surface a risk x value quadrant in the PR panel - #4964
Conversation
Crosses the existing slop-risk band with the deterministic structural-improvement band into a compact "risk: X · value: Y" label, prefixed onto the existing Improvement row's Evidence cell -- the maintainer 2x2 from the epic's design doc (safe-but-worthless churn vs. risky-but-valuable work vs. actual slop vs. a fast-track candidate). Reuses the already-computed slop band and structural-improvement assessment for the current pass; no new fields: toggle key, no second convergedFeature resolution, and no gate/blocker involvement. Repos that have not opted into the improvementSignal converged feature see byte-identical panel output, since the row (and therefore the quadrant prefix) only ever renders when that feature resolves on for the repo.
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4964 +/- ##
=======================================
Coverage 94.26% 94.26%
=======================================
Files 447 447
Lines 38884 38893 +9
Branches 14167 14172 +5
=======================================
+ Hits 36653 36662 +9
Misses 1574 1574
Partials 657 657
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-11 04:16:14 UTC
⏸️ Suggested Action - Manual Review
Review summary Nits — 6 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 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.
|
Summary
crosses the existing slop-risk band (
src/signals/slop.ts) with the deterministic structural-improvementband (Aggregate deterministic structural-improvement sub-score #4742) into a compact
"risk: X · value: Y"string — exactly the maintainer 2x2 from this issue'sown body (safe-but-worthless churn vs. risky-but-valuable work vs. actual slop vs. a fast-track candidate).
formatRiskValueQuadrant(slopBand, improvementBand)insrc/signals/engine.ts.Degrades in two independent steps, never fabricating a reading for an axis a given pass didn't compute:
absent
improvementBand→ risk-only label; absentslopBand→undefined(nothing shown).buildImprovementSignalRow) as a prefix on its Evidencecell, instead of a new row or a new
fields:toggle key — the row already only renders when theimprovementSignalconverged feature resolves on for the repo, so reusing it means opted-out repos staybyte-identical for free, with no new key to hand-sync across
.gittensory.yml.example/config/examples/gittensory.full.yml/gittensory-repo-focus-manifest.ts/.gittensory.yml.src/queue/processors.ts: hoists aslopBand: SlopBand | nullout of the try-block (mirroring theexisting
slopRiskhoist right next to it) so the quadrant can reuse the slop band already computedby the existing
buildSlopAssessmentcall this pass — no second slop computation, no secondresolveConvergedFeature/convergedFeatureActiveresolution. Threaded into both panel builders(
commentArgsfor the legacy comment, and thebuildPublicPrPanelSignalRowscall for the unified-commentbridge) so the two never diverge, matching how every other row in this panel is already hand-mirrored.
evaluateGateCheck,isConfiguredGateBlocker, or any blocker path(epic design constraint 2).
SlopBand/ImprovementBandare closed enums interpolated verbatim, so thequadrant clause is public-safe by construction — no sanitizer/
containsPrivatePublicTermcheck needed forthe clause itself (verified with a dedicated regression test anyway, mirroring this epic's existing style).
worklist is not built in this PR — spun out as an explicit fast-follow. I don't have a
spawn_tasktool in this environment, so per the issue's own fallback instruction I'm stating the decision here instead
of filing a tracking issue myself: this repo's small-PR preference plus the issue's own "Optional" framing
point at shipping the per-PR panel view first (this PR) and building the queue-level worklist as its own
follow-up once the panel version proves useful, exactly as the issue body suggests.
src/signals/engine.ts'simprovement-row section and
src/queue/processors.ts's slop-evidence block were shipped earlier today(feat(review): surface the improvement signal in the PR panel #4954/feat(review): surface the improvement signal in the PR panel #4954-adjacent) and are already clean; nothing adjacent needed modernizing in this pass.
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 typecheck— clean.npm run test:coverage(unsharded, full local run) — clean; diff-scoped cross-reference againstcoverage/lcov.info(not just the terminal summary): zero uncovered statements and zero uncoveredbranches on any changed/added line in
src/signals/engine.tsorsrc/queue/processors.ts. Specificallyconfirmed both arms of every new conditional are hit:
formatRiskValueQuadrant'sslopBand === undefinedbranch (13/11 hits), its
improvementBand === undefinedbranch (3/8 hits),buildImprovementSignalRow'squadrant ? … : …branch (4/11 hits), and bothslopBand ?? undefinedcall sites inprocessors.ts(141/136 and 27/26 hits).
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=moderate— 0 vulnerabilities.boundaries — see below.
test:cigate piece by piece (all green):db:migrations:check,db:schema-drift:check,selfhost:env-reference:check,selfhost:validate-observability,cf-typegen:check,test:engine-parity,test:driver-parity, the@jsonbored/gittensory-engineworkspace test,
build:miner,test:miner-pack,rees:test(1297 tests),ui:openapi:settings-parity,ui:version-audit,docs:drift-check,manifest:drift-check,command-reference:check,ui:test.npx tsx scripts/check-engine-parity.tsdirectly — "22 hand-duplicated file pair(s) agree, no drift".signals-coverage.test.ts,ai-review-advisory.test.ts,queue.test.ts,queue-2/3/4/5.test.ts) — 735/735 passing. Broadernpm run test:unitsanity sweep (the entiretest/unit/directory, not just touched files) — 679 files / 13573 tests, all passing.high-risk/low-value, high-risk/high-value) plus the "improvement signal unavailable" degraded case
(risk-only label) plus the "slop band unavailable" case (
undefined, nothing shown) — per this issue'sown acceptance criteria.
Safety
rankings, or private maintainer evidence are exposed.
optimization tactics —
SlopBand/ImprovementBandvalues are closed enums, never free text, and adedicated regression test asserts the quadrant clause can never carry forbidden vocabulary.
ui:openapi:checkandui:openapi:settings-parity, both clean/no-op for this diff).apps/**files touched.fields:toggle key, so no.gittensory.yml.exampleupdate is needed (thequadrant reuses the existing
improvementSignalkey's row and gating end to end).UI Evidence
This is a Markdown/text panel-comment change (an existing GitHub PR comment row), not a rendered browser UI
surface, so no screenshot/preview tooling in this environment applies (same precedent as the sibling #4954
PR that shipped the row this PR extends). Per this issue's own acceptance criterion for UI evidence, here is
the exact rendered text from this PR's own test assertions, in place of a screenshot:
buildPublicPrPanelSignalRows/buildPublicPrIntelligenceComment, both risk and value present):slopBandthreaded — byte-identical to before this PR):processJob→ posted GitHub comment, unified-comment renderer, realbuildSlopAssessment+buildStructuralImprovementAssessmentoutput for the test fixture PR):Notes
gh pr view --json closingIssuesReferences(see this PR's own check after opening) that thisPR closes exactly Maintainer risk x value triage view #4745, not the parent epic Epic: PR improvement signal — quality-delta scoring as the positive-axis counterpart to slop-risk #4737 (which stays open — it has other sub-issues, MCP pre-submit value-potential tool #4746,
still pending).
already merged to
main; this PR only adds the quadrant crossing on top of their already-shipped output,per this issue's own scope.
apps/gittensory-ui/) is added — explicitly not required by this issue's ownacceptance criteria, and not built here.
Closes #4745
Part of epic #4737