Skip to content

Improve Lead Discovery and Email Quality Pipeline #26

@armaan-71

Description

@armaan-71

Problem

The current pipeline passes raw Google Search results directly to the LLM
for email generation. This produces low-quality leads (blog posts, listicles)
and generic-sounding emails because the LLM only has a 2-line search snippet
as context.

Proposed Solution

Introduce a multi-stage enrichment pipeline:

  1. Smart query rewriting — LLM rewrites user queries and selects the
    right SerpApi engine (google vs google_maps) based on query intent
  2. Result filtering — LLM classifies results and removes non-company
    pages (blogs, directories) before processing
  3. Website scraping — Fetch actual company websites to extract real
    content for the LLM
  4. Improved email generation — Use full website context instead of
    search snippets for personalized, higher-quality outreach

Sub-Issues

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions