Spaces:
Build error
Build error
Upload app.py
Browse files
app.py
CHANGED
@@ -669,11 +669,8 @@ class Reader:
|
|
669 |
@tenacity.retry(wait=tenacity.wait_exponential(multiplier=1, min=4, max=10),
|
670 |
stop=tenacity.stop_after_attempt(5),
|
671 |
reraise=True)
|
672 |
-
def chat_review(self, text):
|
673 |
-
openai.api_key =
|
674 |
-
self.cur_api += 1
|
675 |
-
self.cur_api = 0 if self.cur_api >= len(self.chat_api_list) - 1 else self.cur_api
|
676 |
-
|
677 |
response = openai.ChatCompletion.create(
|
678 |
model="gpt-3.5-turbo",
|
679 |
messages=[
|
|
|
669 |
@tenacity.retry(wait=tenacity.wait_exponential(multiplier=1, min=4, max=10),
|
670 |
stop=tenacity.stop_after_attempt(5),
|
671 |
reraise=True)
|
672 |
+
def chat_review(self, text, key):
|
673 |
+
openai.api_key = key
|
|
|
|
|
|
|
674 |
response = openai.ChatCompletion.create(
|
675 |
model="gpt-3.5-turbo",
|
676 |
messages=[
|