Harvey: a custom U.S. case law model that lawyers preferred over GPT-4 97% of the time
To test the model, Harvey brought in attorneys from 10 of the largest law firms. They were shown side-by-side outputs of the custom case law model and GPT-4 for the same question. "97% of the time, the lawyers preferred the output from the case law model," says Weinberg. "Usually, it was because it was a longer, more complete answer. It went into the nuance of what the question was asking and covered more relevant case law." The strength of the reaction, the team admits, surprised them. The second result concerns hallucinations — largely the reason the model was built: "Not only does the case law model not make up cases, but every sentence is actually supported with the case it's citing," Weinberg states. Framing that matters. The 97% is a preference metric, not a measure of formal legal accuracy: it shows which answer lawyers choose, not how many errors it contains. The testing was organized by Harvey itself; the question sample size was not disclosed; no independent replication has been published; and the case study was published by OpenAI — an interested party whose product underpins the solution. The no-hallucinations claim is likewise a founder's statement, not the result of a published independent audit. Editorial analysis. Indirect evidence that the custom-model bet paid off at least commercially is Harvey's trajectory after the case study: a $100M Series C at a $1.5B valuation (July 2024), $300M Series D at $3B (February 2025), $300M Series E at $5B (June 2025), $160M Series F at $8B (December 2025), and a $200M round at an $11B valuation in March 2026; 2025 revenue was $190M (Wikipedia, based on public disclosures). Customers include firms like Paul Weiss and A&O Shearman, where 3,500 lawyers ran about 40,000 queries during a trial period; Ashurst rolled Harvey out globally, Singapore's WongPartnership became the first Southeast Asian firm to test the product, and PwC adopted it for legal services in Singapore. In fairness: the company's growth does not isolate the custom model's contribution — Harvey grew across its whole product line, and an $11B valuation cannot be attributed to one technical decision. A second observation: the case captured the "maturity ladder" of working with LLMs — prompting → RAG → fine-tuning → custom training — which later became industry common sense. It also shows how fast baselines age: "preferred over GPT-4 97% of the time" sounded strong in April 2024, but a comparison against a long-surpassed model says nothing by itself about where Harvey stands against today's frontier models.
- Harvey partners with OpenAI to build a custom-trained model for legal professionals — OpenAI (customer story), 2024-04-02
- Harvey raises $80M Series B from Elad Gil, Kleiner Perkins, OpenAI and Sequoia — Harvey (blog), 2023-12-19
- Harvey (software) — Wikipedia (история финансирования и клиентов), 2026
Background
Harvey is a generative AI platform for professionals in law, tax, and finance, founded in the summer of 2022. Behind it are two people with rarely overlapping backgrounds: Winston Weinberg, an attorney with antitrust and securities litigation experience, and Gabe Pereyra, an AI researcher who previously worked on large language models at Google Brain and Meta. Their initial hypothesis was simple: LLMs can synthesize huge volumes of legal information and present it to lawyers for review — instead of lawyers spending weeks sifting through documents themselves. The platform helps with tasks requiring complex reasoning and deep domain knowledge: drafting documents, answering questions about complex litigation scenarios, and identifying material discrepancies between hundreds of contracts.
An early prototype showed the potential before the product even existed. Weinberg and Pereyra pulled 100 landlord/tenant questions from Reddit's r/legaladvice, generated answers with GPT-3, and showed them to practicing attorneys. For 86 out of 100 questions, the attorneys said they would have sent the answer to the client without editing. "It was an aha moment," Weinberg recalls.
From there the company grew at a pace rare for LegalTech. November 2022 brought a $5M seed round led by the OpenAI Startup Fund; April 2023, a $23M Series A from Sequoia. Over 2023, revenue grew more than 10x and the team passed 100 people, and on December 19, 2023, Harvey closed an $80M Series B at a $715M valuation (co-led by Elad Gil and Kleiner Perkins, with participation from the OpenAI Startup Fund and Sequoia), bringing total funding to over $100M. Among the round's stated goals, the company explicitly named expanding its custom model building, scaling the team, and building out the product feature suite. By then the customer base included leading law firms, in-house teams, professional service providers, and private equity firms.
That work is the subject of this case. Harvey, in partnership with OpenAI, built a custom-trained model for U.S. case law — in OpenAI's wording, the first custom-trained case law model. OpenAI published the case study on April 2, 2024, and it remains one of the most-cited answers to the question of when a company should go beyond RAG into custom model training.
Problem
Legal work keeps growing in data volume. "Both transactional work and litigation have been getting increasingly complex — there might be hundreds of thousands of contracts to go through for an international merger, and millions of emails to review for litigation," Weinberg explains. Associates spend countless hours on complex but essentially routine tasks, and the volume only increases. With AI synthesizing documents, lawyers can spend less time sifting through and drafting legal texts — and more time on decisions and clients.
But case law research turned out to be its own category. Harvey envisioned an experience where a lawyer could paste a client question into a model and get a thorough answer citing all its sources. The team first tried the obvious techniques — fine-tuning foundation models via public APIs and retrieval-augmented generation (RAG). Both hit the limits of a uniquely complex, open-ended use case. "If you just do retrieval, you can answer very simple questions about areas of law that you aren't really an expert in, but that's actually not that useful for most attorneys," Weinberg explained. "With case law research, you're finding ammo for your argument, and that's much more difficult to do."
The team's diagnosis: foundation models are strong at reasoning but lack the knowledge required for legal work. Knowledge can't be blended in by a retriever when the task is not finding a fact but building an argument across the entire body of law. Fine-tuning via public APIs fell short too: for a uniquely complex, open-ended use case, the standard tuning levers were not enough. A separate requirement was zero tolerance for made-up cases: hallucination reduction was one of Harvey's main motivations for building a custom model, because an answer without verifiable sources is unusable in a lawyer's real work. That finalized the problem statement: they needed a way to inject both new knowledge and new ways of reasoning about that knowledge into the model itself — deeper than either retrieval or conventional fine-tuning allows.
Solution
Harvey decided to build a custom-trained model together with OpenAI — not fine-tuning via a public API, but joint research work that injects new knowledge, and new ways of reasoning about that knowledge, into a base model. "This was cutting-edge research. We needed a partner that was willing to invest resources to try something new. We looked at all options, but we only trusted building a custom-trained model with OpenAI," says Pereyra.
The process itself was emphatically iterative and human. "None of these problems have a clear-cut solution," Pereyra describes. "A lot of it was sitting down together, having our lawyers explain how case law research works, having our researchers show what we've done, and learning from OpenAI about the levers we had to approach the problem." That detail is rare in vendor case studies: the custom model was born not from a dataset but from translating lawyers' expertise into the language of model training.
Scaling proceeded as a ladder. First, the case law of a single state — Delaware: a compact jurisdiction, but disproportionately important for U.S. corporate law. Then, expansion to the entire body of U.S. case law. In total, the equivalent of 10 billion tokens of data was added to the base model. The order of magnitude matters: this is not "fine-tuning on a few thousand examples" but embedding an entire corpus of professional knowledge into the model. It is also worth noting what the case study does not contain: OpenAI uses the careful wording "the equivalent of 10 billion tokens" and discloses neither the base model nor the training methodology — which levers were ultimately used, how many iterations it took. For anyone hoping to replicate the approach, the public case sets a direction but provides no recipe.
The architectural requirement designed in from the start was verifiability. The model was built so that every sentence of an answer rests on a specific cited case: the lawyer gets not the model's "opinion" but an argument with references that can be checked. This directly addresses the profession's biggest fear — fabricated precedents in documents filed with a court.
The custom model is part of a broader platform: Harvey applies AI to drafting documents, answering questions about complex litigation scenarios, and identifying material discrepancies between hundreds of contracts. The next directions named in the case study: drafting briefs and motions on top of the case law model, helping attorneys understand how case law varies across jurisdictions, and agents — combining multiple model calls into a single working output to reduce the prompt engineering and typing users need to do. The end state the company describes is Harvey as a supportive member of a law firm's team. "The volume of legal work is growing and associates spend countless hours on complex, but routine, tasks," Weinberg says. "The opportunity we have, not just with legal but with all professional services, is to take care of the routine tasks so professionals can focus their time on client interactions."
Asked how to build AI products amid a constant stream of new models, Pereyra gives advice that has since spread across the industry: "Don't build for the current capabilities of models today — build for where the models are going to be. Tackle more complex versions of problems so that when better versions of the models come out, they aren't solved as a side effect."
Result
To test the model, Harvey brought in attorneys from 10 of the largest law firms. They were shown side-by-side outputs of the custom case law model and GPT-4 for the same question. "97% of the time, the lawyers preferred the output from the case law model," says Weinberg. "Usually, it was because it was a longer, more complete answer. It went into the nuance of what the question was asking and covered more relevant case law." The strength of the reaction, the team admits, surprised them.
The second result concerns hallucinations — largely the reason the model was built: "Not only does the case law model not make up cases, but every sentence is actually supported with the case it's citing," Weinberg states.
Framing that matters. The 97% is a preference metric, not a measure of formal legal accuracy: it shows which answer lawyers choose, not how many errors it contains. The testing was organized by Harvey itself; the question sample size was not disclosed; no independent replication has been published; and the case study was published by OpenAI — an interested party whose product underpins the solution. The no-hallucinations claim is likewise a founder's statement, not the result of a published independent audit.
Editorial analysis. Indirect evidence that the custom-model bet paid off at least commercially is Harvey's trajectory after the case study: a $100M Series C at a $1.5B valuation (July 2024), $300M Series D at $3B (February 2025), $300M Series E at $5B (June 2025), $160M Series F at $8B (December 2025), and a $200M round at an $11B valuation in March 2026; 2025 revenue was $190M (Wikipedia, based on public disclosures). Customers include firms like Paul Weiss and A&O Shearman, where 3,500 lawyers ran about 40,000 queries during a trial period; Ashurst rolled Harvey out globally, Singapore's WongPartnership became the first Southeast Asian firm to test the product, and PwC adopted it for legal services in Singapore. In fairness: the company's growth does not isolate the custom model's contribution — Harvey grew across its whole product line, and an $11B valuation cannot be attributed to one technical decision.
A second observation: the case captured the "maturity ladder" of working with LLMs — prompting → RAG → fine-tuning → custom training — which later became industry common sense. It also shows how fast baselines age: "preferred over GPT-4 97% of the time" sounded strong in April 2024, but a comparison against a long-surpassed model says nothing by itself about where Harvey stands against today's frontier models.
Lessons learned
- RAG is not the ceiling: for open-ended expert tasks (finding arguments, not facts) Harvey hit retrieval's limits and moved to custom training — costlier, but a different quality level.
- An 'aha moment' is cheaper than a pilot: the test on 100 real r/legaladvice questions (86 answers attorneys would send unedited) cost almost nothing but gave the founders early proof of demand before the product existed.
- 97% preference is a strong but specific metric: it measures which answer lawyers choose, not formal correctness; when porting to your domain, plan a separate accuracy check.
- The anti-hallucination architecture — 'every sentence supported by the case it cites' — is a template for any zero-tolerance domain (medicine, compliance, finance).
- Test with the most demanding users: side-by-sides with attorneys from 10 top firms yield valid feedback and build future customers' trust at the same time.
- Starting with a narrow jurisdiction (Delaware) and expanding to the whole country is the right scaling ladder for custom models.
- Pereyra's advice — 'build for where the models are going to be, not where they are' — is a practical strategy against product obsolescence with every new model release.
Frequently asked questions
What does 'lawyers preferred the model 97% of the time' mean?
Harvey showed attorneys from 10 of the largest law firms side-by-side outputs of the custom model and GPT-4 for the same question. Lawyers picked the custom model's answer 97% of the time — usually for completeness and case law coverage. It is a preference metric, not a formal accuracy measure.
Does the Harvey model make up nonexistent court cases?
Per Harvey's co-founder in the OpenAI case study, the custom model does not make up cases, and every sentence is supported by the case it cites. Hallucination reduction was one of the main goals of custom training.
How does a custom-trained model differ from RAG?
RAG feeds retrieved documents into a stock model's context; custom training injects knowledge and reasoning patterns into the model itself. Harvey added the equivalent of 10 billion tokens of U.S. case law data because pure retrieval proved insufficient for finding legal arguments.
Who founded Harvey and when?
The company was founded in the summer of 2022. Co-founders: Winston Weinberg, an attorney with antitrust and securities litigation experience (per Wikipedia, previously at O'Melveny & Myers), and Gabe Pereyra, an AI researcher who, per OpenAI's case study, previously worked on LLMs at Google Brain and Meta.
What happened to Harvey after the case study?
Per Wikipedia, the company kept growing: a $100M Series C at $1.5B (July 2024), $300M Series D at $3B (February 2025), $300M Series E at $5B (June 2025), $160M Series F at $8B (December 2025), and a $200M round at $11B in March 2026; 2025 revenue was $190M.