Routine legal documents — NDAs, service agreements, DPAs, HIPAA BAAs, licensing — are template-driven but still leave people unsure which document they need and how to complete it correctly. Slow, error-prone, and not worth a lawyer's hourly rate for standard agreements.
AI Legal Document Builder
PreLegal
A SaaS document builder for routine legal agreements — NDAs, service contracts, GDPR DPAs, HIPAA BAAs, licensing, and more — where an AI assistant guides the user to the right document, fills the fields via structured generation, and outputs a finished PDF.
Problem, approach, result
Built a SaaS document builder with a catalog of eleven agreement types spanning confidentiality, commercial services, data-protection compliance (GDPR DPA, HIPAA BAA), IP and licensing, and an AI-specific addendum. An AI assistant helps the user choose the right document and walks them through the fields, then an LLM with Structured Outputs populates the template, renders a live preview, and produces a downloadable PDF.
A working multi-document legal-drafting product covering regulated domains end to end — catalog-driven, AI-guided selection, structured generation mapped to real contract fields, and a finished PDF deliverable. Proves the pattern that turns an LLM from "answers questions" into "produces usable legal work."
What it can produce
- Mutual NDA
- Cloud Service Agreement
- Data Processing Agreement (GDPR)
- Professional Services Agreement
- Service Level Agreement
- Design Partner Agreement
- Partnership Agreement
- Pilot Agreement
- Business Associate Agreement (HIPAA)
- Software License Agreement
- AI-Specific Addendum
Built with
- FastAPI
- Docker
- SQLite
- OpenAI Structured Outputs (gpt-4.1)
- PDF generation
- Authentication
How it was built
Built via an agentic coding workflow — features specced in Jira, developed through a 7-step process with unit and integration tests, and shipped via GitHub PRs.