AI Email Automation hero

AI Email Automation

An AI agent that reads inbound emails, pulls context from a knowledge base, and drafts replies for review — cutting inbox management from hours to minutes.

Client Overview

Early-Stage B2B SaaS Founder

B2B public safety SaaS selling to law enforcement agencies. Founder-led sales motion, the founder owned every campaign reply with no budget for a dedicated email rep at this stage.

The Problem

Outbound campaigns generated more reply volume than one person could keep up with. Every inbound reply routed to the founder regardless of intent, each one written from scratch with no template system. Product knowledge and objection handling lived in Google Drive and never made it into replies. Campaign cadence had to stay artificially low because more outreach meant more manual work.

What We Did

We built an n8n pipeline that watches the inbox, classifies each reply by intent, and retrieves the right context from a vector store of internal Drive docs before writing a draft. Meeting requests get real calendar availability pulled in automatically. The founder gets a ready-to-review draft sitting in Gmail on the original thread, same inbox, no new tools, final send stays with him.

The Solution

Intent-routed RAG draft engine writing directly into Gmail. The system classifies each reply as an objection, meeting request, question, or out-of-office before retrieval so the right context is pulled every time. Drafts are grounded in the actual product knowledge base, not guessed, no hallucinated claims, no generic responses. The Drive ingestion pipeline keeps the vector store current automatically.

Tech Stack

n8n orchestrates two workflows: reply pipeline and document ingestion. Everything else is a signal source, retrieval layer, or output target.

n8n

Orchestration — reply pipeline and Drive ingestion workflow

OpenAI API

Intent classifier and draft generator

Gmail API

Inbox trigger and draft creation on the original thread

Google Calendar

Real-time availability lookup for meeting-request drafts

Google Drive

Source of truth — docs ingested and re-indexed on change

Supabase + PGVector

Vector store for semantic retrieval and run tracking

Project Walkthrough