You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Build the adapter that takes a driver's raw diff/worktree state each iteration and turns it into the SAME inputs buildPredictedGateVerdict and the slop/scoring signals expect (a synthetic PR record, changed paths, title/body), so the iterate loop's self-review call is genuinely byte-identical to what the live maintainer gate would compute post-submission — not an approximation. This is the piece that makes the miner's own self-assessment trustworthy enough to decide autonomously whether to keep iterating, and is inseparable from the trigger-surface concern the orchestration-loop issue covers, so it is held to the same maintainer tier.
Deliverables
packages/gittensory-engine/src/miner/self-review-adapter.ts exporting a function that builds a PredictedGateInput-shaped object (repo, contributor login, title, body, labels, linked issues, changed paths) from an attempt's live worktree diff state
Calls buildPredictedGateVerdict (imported from wherever the shared-engine extraction issue relocates it, or directly from src/rules/predicted-gate.ts if that extraction has not yet landed — coordinate with whichever issue owns moving deterministic logic into packages/gittensory-engine) and returns its verdict alongside a slop-signal pass using src/signals/slop.ts
Explicitly threads changedPaths (the real changed file paths from the diff) so the path-dependent predicted-gate checks are evaluated, not skipped — an omitted-paths call silently under-predicts per the existing PREDICTED_GATE_NOTE_NO_PATHS disclaimer, which would be a dangerous false-confidence bug if the miner's own loop relied on it
A hard requirement (asserted in tests) that a conclusion other than a clear pass is treated as "do not hand off to submission" by any caller (this issue, plus the orchestration-loop issue, both enforce this independently — defense in depth)
Owner-reviewed tests using real predicted-gate fixtures (a genuinely passing synthetic diff and a genuinely blocked one) proving the adapter's verdict matches calling buildPredictedGateVerdict directly with the same inputs
References
/Users/shadowbook/Documents/gittensory/.claude/worktrees/quizzical-engelbart-34f3be/src/rules/predicted-gate.ts lines 95-263 (buildPredictedGateVerdict — the exact function this adapter feeds) and lines 107-112 (the changedPaths doc comment explaining why omitting them under-predicts — the precise footgun this issue must avoid)
src/signals/slop.ts (516 lines) — the slop-signal pass this adapter also threads through, per the predicted-gate's own PREDICTED_GATE_NOTE_SLOP disclaimer (slop is NEVER evaluated pre-submission from metadata alone, but the miner's own loop DOES have the full diff content locally, so it can run a real slop pass the metadata-only public predictor cannot)
packages/gittensory-engine/src/miner/iterate-loop.ts (the consumer of this adapter's verdict, sibling maintainer issue in this batch)
Build the adapter that takes a driver's raw diff/worktree state each iteration and turns it into the SAME inputs
buildPredictedGateVerdictand the slop/scoring signals expect (a synthetic PR record, changed paths, title/body), so the iterate loop's self-review call is genuinely byte-identical to what the live maintainer gate would compute post-submission — not an approximation. This is the piece that makes the miner's own self-assessment trustworthy enough to decide autonomously whether to keep iterating, and is inseparable from the trigger-surface concern the orchestration-loop issue covers, so it is held to the samemaintainertier.Deliverables
packages/gittensory-engine/src/miner/self-review-adapter.tsexporting a function that builds aPredictedGateInput-shaped object (repo, contributor login, title, body, labels, linked issues, changed paths) from an attempt's live worktree diff statebuildPredictedGateVerdict(imported from wherever the shared-engine extraction issue relocates it, or directly fromsrc/rules/predicted-gate.tsif that extraction has not yet landed — coordinate with whichever issue owns moving deterministic logic intopackages/gittensory-engine) and returns its verdict alongside a slop-signal pass usingsrc/signals/slop.tschangedPaths(the real changed file paths from the diff) so the path-dependent predicted-gate checks are evaluated, not skipped — an omitted-paths call silently under-predicts per the existingPREDICTED_GATE_NOTE_NO_PATHSdisclaimer, which would be a dangerous false-confidence bug if the miner's own loop relied on itconclusionother than a clear pass is treated as "do not hand off to submission" by any caller (this issue, plus the orchestration-loop issue, both enforce this independently — defense in depth)buildPredictedGateVerdictdirectly with the same inputsReferences
/Users/shadowbook/Documents/gittensory/.claude/worktrees/quizzical-engelbart-34f3be/src/rules/predicted-gate.tslines 95-263 (buildPredictedGateVerdict— the exact function this adapter feeds) and lines 107-112 (thechangedPathsdoc comment explaining why omitting them under-predicts — the precise footgun this issue must avoid)src/signals/slop.ts(516 lines) — the slop-signal pass this adapter also threads through, per the predicted-gate's ownPREDICTED_GATE_NOTE_SLOPdisclaimer (slop is NEVER evaluated pre-submission from metadata alone, but the miner's own loop DOES have the full diff content locally, so it can run a real slop pass the metadata-only public predictor cannot)packages/gittensory-engine/src/miner/iterate-loop.ts(the consumer of this adapter's verdict, siblingmaintainerissue in this batch)