Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,13 +1,15 @@
|
|
1 |
import argparse
|
2 |
import logging
|
3 |
-
|
4 |
import datasets
|
5 |
import gradio as gr
|
6 |
|
7 |
logging.disable(logging.CRITICAL)
|
8 |
|
9 |
-
|
10 |
-
model =
|
|
|
|
|
11 |
|
12 |
dataset = datasets.load_dataset("json", data_files=["./data/dataset.json"], split="train")
|
13 |
dataset.load_faiss_index("embeddings", "index.faiss")
|
|
|
1 |
import argparse
|
2 |
import logging
|
3 |
+
import sentence_transformers
|
4 |
import datasets
|
5 |
import gradio as gr
|
6 |
|
7 |
logging.disable(logging.CRITICAL)
|
8 |
|
9 |
+
|
10 |
+
model = sentence_transformers.SentenceTransformer(
|
11 |
+
"dangvantuan/sentence-camembert-large", device="cpu")
|
12 |
+
|
13 |
|
14 |
dataset = datasets.load_dataset("json", data_files=["./data/dataset.json"], split="train")
|
15 |
dataset.load_faiss_index("embeddings", "index.faiss")
|