Submitted:
22 July 2025
Posted:
23 July 2025
Read the latest preprint version here
Abstract
Keywords:
1. Introduction and Motivation
1.1. Technical Background
2. Multimodality and the Law
2.1. Expert Systems
2.2. Knowledge, Rule Bases and Inference Engines
2.3. LLMs and Other Approaches to Legal Reasoning
2.4. Tax Preparation Systems
3. First-Order Logic Systems
| Listing 1. A rule in ErgoAI |
| ?X:Deduction :- ?X:Expenditure, ?X[ordinary -> \true], ?X[necessary -> \true], ?X[forBusiness -> \true]. |
“Words change meaning over time, and often in unpredictable ways.”
3.1. Interpretations and Models
- variables
- logic connectives
- quantifiers
- scoping (, ) or [] or such-that :
- equality =
- Constants in D
- n-ary functions, such a function has domain and range D.
- n-ary relations, such a relation has domain and range .
- There is a interpretation domain made from the elements in I
- If there is a constant , then it maps uniquely to an element
- If there is a function symbol where f takes n arguments, then there is a unique where is an n-ary function.
- If there is a relation symbol where R takes n arguments, then there is a unique n-ary relation .
- Valid if every interpretation I is so that E is true
- Inconsistent or Unsatisfiable if E is false under all interpretations I
- Consistent or Satisfiable if E is true under at least one interpretation I
- If E is true, then there is an algorithm that can verify E’s truth in a finite number of steps.
- If E is false, then in the worst case there is no algorithm can verify E’s falsity in a finite number of steps.
- Listing 2. Provability in ErgoAI
- ?X:Expenditure
- ^ ?X[ordinary -> \true ]
- ^ ?X[necessary -> \true ]
- ^ ?X[forBusiness -> \true ]
- $\vdash$ ?X:Deduction
4. Models and LLMs
“26 §162 In general - There shall be allowed as a deduction all the ordinary and necessary expenses paid or incurred during the taxable year in carrying on any trade or business, including—”
5. Löwenheim–Skolem Theorems
- If , then is an elementary extension of ,
- If , then is an elementary substructure of .
- Upward If , then is an elementary extension of , or ,
- Downward If , then is an elementary substructure of , or .
6. Discussion
7. Conclusions
References
- Cohen, P. J.; Set theory and the continuum hypothesis, Dover (re-print): New York, 1994.
- Hodel, R. E.; An Intoduction to Mathmatical Logic, Dover: New York, 1995.
- Scalia, A.; Garner, B. A.; Reading Law: The Interpretation of Legal Texts, Thomson West, 2012.
- Shoenfield, J. R.; Mathematical Logic, Association for Symbolic Logic: Storrs CT, USA, A. K. Peters Ltd, 1967.
- Chang, C. C.; Keisler, H. J. Model theory, 3rd Edition, Dover 2012.
- Xu, J.; Fei, H.; Pan, L.; Liu, Q.; Lee, M.-L.; Hsu, W. Faithful Logical Reasoning via Symbolic Chain-of-Thought, 2024, arXiv preprint arXiv:2405.18357v2. [CrossRef]
- Ye, X.; Chen, Q.; Dillig, I; Durrett, G; Satlm: Satisfiability-aided language models using declarative prompting. Advances in Neural Information Processing Systems, 36, 2024.
- Wei, J.; et al. Chain-of-thought prompting elicits reasoning in large language models. Advances in neural information processing systems, 35:24824–24837, 2022.
- Marker, D. Model Theory: An Introduction, Graduate Texts in Mathematics, Springer, 2002.
- Denis Merigoux,D.; Chataing, N.; Protzenko, J; 2021. Catala: a programming language for the law. Proc. ACM Program. Lang. 5, ICFP, Article 77, 2021, 29 pages. [CrossRef]
- Leith, P.; The rise and fall of the legal expert system, European Journal of Law and Technology, Vol 1, Issue 1, 2010.
- Franklin, J.; How much of commonsense and legal reasoning is formalizable? A review of conceptual obstacles, 2012.
- Ebbinghaus, H.D. Löwenheim-Skolem Theorems. Philosophy of Logic (pp. 587-614). North-Holland. 2007.
- Isozaki, I.; Literature review on AI in Law, https://isamu-website.medium.com/literature-review-on-ai-in-law-7fe80e352c34 2024.
- Kirtania, S; Gupta, P.; Radhakirshna, A.; Logic-lm++: Multi-step refinement for symbolic formulations. arXiv preprint arXiv:2407.02514, 2024.
- Goldshmidt, R; Horovicz, M; TokenSHAP: Interpreting Large Language Models with Monte Carlo Shapley Value Estimation, In Proceedings of the 1st Workshop on NLP for Science (NLP4Science) (pp. 1-8). 2024.
- Dixon, M; Bilokon, P.; Halperin, I.; Machine Learning in Finance: from Theory to Practice, Springer, 2020.
- Exploring explainable AI in the tax domain https://link.springer.com/article/10.1007/s10506-024-09395-w (Accessed 2025-06-27).
- Towards eXplainable Artificial Intelligence (XAI) in Tax Law: The Need for a Minimum Legal Standard, 2022.
- Reviewing the explainable artificial intelligence (XAI) and its importance in tax administration https://www.ciat.org/reviewing-the-explainable-artificial-intelligence-xai-and-its-importance-in-tax-administration/?lang=en (Accessed 2025-06-27).
- Katz, S. M. Distribution of content words and phrases in text and language modelling. Natural language engineering. 1996 Mar;2(1):15-59.
- https://www.law.cornell.edu/uscode/text/26/162 (Accessed 2025-04-28).
- Fast text, https://fasttext.cc/ (Accessed 2025-04-15).
- Bonner, A. J.; Kifer, M. An overview of transaction logic, Theoretical Computer Science 133, no. 2 1994: 205-265.
- Bradford, P. G.; Wollowski, M. A formalization of the Turing Test, ACM SIGART Bulletin 6, no. 4 1995: 3-10.
- Chang, C-L.; Lee, R. C.-T. Symbolic Logic and Mechanical Theorem Proving, Academic Press, 1973.
- Coherent Knowledge: http://coherentknowledge.com/ (Accessed 2025-04-13).
- https://shap.readthedocs.io/en/latest/ (Accessed 2025-06-30).
- Duncan-Jones, R. Money and Government in the Roman Empire, Cambridge University Press, 1994.
- Gao, T; Fodor, P.; Kifer, M; Knowledge Authoring for Rule-Based Reasoning, ODBASE, OTM Conferences, 2018: 461-480.
- Kunik, M.; On the downward Löwenheim-Skolem Theorem for elementary submodels. arXiv preprint arXiv:2406.03860, 2024.
- Lidz, F.; How to Evade Taxes in Ancient Rome? A 1,900-Year-Old Papyrus Offers a Guide, New York Times, (Accessed: 2025-04-14).
- Michel, J.-B.; et al. Quantitative Analysis of Culture Using Millions of Digitized Books, Science 331, 2011, pp. 176–182.
- Nay, J. J; et al. Large language models as tax attorneys: a case study in legal capabilities emergence, 2024, Phil. Trans. R. Soc. A. [CrossRef]
- Neural Tax Networks: https://neuraltaxnetworks.com/ (Accessed 2025-04-13).
- Orphys, H. A. (assignee); Jaworski, W.; Filatova, E., Bradford, P. G. Determining Correct Answers To Tax And Accounting Issues Arising From Business Transactions And Generating Accounting Entries To Record Those Transactions Using A Computerized Logic Implementation. US 11295393 B1, Published: 2022-04-05.
- Pan, L; Albalak, A.; Wang, X.; Wang, W. Y. Logic-lm: Empowering large language models with symbolic solvers for faithful logical reasoning, arXiv preprint arXiv:2305.12295, 2023.
- Petersen, A. M.; et al. Statistical Laws Governing Fluctuations in Word Use from Word Birth to Word Death, Scientific Reports 2:313, 2012.
- Putnam, H; Models and Reality, The Journal of symbolic logic, 45(3), 464-482.
- Swift, T.; Kifer, M. Multi-paradigm Logic Programming in the ErgoAI System, In Logic Programming and Nonmonotonic Reasoning: 17th International Conference, LPNMR 2024, Dallas, TX, USA, October 11–14, Proceedings. Springer-Verlag, Berlin, Heidelberg, 2024, 126–139. [CrossRef]
- ErgoText System. https://sites.google.com/coherentknowledge.com/ergoai-tutorial/ergoai-tutorial/ergotext (Accessed 2025-06-29).
- 1997, Thomas, W. Languages, automata, and logic. In Handbook of Formal Languages: Volume 3 Beyond Words (pp. 389-455). Berlin, Heidelberg: Springer Berlin Heidelberg. 1997.
- Tunstall, L; Von Werra, L.; and Wolf, T. Natural language processing with transformers, O’Reilly Media, Inc., 2022.
- Van Dalen, D. Logic and structure, 4th edition, Universitext, Springer, 2004.
- Wolfram, S. What is chat-gpt doing and Why does it work, Wolfram Media, 2023.



Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2025 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).