[PR #9522] feat: enhance duplicate-issues workflow with agent review and spam detection #13134

Closed
opened 2026-02-16 18:18:00 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/9522

State: closed
Merged: No


Summary

Enhances the duplicate issue detection workflow with:

  • Agent Review format - Structured comments with confidence scores (0-100%) for duplicate detection
  • Spam detection - Auto-closes empty issues and service offer spam
  • Codebase exploration - AI can explore repo to answer OpenCode tooling questions
  • Reaction-based auto-close - Issues closed after 6 hours if no 👎 reaction (50%+ confidence threshold)

Changes

New Features

  1. Confidence scoring for duplicates:

    • 90-100%: Nearly identical
    • 70-89%: Very similar
    • 50-69%: Related (threshold for auto-close)
    • <50%: Not included
  2. Spam detection (runs before AI review):

    • Empty body + title with <3 alphanumeric chars
    • Service offers ("i can fix", "hire me", "freelanc")
  3. Quick answers - AI explores codebase to answer OpenCode questions directly

Security Fixes

  • Fixed shell injection vulnerability by using env vars for issue title/body
  • Labels auto-created in issues-opened job (not just scheduled job)

Labels

  • spam (red) - spam/low-quality issues
  • potential-duplicate (yellow) - pending confirmation
  • duplicate (gray) - confirmed duplicates

Testing

  • YAML syntax validated
  • Reviewed by sophos agent for security issues

Closes issues like #9513, #9498 (spam/empty issues)

**Original Pull Request:** https://github.com/anomalyco/opencode/pull/9522 **State:** closed **Merged:** No --- ## Summary Enhances the duplicate issue detection workflow with: - **Agent Review format** - Structured comments with confidence scores (0-100%) for duplicate detection - **Spam detection** - Auto-closes empty issues and service offer spam - **Codebase exploration** - AI can explore repo to answer OpenCode tooling questions - **Reaction-based auto-close** - Issues closed after 6 hours if no 👎 reaction (50%+ confidence threshold) ## Changes ### New Features 1. **Confidence scoring** for duplicates: - 90-100%: Nearly identical - 70-89%: Very similar - 50-69%: Related (threshold for auto-close) - <50%: Not included 2. **Spam detection** (runs before AI review): - Empty body + title with <3 alphanumeric chars - Service offers ("i can fix", "hire me", "freelanc") 3. **Quick answers** - AI explores codebase to answer OpenCode questions directly ### Security Fixes - Fixed shell injection vulnerability by using env vars for issue title/body - Labels auto-created in issues-opened job (not just scheduled job) ### Labels - `spam` (red) - spam/low-quality issues - `potential-duplicate` (yellow) - pending confirmation - `duplicate` (gray) - confirmed duplicates ## Testing - YAML syntax validated - Reviewed by sophos agent for security issues Closes issues like #9513, #9498 (spam/empty issues)
yindo added the pull-request label 2026-02-16 18:18:00 -05:00
yindo closed this issue 2026-02-16 18:18:00 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#13134