Proof Portal
litellm
BerriAI117 findings · 107 requirementsLiteLLM Python->Rust migration audit (proof mirroring).
93 withheld (location undisclosed)
_validate_input_param converts pydantic input items to dicts (exclude_none) and routes reasoning-typed dict items through _handle_reasoning_item, which filters null fields via OpenAI's ResponseReasoningItem and, when construction fails, falls back to a manual filter that drops only null status/content/encrypted_content while keeping every other key
Specification
The requirement exactly as authored — its complete prose text and, where present, the formal FRETish sentence it compiles to.
_validate_input_param converts pydantic input items to dicts (exclude_none) and routes reasoning-typed dict items through _handle_reasoning_item, which filters null fields via OpenAI's ResponseReasoningItem and, when construction fails, falls back to a manual filter that drops only null status/content/encrypted_content while keeping every other key
the openai_responses shall always satisfy reasoning_input_normalized
Verification & provenance
How this requirement was checked: the review trail, edit history, and the machine-analysis status terms (each ⓘ explains what it means).
Review
- Status
- pending
History
- Created
- Jul 31, 2026, 00:00 UTC · Claude Code · AI agent
- Modified
- Jul 31, 2026, 00:00 UTC · Claude Code · AI agent
Hazard review
- scenarioreviewednominalmalformed_inputerror_handling
nominal converts pydantic items and passes plain dict/scalar items through; malformed_input is the reasoning item with a null status/content that must be filtered before send; error_handling is the ResponseReasoningItem construction failure that falls back to the manual null filter rather than propagating
- propertynot applicable
_validate_input_param/_handle_reasoning_item are branchy normalizers over heterogeneous input items, not an algebraic property surface; the null-drop invariant is covered by the malformed_input scenario rather than a restated property
- structuralnot applicable
Garbage-collected Python dict/list normalization with no manual memory, pointer arithmetic, overflow, or format string
- domainnot applicable
Pure in-process item normalization issuing no network/filesystem/IPC call
Change history
Every recorded revision of this requirement's source file — newest first, each with its commit message and the diff for that change.
Review history
Human and AI-agent approvals of this requirement — the 'why was this approved' lineage, each with the reviewer's justification and the code it cites.
- Claude Code · AI agentApprovedSpec conformanceJul 31, 2026 · 4 months agoREVIEW-19
_validate_input_param: line 209 'isinstance(item, dict)' and 211 'item.get("type")=="reasoning"' route reasoning dicts to _handle_reasoning_item; pydantic items dumped exclude_none (207). _handle_reasoning_item: 235 gates reasoning type, 239 synthesizes missing summary, 259 fallback comprehension drops null status/content/encrypted_content while keeping other keys. reasoning_input_normalized holds.
Cited code (5)
Open known issues
Findings currently open against this requirement — issues its verification surfaced that are not resolved yet. Each links to the full finding.
Obligations
What this requirement must witness to be considered satisfied — the required evidence, and the tests that discharge each one.
3 obligations · 3 discharged
Browse the catalogueHappy-path behavior with valid inputs.
- nominalrequiredpresentCovered by 2 tests
Behavior when inputs are syntactically or structurally invalid.
- negativerequiredpresentCovered by 1 test
- nominalrequiredpresentCovered by 2 tests
Behavior when operations fail or dependencies are unavailable.
- negativerequiredpresentCovered by 1 test
- nominalrequiredpresentCovered by 1 test
Code signals
Static-analysis signals from external scanners that bear on this requirement's obligations — the source location, the obligation each touches, and its closure status.
- Missingbuiltinunordered_set_to_outputObligation: Determinism · Property
Output identical regardless of collection ordering or runtime conditions.
OpenAIResponsesAPIConfig.get_supported_openai_params: list(set(...)) — no total order
Formula evidence
The formal formula behind this requirement, the variables it is written over, and the tests that exercise it (each term is explained inline).
Formula evidence
The formal formula behind this requirement, the variables it is written over, and the tests that exercise it (each term is explained inline).
FRETish formula
the openai_responses shall always satisfy reasoning_input_normalized
Witnesses· 1 scenario total
- test_pydantic_reasoning_plaindict_and_scalar_itemsexercises 1 condition scenario
MC/DC truth table· 2 rows
Each row assigns the formula's conditions (T/F) and shows the Result— the formula's value for that input row, not a test pass/fail. A row proves a condition when flipping only that condition flips the outcome. The test that covers each row is linked.
mcdc:ignoreNo-actionfalse-result row satisfied by designUncoveredneeds a covering test| # | reasoning_input_normalized | Result | Proves | Covering test |
|---|---|---|---|---|
| 1 | F | F | reasoning_input_normalized | Exempted · defensive — pydantic items are always dumped to dicts and reasoning items always routed through the null filter; leaving input unnormalized is unreachable in a correct build (reviewed: agent:claude-opus-4-8) |
| 2 | T | T | reasoning_input_normalized |
Its place
How this requirement connects — what proves it, what it affects, and what it rests on. Authored links only here; automatically derived links come from the audit index.
Loading graph…
Trace evidence
The concrete artifacts linked to this requirement — implementing code, verifying tests, documents, and the findings raised against it.
Mirrors
Ports this requirement participates in — it carries a reviewed exemption on one side, or a finding raised against it is tracked as part of the port.
Mirrors
Ports this requirement participates in — it carries a reviewed exemption on one side, or a finding raised against it is tracked as part of the port.
- OpenAI Responses API: Python -> RustMIR-003InheritedPython → RustView in Mirrors
Impact
Blast radius — authored trace links only (automatically derived links come from the audit index and aren't shown here).
Impact
Blast radius — authored trace links only (automatically derived links come from the audit index and aren't shown here).
If you change this
Files to re-check (1)
- transformation.pylitellm/llms/openai/responses/transformation.py
Tests to re-run (1)
- test_openai_responses_transformation.pytests/test_litellm/llms/openai/responses/test_openai_responses_transformation.py
What this rests on
Discussions
Discuss this with the proof team. Nothing changes in your audit automatically — you open a request and a staff member records any outcome inside the thread.