Speeding up legal research with an AI assistant

One of the hallmarks of the legal profession is that it has historically been very labour-intensive, with a great deal of time spent on manual tasks like document review, legal research and drafting.

 

Legal professionals must conduct comprehensive research when building their case.

 

Sifting through vast volumes of data and documents to find a single relevant clause or case can be an incredibly slow and tedious process.

 

We a looking at how we can build similar AI tools for other sectors, says IMDA’s Janet Chiew.
 

The process requires them to spend countless hours reading through lengthy judgments, each containing tens of thousands of words. And there are no shortcuts.

 

Fortunately, technology can help.

 

Artificial intelligence (AI), particularly large language models (LLMs), can be used to automate many of the repetitive text-heavy tasks that have traditionally consumed time in the legal profession.

 

It is with this premise that the Infocomm Media Development Authority of Singapore (IMDA) partnered with the Singapore Academy of Law (SAL) to create GPT-Legal, an LLM which makes legal research quicker and more efficient.

 

The LLM for the legal fraternity debuted at TechLaw.Fest 2024.

 

IMDA’s Deputy Director (Incubation), Janet Chiew, notes that around two out of every three judgments in Singapore are not summarised, and some of these judgments can span up to 100 pages.

 

The team behind GPT-Legal trained the model to provide legal summaries that use official legal terminology and follow the standard format in use by the Singapore legal fraternity, which consists of catchwords, facts, and holdings.

 

IMDA looks to tap the potential of generative AI (GenAI) to benefit Singapore’s text-heavy legal profession.

 

Speaking to GovInsider, Chiew says that the main objective is to make the legal sector “more efficient”.

Distinct blend of influences

 

She notes that Singapore’s legal system stands out for its distinctive blend of influences from multiple jurisdictions.

 

While it is fundamentally rooted in English common law, Singapore’s legal system incorporates elements from other jurisdictions, including the US and India.

 

“This unique legal landscape presents both opportunities and challenges for legal practitioners and technology developers. For AI models like GPT Legal to be effective, they must be intimately familiar with the specific terminologies, legal principles, and formatting conventions that arise from this complex mix of legal sources,” she adds.

 

To date, GPT-Legal has been used to generate summaries of over 15,000 court judgments, condensing 8,000-word judgments into concise 800-word summaries.

 

“These summaries follow the format and structure of ‘headnotes’, which are the official summaries of select judgments authored by Justices’ Law Clerks. The summaries can be found on SAL LawNet,” Chiew adds.

Overcoming hurdles

 

Chiew notes that a core part of GPT Legal’s vision is to foster trust and confidence among its users.

 

Talking about the hurdles the team overcame, she notes that data quality and model accuracy go hand-in-hand.

 

“If the system is trained but uses poor-quality data, users would get poor responses from the system. Gen AI systems are prone to hallucinations, so it is paramount that we figure out ways to mitigate this and assist users in detecting these as well,” she notes.

 

The challenge of GenAI hallucination was particularly critical in the legal domain, where accuracy is paramount. And the users in SAL need to identify hallucinations before the summaries are rolled out, Chiew adds.

 

One of the challenges centres around finding high-quality legal data due to the rarity of vetted, comprehensive legal documents.

 

The model also needs to contend with the risk of “catastrophic forgetting” during fine-tuning, where specialised training might cause the AI to lose previously learned knowledge.

 

Chiew says the team developed a comprehensive suite of safety features that work with the users.

 

“Our system shows users exactly where each summary paragraph originates through similarity highlighting. It also flags weakly substantiated paragraphs and potentially hallucinated entities,” she adds.

 

Most importantly, every summary must achieve a 90 per cent score when “we conduct automated and randomised fact-checking” before being presented to users.

 

To achieve this level of accuracy, the team invested heavily in Direct Preference Optimisation (DPO) – a technique to align AI with the legal professionals’ needs, Chiew shares.

 

“Legal professionals helped to ‘mark’ our system responses, and these markings are then used to align the model. This iterative process is crucial for aligning our AI with legal terminology and Singapore’s unique legal context. The support from SAL and the legal community has been amazing,” she adds.

Positive feedback

 

Chiew notes that there has been good feedback on the usefulness of the model. “We are glad that the summarisation model has managed to improve the productivity for this process,” she adds.  

 

She notes that the team is working to expand the capabilities to include features that would be useful for the legal fraternity, and “they will be publicly shared when ready”.

 

During an earlier presentation on GPT-Legal at GovInsider’s Festival of Innovation 2025, Chiew mentioned that the focus would be on collaborating with industry partners, small and medium enterprises (SMEs), and legal tech firms to develop transformative tools that can uplift job scopes and roles across different legal practice areas.

 

This includes potential applications in front-office technology, back-end services, and comprehensive support for lawyers in various legal domains.

 

The development roadmap prioritises continuous improvement of the model’s accuracy, context understanding, and safeguards, says Chiew.

 

IMDA plans to refine the model’s ability to handle large, complex legal documents while maintaining high standards of semantic accuracy and reducing hallucinations.

 

Summing up, Chiew says: “Now that we have gained experience creating AI solutions for the legal sector, we are excited to see how we can work with other sectors to build similar specialised AI tools to unlock greater possibilities.”

Continue Reading