LeadScope is a Streamlit dashboard that searches public data sources to find potential B2B prospects β wedding photographers, makeup artists, fitness coaches, real estate agents, and any other local sector β and turns them into a structured, tagged, exportable lead table.
Everything is based on publicly available information. No Instagram scraping, no private APIs, no shady data sources.
LeadScope uses DuckDuckGo as its default search engine.
| Search Backend | Cost | API Key Required? | How to Enable |
|---|---|---|---|
| DuckDuckGo (default) | Free | β No | Works out of the box |
| SerpAPI | Free tier (100/mo) | β Yes β sign up | Paste key in sidebar |
| Google Custom Search | Free tier (100/day) | β Yes β get key | Paste key + CX in sidebar |
Just install and run β no accounts, no credit cards, no setup beyond Python.
| Dashboard | Tagging |
|---|---|
| Dark glassmorphism UI with metrics and sortable lead table | Tag leads Hot/Warm/Skip with notes, export to CSV |
- Python 3.10 or higher
- Git (for cloning)
git clone https://github.com/KernelLex/scrapperv2.git
cd scrapperv2# Windows
python -m venv .venv
.venv\Scripts\activate
# macOS / Linux
python -m venv .venv
source .venv/bin/activatepip install -r requirements.txtcopy .env.example .env # Windows
cp .env.example .env # macOS / LinuxEdit .env if you want to boost your quota with SerpAPI or Google CSE.
Leave it blank to use DuckDuckGo for free.
streamlit run app.pyOpen http://localhost:8501 in your browser. That's it! π
- Enter a City β e.g.
Bangalore,Mumbai,Delhi - Enter a Sector β e.g.
wedding photographers,bridal makeup artists,fitness coaches - Adjust Filters (optional):
- Max results
- Must have Instagram
- Must have phone or email
- Weak digital presence only
- Follower range (for Instagram leads)
- Fetch landing pages (richer data, slower)
- Click π Find Leads
- Browse the Results tab β sort by Quality Score or DP Score
- Switch to π·οΈ Tag Leads β mark prospects as Hot / Warm / Skip
- Export CSV anytime for your CRM or outreach tool
scrapperv2/
βββ app.py # Streamlit dashboard β UI, pipeline orchestration, tabs
βββ search.py # Search backends: DuckDuckGo (free), SerpAPI, Google CSE
βββ extractor.py # BeautifulSoup page fetch + phone/email/Instagram extraction
βββ scoring.py # Digital presence score + lead quality score + filters
βββ database.py # SQLite: sessions + leads (upsert, tag, delete)
βββ utils.py # Rate limiter, dedup fingerprint, phone/email/URL helpers
βββ requirements.txt
βββ .env.example # Copy to .env β all keys are optional
βββ README.md
[Sidebar Input]
city + sector + filters
β
βΌ
[search.py] run_searches()
β 8 varied query templates per search run
β Auto-selects: SerpAPI β Google CSE β DuckDuckGo (free)
β Rate limited (1.5 s between DuckDuckGo calls)
β
βΌ
[extractor.py] extract_leads()
β Regex parse of snippet: phones, emails, Instagram URLs
β Optional: fetch landing page with requests + BeautifulSoup
β Heuristic name extraction from page title
β
βΌ
[utils.py] deduplicate_leads()
β MD5 fingerprint on name + city + instagram_url
β
βΌ
[scoring.py] score_leads() β apply_filters()
β digital_presence_score (higher = weaker online presence)
β lead_quality_score (higher = more contact info)
β
βΌ
[database.py] save_leads()
β SQLite upsert β INSERT OR IGNORE by fingerprint
β Session tracking
β
βΌ
[app.py] Results tab
β Sortable, paginated dataframe with clickable links
β 4 summary metric cards
β Score distribution charts
β CSV export
β Tagging workflow (Hot / Warm / Skip + notes)
| Signal | Points |
|---|---|
| No website found | +3 |
| Only Linktree / bio link page | +2 |
| Simple page-builder website (Wix, Carrd, etc.) | +2 |
| WhatsApp-only contact (no email) | +1 |
| No email AND no phone | +2 |
| Strong professional website + full contact info | β5 |
| Signal | Points |
|---|---|
| Has Instagram URL | +2 |
| Has phone / WhatsApp | +2 |
| Has email | +2 |
| Has website | +1 |
| Has both phone AND email | +3 (bonus) |
| DP score β₯ 5 (weak presence = sales opportunity) | +2 (bonus) |
| No contact info at all | β1 |
| DP Score | Meaning |
|---|---|
| 7+ | Very weak online presence β prime opportunity |
| 4β6 | Some gaps β could benefit from services |
| 0β3 | Reasonably established digital presence |
| Quality Score | Meaning |
|---|---|
| 8+ | Excellent β multiple contact channels |
| 4β7 | Good β some contact info available |
| 0β3 | Limited β minimal actionable data |
All settings are optional. Copy .env.example to .env and edit:
# Option A β SerpAPI (100 free searches/month)
SERPAPI_KEY=your_key_here
# Option B β Google Custom Search Engine
GCSE_API_KEY=your_google_api_key
GCSE_CX=your_search_engine_id
# Phone number parsing region (default: India)
DEFAULT_PHONE_REGION=IN
# SQLite database path
DB_PATH=leads.db| Problem | Solution |
|---|---|
| Zero results from DuckDuckGo | DDG may be rate-limiting β wait 30 s and retry |
duckduckgo_search import error |
Run pip install duckduckgo-search |
| Slow with "Fetch landing pages" | Toggle it off for faster (shallower) results |
| Phone numbers not found | Check DEFAULT_PHONE_REGION in .env |
| Duplicate leads appearing | They're deduplicated by fingerprint; re-run clears cache |
| Streamlit won't start | Ensure you're in the venv: .venv\Scripts\activate |
- β Only publicly listed information is collected
- β No Instagram private API, no account login, no scraping of follower lists
- β Polite rate-limiting between all HTTP requests
- β Intended for manual, personalised B2B outreach β not bulk spam
- β
Respects the spirit of
robots.txtβ only reads publicly served HTML
| Technology | Purpose |
|---|---|
| Streamlit | Dashboard UI |
| ddgs | Free DuckDuckGo search (no key) |
| requests | HTTP client for page fetching |
| BeautifulSoup4 | HTML parsing |
| pandas | Data manipulation & CSV export |
| phonenumbers | Phone number parsing |
| validators | URL & email validation |
| SQLite3 | Local persistent storage |
| python-dotenv | Environment config |
MIT License β free for personal and commercial use.