QWED-Legal
Deterministic verification guards for computational legal claims.Block unproven legal claims before they become liabilities.
What is QWED-Legal?
QWED-Legal is a verification layer for deterministic, computational legal claims. It is designed to sit between untrusted LLM or workflow output and any downstream legal action. QWED-Legal verifies only what can be deterministically proven, such as:- Date calculations (business days, holidays, leap years)
- Liability arithmetic (cap percentages, tiered amounts, indemnity multipliers)
- Structured contradictions between modeled clauses
- Citation format for supported reporters
- Provenance metadata (hash integrity, disclosure markers, allowed models)
Verification boundaries
QWED-Legal operates under strict limits:- Only deterministic claims can be verified.
- Ambiguous or interpretive output is rejected or marked unverified.
- Legal reasoning is not assumed correct without proof.
- If something cannot be proven, it must not pass.
- a legal reasoning engine
- a source of legal truth
- a replacement for lawyers
- a contract drafting or review platform
- a guarantee that every legal output can be verified
Guard coverage
Not every guard provides full formal verification. Some operate on partial rules or structured validation and should not be treated as complete legal proof.| Guard | Status | What it checks |
|---|---|---|
| DeadlineGuard | DETERMINISTIC | Date arithmetic and business-day calculations for supported, structured inputs |
| LiabilityGuard | DETERMINISTIC | Cap and tiered amount computations for supported numeric inputs |
| ClauseGuard | PARTIAL / HEURISTIC | Limited text-based clause consistency and contradiction checks |
| CitationGuard | PARTIAL / HEURISTIC | Citation shape / format validation, not authoritative existence proof |
| JurisdictionGuard | PARTIAL / HEURISTIC | Structured checks around governing law and forum combinations |
| StatuteOfLimitationsGuard | PARTIAL / HEURISTIC | Limitation-period calculations for supported jurisdictions and claim types |
| IRACGuard | PARTIAL / HEURISTIC | IRAC structure and consistency checks, not proof of legal reasoning |
| FairnessGuard | PARTIAL / HEURISTIC | Counterfactual consistency checks (requires an external LLM client) |
| ContradictionGuard | PARTIAL / HEURISTIC | Structured contradiction checks for a limited set of modeled clause categories |
| ProvenanceGuard | DETERMINISTIC | SHA-256 hash integrity, disclosure markers, model allowlist, timestamp validity |
PARTIAL / HEURISTIC guard does not mean the underlying legal claim is correct. It means the claim matched a supported structural pattern.
Quick Example
Verify a Deadline Calculation
Verify a Legal Citation
Architecture
High-Level Flow
Guard Selection Flow
Examples of claims QWED-Legal can reject
These are examples of supported checks catching unsupported claims. They are not proof that every legal hallucination is detectable.| Input | Claimed result | Example outcome |
|---|---|---|
| ”Net 30 business days from Dec 20” | Wrong computed date | Blocked by DeadlineGuard |
| ”Liability cap: 2x fees” | Wrong cap arithmetic | Blocked by LiabilityGuard |
| Structured liability conflict | ”Clauses are consistent” | Blocked by ContradictionGuard |
| Unsupported citation reporter | ”Valid citation” | Blocked by CitationGuard format checks |
Why not just trust the LLM?
LLMs are probabilistic and can fail in legally significant ways:| Failure mode | Example | Risk |
|---|---|---|
| Fabricated authority | AI cites a nonexistent or malformed legal source | Sanctions, bad filings |
| Deadline mistakes | ”30 business days” miscomputed | Missed obligations, defaults |
| Clause inconsistency | Two provisions cannot both be true | Disputes, unenforceable terms |
| False certainty | Model states a legal conclusion without proof | Liability, audit failure |
Jurisdiction Support
DeadlineGuard supports jurisdiction-specific holidays:Next Steps
- The 10 Guards - Deep dive into each verification guard
- Examples - Real-world contract verification scenarios
- Troubleshooting - Common issues and solutions