How AVA processes a NYCSCA renewal from inbox to draft in under 5 minutes
The problem with renewal inboxes
A typical compliance coordinator's inbox on a Monday morning looks like this: 14 emails from NYCSCA, 6 from DOB, 3 from FDNY, all requiring action, all with different deadlines, all requiring you to cross-reference a license database you have open in another tab. This is the problem AVA was built to solve.
AVA doesn't just read the emails. It runs each one through an 8-stage pipeline that mirrors exactly what an experienced coordinator would do, but in under 5 minutes, with a full audit trail.
Stage 1 & 2: Inject & Read
When a new email arrives in the monitored Gmail inbox, a webhook fires and AVA creates a transaction record. The first job, ReadEmailJob, sends the raw email to Claude with a structured prompt asking for a plain-English summary, the action needed, the due date, and an urgency rating. The output is JSON: structured data that every downstream stage can use.
Stage 3: Classify
ClassifyEmailJob takes the read output and categorizes the email: renewal, new application, status inquiry, or not relevant. It also assigns priority (Low/Medium/High/Critical) and determines what type of response is needed. Emails that don't match any renewal pattern are marked as not relevant and no further AI runs.
Stage 4: Memory Lookup
MemoryLookupJob searches the tenant's client and asset records for the relevant entity, matching by license number, company name, or contact email. This is what allows AVA to say "this is John D. at Acme Corp, License #2847, renewal due August 15th" instead of treating every email as if it's the first time.
Stage 5 & 6: Log & Select Template
LogTransactionJob writes the renewal to the register. SelectTemplateJob picks the best-matching email template for this type of response, considering the agency, the category, and the tone setting the tenant configured.
Stage 7: Draft
DraftEmailJob is where the actual writing happens. It combines the read output, classification, memory data, and selected template into a single Claude prompt. The output is a complete email body, ready for human review. Nothing is sent at this stage.
Stage 8: Push to Gmail Draft
PushToGmailJob takes the draft and pushes it directly into Gmail Drafts via the Gmail API. The coordinator opens Gmail, sees a draft already written and addressed, reads it, makes any edits, and hits send. The whole pipeline, inbox to draft, takes between 90 seconds and 5 minutes depending on API response times.
The human gate
AVA never sends email. This is deliberate. Every draft requires your explicit approval. The pipeline surfaces the work; you make the call. This isn't a limitation, it's the design. Compliance work has consequences, and the human should always be in the loop on what goes out.