﻿# LiteLLM gateway applies Messages deployment defaults with client-value precedence

Compare omitted, explicit and null Messages fields against deployment defaults, including tools and stream; the effective request can change even when client code does not.

Author: Retrivium team
Updated: 2026-11-15
Canonical URL: https://retrivium.ai/journal/week46-agent-litellm-messages-deployment-default-precedence/
Language: en

The November 15 LiteLLM v1.111.0-dev.4 prerelease applies deployment parameters such as system, thinking, tools and stream to Messages requests when the client omits them. Client values retain precedence with documented exceptions. Existing callers can therefore observe changed behavior without changing their request body, making effective configuration a required part of upgrade review.

## Omission is not an explicit value

Create a synthetic deployment with distinctive system, thinking and streaming defaults. Send matched requests that omit each field, set a value and use null where supported. Capture the resolved upstream payload. A client wrapper can serialize defaults automatically, so inspect actual bytes rather than the application’s in-memory intention. This shows which settings come from deployment policy and which remain controlled by the caller.

## Tools need ordering and identity checks

Put one harmless tool in the deployment and another in the client request. Inspect the merged declaration order and test name conflicts under the documented behavior. A count of two tools cannot establish that their schemas or ownership are correct. Keep tool execution disabled during the first payload test, then validate one controlled invocation through the application’s normal authorization boundary before accepting the new effective catalog.

## Deployment streaming can change the client path

With stream enabled in the deployment, send a request that omits stream and verify the client handles the resulting response form. Then send an explicit client value as the control. The PR calls this an intentional compatibility change. An application that always parses a single JSON response can fail despite an otherwise correct upstream request. Acceptance should include the outer HTTP response and the client parser, not only forwarded parameters.

## Capability validation remains a separate decision

The implementation also resolves model capabilities and changes rejection of unsupported parameters unless dropping is enabled. Test one valid and one unsupported synthetic configuration with the actual drop policy. Do not infer model support from a field appearing in deployment metadata. A useful upgrade record captures client input, effective defaults, capability decision and response form, explaining changed behavior without claiming that the model itself gained a new capability.

## Sources

- [LiteLLM v1.111.0-dev.4 prerelease notes](https://github.com/BerriAI/litellm/releases/tag/v1.111.0-dev.4)
- [LiteLLM implementation and review #51834](https://github.com/BerriAI/litellm/pull/51834)

## Related reading

- [LiteLLM Proxy: when to operate your own model gateway](/journal/litellm-proxy-guide/)
- [LiteLLM virtual keys: separate access for each application](/journal/litellm-virtual-key-scopes/)
