Update static/script.js
Browse files- static/script.js +19 -17
static/script.js
CHANGED
@@ -159,23 +159,25 @@ chatForm.addEventListener("submit", async (e) => {
|
|
159 |
configPanel.classList.remove("expanded");
|
160 |
configPanel.classList.add("minimal");
|
161 |
|
162 |
-
|
163 |
-
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
|
168 |
-
|
169 |
-
|
170 |
-
|
171 |
-
|
172 |
-
|
173 |
-
|
174 |
-
|
175 |
-
|
176 |
-
|
177 |
-
|
178 |
-
}
|
|
|
|
|
179 |
|
180 |
try {
|
181 |
const response = await fetch("/chat", {
|
|
|
159 |
configPanel.classList.remove("expanded");
|
160 |
configPanel.classList.add("minimal");
|
161 |
|
162 |
+
const selections = {
|
163 |
+
"LLM-A": document.getElementById("modelA").dataset.value || "deepseek/deepseek-chat-v3-0324:free",
|
164 |
+
"LLM-B": document.getElementById("modelB").dataset.value || "google/gemini-2.0-flash-exp:free",
|
165 |
+
"LLM-C": document.getElementById("modelC").dataset.value || "meta-llama/llama-4-maverick:free",
|
166 |
+
"LLM-D": document.getElementById("aggregator").dataset.value || "google/gemini-2.5-pro-exp-03-25:free"
|
167 |
+
};
|
168 |
+
|
169 |
+
// Start loaders for LLM-A, LLM-B, LLM-C
|
170 |
+
["A", "B", "C"].forEach(id => showLoader(id));
|
171 |
+
|
172 |
+
// Prepare settings object normally
|
173 |
+
const settings = {
|
174 |
+
models: {
|
175 |
+
"LLM-A": selections["LLM-A"],
|
176 |
+
"LLM-B": selections["LLM-B"],
|
177 |
+
"LLM-C": selections["LLM-C"]
|
178 |
+
},
|
179 |
+
aggregator: selections["LLM-D"]
|
180 |
+
};
|
181 |
|
182 |
try {
|
183 |
const response = await fetch("/chat", {
|