I developed an AI-powered lead outreach automation system using Langgraph that integrates with HubSpot and LinkedIn to streamline lead research and outreach. This project includes monitoring Hubspot contacts list, automated lead research, lead scoring, identification of company pain points, and personalized communication via email, video, and call scripts.
- Integrate with HubSpot CRM to fetch new leads and record contacts updates.
- Research leads on LinkedIn and score them based on specified business rules.
- Identify key pain points and generate personalized outreach materials.
- Create customized emails, videos, and call scripts to engage leads effectively.
- Monitor HubSpot CRM: Continuously fetch new leads added into your contacts list.
- Lead and Company Research: Scrape LinkedIn for lead and company information, and gather current open positions by scraping the company's website for deeper insights into their needs.
- Pain Point Identification: Detect company challenges that align with provided services for more impactful communication.
- Automated Lead Scoring: Assess and rank leads based on predefined criteria to prioritize high-value prospects.
- Categorize Leads: Categorize leads into qualified or not qualified based on the lead score, and update HubSpot CRM accordingly.
- Personalized Outreach: Generate tailored emails, videos, and call scripts to engage qualified leads with relevant solutions and content.
This is the detailed flow of the system:
- HubSpot CRM: To integrate with your HubSpot contacts CRM, you must sign up for a HubSpot account, then create a private app and get your API key. Follow this quick tutorial.
- LinkedIn Data: Scrape profile information using the RapidAPI LinkedIn Profile Data API. Get your API key here.
- Google Searches: Perform web searches with the Serper API. Get your API key here.
- Content Generation: Use Groq for LLAMA3.1 and LLAMA3 models. Get your API key here.
- Enhanced Personalization: Improve the system by expanding the dataset of personalized outreach materials and implementing a continuous feedback loop to refine content generation.
- Langgraph: Utilized for building the AI automation workflow.
- Litellm: Used for connecting and leveraging multiple large language models (LLMs) such as GPT-4, LLAMA3, LLAMA3.1,...
- HubSpot Python API: Implemented for interacting with the HubSpot private app.
- Python 3.9+
- API keys for RapidAPI (LinkedIn see), Serper, HubSpot (private app), and Groq
- Necessary Python libraries (listed in
requirements.txt
)
-
Clone the repository:
git clone https://github.com/AIXerum/AI-Sales-Outreach-Langgraph.git cd AI-Sales-Outreach-Langgraph
-
Create and activate a virtual environment:
python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`
-
Install the required packages:
pip install -r requirements.txt
-
Set up environment variables:
Create a
.env
file in the root directory and add your API keys:RAPIDAPI_KEY=your_rapidapi_key SERPER_API_KEY=your_serper_api_key GROQ_API_KEY=your_groq_api_key HUBSPOT_API_KEY=your_hubspot_api_key
-
Start the automation:
python main.py
The application will connect with your HubSpot CRM to fetch all the new leads, analyze, research, and score them, and generate personalized outreach materials for the qualified leads.
To customize the scoring rules or outreach templates, edit the relevant configuration file in src/prompts
.