Update index.html
Browse files- index.html +2 -2
index.html
CHANGED
|
@@ -291,14 +291,14 @@
|
|
| 291 |
.value.trim();
|
| 292 |
const labelTexts = labelInput
|
| 293 |
.split("\n")
|
| 294 |
-
.map((s) =>
|
| 295 |
.filter((s) => s);
|
| 296 |
|
| 297 |
let labelEmbeddings = [];
|
| 298 |
if (labelTexts.length) {
|
| 299 |
statusEl.textContent = "Embedding labels...";
|
| 300 |
const lblOut = await embed(
|
| 301 |
-
labelTexts.map((x) => `
|
| 302 |
{ pooling: "mean", normalize: true },
|
| 303 |
);
|
| 304 |
labelEmbeddings = lblOut.tolist();
|
|
|
|
| 291 |
.value.trim();
|
| 292 |
const labelTexts = labelInput
|
| 293 |
.split("\n")
|
| 294 |
+
.map((s) => s.trim())
|
| 295 |
.filter((s) => s);
|
| 296 |
|
| 297 |
let labelEmbeddings = [];
|
| 298 |
if (labelTexts.length) {
|
| 299 |
statusEl.textContent = "Embedding labels...";
|
| 300 |
const lblOut = await embed(
|
| 301 |
+
labelTexts.map((x) => `Represent this sentence for searching relevant passages: ${x}`),
|
| 302 |
{ pooling: "mean", normalize: true },
|
| 303 |
);
|
| 304 |
labelEmbeddings = lblOut.tolist();
|