Update app.py
Browse files
app.py
CHANGED
@@ -70,7 +70,7 @@ def ask_groq_llm(req: ChatRequest):
|
|
70 |
resp = requests.post("https://api.groq.com/openai/v1/chat/completions", verify=False, headers={"Content-Type": "application/json", "Authorization": f"Bearer {key}"}, data=json.dumps({"model": models[0], "messages": messages}))
|
71 |
if resp.status_code == 200:
|
72 |
respJson = resp.json()
|
73 |
-
print("Asked to",
|
74 |
return {"error": False, "content": respJson["choices"]}
|
75 |
print(resp.status_code, resp.text)
|
76 |
looping = False
|
|
|
70 |
resp = requests.post("https://api.groq.com/openai/v1/chat/completions", verify=False, headers={"Content-Type": "application/json", "Authorization": f"Bearer {key}"}, data=json.dumps({"model": models[0], "messages": messages}))
|
71 |
if resp.status_code == 200:
|
72 |
respJson = resp.json()
|
73 |
+
print("Asked to", models[0], "with the key ID", str(api_keys.index(key)+1), ":", messages)
|
74 |
return {"error": False, "content": respJson["choices"]}
|
75 |
print(resp.status_code, resp.text)
|
76 |
looping = False
|