mirror of
https://github.com/BerriAI/litellm.git
synced 2026-11-28 00:00:38 +00:00
completion() and acompletion() now read LiteLLM's control settings from kwargs
once, before the prompt management hooks run. A stream_chunk_size written as a
string of digits ("64", which is what a quoted YAML value or os.environ/...
produces) is read as that int. Anything else that is not a positive int
("sixty-four", 64.0, True, 0, -1) fails with a 400 naming the param, for every
provider and whether or not the request streams. With drop_params on, per
request or through litellm.drop_params, the bad value is dropped instead and
default chunking applies. Before, only Bedrock streams checked it, 0 was
accepted, and a Router deployment with a bad value reached the provider
control_params_from returns the typed LiteLLMControlParams or an
InvalidControlParam value, and one match in main.py turns the failure into the
400. completion() adds the validated bag to litellm_params under
CONTROL_PARAMS_KEY after get_litellm_params builds them, so a caller cannot
supply its own. control_params_in reads the bag back. The flat
stream_chunk_size key stays until Bedrock reads the bag
Refs LIT-8317
|
||
|---|---|---|
| .. | ||
| batches | ||
| chat | ||
| count_tokens | ||
| embed | ||
| files | ||
| image | ||
| image_edit | ||
| invoke_agent | ||
| messages | ||
| passthrough | ||
| realtime | ||
| rerank | ||
| responses | ||
| search | ||
| vector_stores | ||
| __init__.py | ||
| event_loop_probe.py | ||
| test_anthropic_beta_support.py | ||
| test_base_aws_llm.py | ||
| test_bedrock_common_utils.py | ||
| test_bedrock_ssl_verify.py | ||
| test_claude_platform_provider.py | ||
| test_common_utils.py | ||
| test_converse_context_management.py | ||
| test_cross_region_inference_profile_mapping.py | ||
| test_mantle.py | ||
| test_nova_imported_models.py | ||
| test_request_metadata.py | ||
| test_web_identity_session_policy.py | ||