Now handling temperature and max_tokens correctly

This commit is contained in:
k
2026-03-04 00:55:29 -05:00
parent a37d05a2de
commit 8e576ae332

4
bot.py
View File

@@ -164,8 +164,10 @@ def completions():
messageArray = data.get("messages", [])
stream = data.get("stream", False)
model = data.get("model", "RatChat")
temp = data.get("temperature", 0.7)
maxGen = data.get("max_tokens", 50)
chat = messageArray[-1]["content"] if messageArray else ""
msgobj = messageOBJ(chat)
msgobj = messageOBJ(chat,maxGen,temp)
msg_q.put(msgobj)
if stream: