Large language model and its application in the questioning-answering system of minerals
Xiaohui Ji, Chengjian Liu, Mei Yang, Mingyue He, Zhaochong Zhang, Shan ZENG, Yuzhu Wang · Bulletin of Mineralogy Petrology and Geochemistry · 2025
Large Language Models (LLMs) have strong capabilities for understanding natural languages and solving complex problems. This article constructs a questioning-answering system of minerals based on the LLM in order to efficiently acquire mineral knowledge. In the system, data of minerals were firstly obtained from Internet resources, and then they were structured to mineral documents and Q&A pairs after the data cleaning. The mineral knowledge base formed through the format conversion and indexing of mineral documents is used for the retrieval-augmented generation of an large language model. The questioning-answering pairs are used for the fine-tuning of the large language model. When the mineral knowledge base retrieval is used to enhance the generation of large language model, a two-level retrieval mode of first recalling and then refining is adopted in order to obtain better results of the large language model generation. The mainstream Low-Rank Adaptation (LoRA) method is used to fine-tune the large language model of minerals, in order to achieve comparable performance of the full parameter fine-tuning by using relatively small numbers of training parameters and to save computational resources. The experimental results show that the questioning-answering system of minerals based on the retrieval-augmented generation of large language models can quickly and accurately obtain mineral knowledge.