Skip to main content Skip to main navigation menu Skip to site footer

Chain of Prompts and Memories for Accessible Symbolic Applications in the Legal Domain

Abstract

This article introduces a novel hybrid approach that enhances the accessibility and explainability of symbolic legal systems by integrating them with large language models (LLMs). While symbolic systems provide transparency and justifiability, they suffer from communicability issues and limitations in knowledge representation. Conversely, LLMs offer natural language fluency but struggle with reliability and justifiability in legal reasoning. The article bridges this gap by structuring legal tasks into a modular, interconnected sequence of prompts, supported by contextually relevant memory retrieval, thus creating a chain of prompts and memories. The methodology is validated through two case studies. The first applies it to computable contracts, demonstrating its ability to map code to contractual provisions, thereby making them more accessible. The second case study involves an expert legal system, where the hybrid approach generates accessible explanations of Prolog-based legal reasoning. The findings show that the hybrid approach enhances the clarity and interpretability of legal applications while preserving justifiability, using a modular structure that allows for adaptability across different legal tasks.

Published: 2025-09-22
Issue:Online First
Section: Articles
How to Cite
Billi, Marco, Alessandro Parenti, Giuseppe Pisano, and Marco Sanchi. 2025. “Chain of Prompts and Memories for Accessible Symbolic Applications in the Legal Domain”. Law, Technology and Humans, September. https://doi.org/10.5204/lthj.4010.

Author Biographies

University of Bologna
Italy Italy

Marco Billi, Ph.D. is a research fellow affiliated with the Law Department at the University of Bologna. Marco holds a joint Ph.D. in Law, Science, and Technology from the University of Bologna and the University of Luxembourg. His work focuses on explainability in legal informatics through norms and argumentation, also exploring the relationship between Large Language Models and expert systems for the legal domain.

University of Bologna
Italy Italy

Alessandro Parenti is a third-year PhD student in the Law, Science and Technology program at the University of Bologna, where he collaborates with the CIRSFID research centre and the Chair of IT Law.

His research focuses on computational law, smart contracts, and artificial intelligence, with particular attention to the modelling of legal provisions in computational form.

University of Bologna
Italy Italy

Giuseppe Pisano, Ph.D. is a research fellow affiliated with the Alma Mater Research Institute for Human-Centered Artificial Intelligence (CIRSFID - Alma AI) at the University of Bologna. Giuseppe holds a joint Ph.D. in Law, Science and Technology from the University of Bologna and the University of Luxembourg. His research focuses on the application of computational logic and argumentation theory to legal reasoning.

University of Bologna
Italy Italy

Marco Sanchi is a Ph.D candidate affiliated with the Italian National Ph.D. in Artificial Intelligence & Society (University of Pisa), and the CIRSFID - Alma AI Research Center (University of Bologna). Marco additionally works as a Research Assistant with the European University Institute (EUI) in the context of the H.U.C.A.N project. Marco held the role of visiting PhD candidate at the Law and Tech Lab (LTL) of Maastricht University, Faculty of Law. Marco researches the legal, social and ethical implications of Explainable AI in the context of Autonomous Vehicles.

Open Access Journal
ISSN 2652-4074