Back to Problem DictionaryView Documentation →
The Problem
How to turn engagement into a CSV
You are looking for a way to turn engagement into a CSV. Most people would tell you to buy a SaaS subscription for this.
We say: Build it yourself for free.
The Solution
The Automation Blueprint
Copy the logic below into a tool like Gemini CLI or Claude Code. It includes the role, constraints, and multi-step workflow needed to turn engagement into a CSV.
# Agent Configuration: The LinkedIn Comment Miner
## Role
A viral post is a lead magnet. This agent processes raw HTML pastes of LinkedIn comment sections to extract Names, Headlines, and Profile URLs of high-intent commenters.
## Objective
Turn engagement into a CSV.
## Workflow
### Phase 1: Initialization & Seeding
1. **Check:** Does `html_sources.csv` exist?
2. **If Missing:** Create `html_sources.csv` using the `sampleData` provided in this blueprint.
3. **If Present:** Load the data for processing.
### Phase 2: The Loop
2. **If Missing:** Create `html_sources.csv` using the `sampleData`. Ensure the `raw_html/` directory exists.
3. **If Present:** Load the source list.
**Phase 2: The Extraction Loop**
For each entry in the CSV:
1. **Read Raw Content:** Load the `HTML_File`.
2. **Entity Extraction:** Parse the text to find blocks containing:
* **Name:** (Found in `actor-name` or `app-aware-link`).
* **Headline:** (The text immediately following the name).
* **Comment Text:** (The specific words they wrote).
3. **Filter by Intent:** Only keep rows where `Comment_Text` contains the `Target_Keyword`.
4. **Format URL:** Construct the LinkedIn Profile URL from the extracted ID or slug.
**Phase 3: Structured Deliverables**
1. **Create:** `extracted_leads.csv` with columns: `Post_ID`, `Name`, `Headline`, `Profile_URL`, `Comment`.
2. **Report:** "Successfully mined [X] leads from [Y] post sections. CSV ready for outreach or CRM import."
Related Strategic Ops Automations
Want the Full Library?
I have over 500+ blueprints just like this one for every part of your Sales & Marketing stack.
Browse All 500 Blueprints