main #38

Merged
Patrick_Pluto merged 8 commits from YasinOnm08/interstellar_ai:main into main 2024-09-24 14:19:12 +02:00
Showing only changes of commit d037439b4c - Show all commits

View file

@ -113,13 +113,15 @@ const InputOutputBackend: React.FC = () => {
setMessages(previous => [...previous,{role,content}])
}
const handleSendClick = (inputValue: string) => {
if (sendable) {
sendable=false
if (postWorkerRef.current) {
addMessage("user", inputValue)
console.log("input:",inputValue);
postWorkerRef.current.postMessage({messages:[...messages, { role: "user", content: inputValue }], ai_model:"phi3.5", access_token:accessToken})
startGetWorker()
if (inputValue != "") {
if (sendable) {
sendable=false
if (postWorkerRef.current) {
addMessage("user", inputValue)
console.log("input:",inputValue);
postWorkerRef.current.postMessage({messages:[...messages, { role: "user", content: inputValue }], ai_model:"phi3.5", access_token:accessToken})
startGetWorker()
}
}
}
}