mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-25 22:20:43 +00:00
* fix(responses): replay phase on the azure route and tag streamed text deltas with phase * test(integration): expect phase and replay on azure responses bridge chat cases * test(responses): expect phase and the replay record in the Azure translation cases Azure now joins the replay path, so its bridged tool turns carry phase and openai_responses_replay. Follow-up requests replay the previous turn without its record, and the streamed_phases docstring names the event that sets it * fix(responses): label each cached stream chunk with its own message's phase A cache hit replayed as a stream put the whole message's phase on the first text chunk and none on the rest. The replay now splits the cached content by the replay record's message lengths, so each chunk carries its message's phase like a fresh stream. The undefined-phase tests also run on Azure now. * fix(responses): carry each stream chunk's phase at chunk level so the OpenAI SDK keeps one phase The OpenAI SDK's client.chat.completions.stream() joins every string in a delta, so a phase on every text delta assembled as "commentarycommentary..." and LiteLLM rejected the next turn. The phase now goes in the chunk's own provider_specific_fields on live and cached streams, and the final chunk's delta carries the turn's phase and replay record once, as on main * fix(responses): build the replay chunk's empty default with a factory so the module imports on Python 3.11 --------- Co-authored-by: mateo-berri <277851410+mateo-berri@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| litellm_responses_transformation | ||
| __init__.py | ||
| test_litellm_responses_transformation_transformation.py | ||
| test_responses_bridge_provider_propagation.py | ||