
Contracts, amendments, powers of attorney and court filings are documents that law firms, in-house legal teams and procurement departments should not paste into a public AI chat. AI contract analysis can still run entirely on a server you control: the model extracts clauses, compares them with your template and flags risks, while a lawyer always makes the final call.
Below: how it works in practice, what hardware it needs and where first projects stumble. We write as a team that runs GPU servers, not as a law firm, so treat the legal points as a starting point for your compliance team.
The problem: hundreds of pages to read and data that must stay in-house
Law firms, bank legal departments and procurement teams repeat the same tasks: check whether a counterparty’s contract deviates from the standard template, find the clauses on penalties, liability and termination, and prepare a short summary for management. In due diligence or a tender with dozens of annexes, that means days of largely mechanical work.
Public AI tools do this quickly, but only by sending the document to an external provider: counterparty data, commercial terms, often personal data and, in a law firm, privileged information.
The solution: AI contract analysis on a self-hosted model
Open-weight language models can run on your own GPU server. A document reaches the model through an internal application, and the answer returns to the user without leaving infrastructure you control. In practice, such a system covers four types of task:
| Task | What the model does | The lawyer’s role |
|---|---|---|
| Clause and data extraction | Pulls parties, dates, amounts, notice periods and penalties into a table | Verifies the output, especially numbers and dates |
| Comparison against templates | Highlights differences between the contract and your template or negotiation playbook | Decides which deviations are acceptable |
| Risk flags | Marks unusual, one-sided or non-compliant clauses against your checklist | Judges how serious each risk is and what to recommend |
| Summaries and questions | Writes a summary and answers questions such as “who pays for insurance?” with a reference to the clause | Checks the answer against the source |
Template comparison works best when the model can draw on your templates, checklist and earlier opinions. It is the mechanism we describe in our article on the company knowledge assistant (RAG): the system first retrieves the relevant passages, and only then does the model write an answer that cites its source.
Which model to choose
As of November 2026, good starting points include Qwen3.8-27B (Apache 2.0, multimodal, so it can also read page images), gpt-oss-120b (Apache 2.0) and Mistral Small 4 (Apache 2.0). The market changes monthly, so we confirm the choice with a test on your own documents, not generic leaderboards.
Scans and OCR
Many contracts exist only as scans with signatures and stamps. Before analysis, the document goes through locally run OCR or is passed to a multimodal model as an image. A misread amount or date here will appear in the summary as fact.
Why on-premises: privilege and confidentiality
Lawyers are bound by professional secrecy, banks by banking secrecy, procurement teams by confidentiality clauses. However you interpret these duties, you need clear answers to three questions: where the data goes, who can access it and how long it is kept. With your own model in a Polish data center, the answer is simple: documents never leave the infrastructure, logs stay under your control, and the model’s developer never sees your prompts.
Contracts also contain personal data (signatories, employees, sole traders), so the GDPR applies. We cover the GDPR, the AI Act, NIS2 and DORA for self-hosted models in Self-hosted AI and EU compliance. Our earlier piece on avoiding data leaks to public AI tools is also worth a read.
What hardware AI contract analysis needs
Sizing depends on three things: model size, document length (longer context means more memory for the KV cache) and how many people work at the same time. A simple rule: model weights take roughly the number of parameters × bytes per parameter, plus 10–20% overhead. Qwen3.8-27B in BF16 is about 56 GB of weights; gpt-oss-120b at 4-bit precision is about 59 GB. Either fits on a single RTX PRO 6000 card with 96 GB of memory, leaving headroom for context.
| Option | Memory | Best for | Notes |
|---|---|---|---|
| NVIDIA DGX Spark as a Service | 128 GB unified memory | Pilots, small firms, legal teams of a few people | Memory bandwidth of 273 GB/s means slower generation with large models; custom quote |
| Server with 1–2 RTX PRO 6000 cards | 96 GB GDDR7 per card | Law firms or legal departments, many concurrent users, long documents | Good price/performance for inference and RAG; custom quote |
| Server with 4–8 RTX PRO 6000 cards | Up to 768 GB in total | Larger organisations, bigger models, bulk processing (due diligence) | Supermicro 5U platform holds up to 8 cards; custom quote |
We cover DGX Spark in detail in NVIDIA DGX Spark as a Service, and compare GPUs in the best GPU for LLMs in 2026. You can rent the machine as a GPU server in our ISO 27001-certified Tier III data center, or buy it and place it with us under colocation. As a Supermicro and NVIDIA partner, we size the configuration to your model and workload.
Rollout step by step
- Pick one process. For example, lease reviews: one document type, a clear checklist, a measurable outcome.
- Prepare reference material. Templates, a risk checklist and a few dozen sample contracts with a lawyer’s assessment. This is what you will test the model against.
- Run a pilot. Model, OCR and document retrieval on a DGX Spark or a single GPU server. Compare the model’s output with your lawyers’ assessment of the same sample.
- Integrate with your document workflow. Browser or DMS access, single sign-on, and permissions that mirror who may see which matters.
- Agree working rules. Who reviews the output, how AI-assisted documents are labelled, and how long logs are kept.
- Operate and measure. Model updates, backups, monitoring. Run it yourself with root access, or hand it to our 24/7 server administration team.
Pitfalls to watch for
- The model is not a lawyer. It can be confidently wrong or miss a clause. Every result needs review, with a pointer to the source clause.
- OCR quality. Stamps, handwritten notes and tables in scans are frequent sources of errors. Test OCR on your worst scans, not your best.
- Access rights. If retrieval covers every document, the model may show part of a matter to someone who should not see it. Enforce permissions in the retrieval layer.
- Undersized hardware. Long contracts and parallel users quickly eat context memory. Plan for headroom, not just model size.
- Model licence. Some models use custom licences. For commercial use, Apache 2.0 or MIT models are the simplest choice; read any other licence before deployment.
FAQ: frequently asked questions
Can AI review contracts on its own?
It should not. AI contract analysis speeds up finding clauses, comparing against templates and drafting summaries, but the legal assessment stays with the lawyer, helped by source references that make review quick.
Can a law firm use ChatGPT to analyse contracts?
That depends on the firm’s risk assessment, the provider’s terms and professional conduct rules, and the firm has to decide. A self-hosted model on a server in the EU removes the main concern: document contents never reach an external AI provider.
What server do I need for legal document analysis?
A DGX Spark is enough for a pilot or a small team. For a law firm or legal department where several to a dozen or so people work on long documents at once, a server with one or two RTX PRO 6000 cards (96 GB per card) is a better fit.
Does on-premises AI work with contracts in languages other than English?
Large open-weight models are multilingual, and smaller language-specific models (for Polish, Bielik or PLLuM) are cheaper to run for single-language work. Test on your own documents before choosing.
Want to see how AI contract analysis performs on your documents? We will select the model and a GPU server or DGX Spark, run a pilot in our Polish data center and leave you in full control of the data. Get in touch for a quote.
