How Natural Language Processing Can Improve Legal Search Results


Written by: Alison Wilkinson
Legally Reviewed by: Jennifer Tsai and David Curle

July 22, 2020

7 minute read

Legal research lies at the heart of the legal profession. Any legal advice attorneys provide has to stay in line with constitutional, statutory (as created by legislators), and case law (as created by judges). For instance, when including a non-compete in an employment contract, the drafter would need to understand how restrictive it can be. If the non-compete period is too short, it will not provide the client with the assurances they may need; too long, and the entire clause may be deemed unenforceable in a court of law.

While online legal databases have been available for more than a decade, natural language processing (NLP) can help streamline the research process. Read on to learn more about traditional legal research and how NLP can positively impact legal search results.

Every budding lawyer has learned how to search online databases. These legal research skills need to be taught because they are not intuitive. Let’s refer back to the above non-compete clause example. Say an attorney needed to find out how long a non-compete period could be before a court would find the clause too restrictive. Under traditional research methods, they would have to craft a search query like “noncompete/s (restrictive or illegal)/s long.” This search may or may not yield complete results. For instance, if a court found that the non-compete was “onerous” rather than “restrictive,” this case would not be included in the search results. If the decision referred to the clause as a “non-compete” rather than a noncompete, the case also may not be included in the results. This search is also likely to pull far more cases than are relevant. For instance, this query could list a case that said “Restrictive noncompete agreements have long been a staple of employment agreements” — and likely hundreds more. This means more cases to sift through, at the cost of lawyer time and client money.

The over- and under-inclusive nature of this traditional method of legal research is a time waster for lawyers and a concern for cost-savvy clients. Lawyers also run the risk of missing the crucial cases they need to find in order to provide sound legal advice.

What is NLP and How Does It Work?

NLP uses artificial intelligence to streamline the research process and prevent many of the pitfalls of traditional legal research. AI and legal research are big business. The global NLP market size is expected to grow from $10.2 billion in 2019 to $26.4 billion in 2024. That’s an average annual growth of 21 percent per year for this five-year period.

NLP works by learning human language, using context and prior queries and results to predict what attorneys need in their searches. One clearcut example of NLP is the use of Google searching. For instance, if a user starts typing “restaurant,” Google may automatically suggest “restaurants near me.” The more the user searches Google, the more Google can predict what the user is looking for when they type “Resta….” Similarly, if the user misspells “restaurants near me,” Google will recognize the misspelling and provide the correct search results. The same is true for AI in legal research. Similar to Google, NLP improves legal search results as lawyers use online research tools. Here are some ways AI legal research streamlines and simplifies legal research.

As discussed above, in traditional online legal research, the failure to craft a sufficiently precise string of search terms is crucial to getting the right information. However, this method of legal research is certain to return too many irrelevant cases and means relevant cases may be missed.

Using AI legal research, attorneys can frame their queries as they would to a colleague using natural language. Instead of typing in “noncompete /s (restrictive or illegal) /s long,” a person could type “What is the time limit on non-competes in New Jersey?” Based on the context of the query and thousands of other related queries, the program would make predictions as to what exactly the attorney wants to find, suggesting keywords to fill out the search (for example, adding in “onerous” and “non-compete”).

The program continues to learn based on what cases are clicked on and reviewed. If it sees that all the cases using the phrase “have long been,” are ignored, it will narrow the search results, putting less emphasis on those terms.

NLP Can Find Information Relevant to How a Court May Rule

NLP and machine learning can also provide predictive models to help better understand how a given judge or court may rule. For instance, a study from 2016 found that by using NLP and machine learning, researchers could predict with 79 percent accuracy how the European Court of Human Rights would rule on a given case.

Having an understanding of how a court will likely rule can help attorneys better tailor their arguments to support or combat the prediction. This happens all the time when trying to appeal to the median justice on the Supreme Court, who will likely be the swing voter. Legal professionals can do this work themselves with the Supreme Court, where the body of law for any particular judge on any particular topic is relatively small and AI assistance isn’t always necessary. But that’s not always the case. When turning to a lower court in New York, for instance, where a judge may have thousands of decisions, the use of technology helps to quickly streamline and identify the relevant cases for analysis.

NLP can analyze the decisions of any given judge or court in seconds, providing a takeaway on the issues that will likely be determinative. For instance, referring back to the non-compete example again, an attorney may find that the judge who will rule on the case is highly moved by evidence that the parties were in equal bargaining positions, even if the noncompete is somewhat lengthy. The attorney could then structure their argument around what the judge will find most persuasive, emphasizing the parties’ equal bargaining power.

NLP Can Reveal Where Specific Phrases Appear in a Lengthy Document

NLP also saves time for legal researchers by pinpointing and directing the researcher to where specific phrases appear in lengthy court decisions, or where parts of a search query appears in relation to other terms. This means attorneys can quickly decide which cases are not relevant and move on to the next case, or dig in deeper on the cases whose search terms better match the desired search parameters.

NLP Can Offer Visualizations to Help Users Better Understand Results

For more visual learners, NLP can also array search results visually. Visual data can help users identify patterns and relationships that may otherwise be obscured by the traditional list-form of search results.

For instance, one program uses circles to represent various cases, with the circles displayed along a graph. The Y-axis of the graph is divided into sections to show the jurisdiction (higher courts on top, lower courts on the bottom), and arranged chronologically along the X-axis. The larger the circle, the more frequently that case has been cited; the higher up the circle appears, the more likely that case is to be relevant.

Different programs employ different visualization techniques, but whatever way it’s presented, this is an exciting new development in AI legal research.

How AI Research Benefits Attorneys and Clients

As the above points make clear, NLP has dramatically improved legal research. It allows attorneys to find relevant law faster, which saves time and money. This translates into very real benefits for attorneys and their clients.

One study by the National Legal Research Group, Inc. found that AI tools allowed expert legal researchers to finish their research 24.5 percent faster than when using traditional legal research, amounting to between 132 and 210 hours saved per year. These extra hours can be spent on drafting, revision, and higher-level case management — tasks that computers cannot complete.

Attorneys working smarter and more efficiently positively impacts their clients, too. AI legal research allows attorneys to provide their clients with work products that are more accurate and completed more quickly, without a corresponding increase in legal costs.

Articulating the need for innovative investments can be challenging. Take a deep dive into how this can easily be done by presenting quantifiable outcomes.

Read the whitepaper