diff options
Diffstat (limited to '')
-rw-r--r-- | g4f/gui/server/backend.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/g4f/gui/server/backend.py b/g4f/gui/server/backend.py index d17e21b7..9dc5dbb4 100644 --- a/g4f/gui/server/backend.py +++ b/g4f/gui/server/backend.py @@ -74,14 +74,14 @@ class Backend_Api: provider = g4f.Provider.ProviderUtils.convert.get(provider) def try_response(): - response = g4f.ChatCompletion.create( - model=model, - provider=provider, - messages=messages, - stream=True, - ignore_stream_and_auth=True - ) try: + response = g4f.ChatCompletion.create( + model=model, + provider=provider, + messages=messages, + stream=True, + ignore_stream_and_auth=True + ) yield from response except Exception as e: print(e) |