General-purpose coding policy for Baruch's AI agents
90
91%
Does it follow best practices?
Impact
90%
1.30xAverage score across 18 eval scenarios
Advisory
Suggest reviewing before use
Process steps in order. Do not skip ahead.
Classify a referenced pull request and, when it comes from a fork, adopt its branch into the base repo as a same-repo PR the policy reviewer can run on.
Run gh pr view <N> --json number,isCrossRepository,headRefName,headRepositoryOwner,headRepository,author,title,url,state.
isCrossRepository: false — same-repo PR. Proceed to Step 2.isCrossRepository: true — fork PR. Proceed to Step 3.The policy reviewer already covers same-repo PRs. Report the PR's review and check status from gh pr view <N> --json reviewDecision,statusCheckRollup and finish here. Do not create branches, push, or open duplicate PRs.
Tell the user PR #N comes from fork <headRepositoryOwner.login>/<headRepository.name> and that the policy reviewer's fork-guard skips it. Proceed immediately to Step 4.
Ask with AskUserQuestion:
On Just inspect, report the diff and status, then finish here. On Adopt for review, proceed to Step 5.
.tessl/plugins/jbaruch/coding-policy/skills/adopt-fork-pr/adopt.sh <N>Contract: see skills/adopt-fork-pr/adopt.sh — top-of-file docstring carries the branch-naming rule, the verbatim new-PR-body and original-PR-comment templates, the idempotency states, and the exit codes. It checks out the fork head, pushes it to a base-repo branch preserving the original commits, opens a same-repo PR, and comments on the original fork PR linking the adopted one. Emits { "state", "adopted_branch", "new_pr_url", "original_pr", "author" }.
Report the adopted PR URL. The original fork PR is left open with a pointer comment — the contributor closes it on their own. adopt.sh carries the Author-Model signal automatically: the Co-authored-by: trailer rides on the preserved commits, and a body-only **Author-Model:** line is copied from the original PR body. From here it is an ordinary same-repo PR: the cross-family reviewer runs and you merge through your normal flow. Finish here.
.tessl-plugin
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10
scenario-11
scenario-12
scenario-13
scenario-14
scenario-15
scenario-16
scenario-17
scenario-18
rules
skills
adopt-fork-pr
eval-curation
install-reviewer