Skip to main content
Back

Cyber Monday Deal: Get 20% off all AlphaSignal Pro subscriptions. Ends soon.

Nagoya University's Ruri v3 Beats OpenAI Embeddings on Japanese Retrieval

A 315M-parameter Japanese embedding model built on ModernBERT-Ja tops JMTEB benchmarks while handling 8K context, outperforming OpenAI and billion-parameter rivals.

Pro

  • Ruri v3 is a Japanese text embedding family built on ModernBERT-Ja, Apache 2.0 licensed.
  • The 310M flagship scores 77.24 on JMTEB, beating OpenAI text-embedding-3-large and billion-parameter rivals.
  • Context window jumps from 512 to 8192 tokens, enabling full-document embedding without chunking.
  • SentencePiece-only tokenizer removes the MeCab preprocessing dependency that plagued earlier Japanese BERTs.
  • Four sizes available (30M, 70M, 130M, 310M) spanning 256 to 768 embedding dimensions.
  • Uses a prefix scheme (query, document, topic, semantic) that you must apply for best retrieval quality.

Nagoya University’s CL Research Group has released Ruri v3, a family of Japanese sentence-embedding models built on ModernBERT-Ja. The models support inputs of up to 8,192 tokens, remove the MeCab preprocessing dependency used by many earlier Japanese encoders, and deliver strong reported results with as few as 30 million parameters.

Sentence-embedding models convert text into fixed-length vectors for semantic search, retrieval-augmented generation, clustering, classification, and duplicate detection. Ruri v3 targets Japanese workloads specifically, giving teams an Apache 2.0-licensed alternative to proprietary embedding APIs and larger open models.

An 8K-token rebuild

Ruri v3 updates the architecture and tokenizer in several practical ways:

  • Longer inputs: The maximum sequence length rises from 512 tokens in Ruri v1 and v2 to 8,192 tokens.
  • Larger vocabulary: A 100,000-token vocabulary replaces the earlier 32,000-token vocabulary, often reducing the number of tokens required for Japanese text.
  • Faster attention: ModernBERT’s FlashAttention support can accelerate inference and fine-tuning on compatible hardware and software.
  • Simpler tokenization: A SentencePiece-only tokenizer removes the need for an external Japanese morphological analyzer such as MeCab.

Removing morphological preprocessing simplifies container builds, cross-platform serving, and integration with standard sentence-transformers pipelines. The larger context window also accepts long articles, documentation pages, and conversations without truncating them at 512 tokens, although memory use and retrieval quality still depend on input length and batch size.

JMTEB favors the compact flagship

The JMTEB repository evaluates embedding models across Japanese retrieval, semantic textual similarity, classification, reranking, clustering, and pair-classification tasks. Published results give Ruri-v3-310m an average score of 77.24.

Reported Ruri-v3-310m scores by JMTEB category
Category Score
Retrieval 81.89
Semantic textual similarity 81.22
Classification 78.66
Reranking 93.43
Clustering 55.69
Pair classification 62.60

The published comparison places the flagship ahead of several larger or proprietary alternatives. The public model name rounds its size to 310M, while the comparison reports approximately 315 million parameters.

Selected reported JMTEB results
Model Parameters Average
Ruri-v3-310m 315M 77.24
PLaMo-Embedding-1B 1.05B 76.10
sarashina-embedding-v1-1b 1.22B 75.50
OpenAI text-embedding-3-large Undisclosed 73.97
multilingual-e5-large 560M 71.65

Ruri-v3-310m also reports 81.89 for retrieval, compared with 74.48 for text-embedding-3-large in the same evaluation. JMTEB scores provide a controlled comparison, while production results will also depend on corpus structure, chunking, query distribution, and indexing settings.

One family, four budgets

Four checkpoint sizes let developers trade embedding quality, vector width, memory use, and latency:

Ruri v3 model sizes
Model Parameters Dimensions JMTEB average
ruri-v3-30m 30M 256 74.51
ruri-v3-70m 70M 384 75.48
ruri-v3-130m 130M 512 76.55
ruri-v3-310m 315M 768 77.24

Smaller checkpoints reduce model memory and vector-storage requirements, which can matter for CPU serving, edge deployment, and high-throughput APIs. Hardware-specific benchmarks remain necessary because parameter count alone does not determine latency.

Prefixes are part of the model

Ruri v3 works through sentence-transformers and uses task-specific prefixes learned during training. Retrieval systems should encode queries and indexed documents with their respective prefixes.

Ruri v3 prefix scheme
Use Prefix
General semantic similarity Empty string
Classification or clustering トピック:
Retrieval query 検索クエリ:
Retrieval document 検索文書:
python -m pip install -U sentence-transformers
from sentence_transformers import SentenceTransformer

model = SentenceTransformer("cl-nagoya/ruri-v3-310m")

queries = ["瑠璃色はどんな色?"]
documents = ["瑠璃色は、紫みを帯びた濃い青。"]

query_vectors = model.encode(
    [f"検索クエリ: {text}" for text in queries],
    normalize_embeddings=True,
)

document_vectors = model.encode(
    [f"検索文書: {text}" for text in documents],
    normalize_embeddings=True,
)

scores = query_vectors @ document_vectors.T
print(scores[0, 0])

Normalizing the vectors makes the matrix product equivalent to cosine similarity. Omitting or mixing the retrieval prefixes changes the input format the model saw during training and can reduce ranking quality.

Where Ruri v3 fits

Japanese documentation search, e-commerce retrieval, support-ticket clustering, article deduplication, and Japanese RAG are direct matches for the model’s training scope. The 8,192-token limit can accommodate long inputs, while passage-level chunking may still produce more precise retrieval by keeping each vector focused on a smaller topic.

Ruri v3’s published scope is Japanese rather than cross-lingual alignment. Applications that mix Japanese, English, and other languages in the same retrieval space should also evaluate multilingual models such as multilingual-e5 or BGE-M3.

Apache 2.0, with standard obligations

The checkpoints are released under Apache 2.0, which permits commercial use, modification, and redistribution subject to the license’s notice and attribution requirements. The Ruri paper describes the project’s training approach, while the full model collection provides every Ruri v3 size and its configuration.