Skip to content

ALPHAintelligenceBD/lawstatics-triage

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Lawstatics Triage

Voice + email triage agent for legal practices — automates first-contact handling of inbound legal inquiries via a voice assistant (VAPI-based) and an outreach wizard for follow-up email sequences.

License: MIT Status: Archived


What this is

Lawstatics was a productization attempt that spun out of Semantic Law Search (Corpus). Where Corpus was the platform lawyers use internally, Lawstatics was the customer-facing layer: a triage agent that handles inbound calls and emails from prospective clients before they reach a lawyer.

Two components:

  1. Voice agent (voice/) — Three iterations (V1.0.0, V1.0.1, V1.0.2). VAPI-based voice assistant that answers calls, captures intake details, and routes to the right practice area. Latest (V1.0.2) has a microservice architecture with separate apps, workers, and infra layers.
  2. Outreach wizard (outreach_wizard/) — Email outreach automation: lead enrichment, draft generation, SMTP sending, tracker. Used in the validation campaign described below.

Status

Archived March 2026. Single-developer project. Validation campaign concluded the moat was insufficient; pivoted away.

What was built

  • ✅ Voice agent V1.0.0, V1.0.1, V1.0.2 — full Next.js dashboards + Python backend + worker/infra split
  • ✅ Outreach wizard V2.0.0 — config-driven email pipeline (FastAPI + SMTP)
  • ✅ Lead enrichment + draft generation + tracker workflow
  • ✅ Onboarding packet documentation

What the validation campaign showed

The outreach wizard was used to send 48 cold emails to law firms in March 2026. Result: 0 replies. The user concluded the product wasn't a moat business and pivoted resources to other ventures.

The agent code itself works. The market response said the commercial wedge didn't.

What's not in this repo

  • The actual lead data, email drafts, and outreach tracker files (PII — kept private)
  • VAPI API keys and SMTP credentials (use .env.example if present, supply your own)

Quick start

This is archived code; verify dependencies before running.

Voice agent (V1.0.2 — latest)

cd voice/"Lawstatics Voice V1.0.2"
# See README.md inside that dir for setup
# Architecture: voice/Lawstatics Voice V1.0.2/architecture_v1_0_2.html

Outreach wizard

cd outreach_wizard
python -m venv .venv
source .venv/bin/activate  # or .venv\Scripts\activate on Windows
pip install -r requirements.txt
# Configure .env with SMTP credentials and CRM source
python app.py

Key decisions

1. VAPI for voice, not custom

The voice layer uses VAPI for telephony + LLM orchestration rather than building a Twilio + Whisper + LLM pipeline from scratch. Trade-off: faster to ship, less control over latency. For triage (where calls are short and structured), VAPI was the right call.

2. Email workflow is config-driven, not hardcoded

The outreach wizard's prompts, sender personas, and follow-up cadences live in config files, not in code. Reason: the validation hypothesis was "the right pitch matters" — config-driven means you can A/B-test pitches without redeploying.

3. Lead data is segregated from agent code

The wizard treats lead data as input only, never committed. The actual outreach campaign data (emails sent, replies received, tracker) is excluded from this repo by .gitignore. The agent code can run on any lead source.


Repository layout

lawstatics-triage/
├── voice/
│   ├── Lawstatics Voice V1.0.0/   First voice agent
│   ├── Lawstatics Voice V1.0.1/   Iteration
│   ├── Lawstatics Voice V1.0.2/   Final version (microservices)
│   └── LAWSTATICS_VOICE_ONBOARDING_PACKET.md
│
└── outreach_wizard/
    ├── app.py                      FastAPI entry point
    ├── config.py
    ├── db.py
    ├── email_sender.py             SMTP integration
    ├── prompts/                    Email draft templates
    ├── tests/
    ├── DEPLOYMENT.md
    ├── SMTP_PLAN_README.md
    ├── SYSTEM_ARCHITECTURE.html    System diagrams
    └── outreach-wizard-v2.0.0/     V2 codebase

Stack

Voice: VAPI (LLM voice orchestration), Next.js (dashboard), Python (workers), TypeScript Email: Python 3.11+, FastAPI, SMTP, SQLite Templates: HTML/Jinja for email drafts; YAML/JSON for prompt configs


License

MIT — see LICENSE.


Built by Jawad Bin Rashid. Sister project to Semantic Law Search.

About

Voice + email triage agent for legal practices: VAPI voice assistant + SMTP outreach wizard. Spinoff from Semantic Law Search.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors