Dataset Viewer
Full Screen Viewer
Full Screen
The dataset viewer is not available because its heuristics could not detect any supported data files. You can try uploading some data files, or configuring the data files location manually.
The following data set was vectorized with the intfloat/multilingual-e5-base model and an index file created by faiss.
oshizo/japanese-wikipedia-paragraphs
Usage
First, download index_me5-base_IVF2048_PQ192.faiss from this repository.
import faiss
import datasets
from sentence_transformers import SentenceTransformer
ds = datasets.load_dataset("oshizo/japanese-wikipedia-paragraphs", split="train")
index = faiss.read_index("./index_me5-base_IVF2048_PQ192.faiss")
model = SentenceTransformer("intfloat/multilingual-e5-base")
question = "日本で二番目に高い山は?"
emb = model.encode(["query: " + question])
scores, indexes = index.search(emb, 10)
scores = scores[0]
indexes = indexes[0]
results = []
for idx, score in zip(indexes, scores):
idx = int(idx)
passage = ds[idx]
passage["score"] = score
results.append((passage))
- Downloads last month
- 39