v0.2.0 Now open source · Apache-2.0 →

Legal AI that stays where your clients' data lives.

OpenLex reads contracts, searches the law and drafts with you, in Word, in the app or in your terminal. It runs on your machine, uses the model you choose, and every answer quotes its source.

$curl -fsSL https://openlex.pinemarshlands.com/install | bash

Needs Node.js 20+. Installs into ~/.openlex, checks the release checksum, changes nothing else. Read the script · Releases

openlex — example session

  
Built for legal work

Not a chatbot with a law degree.
A workbench that shows its sources.

Every finding carries a verbatim quote from your document or the statute. If the quote isn't there, the finding isn't shown as fact.

Verified, never invented

Reviews, chronologies and grid cells keep only answers whose quote appears word for word in the document. A judge checks suggested edits against the cited law.

review · chronology · judge

Review grids

Rows are documents, columns are your questions: yes/no, choice, dates, amounts, or built on another column. Every cell links to its quote. Export to Excel.

openlex grid

A data policy per matter

Local-only by default. Allow a cloud model per matter, limit it to EU regions, pseudonymise names before anything leaves. Privileged matters never leave.

policy · redaction · audit

Plans you approve first

Describe the goal; OpenLex proposes the steps and stops at checkpoints where judgment is yours. Nothing runs before you approve.

openlex plan

Monitors on official sources

Watch new EU acts, the Austrian federal gazette, any RSS feed or a public page. Alerts land in the matter with their source.

EUR-Lex · RIS · RSS

Where you already work

A Word add-in with tracked changes and comments, a desktop app, Outlook, a CLI and a local API: one engine, one set of matters.

Word · app · CLI · API
Your model, your keys

Bring any model. Change it per task.

Run fully local with llama.cpp, or use your own key with a hosted provider. The data policy decides what may leave the machine, matter by matter, and every call is written to an audit log without its content.

Local llama.cpp · OllamaAnthropic ClaudeOpenAI GPTAzure OpenAI, EU regionsMistral EUAWS BedrockGoogle Vertex AIOpenRouter any modelCustom OpenAI-compatibleKev / Jev decision modelsLocal llama.cpp · OllamaAnthropic ClaudeOpenAI GPTAzure OpenAI, EU regionsMistral EUAWS BedrockGoogle Vertex AIOpenRouter any modelCustom OpenAI-compatibleKev / Jev decision models
Customizable at every turn

One file your firm can version.

The harness map in openlex.json decides which model handles each step, which firm rules apply at each decision point, and which agent profiles your lawyers can call. The firm sets it; partners can lock it.

  • Route drafting, judging and translation to different models, with fallbacks
  • Rules before tools, answers and suggestions: block, warn, flag, or ask your own script
  • Agent profiles like @researcher or @drafter, and skills like /nda-review, as plain files
openlex.jsonfirm layer
// which model does what
"routes": {
  "roles": {
    "write": "anthropic:claude-opus-5-5",
    "judge": "local"
  },
  "rules": [{ "when": { "privileged": true }, "use": "local" }],
  "fallback": ["local"]
},
// firm rules at the decision points
"hooks": {
  "before_answer": [{ "match": { "notRegex": "§|Art\\." },
      "action": "warn", "message": "No citation — verify." }],
  "on_suggestion": [{ "match": { "regex": "(?i)indemnif" },
      "action": "flag", "message": "Partner sign-off." }]
},
"lock": ["routes"]
Open source

Read it. Run it air-gapped. Check what it does.

The engine, the Word add-in, the CLI, skills and playbooks are Apache-2.0. The community build needs no account and no licence server. Firms that want curated law packs, the Lotus models and support take a subscription.

free · Apache-2.0

Community

€0

The engine, CLI, Word add-in code, skills, playbooks and the harness map. Your models, your law sources.

integration

For your firm

by project

Connect your DMS, set up the harness map, firm skills and playbooks, and bring OpenLex to your infrastructure.

Start in your terminal.
Keep your data where it is.

$curl -fsSL https://openlex.pinemarshlands.com/install | bash