Item 02 / 04 · AI trust · LegalTech
Malakah Citations
Making a legal AI show its sources, down to the article.
Lawyers wouldn’t act on an AI answer they couldn’t check. I designed the system that lets every claim in Malakah’s answers open the exact article of Saudi law it came from.

Packing slip
- Role
- Product Designer at Stixor, for Malakah. Legal chat, legislation CMS and evaluation admin.
- Duration
- 2024 – 2026
- Team
- Lawyers, plus the internal content and AI team as users.
- Status
- Shipped
- Work
- 10 of 12
- would re-check an unsourced answer
- 1,000+
- legal professionals
01 · Problem
An answer you can’t check is a research task.
A lawyer is accountable for every piece of advice they give. Saudi law also changes, so “the law says” is only useful if you know which version said it.
The reframe: not “make the answer more accurate”, but “make every claim cheap to check”.

02 · Approach
A citation is only as good as the three layers under it.
A source link only works if the law is stored in pieces small enough to point at, and if retrieval reliably finds the right piece.
- Structure the law.A legislation CMS for the content team: chapters, parts, articles, annexes and amendments.
- Measure retrieval.An evaluation tool for the AI team: did the right articles come back, and in what order?
- Show the source.Legal chat for lawyers: each claim links to its article, which opens beside the answer.
03 · Solution
Four ways to show a source.
I judged every option by one question: how much work is left for the lawyer between reading a claim and trusting it?
- A link on every claim won.It opens the exact article beside the answer, with the cited text highlighted.
- Then, the version.A correct article in an outdated version is still wrong advice.

04 · Solution · Content
Making the law addressable.
You can only link to an article if the system knows where each article starts and ends. So the content team rebuilds each law as a tree before it’s published.
- Source priority.Tell “the law says” apart from “a guideline suggests”.
- A translation check next to Publish.An unchecked translation is the wrong text.

05 · Solution · Quality
Measuring whether the right article comes back.
A wrong article, shown with confidence, is worse than no citation. Teams upload test sets and compare runs by precision, recall, F1 and nDCG.
The citation a lawyer sees is the output of retrieval, so this was the most direct way to improve what they’d trust.

06 · Results
The claim-to-source pattern shipped.
The source opens as a third panel next to the chat and the contract, so a lawyer can check a claim while drafting without switching tools. Malakah serves 1,000+ legal professionals.

07 · Learnings
Trust is a path, not a badge.
Next, I’d test citation density on long answers, measured by time to verify.
- The visible pattern depends on invisible structure.The CMS and the evaluation tool are what made the citation link true.
- Design for the people behind the AI too.The content and AI teams were users of this system as much as the lawyers.