Decentralize legal. Balance the power vacuum. Get this into the hands of the people.
The open framework for pro se litigants using AI to organize a case, draft motions, and verify citations before filing β without walking into the AI sanctions trap that's already snared multiple represented attorneys.
This is the open-source companion to CourtDocs.io (the hosted commercial version). Same verification protocol, two access points: run it yourself with any AI coding agent, or use the polished hosted product.
π The story behind it: STORY.md. The legal frame: DISCLAIMER.md. Read both.
Lawyers cost $300β$500/hour. Pro se litigants outnumber represented parties in family court, eviction court, small claims, and most state civil dockets. The system was built for represented parties; the procedural rules assume a lawyer on the other end.
AI changes the math β a motion that took a paralegal three hours costs minutes. But AI hallucinates: it generates fake cases, fabricated quotes, and overstated propositions, and it does so confidently. Pro se litigants who use AI without a verification system are walking into a sanctions trap.
This toolkit closes that gap. Not by being more careful β by making the failure mode structurally impossible.
| If you're worried about... | The toolkit gives you |
|---|---|
| AI fabricating a quote attributed to a real case | Mandatory source-text-and-hash verification before any cite goes in a filing |
| Citing a case that's been reversed | Layer 5+ subsequent-history workflow before any operative authority is filed |
| AI rubber-stamping its own verification | Blind cross-check protocol β independent session, no peeking |
| Disorganized files, missed deadlines | A drop-in case folder scaffold tuned for pro se work |
| Your court issuing an AI warning order | An incident response playbook for that exact scenario |
| Inconsistent agent behavior across sessions | A CLAUDE.md template that loads case context every session |
This is the Scrivener's Exception model in software: you select the document, you provide the facts, software formats and verifies, you review and sign. See DISCLAIMER.md for the legal frame.
Path A β You've used Claude Code, Cursor, or a terminal. Follow the 30-minute setup below. You'll have a working pro se case folder with verification gates by the end.
Path B β You've only used ChatGPT in a browser. The full toolkit's value requires Path A. Three options for you:
- Use the protocol manually. Read docs/CITATION_VERIFICATION_GATE.md and apply it as a paper checklist with whatever AI you already use. You won't get the scripts, but you get the most important thing.
- Use CourtDocs.io instead. Hosted, polished, no setup. Same verification protocol, point-and-click UI. Paid, but no install required.
- Get consulting help to set up Path A with someone walking you through it.
Don't bounce. The verification protocol is more important than which path you pick.
Realistic time: 30 min if you're comfortable with a terminal, 60β90 min if you're new to it. The CLAUDE.md customization is the longest single step.
- A working AI coding agent (Claude Code recommended; Codex / Cursor / Aider also work)
- Git installed
- Python 3.10+ (for the verification scripts)
- A free CourtListener API token β sign up at https://www.courtlistener.com/sign-in/
git clone https://github.com/Traviseric/pro-se-ai-toolkit.git
cd pro-se-ai-toolkitDISCLAIMER.md β non-negotiable. Five minutes. Read STORY.md and docs/CITATION_VERIFICATION_GATE.md when you have time, but those aren't blockers to setup.
The case folder will contain private content. Don't put it inside this repo.
# Mac/Linux
cp -r case-template ~/MyCase
# Windows (PowerShell)
Copy-Item -Recurse case-template C:\MyCaseOpen case-template/CLAUDE.md.template β your starting point. Fill in:
- Your case caption (number, court, parties, judge / magistrate)
- Your jurisdiction's procedural rules
- Key deadlines (convert relative dates to absolute
YYYY-MM-DD) - Your one-paragraph theory of the case
This file is your AI agent's memory. Every session reads it. Done well, the agent won't ask you basic case questions every time.
# Mac/Linux
export COURTLISTENER_TOKEN='your-token-here'
# Windows (PowerShell, persistent across sessions)
[System.Environment]::SetEnvironmentVariable('COURTLISTENER_TOKEN', 'your-token-here', 'User')Verify with python scripts/fetch_case_text.py "410 U.S. 113". You should get back the text of Roe v. Wade. If you don't, see docs/COURTLISTENER_API_PATTERN.md.
If your agent setup feels rough β context times slow, agent ignoring conventions β start at the sister repo: github.com/Traviseric/best-practices. Tool-agnostic foundations (CLAUDE.md, pre-commit gates, MCP optimization). Skip if your setup already works.
cd ~/MyCase
claude # or: codex / cursor / aiderAsk it: "What case are we working on? What's the current focus?" The agent should answer from your CLAUDE.md. If not, the file isn't loading β check the path.
You're ready. Draft your first motion using the verification gate and the pre-filing checklist.
pro-se-ai-toolkit/
βββ README.md # You are here
βββ DISCLAIMER.md # The legal frame β Scrivener's Exception model
βββ STORY.md # Why this exists
βββ QUICKSTART.md # Setup walkthrough (deeper than the 30-min above)
βββ CLAUDE.md # Pin for agents working on this repo
βββ LICENSE # MIT
βββ docs/
β βββ CITATION_VERIFICATION_GATE.md # The core process
β βββ CITATION_ERROR_TAXONOMY.md # Four classes of AI citation errors
β βββ COURTLISTENER_API_PATTERN.md # Working API integration with token auth
β βββ SUBSEQUENT_HISTORY_CHECK.md # Layer 5+ good-law verification
β βββ BLIND_CROSS_CHECK_PROTOCOL.md # Independent verification for high-stakes filings
β βββ RECTIFICATION_PROTOCOL.md # When you find a defect in something already filed
β βββ PRE_FILING_CHECKLIST.md # Pre-flight for every filing
β βββ AI_WARNING_INCIDENT_RESPONSE.md # If your court issues an AI warning order
β βββ SETTING_UP_YOUR_AGENT.md # Links the foundational agent setup
βββ templates/ # Per-filing artifacts
β βββ CITATION_VERIFICATION_REPORT.md
β βββ RECTIFICATION_PLAN.md
β βββ citation_manifest.csv
β βββ fact_claim_manifest.csv
βββ case-template/ # Drop-in scaffold for a new case
β βββ README.md.template
β βββ CLAUDE.md.template
β βββ .claudeignore
β βββ 1_FILED/ 2_MOTIONS/ 3_EXHIBITS/
β βββ _CITATION_SOURCES/ # Verification system, seeded
β βββ deadlines/
βββ scripts/
βββ fetch_case_text.py # CourtListener case fetcher
βββ extract_citations.py # Pull citations from a draft
βββ run_pre_filing_gate.ps1 # Mechanical pre-flight check
If you remember nothing else from this repo, remember this:
No motion gets filed unless every legal citation and every material factual assertion has (1) a saved source file in the filing's
_CITATION_SOURCES/folder, (2) a SHA-256 hash of that source recorded in the manifest, and (3) a completed verification report comparing the filing's claims against the saved source.
The shortcut β "the case exists, so the citation is fine" β is what gets pro se litigants sanctioned. Real cases get cited for fake quotes. Real cases get cited for propositions they don't actually support. The only defense is comparing the filing against the actual source, locally, before the filing leaves your computer.
Full process: docs/CITATION_VERIFICATION_GATE.md.
Open your AI agent in any case folder and paste:
Read the citation verification gate at:
https://raw.githubusercontent.com/Traviseric/pro-se-ai-toolkit/main/docs/CITATION_VERIFICATION_GATE.md
Then audit THIS case folder against the protocol. Check:
1. CLAUDE.md β exists? case caption complete? verification rules referenced?
2. Folder structure β _CITATION_SOURCES per filing? saved_sources populated?
3. Manifests β citation_manifest.csv and fact_claim_manifest.csv per filing?
4. Reports β CITATION_VERIFICATION_REPORT.md complete for every filed paper?
5. Any cite without a saved source and SHA-256 hash?
Give me a scorecard (1β10 per area) and specific recommendations.
The audit prompt itself is a copy of the protocol β your AI is auditing the case against the same standard you'll use to file new motions.
| Need | Resource |
|---|---|
| Hosted, polished version with UI | CourtDocs.io β paid skill packs for motions, exhibits, family court, small claims, financial forensics |
| Set up the toolkit with help | Travis Eric β Consulting |
| Foundational AI agent setup | github.com/Traviseric/best-practices β tool-agnostic principles for CLAUDE.md, pre-commit gates, MCP optimization |
| Community | AI Builders Lab on Skool (general AI development; not legal-specific) |
PRs welcome β especially:
- Jurisdiction-specific adapters (state-by-state procedural rule cheat sheets)
- Working API patterns for other free legal research tools (Justia, Caselaw Access Project, Google Scholar)
- Template improvements based on real use
- Failure-mode case studies β anonymized stories of AI verification breakdowns and how to prevent them
What I won't merge:
- Anything that frames the toolkit as legal advice
- Anything that lowers the verification bar (e.g., "skip the SHA-256 step, the URL is fine")
- Anything jurisdiction-specific without a clear "for this jurisdiction only" label
MIT. Use freely. Not legal advice. See DISCLAIMER.md.