Unilaw-R1: A Large Language Model for Legal Reasoning with Reinforcement Learning and Iterative Inference

Hua Cai, Shuang Zhao, Liang Zhang, Xuli Shen, Qing Xu +3 more
10/11/2025
cs.CL

No official code found. Best implementation: Hanscal/Unilaw-R1 (7 stars, last commit 2025-10-14). 1 more below.

Abstract

Reasoning-focused large language models (LLMs) are rapidly evolving across various domains, yet their capabilities in handling complex legal problems remains underexplored. In this paper, we introduce Unilaw-R1, a large language model tailored for legal reasoning. With a lightweight 7-billion parameter scale, Unilaw-R1 significantly reduces deployment cost while effectively tackling three core challenges in the legal domain: insufficient legal knowledge, unreliable reasoning logic, and weak business generalization. To address these issues, we first construct Unilaw-R1-Data, a high-quality dataset containing 17K distilled and screened chain-of-thought (CoT) samples. Based on this, we adopt a two-stage training strategy combining Supervised Fine-Tuning (SFT) and Reinforcement Learning (RL), which significantly boosts the performance on complex legal reasoning tasks and supports interpretable decision-making in legal AI applications. To assess legal reasoning ability, we also introduce Unilaw-R1-Eval, a dedicated benchmark designed to evaluate models across single- and multi-choice legal tasks. Unilaw-R1 demonstrates strong results on authoritative benchmarks, outperforming all models of similar scale and achieving performance on par with the much larger DeepSeek-R1-Distill-Qwen-32B (54.9%). Following domain-specific training, it also showed significant gains on LawBench and LexEval, exceeding Qwen-2.5-7B-Instruct (46.6%) by an average margin of 6.6%.

View on arXivView PDF

Code Implementations(2)

Hanscal/Unilaw-R1Community71%

The official implementation for the paper Unilaw-R1: A Large Language Model for Legal Reasoning with Reinforcement Learning and Iterative Inference, in EMNLP2025.

70Aug 25, 20251 years ago
OElesin/Leg-R1Community71%

A Large Language Model for Legal Reasoning (German) through Reinforcement Learning

00Roff, ShellApr 12, 20258 months ago

Similar Papers

Cite this paper

@article{cai2025unilawr,
  title  = {Unilaw-R1: A Large Language Model for Legal Reasoning with Reinforcement Learning and Iterative Inference},
  author = {Hua Cai and Shuang Zhao and Liang Zhang and Xuli Shen and Qing Xu and Weilin Shen and Zihao Wen and Tianke Ban},
  year   = {2025},
  eprint = {2510.10072},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2510.10072v2}
}

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/2510.10072.svg)](https://codeofpaper.com/paper/2510.10072)

Discussion