Update app.py
Browse files
app.py
CHANGED
|
@@ -330,7 +330,7 @@ async def chat_completions(request: Request):
|
|
| 330 |
|
| 331 |
# 获取headers
|
| 332 |
headers = {
|
| 333 |
-
"Authorization": f"Bearer {
|
| 334 |
"Content-Type": "application/json",
|
| 335 |
"Accept": "text/event-stream" if body_json.get("stream") else "application/json"
|
| 336 |
}
|
|
|
|
| 330 |
|
| 331 |
# 获取headers
|
| 332 |
headers = {
|
| 333 |
+
"Authorization": f"Bearer {next(key_cycle)}", # 使用 key_cycle 而不是 get_next_key
|
| 334 |
"Content-Type": "application/json",
|
| 335 |
"Accept": "text/event-stream" if body_json.get("stream") else "application/json"
|
| 336 |
}
|