Free-Model PR Triage: A Working Script for Maintainers
Description and use
A script uses a free LLM to pre‑classify PRs by risk, missing tests, and priority, streamlining manual review.
Problem
Maintainers are overwhelmed by pull requests; most PRs do not need full review, but current triage consumes hours.
Outcome
The script reduces manual triage effort by automatically classifying PRs into risk categories and queue priorities, while keeping humans in control for final review.
Workflow
- Collect PR metadata with GitHub CLI and truncate diff to 200 lines
- Build a structured JSON prompt for the LLM
- Call a free OpenAI‑compatible endpoint (MonkeyCode) to get risk, missing_tests, summary, questions
- Apply a decision table to assign triage action (request changes, full review, normal queue, etc.)
Evidence
Free models fail. They miss subtle logic. They invent file names. They cannot run the test suite.
Never merge based on model output. Never skip human review for security or payment code.
- Record date: 2026-09-07T15:29:34.345Z