Adaptive Two-Phase Finetuning LLMs for Japanese Legal Text Retrieval

Quang Hoang Trung, Nguyen Van Hoang Phuc, Le Trung Hoang, Quang Huu Hieu, Vo Nguyen Le Duy
12/3/2024
cs.IRcs.CLcs.LG

No official code found. Best implementation: gptvj/ATFLLM (1 star, Apache-2.0, last commit 2026-03-27).

Abstract

Text Retrieval (TR) involves finding and retrieving text-based content relevant to a user's query from a large repository, with applications in real-world scenarios such as legal document retrieval. While most existing studies focus on English, limited work addresses Japanese contexts. In this paper, we introduce a new dataset specifically designed for Japanese legal contexts and propose a novel two-phase pipeline tailored to this domain. In the first phase, the model learns a broad understanding of global contexts, enhancing its generalization and adaptability to diverse queries. In the second phase, the model is fine-tuned to address complex queries specific to legal scenarios. Extensive experiments are conducted to demonstrate the superior performance of our method, which outperforms existing baselines. Furthermore, our pipeline proves effective in English contexts, surpassing comparable baselines on the MS MARCO dataset. We have made our code publicly available on GitHub, and the model checkpoints are accessible via HuggingFace.

View on arXivView PDF

Code Implementations(1)

gptvj/ATFLLMCommunity60%
Apache-2.0

Adaptive Two-Phase Finetuning LLMs for Japanese Legal Text Retrieval

13Shell, PythonNov 25, 20246 months agoApache-2.0

Cite this paper

@article{trung2024adaptive,
  title  = {Adaptive Two-Phase Finetuning LLMs for Japanese Legal Text Retrieval},
  author = {Quang Hoang Trung and Nguyen Van Hoang Phuc and Le Trung Hoang and Quang Huu Hieu and Vo Nguyen Le Duy},
  year   = {2024},
  eprint = {2412.13205},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2412.13205v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2412.13205.svg)](https://codeofpaper.com/paper/2412.13205)

Discussion