Hybrid Transformer–Rule Based Architecture for Explainable Legal Clause Contradiction Detection
Main Article Content
Abstract
Legal and contractual texts are likely to contain intricate clauses with conditional, modal, referential cross-referential, numeric or temporal restrictions which in turn may be prone to inconsistency. Finding such contradictions manually is inconvenient, error-prone and non-scalable especially with large size documents. There are several existing methods such as keyword-based approaches, rule-based systems and transformer-based models. Keyword and rule-based systems are good at detecting explicit contradictions, but struggle with implicit ones that can be context-dependent. Transformer models do well in semantic coherence but are poor at identifying structural inconsistency and have limited interpretability for expert review.
It introduces Hybrid Transformers, a framework for clause-level contradiction detection that combines transformer-based semantic parsing with rule-based logical validation. Contextual and modality-cue information is built automatically with the legal-domain transformer embedding’s, while structural conflicts (e.g., negation mismatches, numeric incoherencies, or conditional contradictions) are checked by using rule-based checks. Pairs of clauses are compared by applying a pairwise inference method similar to natural language inference, which is designed to detect implicit as well as explicit contradictions. Detected inconsistencies are assigned interpretable confidences based on linguistic and structural evidence, aiding explainability and human validation. Experimental results on curated legal clause datasets show that such the hybrid model can bring higher precision and fewer false positives, outperforming independent transformer or rule-based models. Utilizing deep semantic understanding and explicit logical reasoning connections, Hybrid Transformers are a scalable, dependable, and explainable model for automatic legal document validation, compliance surveillance and expert legal review.