Learning an Effective Premise Retrieval Model for Efficient Mathematical Formalization
Not on the map. Why?
Abstract (arXiv)
Formalized mathematics has recently garnered significant attention for its ability to assist mathematicians across various fields. Premise retrieval, as a common step in mathematical formalization, has been a challenge, particularly for inexperienced users. Existing retrieval methods that facilitate natural language queries require a certain level of mathematical expertise from users, while approaches based on formal languages (e.g., Lean) typically struggle with the scarcity of training data, hindering the training of effective and generalizable retrieval models. In this work, we introduce a novel method that leverages data extracted from Mathlib to train a lightweight and effective premise retrieval model. In particular, the proposed model embeds queries (i.e., proof state provided by Lean) and premises in a latent space, featuring a tokenizer specifically trained on formal corpora. The model is learned in a contrastive learning framework, in which a fine-grained similarity calculation method and a re-ranking module are applied to enhance the retrieval performance. Experimental results demonstrate that our model outperforms existing baselines, achieving higher accuracy while maintaining a lower computational load. We have released an open-source search engine based on our retrieval model at https://premise-search.com/. The source code and the trained model can be found at https://github.com/ruc-ai4math/Premise-Retrieval.
Key facts. Cited by 4 papers in the map (data through 14 Oct 2026). Builds on 18 of its 29 references that are in the map. First posted on arXiv 21 Jan 2025.
Builds on
18 of 29 references.
References · 18
- 2020A Simple Framework for Contrastive Learning of Visual Representationscited by 12,049
- 2020Dense Passage Retrieval for Open-Domain Question Answeringcited by 3,824
- 2022Text Embeddings by Weakly-Supervised Contrastive Pre-trainingcited by 1,253
- 2021Unsupervised Dense Information Retrieval with Contrastive Learningcited by 1,216
- 2024M3-Embedding: Multi-Linguality, Multi-Functionality, Multi-Granularity Text Embeddings Through Self-Knowledge Distillationcited by 1,073
- 2019Passage Re-ranking with BERTcited by 645
- 2021ByT5: Towards a token-free future with pre-trained byte-to-byte modelscited by 509
- 2023LeanDojo: Theorem Proving with Retrieval-Augmented Language Modelscited by 427
- 2021MiniF2F: a cross-system benchmark for formal Olympiad-level mathematicscited by 391
- 2022UniXcoder: Unified Cross-Modal Pre-training for Code Representationcited by 361
- 2023Improving Text Embeddings with Large Language Modelscited by 303
- 2023Fine-Tuning LLaMA for Multi-Stage Text Retrievalcited by 272
6 more
- 2020Fast WordPiece Tokenizationcited by 87
- 2023Llama2Vec: Unsupervised Adaptation of Large Language Models for Dense Retrievalcited by 78
- 2023Magnushammer: A Transformer-Based Approach to Premise Selectioncited by 50
- 2019Understanding the Behaviors of BERT in Rankingcited by 49
- 2023LLMSTEP: LLM proofstep suggestions in Leancited by 32
- 2024A Semantic Search Engine for Mathlib4cited by 31
Built on by
Citing papers per year: 2025: 3; 2026: 1.
4 papers.
- 2025LeanExplore: A search engine for Lean 4 declarationscited by 18
- 2026LeanSearch v2: Global Premise Retrieval for Lean 4 Theorem Provingcited by 10
- 2025Lean Finder: Semantic Search for Mathlib That Understands User Intentscited by 8
- 2025Automated Formalization via Conceptual Retrieval-Augmented LLMscited by 5
- 2026LeanSearch v2: Global Premise Retrieval for Lean 4 Theorem Proving13 May 2026
- 2025Lean Finder: Semantic Search for Mathlib That Understands User Intents8 Oct 2025
- 2025Automated Formalization via Conceptual Retrieval-Augmented LLMs9 Aug 2025
- 2025LeanExplore: A search engine for Lean 4 declarations4 Jun 2025