automation lab / workflow 04

Gmail inbox classifier

A Gmail-led n8n workflow that reads incoming messages, extracts useful sender context, and routes each thread into a practical category.

What this demonstrates

Small language models can remove inbox triage work when the categories stay explicit.

The workflow separates extraction from classification, then uses deterministic Gmail actions to apply the final label.

The project

This workflow turns a busy inbox into a lightweight operating queue. Every new message is checked for a sender name, given a safe greeting fallback, and passed through a classifier with four defined outcomes.

The final branch maps each outcome to a Gmail label. The category list is deliberately narrow so the system remains legible, testable, and easy to adapt to another team’s inbox.

Workflow anatomy

01 / receive

Watch the inbox

Polls for new Gmail messages and passes the message content into the workflow.

02 / understand

Extract and classify

Finds the sender’s name, then assigns the message to one of four operational categories.

03 / route

Apply a label

Uses the category result to add the matching Gmail label to the original message thread.