diff --git a/dist/litellm-1.12.6.dev1-py3-none-any.whl b/dist/litellm-1.12.6.dev1-py3-none-any.whl new file mode 100644 index 00000000000..95ba50b4f65 Binary files /dev/null and b/dist/litellm-1.12.6.dev1-py3-none-any.whl differ diff --git a/dist/litellm-1.12.6.dev1.tar.gz b/dist/litellm-1.12.6.dev1.tar.gz new file mode 100644 index 00000000000..c18e6d1ce49 Binary files /dev/null and b/dist/litellm-1.12.6.dev1.tar.gz differ diff --git a/litellm/main.py b/litellm/main.py index cfd28563034..e12b6418790 100644 --- a/litellm/main.py +++ b/litellm/main.py @@ -190,6 +190,7 @@ async def acompletion(*args, **kwargs): # Call the synchronous function using run_in_executor response = await loop.run_in_executor(None, func_with_context) if kwargs.get("stream", False): # return an async generator + print_verbose(f"ENTERS STREAMING FOR ACOMPLETION") return _async_streaming(response=response, model=model, custom_llm_provider=custom_llm_provider, args=args) else: return response @@ -202,6 +203,7 @@ async def acompletion(*args, **kwargs): async def _async_streaming(response, model, custom_llm_provider, args): try: async for line in response: + print_verbose(f"line in async streaming: {line}") yield line except Exception as e: raise exception_type( @@ -1217,6 +1219,7 @@ def completion( # "SageMaker is currently not supporting streaming responses." # fake streaming for sagemaker + print_verbose(f"ENTERS SAGEMAKER CUSTOMSTREAMWRAPPER") resp_string = model_response["choices"][0]["message"]["content"] response = CustomStreamWrapper( resp_string, model, custom_llm_provider="sagemaker", logging_obj=logging diff --git a/litellm/utils.py b/litellm/utils.py index 4c78a46304e..ccb0450e6d0 100644 --- a/litellm/utils.py +++ b/litellm/utils.py @@ -5685,6 +5685,7 @@ class CustomStreamWrapper: else: chunk = next(self.completion_stream) if chunk is not None and chunk != b'': + print_verbose(f"PROCESSED CHUNK PRE CHUNK CREATOR: {chunk}") response = self.chunk_creator(chunk=chunk) if response is None: continue