Skip to content

feat(signals): flag issues whose body only restates the title#1445

Open
jaso0n0818 wants to merge 1 commit into
JSONbored:mainfrom
jaso0n0818:feat/issue-slop-restated-1782465597
Open

feat(signals): flag issues whose body only restates the title#1445
jaso0n0818 wants to merge 1 commit into
JSONbored:mainfrom
jaso0n0818:feat/issue-slop-restated-1782465597

Conversation

@jaso0n0818

Copy link
Copy Markdown
Contributor

What

Adds a third deterministic issue-slop triage signal (#533) next to the existing empty-body and unfilled-template findings: title_only_restatement fires when a non-empty issue body normalizes to exactly the title — the submitter pasted the title back as the description and added nothing.

Why

The issue-side triage in buildIssueSlopAssessment catches an empty body and an unfilled template, but a body that merely restates the title slips through as clean today even though it carries no more information than the title alone. This is a common low-effort pattern the advisory triage should surface.

How / precision

  • Normalizes both sides case- and punctuation-insensitively (collapsing every non-alphanumeric run to a single space), so reformatting or added punctuation cannot dodge it.
  • Conservative by construction: the body must reduce to the title with zero extra words, so any genuine added detail (steps, location, expected vs actual) clears it.
  • The three issue signals stay mutually exclusive — restatement only evaluates once empty-body and unfilled-template are ruled out, since it needs a body with real prose.
  • Advisory-only, exactly like the sibling signals (issues never block). Static public-safe finding text, no interpolation.

Full branch coverage on every added line; rubric markdown and weights updated in lockstep.

@jaso0n0818 jaso0n0818 requested a review from JSONbored as a code owner June 26, 2026 09:31
@dosubot dosubot Bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Jun 26, 2026
@superagent-security

Copy link
Copy Markdown

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

@codecov

codecov Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.45%. Comparing base (2446a04) to head (04884ed).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1445   +/-   ##
=======================================
  Coverage   95.45%   95.45%           
=======================================
  Files         202      202           
  Lines       21766    21777   +11     
  Branches     7864     7872    +8     
=======================================
+ Hits        20776    20787   +11     
  Misses        414      414           
  Partials      576      576           
Files with missing lines Coverage Δ
src/signals/slop.ts 98.08% <100.00%> (+0.14%) ⬆️
🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@gittensory-orb

gittensory-orb Bot commented Jun 27, 2026

Copy link
Copy Markdown

Tip

🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩🟩

✅ Gittensory review — safe to merge

2 files · 1 AI reviewers · no blockers · readiness 48/100 · CI green · clean

✅ Approved — safe to merge

Review summary
Adds `title_only_restatement` as a third mutually-exclusive issue-triage signal. The mutual-exclusivity guard (`emptyBodyFinding || unfilledTemplateFinding ? null : ...`) is correctly ordered so the new signal only evaluates when both earlier signals are already ruled out. The `normalizeIssueText` helper is sound — Unicode-property regex with the `u` flag handles multibyte characters correctly, and the post-trim empty-length guard in `buildTitleRestatementIssueFinding` handles punctuation-only inputs. The `slopRisk` accumulation correctly adds `ISSUE_SLOP_WEIGHTS.titleRestatement`, and all new paths have full branch coverage per the tests.

Signal Result Evidence
Code review ✅ No blockers 1 reviewers, synthesized
Linked issue ⚠️ Missing No linked issue or no-issue rationale found.
Related work ⚠️ 3 scoped overlaps Top overlaps are listed below; lower-confidence bulk is hidden.
Review load ❌ 8/20 Readiness component derived from cached public PR metadata and labels; size label size:M.
Validation evidence ❌ 5/25 Cached preflight status is hold.
Open PR queue ❌ 3/10 26 open PR(s), 9 likely reviewable, 17 unlinked.
Contributor context ✅ Confirmed Gittensor contributor jaso0n0818; Gittensor profile; 1355 PR(s), 7 issue(s).
Gate result ✅ Passing No configured blocker found.
Nits — 5 non-blocking
  • In `src/signals/slop.ts`, `normalizeIssueText` treats underscores as separators because `_` falls outside `\p{L}` and `\p{N}`, so a title of `null_pointer_exception` and a body of `null pointer exception` are flagged as a restatement — this is consistent with the stated design goal but sufficiently surprising that the function comment should call it out explicitly.
  • In `buildIssueSlopAssessment` (`src/signals/slop.ts`), `unfilledTemplateFinding` is pushed to `findings` before `emptyBodyFinding` even though empty-body is evaluated first; since the three signals are mutually exclusive this is always a single-element array, but matching push order to evaluation order avoids reader confusion.
  • Add a one-line note to the `normalizeIssueText` comment in `src/signals/slop.ts` that underscores (and other `\p{P}` characters) become word boundaries — makes the precision guarantee explicit for future maintainers tuning the signal.
  • Swap the two `findings.push` calls in `buildIssueSlopAssessment` so `emptyBodyFinding` is pushed before `unfilledTemplateFinding`, aligning with the evaluation order already documented in the comment above them.
  • If a sibling PR-side restatement signal is planned (natural extension of feat(github-app): issue-side slop triage #533), consider exporting `normalizeIssueText` from `src/signals/slop.ts` at that point rather than duplicating the normalization logic — it is currently private and would need duplication or a re-export to share.
Review context
Contributor next steps
  • Explain no-issue PR.
  • Review top overlaps.
  • Add scope summary.
  • Fix blocker.
  • Expect slower review.
  • Refresh registry data or choose a registered active repo.
  • Link the issue being solved, or explicitly explain why this is a no-issue PR.
  • Check active issues and PRs before submitting.
Signal definitions
  • Related work = same linked issue, overlapping active PRs, or title/path similarity.
  • Review load = cached public PR metadata such as size labels, changed paths, and preflight status.
  • Open PR queue = repo-wide review pressure; it is not a PR quality failure.
  • Contributor context = public GitHub/Gittensor identity context; non-Gittensor status is not a blocker.
Review details

Generated from public PR metadata and the diff. Advisory only; deterministic signals remain authoritative.

Adds `title_only_restatement` as a third mutually-exclusive issue-triage signal. The mutual-exclusivity guard (`emptyBodyFinding || unfilledTemplateFinding ? null : ...`) is correctly ordered so the new signal only evaluates when both earlier signals are already ruled out. The `normalizeIssueText` helper is sound — Unicode-property regex with the `u` flag handles multibyte characters correctly, and the post-trim empty-length guard in `buildTitleRestatementIssueFinding` handles punctuation-only inputs. The `slopRisk` accumulation correctly adds `ISSUE_SLOP_WEIGHTS.titleRestatement`, and all new paths have full branch coverage per the tests.

Nits (5)

  • In `src/signals/slop.ts`, `normalizeIssueText` treats underscores as separators because `_` falls outside `\p{L}` and `\p{N}`, so a title of `null_pointer_exception` and a body of `null pointer exception` are flagged as a restatement — this is consistent with the stated design goal but sufficiently surprising that the function comment should call it out explicitly.
  • In `buildIssueSlopAssessment` (`src/signals/slop.ts`), `unfilledTemplateFinding` is pushed to `findings` before `emptyBodyFinding` even though empty-body is evaluated first; since the three signals are mutually exclusive this is always a single-element array, but matching push order to evaluation order avoids reader confusion.
  • Add a one-line note to the `normalizeIssueText` comment in `src/signals/slop.ts` that underscores (and other `\p{P}` characters) become word boundaries — makes the precision guarantee explicit for future maintainers tuning the signal.
  • Swap the two `findings.push` calls in `buildIssueSlopAssessment` so `emptyBodyFinding` is pushed before `unfilledTemplateFinding`, aligning with the evaluation order already documented in the comment above them.
  • If a sibling PR-side restatement signal is planned (natural extension of feat(github-app): issue-side slop triage #533), consider exporting `normalizeIssueText` from `src/signals/slop.ts` at that point rather than duplicating the normalization logic — it is currently private and would need duplication or a re-export to share.

🟩 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 gittensory-orb Bot added gittensor Gittensor contributor context gittensor:feature Gittensor-scored feature linked to a feature issue - worth 1.25x multiplier. labels Jun 27, 2026
Add a third deterministic issue-slop signal (JSONbored#533) alongside the empty-body
and unfilled-template findings: `title_only_restatement` fires when a
non-empty issue body normalizes to exactly the title, i.e. the submitter
pasted the title back as the description and added nothing.

Conservative and high-precision, matching the issue-triage rubric: the body
must reduce to the title with zero extra words after case- and
punctuation-insensitive normalization, so any genuine added detail (steps,
location, expected vs actual) clears it. The three issue signals stay mutually
exclusive — restatement only evaluates once empty-body and unfilled-template
are ruled out, since it requires a body with real prose.
@jaso0n0818 jaso0n0818 force-pushed the feat/issue-slop-restated-1782465597 branch from 1284cfa to 04884ed Compare June 27, 2026 02:37
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 - worth 1.25x multiplier. gittensor Gittensor contributor context size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant