Hey everyone ![]()
Small B2B teams lose a lot of leads simply because the first reply takes hours. I built a workflow to fix that and wanted to share how it works and what made it reliable.
The flow
- Form Trigger captures the lead: name, company, size, budget, timeline and message.
- Every submission is logged to Google Sheets.
- An AI Agent scores the lead 0–100 against your ideal customer profile and writes a one-line reason. A Structured Output Parser keeps the JSON clean, so the next nodes never break.
- A Switch routes the lead into Hot, Warm, Cold or Spam.
- Hot: the sales team gets an instant alert, and the lead gets a personal reply with a booking link.
Warm / Cold: a helpful reply with no hard sell.
Spam: no reply, just flagged in the sheet for review.
The AI writes the reply in the lead’s own language: English in, English out; Portuguese in, Portuguese out.
Test results
- 51–200 person company, budget set, wants to start this month → 95 / Hot. Reply sent in 12 seconds, plus a sales alert.
- Solo freelancer, “just researching” → 15 / Cold. Friendly tip, no pitch.
- Casino/pills spam → 0 / Spam. No email sent.
What made it reliable
- One “Business Settings” Set node. Your offer, ideal customer and booking link live there, and the prompt reads from it. You customize without touching the prompt.
- Two few-shot examples in the system message, one hot and one cold lead. Scoring became much more consistent after that.
- Low temperature (0.2) for scoring.
- Swappable chat model. It runs on Claude, Gemini or OpenAI: just replace the model node.
I also submitted a free, simpler version (scoring + auto-reply, no routing) to the n8n template library. It’s in review now, and I’ll drop the link here once it’s live.
If you’d rather import the full version with the setup guide, it’s here (code LAUNCH30 takes 30% off until Nov 4):
Happy to answer questions about the prompt, the parser setup or the routing!

