Quick overview
This template learns lead-fit signals from past customers in Google Sheets by scraping their homepages with Apify and generating yes/no qualification questions with Google Gemini, then scores new inbound leads with TypeSafe and alerts your sales team in Slack when they meet a fit threshold.
How it works
- Manually starts the training run to pull past leads and their Converted status from Google Sheets.
- Scrapes each lead’s homepage using the Apify Website Content Crawler and groups the results into converted vs not-converted examples.
- Sends the labeled homepage content to Google Gemini to generate an ICP summary and 4–8 homepage-based yes/no qualification questions.
- Saves the generated question set and summary to the Google Sheets Questions tab.
- Receives a new lead’s domain via a webhook, normalizes it into a full website URL, and fetches the homepage content via Apify Web Fetch.
- Loads the latest saved question set from Google Sheets and uses TypeSafe to score how well the new homepage matches each question.
- Posts the lead and fit scores to Slack when the qualified score is 0.7 or higher.
Setup
- Create a Google Sheet with a Leads tab (at minimum: Website, Converted with Yes/No values) and a Questions tab (generated_at, questions_json, summary), then paste your spreadsheet ID into all Google Sheets nodes.
- Add credentials for Google Sheets, Apify, Google Gemini (PaLM/Gemini API), TypeSafe, and Slack, and select a Slack channel for notifications.
- Run the manual training path once to generate and store the latest question set in the Questions tab.
- Copy the webhook URL for the qualify-lead endpoint and send requests with a domain parameter (query or body) to score new inbound leads.
Requirements
- Apify Account, Jev and Gemini credit (you can shift to other models to fit your subscription).
Customization
- Change the 0.7 threshold in Is qualified?, route alerts to your CRM instead of Slack, or rerun the manual trigger after new deals close.
- You can change the LLM model used to fit your subscription.
- Change Slack notifcation to any channel your sales team prefer.