fix(anthropic.py): revert client to requests library

This commit is contained in:
Krrish Dholakia 2024-07-18 22:45:41 -07:00
parent 4bde501ee1
commit c56456be64

View file

@ -895,7 +895,7 @@ class AnthropicChatCompletion(BaseLLM):
): # if function call - fake the streaming (need complete blocks for output parsing in openai format) ): # if function call - fake the streaming (need complete blocks for output parsing in openai format)
print_verbose("makes anthropic streaming POST request") print_verbose("makes anthropic streaming POST request")
data["stream"] = stream data["stream"] = stream
response = client.post( response = requests.post(
api_base, api_base,
headers=headers, headers=headers,
data=json.dumps(data), data=json.dumps(data),