Semantic role extraction in law texts: a comparative analysis of language models for legal information extraction

  • Roos M. Bakker*
  • , Akke J. Schoevers
  • , Romy A.N. van Drie
  • , Marijn P. Schraagen
  • , Maaike H.T. de Boer
  • *Corresponding author for this work

Research output: Contribution to journalArticleAcademicpeer-review

Abstract

Norms are essential in our society: they dictate how individuals should behave and interact within a community. They can be written down in laws or other written sources. Interpretations often differ; this is where formalisations offer a solution. They express an interpretation of a source of norms in a transparent manner. However, creating these interpretations is labour intensive. Natural language processing techniques can support this process. Previous work showed the potential of transformer-based models for Dutch law texts. In this paper, we (1) introduce a dataset of 2335 English sentences annotated with legal semantic roles conform the Flint framework; (2) fine-tune a collection of language models on this dataset, and (3) query two non-fine-tuned generative large language models (LLMs). This allows us to compare performance of fine-tuned domain-specific, task-specific, and general language models with non-fine-tuned generative LLMs. The results show that models fine-tuned on our dataset have the best performance (accuracy around 0.88). Furthermore, domain-specific models perform better than general models, indicating that domain knowledge is of added value for this task. Finally, different methods of querying LLMs perform unsatisfactorily, with maximum accuracy scores around 0.6. This indicates that for specific tasks, such as this adaptation of semantic role labelling, the process of annotating data and fine-tuning a smaller language model is preferred over querying a generative LLM, especially when domain-specific models are available.

Original languageEnglish
Article number105864
JournalArtificial Intelligence and Law
DOIs
Publication statusE-pub ahead of print - 24 Mar 2025

Bibliographical note

Publisher Copyright:
© The Author(s) 2025.

Funding

The authors would like to thank the Dutch Ministry of the Interior and Kingdom Relations for the financial support of this research. Furthermore, we extend our sincere gratitude to the norm engineering team for their feedback and work on the annotation tool. Finally, we express our gratitude to all annotators of the datasets.

Funders
Ministerie van Binnenlandse Zaken en Koninkrijksrelaties
Dutch Ministry of the Interior and Kingdom Relations

    Keywords

    • Large language models
    • Legal information extraction
    • Legal semantic roles
    • Legislation
    • Semantic role labelling

    Fingerprint

    Dive into the research topics of 'Semantic role extraction in law texts: a comparative analysis of language models for legal information extraction'. Together they form a unique fingerprint.

    Cite this