A cross-encoder that scores how well an article of Kazakhstan legislation answers a question. It is cross-encoder/mmarco-mMiniLMv2-L12-H384-v1 fine-tuned on question–article pairs, and it is the reranker of pipeline 1.0.0 of Adilet Search.
from sentence_transformers import CrossEncoder
model = CrossEncoder("qb2k/adilet-reranker-mminilm-ru-kk", max_length=256)
scores = model.predict([("работодатель задерживает зарплату", "Статья 113. Порядок и сроки выплаты заработной платы ...")])
ml/notebooks/A4_embeddings_to_finetuning.ipynb in the repository (configuration E3b).Reranking 20 BM25 candidates for 195 test questions (41% Kazakh); the ceiling is 0.923.
| Model | nDCG@10 | MRR@10 | ROC-AUC | F1 |
|---|---|---|---|---|
| Base model, zero-shot | 0.867 | 0.849 | 0.959 | 0.598 |
| This model | 0.880 | 0.866 | 0.973 | 0.652 |
The difference in nDCG@10 is +0.013 (95% bootstrap interval +0.003 to +0.025, p = 0.016). nDCG@10 by language: 0.83 Kazakh, 0.91 Russian.