RELexED: Retrieval-Enhanced Legal Summarization with Exemplar Diversity

T. Y. S. S. Santosh, Chen Jia, Patrick Goroncy, Matthias Grabmair · DOI

Abstract

Legal summarization presents a unique challenge for natural language processing due to the dense structure, specialized terminology, and formal register of court rulings. Standard models often struggle with content deviation—focusing on peripheral facts rather than core legal reasoning—and fail to maintain the stylistic rigor required for official legal documents. This paper introduces RELexED (Retrieval-Enhanced Legal Summarization with Exemplar Diversity), a framework designed to improve summarization quality by providing models with diverse, high-quality "exemplar" cases. By utilizing a two-stage selection process involving Determinantal Point Processes (DPP) and Influence Functions, RELexED ensures that retrieved examples are both relevant and non-redundant. Experimental results on the SuperSCOTUS and CivilSum datasets demonstrate that RELexED significantly outperforms baseline models in coherence, fluency, and factual faithfulness.

Introduction

Summarizing a 50-page court ruling is more than a task of compression; it is an exercise in maintaining factual precision while adhering to strict stylistic templates. In the legal domain, the "ratio decidendi" (the reason for the decision) must be preserved within a specific formal register. Current Large Language Models (LLMs) often produce summaries that are either too casual or lose the central legal themes.

While retrieval-augmented generation (RAG) has been used to provide models with context, traditional methods typically retrieve the most similar examples based on simple lexical or semantic overlap. This often leads to a set of redundant exemplars that occupy the model's limited context window without providing a broad enough stylistic or thematic range. RELexED addresses this by prioritizing exemplar diversity, ensuring the model sees a variety of ways to handle complex legal narratives.

Methodology

The RELexED Framework

RELexED employs a two-stage exemplar selection strategy to optimize the prompt provided to an encoder-decoder model (specifically, a Longformer).

  1. Stage 1: Semantic Filtering: The system first uses BM25, a lexical search algorithm, to retrieve a broad pool of candidate cases from the training corpus that are semantically related to the query case.
  2. Stage 2: Diversity-Aware Selection: From this pool, the system selects a small subset of exemplars. Rather than selecting the top-N most similar cases, RELexED utilizes a Determinantal Point Process (DPP) to balance relevance with diversity.

Influence Functions and TracIn

To determine the utility of an exemplar, the researchers move beyond keyword matching and utilize Influence Functions (TracIn). This method calculates the "influence" of a training example by observing the gradients of the model. It essentially asks: "How much would training on this specific example improve the model's ability to predict the summary for the current query?" This provides a more nuanced notion of similarity that captures underlying reasoning patterns rather than just surface-level vocabulary.

Balancing Relevance and Diversity

The DPP uses these influence scores to construct a set of exemplars where each example is highly relevant to the query, yet distinct from the other examples in the set. This prevents the model from being overwhelmed by redundant information and allows it to see different facets of legal writing—such as how to handle procedural history versus substantive law.

Experimental Setup

The framework was evaluated on two primary legal benchmarks:

  • SuperSCOTUS: A dataset of U.S. Supreme Court cases where the objective is to generate the official "Syllabus" from the majority opinion.
  • CivilSum: A dataset comprising approximately 23,000 court decisions from the Supreme Court and High Courts of India, paired with human-written summaries.

Results and Discussion

RELexED demonstrated superior performance across multiple metrics compared to both no-exemplar baselines and standard similarity-based retrieval methods.

Performance Gains

On the SuperSCOTUS dataset, RELexED achieved a ROUGE-L score of 30.84, a notable improvement over the baseline (28.24) and standard BM25 retrieval (28.91). Similar consistent improvements were observed in the CivilSum dataset across ROUGE and BERTScore metrics.

The Importance of Diversity

Analysis of the results confirmed that redundancy is detrimental to model performance. RELexED consistently maintained the lowest "Inter-Exemplar" (IE) similarity, proving that the DPP successfully selected diverse examples. This diversity directly correlated with higher summary quality, particularly in terms of Coherence and Fluency. The diverse exemplars appear to act as a "stylistic anchor," helping the model maintain the formal tone and structural expectations of legal writing.

Conclusion

RELexED represents a significant step forward in legal NLP by demonstrating that how we select examples is as important as what we select. By leveraging influence functions and diversity-aware selection, the framework provides a more robust template for models to follow when navigating the complexities of legal documentation.

Future research may expand this approach to different jurisdictions and incorporate non-textual features, such as temporal data or court levels, to further refine the exemplar selection process. Additionally, moving beyond automated metrics to include expert legal evaluation remains a critical next step for validating the real-world utility of these generated summaries.

Summary updated

BibTeX
@inproceedings{santosh2025relexed,
  author = {T. Y. S. S. Santosh and Chen Jia and Patrick Goroncy and Matthias Grabmair},
  title = {{RELexED: Retrieval-Enhanced Legal Summarization with Exemplar Diversity}},
  booktitle = {Conference of the North American Chapter of the Association for Computational Linguistics},
  year = {2025},
  doi = {10.18653/v1/2025.findings-naacl.26},
}
Figure