MultiLegalSBD: A Multilingual Legal Sentence Boundary Detection Dataset

Tobias Brugger, Matthias Stürmer, Joel Niklaus

Abstract

Sentence Boundary Detection (SBD) is a fundamental preprocessing step in Natural Language Processing (NLP) pipelines. While often considered a solved problem in general domains, SBD remains a significant challenge in the legal sector due to complex citation formats, non-standard document structures, and domain-specific abbreviations. This paper introduces MultiLegalSBD, a comprehensive multilingual dataset comprising over 130,000 annotated legal sentences across six languages (English, German, French, Italian, Spanish, and Portuguese). We evaluate several architectures, including Conditional Random Fields (CRF), BiLSTM-CRF, and Transformers (DistilBERT), demonstrating that custom-trained models can achieve F1-scores up to 99.6%, significantly outperforming general-purpose baselines and showing robust zero-shot cross-lingual transfer capabilities.

Introduction

Most NLP tasks—such as Named Entity Recognition (NER), summarization, and machine translation—rely on the accurate identification of sentence boundaries. In the legal domain, however, standard SBD tools frequently fail. Legal texts are characterized by dense citations (e.g., "art. 8a. 1er paragraphe"), nested lists, and headlines that lack traditional terminal punctuation. When these boundaries are misidentified, the resulting "error propagation" can degrade the performance of all downstream analytical tasks.

Despite the critical nature of this problem, there has been a notable lack of high-quality, multilingual gold-standard data for legal SBD. MultiLegalSBD addresses this gap by providing a standardized, large-scale dataset to train and evaluate domain-specific models.

The MultiLegalSBD Dataset

The authors curated a dataset of 133,568 sentences and 3.6 million tokens across 906 documents. The dataset is categorized into two primary types of legal text:

  1. Judgments: Court decisions which often feature diverse linguistic structures and narrative styles.
  2. Laws: Statutes and constitutions which tend to be more formulaic and repetitive.

The dataset includes new annotations for French, Italian, and Spanish, a small Portuguese set for zero-shot testing, and integrated existing data for English and German. This diversity allows for a robust analysis of how SBD models perform across different legal systems and languages.

Methodology

The authors framed SBD as a sequence labeling task using the BILOU (Beginning, Inside, Last, Outside, Unit) tagging scheme. Three distinct architectures were evaluated:

  • Conditional Random Fields (CRF): A statistical model utilizing hand-crafted features such as token capitalization, digit presence, and local context windows.
  • BiLSTM-CRF: A neural approach combining the long-range dependency capabilities of Bidirectional LSTMs with a CRF layer for sequence-level optimization.
  • Transformers (DistilBERT): A lightweight, multilingual pre-trained model. To handle the 512-token limit of the Transformer architecture, documents were processed in overlapping chunks during inference.

Performance was measured across three scenarios: monolingual (same language training/testing), multilingual (training on multiple languages), and zero-shot (testing on a language not seen during training).

Key Results and Discussion

Overcoming the "Solved" Problem Myth

The study revealed that popular general-purpose libraries like spaCy and NLTK performed poorly on legal text, with F1-scores sometimes dropping as low as 60-70%. In contrast, the domain-specific models developed in this research consistently achieved F1-scores between 95% and 99.6%.

Generalization and Cross-Lingual Transfer

A significant finding was that models trained on Judgments generalized better to Laws than vice versa. This suggests that the structural complexity of court decisions provides a richer training signal for SBD. Furthermore, the Transformer model demonstrated exceptional cross-lingual synergy. A model trained on other languages achieved a 93.6% F1-score on Portuguese judgments without ever seeing a Portuguese word during training, highlighting the shared "structural logic" of legal documents across different languages.

Computational Efficiency

While the Transformer model provided the most robust performance, the authors noted a trade-off in inference speed. CRFs remain the most efficient choice for CPU-only environments (~5.37ms per sentence), whereas Transformers are highly optimized for GPU environments (~4.18ms per sentence).

Conclusion and Future Work

MultiLegalSBD demonstrates that while legal SBD is a difficult task for general tools, it can be effectively mastered by domain-specific models. Future research may expand the dataset to include non-Germanic and non-Italic languages (e.g., Hungarian or Chinese) and explore "Longformer" architectures to better handle extremely long legal sentences. Additionally, moving beyond binary boundary detection to identify specific boundary types (e.g., citations vs. headlines) could further refine the utility of these models for legal professionals.

Summary updated

BibTeX
@inproceedings{brugger2023multilegalsbd,
  author = {Tobias Brugger and Matthias Stürmer and Joel Niklaus},
  title = {{MultiLegalSBD: A Multilingual Legal Sentence Boundary Detection Dataset}},
  booktitle = {ICAIL},
  year = {2023},
  url = {https://openreview.net/forum?id=1bHPZ093Ia},
}
Figure