mlsanityData to 14 Oct 2026

PYTHEN: A Flexible Framework for Legal Reasoning in Python

arXiv 2603.15317 ↗First posted 16 Mar 2026cs.CLcited by 1

Not on the map. Why?

Abstract (arXiv)

This paper introduces PYTHEN, a novel Python-based framework for defeasible legal reasoning. PYTHEN is designed to model the inherently defeasible nature of legal argumentation, providing a flexible and intuitive syntax for representing legal rules, conditions, and exceptions. Inspired by PROLEG (PROlog-based LEGal reasoning support system) and guided by the philosophy of The Zen of Python, PYTHEN leverages Python's built-in any() and all() functions to offer enhanced flexibility by natively supporting both conjunctive (ALL) and disjunctive (ANY) conditions within a single rule, as well as a more expressive exception-handling mechanism. This paper details the architecture of PYTHEN, provides a comparative analysis with PROLEG, and discusses its potential applications in autoformalization and the development of next-generation legal AI systems. By bridging the gap between symbolic reasoning and the accessibility of Python, PYTHEN aims to democratize formal legal reasoning for young researchers, legal tech developers, and professionals without extensive logic programming expertise. We position PYTHEN as a practical bridge between the powerful symbolic reasoning capabilities of logic programming and the rich, ubiquitous ecosystem of Python, making formal legal reasoning accessible to a broader range of developers and legal professionals.

Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Builds on 6 of its 22 references that are in the map. First posted on arXiv 16 Mar 2026.

Builds on

6 of 22 references.

References · 6

  1. 2023LegalBench: A Collaboratively Built Benchmark for Measuring Legal Reasoning in Large Language Modelscited by 336
  2. 2024Natural Language Processing for the Legal Domain: A Survey of Tasks, Datasets, Models, and Challengescited by 42
  3. 2025On Verifiable Legal Reasoning: A Multi-Agent Framework with Formalized Knowledge Representationscited by 18
  4. 2023The Cambridge Law Corpus: A Dataset for Legal AI Researchcited by 14
  5. 2025Towards a Common Framework for Autoformalizationcited by 7
  6. 2024KRAG Framework for Enhancing LLMs in the Legal Domaincited by 2

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2026: 1.

1 paper.

Similar, not cited

Close in wording, no citation either way

  1. 2024FAERDXEL: An Expert System for Danish Traffic Law
  2. 2024Software Engineering Methods For AI-Driven Deductive Legal Reasoning
  3. 2026OpenExempt: A Diagnostic Benchmark for Legal Reasoning and a Framework for Creating Custom Benchmarks on Demand
  4. 2025LexChain: Modeling Legal Reasoning Chains for Chinese Tort Case Analysis
  5. 2026DeonticBench: A Benchmark for Reasoning over Rules
  6. 2026LegalDrill: Diagnosis-Driven Synthesis for Legal Reasoning in Small Language Models
  7. 2025Towards Trustworthy Legal AI through LLM Agents and Formal Reasoning
  8. 2025An Explicit Syllogistic Legal Reasoning Framework for Large Language Models