Live · Qwen3.5-2B + LoRA · trained on CUAD

Upload a contract, see the risky clauses highlighted.

A 2B-parameter model fine-tuned to find 41 kinds of clauses lawyers look for, from uncapped liability to change of control. It lifts held-out span F1 from 0.02 to 0.49 over the same model untuned.

Not legal advice. Your file is read in your browser; only its text is sent for scanning, and nothing is stored. How your contract is handled

Or try a demo contract

Ask a question, get an answer that points at the text.

Scan a contract or open a demo first.

A small model, measured before and after fine-tuning.

Held-out results · 97 CUAD contracts

MetricZero-shot+ LoRA r8
Span F1 (IoU ≥ 0.5)0.0230.492
Clause presence F10.3870.833
Unparseable outputs58.6%4.1%
Output tokens709k175k

Strong: governing law 0.86, agreement date 0.76, parties 0.70. Weak: non-compete 0.26, termination for convenience 0.21. Cards for weak types say “low accuracy”.

Pipeline

  1. In your browser: pdf.js or mammoth extracts the text and splits it into overlapping sections of about 1,500 tokens, with the same chunker the model was trained on.
  2. Cloudflare Worker: builds the fixed prompt and checks the daily budget.
  3. Modal GPU (L4): vLLM runs Qwen3.5-2B with the LoRA merged in. It returns each clause's type and its first and last words.
  4. Back in the Worker: those anchors are matched to exact character offsets, so highlights land on the real text.
  5. Ask embeds sections with bge-m3 and answers with Qwen3-30B-A3B on Workers AI, citing only sections it was given.

How your contract is handled

Your file
Read in your browser. The file itself is never uploaded.
Its text
Sent in sections to a Cloudflare Worker, then to a GPU on Modal (may run in the US) and, for Ask, to Workers AI. Processed in memory and not stored. Modal doesn't store the requests this app sends, and Cloudflare doesn't train on them.
Logs
One line per request: timings, counts, lengths and a keyed fingerprint. Never the text or your questions.
Your IP
Turned into a pseudonymous id, salted afresh each day, to enforce a fair daily quota. Deleted after the day.
Tip
Remove personal details before scanning a real contract.

Cost and limits

GPU spend is capped at $0.23 a day (under $10 a month). When it runs out, live scanning pauses until midnight UTC and the demos keep working. Scans are fast once the model is warm. The first scan after a quiet spell usually waits about 30 seconds for the GPU to start, and occasionally a few minutes.

The model has only been measured on CUAD: US commercial contracts filed with the SEC. Leases, employment contracts and non-US law are untested. Highlights can be wrong or missing.

Model: Qwen3.5-2B (Apache-2.0), fine-tuned with LoRA. Data: CUAD v1 by The Atticus Project (CC BY 4.0), Hendrycks et al., NeurIPS 2021.

Source code: github.com/thearshkumar/contract-scanner (MIT). Not legal advice.