litellm/litellm-rust
Yujong Lee 9bc6426ae1 refactor(python-bridge): bind OCR arguments once in Rust
The request crossed the boundary four times: Python bind_request into a
dataclass, Rust re-reading each field back with its own precedence rules,
a BridgeOcrRequest copy, then the core request. The dataclass was retained
for the whole call only so map_failure could read model and kwargs at the
end.

Add a route-agnostic Signature binder that reproduces Python's positional
and keyword binding rules and TypeError messages, and project straight
from the bound arguments into the core request. This removes the Python
LiteLLMOcrRequest dataclass, bind_request, PythonOcrInput, BridgeOcrRequest,
and the retained boundary_request, document, api_key and callback_inputs
Python objects. api_key for pre_call now comes from core's resolved
connection, matching the legacy handler, and core no longer carries
retained_fields or retains_document since the bridge stopped re-aliasing.
2026-09-16 17:50:11 +00:00
..
crates refactor(python-bridge): bind OCR arguments once in Rust 2026-09-16 17:50:11 +00:00
.gitignore feat: add LiteLLM Rust workspace with Mistral OCR bridge (#31033) 2026-06-23 13:16:47 -07:00
AGENTS.md refactor(rust): localize route errors 2026-09-16 17:50:10 +00:00
Cargo.lock cleanup dead code 2026-09-16 17:50:11 +00:00
Cargo.toml more porting alignment 2026-09-16 17:50:10 +00:00