Skip to content

Commit

Permalink
[0.4.15] [chore] yields error from API instead of returning
Browse files Browse the repository at this point in the history
  • Loading branch information
yashbonde committed Aug 5, 2024
1 parent 9795eee commit 008d0fa
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
project = "tuneapi"
copyright = "2024, Frello Technologies"
author = "Frello Technologies"
release = "0.4.14"
release = "0.4.15"

# -- General configuration ---------------------------------------------------
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "tuneapi"
version = "0.4.14"
version = "0.4.15"
description = "Tune AI APIs."
authors = ["Frello Technology Private Limited <[email protected]>"]
license = "MIT"
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# Copyright © 2023- Frello Technology Private Limited

__version__ = "0.4.14"
__version__ = "0.4.15"
2 changes: 1 addition & 1 deletion tuneapi/apis/model_anthropic.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def stream_chat(
try:
r.raise_for_status()
except Exception as e:
print(r.text)
yield r.text
raise e

fn_call = None
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/apis/model_gemini.py
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ def stream_chat(
try:
response.raise_for_status()
except Exception as e:
print(response.text)
yield response.text
raise e

block_lines = ""
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/apis/model_groq.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ def stream_chat(
try:
response.raise_for_status()
except Exception as e:
print(response.text)
yield response.text
raise e

fn_call = None
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/apis/model_mistral.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ def stream_chat(
try:
response.raise_for_status()
except Exception as e:
print(response.text)
yield response.text
raise e

fn_call = None
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/apis/model_openai.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def stream_chat(
try:
response.raise_for_status()
except Exception as e:
print(response.text)
yield response.text
raise e

fn_call = None
Expand Down
2 changes: 1 addition & 1 deletion tuneapi/apis/model_tune.py
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ def stream_chat(
try:
response.raise_for_status()
except Exception as e:
print(response.text)
yield response.text
raise e

fn_call = None
Expand Down

0 comments on commit 008d0fa

Please sign in to comment.