From 4d2916cfe6771349b461f35a58bdbb54111bcbc8 Mon Sep 17 00:00:00 2001 From: hanhainebula <2512674094@qq.com> Date: Sat, 19 Oct 2024 18:01:31 +0800 Subject: [PATCH] update m3 example code --- .../inference/embedder/encoder_only/m3_multi_devices.py | 8 ++++---- .../inference/embedder/encoder_only/m3_single_device.py | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/examples/inference/embedder/encoder_only/m3_multi_devices.py b/examples/inference/embedder/encoder_only/m3_multi_devices.py index e8a2303..88753d4 100644 --- a/examples/inference/embedder/encoder_only/m3_multi_devices.py +++ b/examples/inference/embedder/encoder_only/m3_multi_devices.py @@ -13,12 +13,12 @@ def test_m3_multi_devices(): ) queries = [ - "What is BGE M3?", - "Defination of BM25" + "What is the capital of France?", + "What is the population of China?", ] * 100 passages = [ - "BGE M3 is an embedding model supporting dense retrieval, lexical matching and multi-vector interaction.", - "BM25 is a bag-of-words retrieval function that ranks a set of documents based on the query terms appearing in each document" + "Paris is the capital of France.", + "The population of China is over 1.4 billion people." ] * 100 queries_embeddings = model.encode_queries( diff --git a/examples/inference/embedder/encoder_only/m3_single_device.py b/examples/inference/embedder/encoder_only/m3_single_device.py index eeb25e0..a73edaa 100644 --- a/examples/inference/embedder/encoder_only/m3_single_device.py +++ b/examples/inference/embedder/encoder_only/m3_single_device.py @@ -13,12 +13,12 @@ def test_m3_single_devices(): ) queries = [ - "What is BGE M3?", - "Defination of BM25" + "What is the capital of France?", + "What is the population of China?", ] * 100 passages = [ - "BGE M3 is an embedding model supporting dense retrieval, lexical matching and multi-vector interaction.", - "BM25 is a bag-of-words retrieval function that ranks a set of documents based on the query terms appearing in each document" + "Paris is the capital of France.", + "The population of China is over 1.4 billion people." ] * 100 queries_embeddings = model.encode_queries(