Document intake
Every page gets a name and a row before it gets read. Filing first is what makes a 40-page notice survivable.
The tool
bots/ssi/scripts/casefile.py does the filing, the calendar, and the form filling:
bashpython bots/ssi/scripts/casefile.py init <initials> python bots/ssi/scripts/casefile.py intake <initials> scan.pdf \ --source ssa --doctype notice --date 2026-10-02 \ --case-no TX-999 --ask "Return form 827" --due 2026-11-20 python bots/ssi/scripts/casefile.py deadlines <initials> --days 10 python bots/ssi/scripts/casefile.py review <initials> --form SSA-827 --facts facts.json python bots/ssi/scripts/casefile.py fill blank-form.pdf facts.json filled.pdf
facts.json maps each field to {"value": ..., "source": "path"}. A field with no
value or no source is left blank and reported as [[CONFIRM: field]] — the tool
will not put an unverified number on a benefits form.
Procedure
- Scan 300 dpi, grayscale, PDF with a text layer (OCR at scan time if the
scanner supports it; otherwise
ocrmypdf --skip-text in.pdf out.pdf). - Name immediately:
YYYY-MM-DD_<ssa|hhsc|school|medical>_<doctype>_<initials>.pdf. Unknown date → use the postmark date, never today's date. - Extract the ask into
cases/<initials>/intake.md:- Who sent it (agency, office, address)
- What they want (documents, interview, form, payment)
- Due date, verbatim
- Consequence of missing it, verbatim
- Any case/reference number
- Update two tables:
_programs.md(status changed?) and_deadlines.md(new dated obligation). If neither changes, writeno actionin the timeline. - Flag urgency: hearing notice, denial with appeal rights, or a 10-day deadline → top of the deadline table and an immediate injection line.
- Never discard the original. The scan is a copy; the paper stays in a physical folder labeled with the same date.
Rules
- Never retype a number from a scan without confirming it twice — account and case numbers are the #1 source of mis-filed paperwork.
- Never summarize a denial into "denied". Copy the stated reason verbatim; the reason determines the appeal.


