Fix passthrough streaming, send headers properly not part of body :facepalm

This commit is contained in:
Ashwin Bharambe 2024-08-06 16:39:38 -07:00
parent 039861f1c7
commit a0e61a3c7a
2 changed files with 36 additions and 45 deletions

View file

@ -50,6 +50,7 @@ class InferenceClient(Inference):
headers={"Content-Type": "application/json"},
timeout=20,
) as response:
print("Headers", response.headers)
if response.status_code != 200:
content = await response.aread()
cprint(