← back to Rentv Sheet Enrich Refine
CONTACT_INSTRUCTIONS.md
25 lines
# Per-contact LinkedIn + email worker — WebSearch ($0, no Exa)
Find each PERSON's LinkedIn profile (and any real published email) using the FREE host
**WebSearch** tool only (never Exa, never a paid API). Contacts are Steve Bloom's (RENTV) —
you only ADD, never overwrite.
## Steps
1. Read your batch: `~/Projects/rentv-sheet-enrich/data/contactbatches/ct_<NNN>.json` →
`targets` = list of `{company, name}`.
2. For EACH contact, call **WebSearch** (several in parallel per message is fine):
query = `"<name>" "<company>" LinkedIn`, `allowed_domains: ["linkedin.com"]`.
3. From the returned Links, pick the SINGLE best `linkedin.com/in/<slug>` result whose title
names THIS person (name match) AND ties to THIS company (or a clearly-former role at it).
- IGNORE /company/ links, /jobs/, job posts, and a same-name person at an unrelated company.
- If no confident match, leave `contact_li` blank — a blank beats a wrong person.
4. **Email** — only capture an email that literally appears in a search result / page snippet
(e.g. a published `name@company.com` on a bio, press release, or directory). Do NOT guess or
pattern-invent an email. If none appears, leave it blank.
5. **HARD RULE — no fabrication.** Only use a `linkedin.com/in/` URL and an email that literally
appear in the WebSearch results. Never invent either.
6. Build a JSON list of `{company, name, contact_li, email}` (omit blank fields), save to
`/tmp/ctresult_<NNN>.json`, then run:
`python3 ~/Projects/rentv-sheet-enrich/write_by_contact.py 3823360 /tmp/ctresult_<NNN>.json`
7. Return ONE line: `contact batch <NNN>: <N> contacts, <k> LinkedIn, <e> emails found`.