Skip to content
Apixo
Blog
news· 4 min read· via Latent Space

How Legora Built an $8.8B Legal AI Agent Platform Without Access to User Data

Legora CTO Jacob Lauritzen breaks down how the legal tech startup reached $100M+ ARR by building synthetic evals, core primitives, and specialized model routing.

How Legora Built an $8.8B Legal AI Agent Platform Without Access to User Data

Legora, the Stockholm-founded legal tech startup formerly known as Leya, has rapidly expanded into one of the most prominent agentic AI platforms in the enterprise software sector. After crossing $100 million in annual recurring revenue (ARR) in April—less than 18 months after its initial launch—the company raised a $550 million Series E round in October at an $8.8 billion valuation, up from its $5.55 billion valuation in March. With over 1,800 clients and five acquisitions this year, including legal research company Qura and fact-extraction startup Wexler, Legora’s growth offers a clear case study in building specialized AI agents for high-stakes industries. In a recent interview on Latent Space, Legora CTO Jacob Lauritzen detailed the architectural, operational, and evaluation strategies behind scaling legal AI agents.

Overcoming strict data privacy and evaluation hurdles

Building AI agents for legal professionals presents unique technical challenges, particularly around data privacy. Because law firms and corporate legal departments handle strictly confidential client documents, Legora’s engineering team cannot access customer traces or real user data to evaluate model behavior. To address this constraint, Legora built an internal evaluation team comprising three software engineers and three lawyers, supported by a pool of approximately 100 legal engineers—former big law attorneys who often hold computer science degrees.

Instead of analyzing user logs, the team constructs synthetic reinforcement learning (RL) environments that simulate actual legal workflows. For instance, they evaluate agents inside simulated 10,000-file data rooms designed for corporate due diligence, assessing whether the agent successfully identifies specific red flags and generates concise reports. Running up to 2,000 parallel agent evaluations on Modal Sandboxes, the team plots performance on a heat map segmented by practice area and specific task. In production, Legora monitors performance without viewing user content by categorizing system errors into 10 to 20 known failure types, running lightweight LLM checks behind feature flags. Security constraints also dictated the company's infrastructure choices: Legora runs entirely on Microsoft Azure because enterprise law firms had already vetted and approved Microsoft through Microsoft 365.

Architecture, primitives, and model routing

Rather than building distinct point solutions for every legal task, Legora relies on a small set of core software primitives that enable fast product development. These primitives include projects (file containers), the central agent, Notion-style databases called Lists with automated triggers, Slack-based Intake bots, and Tabular Review. Tabular Review allows users to execute bulk document extraction across datasets containing up to one million cells, beginning with an initial 10-row sample so lawyers can refine prompts before processing large contract batches. Legora's legal engineers utilize these primitives to configure new tools without writing production code, while forward deployed engineers (FDEs)—such as former Meta search engineer Di Qi—write production integrations connecting Legora to firm document management systems and CRMs.

On the model layer, Legora implements task-based routing rather than relying on a single foundation model. Lauritzen notes that current frontier models handle roughly 60% of legal tasks effectively, shifting the challenge for those workloads to latency and cost optimization. However, complex multi-document editing still requires higher intelligence. For drafting, Legora observed that models like Fable and Opus can be overly verbose, whereas models like Astra produce more concise output. To eliminate hallucinations, the system incorporates citation tracking that highlights exact bounding boxes within source PDFs multiple layers deep. For engineering teams looking to experiment with task-specific model routing and optimize token costs across different providers, developers can try top AI models cheaply through one API at https://apixoai.online. Additionally, Legora post-trains open-weight models for narrow tasks like legal research rather than training frontier foundation models from scratch.

What it means for developers

Legora’s technical choices provide actionable insights for software engineers building domain-specific AI agents:

  • Synthetic evaluation environments are essential when traces are unavailable: In privacy-sensitive verticals like law, healthcare, or finance, developers cannot rely on real user logs. Synthetic RL benchmarks and simulated multi-document environments allow teams to measure accuracy across task heat maps without violating user privacy.
  • Modular primitives scale faster than bespoke features: Building core building blocks (such as structured lists, batch processing tables, and file containers) allows non-engineering domain experts to assemble specialized workflows without modifying core codebase logic.
  • Hybrid teams bridge the domain gap: Combining software engineers with domain experts who have technical backgrounds—like Legora's legal engineers—creates a feedback loop that improves prompt design, evaluation suite design, and product configuration.
  • Model selection requires multi-dimensional benchmarking: A single frontier model is rarely optimal across all sub-tasks. Developers should route specialized tasks (e.g., concise drafting vs. wide retrieval) based on cost, latency, verbosity, and context constraints rather than exposing raw model selection choices to non-technical end-users.

Source: Building AI for Lawyers - Jacob Lauritzen, CTO of Legora — Latent Space. Written by the Apixo team from that report.

#ai-news#ai-agents#legaltech#software-architecture#evaluations#llm-routing
Try it with your own tools

One key for Claude, GPT, GLM, DeepSeek and more. Pay per token with crypto.

Get your API key

Keep reading