A guide to legal prompt engineering in 2024

AI
October 17, 2023
6
min
Legal prompt engineering enables lawyers to maximize the value they receive from AI tools. But what does it involve, and how can you get started?  

What is legal prompt engineering?

Legal prompt engineering is the process of carefully crafting and optimizing prompts for AI assistants to effectively address legal queries, provide accurate legal information, and assist in various legal tasks.

Legal prompt engineering involves learning how to ask the right questions and optimize your prompts to receive the best possible outputs. It requires individuals to test various terminology, phrases, and instructions to understand what works and what doesn’t. 

These insights are then used to engineer prompts that enable lawyers to automate their routine admin tasks safely and efficiently. Well-engineered prompts will result in more relevant and high-quality responses, enabling lawyers to gain the most value from the legal AI tools they have access to. 

Why is legal prompt engineering important?

Legal prompt engineering is important because it empowers lawyers to unlock more value from AI chatbots. This is because the quality of the outputs from AI tools like ChatGPT and Bard improve significantly when know how to ask the right questions in the right way. 

By including the right language and context in your prompt, you can enable AI assistants to predict responses with greater accuracy. This means that well-engineered prompts will eliminate the risk of the AI producing inaccurate or irrelevant answers

You can also use legal prompt engineering to refine the outputs you receive and understand which prompts produce more reliable results than others. This knowledge will empower lawyers to use tools like ChatGPT safely since they’re aware of where guardrails need to be set and how to use the AI assistant responsibly

What is a legal prompt engineer?

A legal prompt engineer is someone who is tasked with testing, optimizing, and evaluating ChatGPT prompts for lawyers. Their goal is to reduce the burden of time-intensive legal tasks and find ways to make legal automation more accessible by configuring the best prompts to use. 

While legal prompt engineer jobs are fairly new to the market, a handful of vendors and law firms already hiring them, including Mishcon de Reya, a law firm based in the UK.

When describing the job role on LinkedIn, Michcon de Reya said that legal prompt engineers will be expected to: 

Design and develop high-quality prompts for a range of legal and non-legal use cases, working closely alongside our data science team

They will also be responsible for evaluating and reviewing existing prompts, understanding use cases, and working with the wider team to ensure that AI usage remains both legal and ethical. 

With prompt engineer roles becoming topical in other industries, many legal teams will be wondering whether they need a legal prompt engineer in-house. Let's cover that question in more detail now.

Do you need a legal prompt engineer?

It’s true that well-engineered prompts will enable you to leverage AI more effectively. But do you really need to hire a prompt engineer to unlock these results from your legal AI assistants

Probably not.

Lawyers actually have a lot of the soft skills required to engineer prompts already, so there's rarely a need to hire someone else to take on this role.

For example, lawyers are often required to analyze information, solve problems and work closely with language. Lawyers that successfully apply these skills during the prompting process will already have more control over the quality of outputs.

Lawyers also have the legal expertise and experience required to understand what the tool needs to produce for it to be successful. This makes them well-placed to engineer their own prompts.

How to engineer prompts effectively as a lawyer

We recently covered some best practices for prompting in this guide to ChatGPT for lawyers. However, there are a few expert takeaways that can also be applied when prompting other AI assistants and chatbots. Let's explore these now.

1. Clearly define your objectives

Make sure you define exactly what you want to achieve in a clear and articulate way. Whether it's legal research, document drafting, or case analysis, a well-defined objective helps tailor your prompts appropriately.

For example, if you want to use contract AI tools to review or summarize a contract, be sure to provide these clear instructions.

2. Use precise language

Try to be specific in your prompts and either avoid or clarify any ambiguous language. Where possible, use legal terminology and language that aligns with the context of your task, ensuring the AI system understands the nuances and requirements involved.

Some AI assistants, like Juro, will even offer prompting shortcuts. This functionality enables you to use prompts that have already been fine-tuned and engineered to use the right language for a specific request.

For common use cases, Juro users can select one of the shortcut buttons instead of drafting the request themselves. This includes requests to make a contract mutual or create a contract summary, for example.

