GIVENALITY wires Mike into Tanzanian statute law

A Dar es Salaam-flavoured fork pipes a local legal corpus directly into every chat and contract review.

contract-reviewsearch

GIVENALITY has hooked Mike up to Leksa, an external retrieval service that searches Tanzanian statutes and case law, and feeds the most relevant passages straight into the model's prompt before it answers. Project chat gets the treatment, but so does the tabular contract review pipeline - every column of a contract analysis now lands on top of fresh statutory context.

The team has gone further than plumbing. The analyst persona has been rewritten to specialise in Tanzanian law, the verdict language shifts from "favorable / standard" to "compliant / non-compliant", and reviewers are now required to cite the page and quote the statute they're relying on. Four ready-made review templates ship in the box - employment contracts, share purchase agreements, loan agreements and court pleadings - each pre-loaded with the specific Tanzanian acts a local lawyer would actually reach for.

It's one of the clearer pictures yet of what a single-jurisdiction Mike looks like in production.

So what Anyone building Mike for a specific country's law should study this fork before reinventing the retrieval layer.

View this fork on GitHub →

Spotted something wrong? Or know the PR text has fresher detail than the writeup above?

Commits in this thread

2 commits from GIVENALITY/mike, oldest first. Source extracted verbatim from the harvested git log.

SHA Subject Author Date
0c2eb990 Integrate Leksa RAG for Tanzanian legal context in project chat GIVENALITY 2026-05-14 ↗ GitHub
commit body
Adds fetchLegalContext() to projectChat.ts - on each project chat turn,
queries the Leksa /rag/retrieve endpoint (hybrid pgvector + FTS search
over Tanzanian statutes and case law) and injects the top-k results into
the system prompt. Degrades silently if LEKSA_RAG_URL is unset or the
service is unreachable.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
d5b14f75 Add Leksa RAG legal context injection into tabular review extraction GIVENALITY 2026-05-14 ↗ GitHub
commit body
- Extract fetchLegalContext into shared lib/leksaRag.ts (used by both
  projectChat and tabular routes)
- Inject Tanzanian legal context into queryTabularAllColumns and
  queryTabularCell so the LLM can flag clauses as compliant/non-compliant
  against actual Tanzanian law (not just extract text)
- Extend inline citation requirement to all column formats (was only
  yes_no/date/tag; now text and bulleted_list also require citations)
- Add seedWorkflows.ts script: seeds 4 system tabular review workflows
  for Employment, SPA, Loan Agreement, and Court Pleading review

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

Capture this thread into my fork

Download a single Markdown prompt that tells Claude how to port every commit above into your working tree — adapting paths and structure to match your repo. Run it via claude -p < capture-thread-432.md from inside the repo you want the changes in.

⬇ Download capture-thread-432.md