Repository navigation
fix(gateway): resolve configured aliases for typed decisions - #785
Conversation
|
Agent-generated independent adversarial review. The report and full prompt below are preserved verbatim. Independent adversarial review — public SIE PR #785Disposition: REQUEST CHANGES. Reviewer: Base: The supplied public checkout remained clean and at that head. The complete diff changes only Finding[P2] Normalize hidden and absent 404 responses when the model registry is emptyLocation: The new preflight can distinguish an alias hidden by This violates the public model-policy contract that a hidden model be indistinguishable from an absent one ( Independent reproduction used two otherwise equivalent empty-registry fake gateways and the same caller request for {"detail":{"error_type":"not_found_error","message":"Model 'decision' not found","code":"model_not_found"}}{"detail":{"error_type":"not_found_error","message":"Model 'decision' not found","code":"MODEL_NOT_FOUND"}}The same equality assertion fails at the reviewed head and passes at the exact base. The Decisions wrapper forwards this code through its existing conversion ( Requested correction: render model-not-found failures through one consistent response path, preserving the original caller spelling and the early visibility check. Add hidden-versus-absent equality coverage for empty and populated registries through both typed-decision surfaces. Do not remove or postpone the policy check to solve the discrepancy. Other abuse cases assessed
Review scope and sibling sweepFull changed files and all diff hunks were reviewed:
Relevant unchanged public files were reviewed in the following scope (not a claim of whole-file review for these dependencies):
The sibling sweep traced both typed-decision surfaces to the shared native resolver, and checked the embeddings preflight, audio model validation, profile-expansion semantics and existing resolver tests. It did not expand into a full audit of all public endpoints. Independent tests and isolationAll test/build invocations used No credentials were inspected or supplied. No provider/model calls, real API requests, GitHub writes, deployment actions or external network requests were made. Tests used temporary YAML fixtures, pure resolution functions and fake dispatch. No service was started for this review. The source checkout was not modified; the regression test was added only to a temporary public source copy. This is not a hard operating-system credential or network firewall. Clearing the environment and HOME prevents ambient configuration being passed normally; it does not establish that arbitrary executable code could not read an absolute host path. Cargo's offline mode prevents dependency fetching; it is not a general sandbox for all test/build code. The claim here is the actual commands and local fake code paths exercised, not stronger isolation.
Thus 58 existing focused tests passed independently; the new regression probe failed only at the reviewed head. Full logs and the exact runner scripts accompany this report. The initial full test-binary build used a fresh target; later runs reused only this review's own artifacts. The head and base probe builds ran sequentially in that target. The supplied claims about CodeRabbit approval, all-target Clippy/fmt and CI status were not independently fetched or treated as safety evidence. No CI conclusion is asserted here. This review did not run all gateway tests, live models, deployment integrations, benchmarks, or every feature combination. Prompt recordThe complete initial review prompt follows verbatim. No follow-up prompts were received by this reviewer before this report was finalized. |
Agent-generated interrupted independent review recordThis record is supplied by the parent session, not a completed reviewer report. Reviewer session: Disposition: INCOMPLETE — no approval or finding disposition issued. The platform usage limit interrupted the reviewer before its report. The prior P2 remains unresolved by this attempt. A separate fresh reviewer is examining the complete change and that finding. The retained local run-status record lists these selections as completed; this is evidence of attempted validation, not a completed whole-diff security conclusion. An additional probe source file was drafted, but no execution result is asserted for it. All artifacts are preserved. No report is being reconstructed or attributed to the interrupted reviewer. No changed file was excluded by the prompt. Full prompt verbatim |
Agent-generated independent adversarial review — public SIE PR #785Disposition: APPROVE at Original P2: RESOLVED, not invalidated. No additional actionable finding was established within the full PR scope and the verification limits below. Reviewer canonical session ID: Base / recorded Head: Full requested range: The entire change is 227 additions and 2 deletions in two files. Both complete changed files and every diff hunk were reviewed; no changed file was excluded:
The supplied checkout remained clean at the exact head before and after review. No source edits were made there. Original P2: independent dispositionThe prior report's SHA-256 was independently verified as
The original finding follows verbatim, including its original line references and evidence statements. Those statements describe the earlier review, not this head: [P2] Normalize hidden and absent 404 responses when the model registry is emptyLocation: The new preflight can distinguish an alias hidden by This violates the public model-policy contract that a hidden model be indistinguishable from an absent one ( Independent reproduction used two otherwise equivalent empty-registry fake gateways and the same caller request for {"detail":{"error_type":"not_found_error","message":"Model 'decision' not found","code":"model_not_found"}}{"detail":{"error_type":"not_found_error","message":"Model 'decision' not found","code":"MODEL_NOT_FOUND"}}The same equality assertion fails at the reviewed head and passes at the exact base. The Decisions wrapper forwards this code through its existing conversion ( Requested correction: render model-not-found failures through one consistent response path, preserving the original caller spelling and the early visibility check. Add hidden-versus-absent equality coverage for empty and populated registries through both typed-decision surfaces. Do not remove or postpone the policy check to solve the discrepancy. Current disposition: RESOLVEDAt the new head, I reran the unchanged original
The new head also independently passes a stronger 24-pair matrix: both endpoints, empty and populated registries, and six spellings covering simple/mixed-case aliases, configured profile and bundle targets, Abuse cases and conclusions
Relevant dependencies and sibling sweepThe following unchanged public files were inspected in the stated scope. This table is not a claim of whole-file review beyond the two changed files:
Independent verification and preserved runsAll build/test invocations used The unmodified head was archived from Git and independently built. No prior or author target directory was copied or used. Later test runs reused only artifacts built by this review. The original regression probe and the interrupted review's six supplemental probe drafts were read and reused as source, not accepted as previous passing evidence; I added the bundle-conflict probe and compiled all eight locally. The prior completed report and prior interrupted review directory were left unchanged. The interrupted review has no disposition and is not treated as approval.
Thus 60 existing focused tests and 8 reviewer probes passed at the reviewed head. The old-head control failed as expected, and the base control passed. There were no other failed test/check invocations in this review. Every test/check log, including the expected failure, and each runner is retained in the evidence directory. Tests used only local YAML fixtures, fake policies, fake workers and an in-memory recording dispatcher. No model/provider request, external API request, authenticated tool, real service, release or deployment was used. No credential was inspected or supplied. Shell/source inspection was read-only outside the designated scratch directory. This is not a hard filesystem or network firewall. An empty environment/HOME avoids passing ordinary ambient configuration but does not prevent arbitrary executable code from opening a known absolute host path. Cargo offline mode prevents dependency fetching, not arbitrary network access by executable code. The isolation claim is limited to the actual local fake paths and commands exercised. No full runtime, real model, live policy, transport-service, full gateway suite, benchmark or exhaustive feature-matrix claim is made. The reported CodeRabbit approval and CI status were not independently fetched and are not asserted as evidence by this review. This approval concerns the exact full PR diff reviewed above and does not itself authorize merge, release or deployment. Full initial prompt, verbatimThe complete initial task prompt follows verbatim. One subsequent coordination message, received while finalizing this report, is recorded after it. The reported CI status in that message was not independently fetched by this reviewer and did not change the review scope or test evidence. Subsequent coordination message, verbatim |
Configured model aliases already work for native extract, but System One and Decisions checked the unresolved alias for typed-question support and returned
MODEL_NOT_FOUND.Resolve aliases through the existing model and access-policy helper before checking capability. Responses retain the caller’s model spelling, while native dispatch uses the canonical model. Regression tests cover aliases, case normalization, named profiles, bundle targets, non-decision models and hidden models.
Validation at
f124a99183a8a7e3e564a699158882df4a9e19a2: 19 System One tests and 14 Decisions tests passed. Three existing model-resolution policy regressions, all-target Clippy and formatting checks also passed. The independent review found a distinguishable not-found error for hidden versus absent aliases with an empty registry. The follow-up normalizes that code while preserving early visibility checks; both routes now compare complete error bodies for empty and populated registries. CodeRabbit and all20 current checks pass. The fresh independent review approves this head and explicitly resolves the original finding, with60 focused tests and8 independent probes. The interrupted prior attempt is retained without approval. No release or deployment is included.Summary by CodeRabbit
404response as unavailable models, without revealing the resolved model’s name.