To find out more about Juro's AI Assistant and shortcuts, hit the button below for a personalized demo. Otherwise, keep reading for more tips on legal prompt engineering.

Want to save 90% of time on contracts?

Book a demo to find out how Juro is helping 6000+ companies to agree and manage contracts up to 10x faster than traditional tools.

Get a demo

3. Provide sufficient context

Be sure to provide the necessary context for the task, such as the legal issue, jurisdiction, relevant laws, or case details. The more context you provide in your prompt, the more relevant and accurate the response will be.

This is one of the most important rules of legal prompt engineering because law can differ a lot in different jurisdictions and on different facts.

4. Specify the format you want the output to take

If you have a specific format or structure in mind for the output (e.g., a memo, brief, or contract clause), make sure to mention it in your prompt. This guides the AI in generating content that fits the intended format.

I tend to prompt AI Assistant to structure its output in an email to the relevant leader. It's a great way of using AI to save yourself some time - Michael Haynes, General Counsel, Juro

5. Highlight key points

If there are specific points or arguments you want to emphasize, try to explicitly mention them in your prompt. This helps steer the AI's focus and ensure those aspects are addressed in enough detail. This is particularly important if you use long prompts with various focus areas and asks.

6. Practice, practice, practice

Remember that engineering a prompt takes practice. If the initial AI-generated response doesn't meet your expectations, iterate and refine your prompt. You can experiment with different phrasing, context, or instructions until you get close to the desired output.

7. Learn how to use AI responsibly

There are various risks associated with AI use, from concerns about confidentiality to hallucinations. To use AI safely and effectively, you need to understand what these are and how they apply to your prompts.

We’re keen to lean in and embrace the technology, but we need to do so in a transparent and respectful way -Caroline Iroegbu, General Counsel, Clarity

For example, you should avoid using prompts that include personal data when using certain AI platforms. This will eliminate the risk of that data being used to train LLMs in the future. You should familiarize yourself with the risks and put appropriate measures in place.

You can find out more about these issues and how you can safeguard against them in this guide to AI risks for lawyers.

Legal prompt engineering: how to get started

To summarize: legal prompt engineering can be an effective way to get maximize the value you gain from your AI tools. However, you don't need to hire a legal prompt engineer to unlock this value.

Instead, lawyers can learn to engineer their own prompts. One of the best ways to do this is through trial and error since it allows them to practice with their own use cases and parameters.

Lawyers can also complete courses on legal prompt engineering if they want to develop these skills in a more structured way.

Whichever approach they choose, lawyers should be excited about what the future holds, and the benefits of AI for lawyers.

It's likely that lots of legal professionals will be sharing their tips and use cases in the months to come, with AI presenting lawyers with an exciting opportunity to upskill.

Liked what you read? Stay in touch for all the latest insights.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.
To learn more about the use of your personal data, please consult our readable Privacy Policy

About the author

Juro knowledge team

The Juro knowledge team is an interdisciplinary group of Juro's brightest minds. Our knowledge team incorporates different perspectives from a range of knowledgeable stakeholders at Juro, including our legal engineers, customers success specialists, legal team, executive team and founders. This breadth and depth of knowledge means we can deliver high-quality, well-researched, and informed content, leaning on our internal subject matter experts and their unique experience in the process.

Juro's knowledge team is led by Tom Bangay, Sofia Tyson, and Katherine Bryant, but regularly features other contributors from across the business.

Instantly book a personalized demo

  • Schedule a live, interactive demo with a Juro specialist

  • See in-depth analysis of your contract process - and tailored solutions

  • Find out what all-in-one contract automation can do for your business

4.8
4.8

Schedule a demo

To learn more about the use of your personal data, please consult our readable Privacy Policy.

Your privacy at a glance

Hello. We are Juro Online Limited (known by humans as Juro). Here's a summary of how we protect your data and respect your privacy.

Read the full policy
(no legalese, we promise)

Don't waste your time on contract admin.

Most contract tasks don't require lawyers. Let your business self-serve on contracts from Juro, Slack, or integrated CRMs, then automate the contract lifecycle with AI.

Book a demo