Repository navigation
refactor(openrouter): prepare Decision routing before execution - #188236
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. What this changesThis PR separates OpenRouter Decision routing and transport preparation from private HTTP execution. Example: Evaluate a billing question with openrouter/typesafe/jev-1.13.
Review scores
ProductKind: Refactor · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review Keep open: this maintainer-authored refactor preserves the existing Decision transport contract, and inspection found no actionable introduced defect. Priority: P3 Before mergeNone. FindingsNone. Tests
Agent review detailsHow this fits togetherThe OpenRouter plugin receives validated Decision batches and host-prepared credentials, applies provider routing policy, and returns typed outcomes through guarded HTTP transport. flowchart LR
A[Decision host] --> B[OpenRouter adapter]
B --> C[Request codec]
B --> D[Private executor]
D --> E[Guarded HTTP transport]
E --> F[System One endpoint]
D --> G[Typed outcome]
Technical reviewBest possible solution: Retain this focused private extraction with provider policy in the adapter and one executor owning dispatch, response handling, and cleanup. Do we have a high-confidence way to reproduce the issue? There is no reported runtime bug to reproduce; source comparison checks preservation of the existing execution contract. Is this the best way to solve the issue? The extraction establishes a narrow private boundary without duplicate execution paths, new state, or public SDK expansion. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 9b3d8bc36ea6. Provenance checked
TestingProof path: in-process harness. SecurityNone. EvidenceWhat I checked:
Likely related people:
PR surfaceSource +51. Total +51 across 2 files. Added test files: 0. View PR surface stats
LabelsLabel changes:
Label justifications:
Rank-up movesOptional improvements that raise the rating; they are not merge blockers.
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment Reviewed October 30, 2026, 6:35 AM ET / 10:35 UTC. |
6c1a53e to
defb385
Compare
d5746a7 to
14b7d2f
Compare
defb385 to
44028d8
Compare
14b7d2f to
d6fa822
Compare
44028d8 to
196c913
Compare
d6fa822 to
1a4176a
Compare
44028d8 to
196c913
Compare
1a4176a to
12e95a9
Compare
12e95a9 to
5a27e77
Compare
|
Merged via squash.
|
What Problem This Solves
OpenRouter Decision execution receives broad plugin configuration alongside its request lifetime and transport work.
User Impact
No user-visible behavior or configuration change. Part 11 of the Decision refactor stack, based on part 10.
Why This Change Was Made
Keep native eligibility, routing/privacy merges, credential availability and network projection in the plugin adapter. The private executor receives explicit body, capability and lifetime facts plus synchronous transport preparation. It retains the existing transport, dispatch-time admission, response handling and awaited release.
Two production files, +157/-106 lines. The growth defines the private execution boundary; no framework, cache, retry or new public SDK surface is added. Existing provider and registered integration tests remain.
Evidence
git range-diff.d5746a74e3a4da136d62dcf64afb925bc2f49d48, including the configured runtime, type, lint and guard lanes.5b235dd694af030aeb75e1ec6e831b71ce4b745c. Shared SDK source-audit evidence, the advisory API-report timeout and broader manual-campaign limitations are recorded in part01.Landing update
Current head:
5a27e7783a4cd9ef2fb2991672d27196ae5c1a4d; current-head CI passed at5a27e7783a4cd9ef2fb2991672d27196ae5c1a4d. Native landing targets main after the preceding slice merged. Replayed only this slice onto verified landed part1070ceaa1e9efbdfc481cbee41fb1e6bb5f576ae7bafter an observed squash-ancestry conflict in the OpenRouter adapter. The predecessor's OpenRouter source is byte-identical to its landed form. The own-slice range remains patch-identical bygit range-diff, with a valid commit signature. Prior passing CI41162922912 at12e95a9aa1b8ae3ace8516dccc45877adf150201remains historical evidence; fresh CI and native admission are required for this head.Earlier landing evidence
Earlier head:
1a4176a01ea3c68c3911aa5981418054a1a7bb38; that head's CI is pending. After part04 landed, the remaining stack was replayed onto its actual protected-main commit63dbee6a514580948082dc20cb930c7e748c019eto resolve the named CI/base-context gap in part05. All 20 commit ranges remain patch-identical bygit range-diff; the allocation guard passes. Earlier CI/build evidence above remains historical. Each slice lands through the native main-targeted review, preparation, and merge workflow after its predecessor.