MoizIbnYousaf/marketing-cli

lead-generation

Generate enriched ICP-based lead lists with Exa Agent, including structured scoring and CSV output. Use when generating leads, building prospect lists, finding companies to sell to, outbound research, or ICP-based company discovery. Triggers on leads, lead gen, prospect list, find companies, ICP, outbound list. Distinct from lead-magnet (content asset that captures emails).

91CollectingRuns scriptsNetwork access
See how to use itView GitHub source
npx skills add https://github.com/MoizIbnYousaf/marketing-cli --skill "skills/lead-generation"
Automated source guide

Source checked Jul 28, 2026·Refresh due Oct 26, 2026

Reorganized from the pinned upstream SKILL.md

Turn lead-generation's source instructions into a guide you can follow

According to the pinned SKILL.md from MoizIbnYousaf/marketing-cli: 1. Read brand/audience.md, brand/positioning.md, and brand/competitors.md if present to seed ICP + exclusions. All optional. 2. Confirm Exa MCP with Agent tools (agenttools / agentrun) or EXAAPIKEY. Without Agent access, stop and surface the MCP config from this skill. 3. Confir…

npx skills add https://github.com/MoizIbnYousaf/marketing-cli --skill "skills/lead-generation"
Check the pinned source

Best fit

  • Use when generating leads, building prospect lists, finding companies to sell to, outbound research, or ICP-based company discovery.
  • Generate enriched ICP-based lead lists with Exa Agent, including structured scoring and CSV output. Use when generating leads, building prospect lists, finding companies to sell to, outbound research, or ICP-based company discovery. Triggers on leads, lead gen, prospect list, find companies, ICP, outbound list. Distinct from lead-magnet (content asset that captures emails).

Bring this context

  • This skill requires the Exa MCP server with the Agent tools enabled (agenttools): agentcreaterun, agentwaitforrun, agentgetrunoutput, agentcancelrun.
  • If the Agent tools are not available, tell the user:
  • You need the Exa MCP server installed with the Agent tools and your API key. Instructions: https://docs.exa.ai/reference/exa-mcp

Expected outputs

  • Call agentwaitforrun with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going.
  • When completed, call agentgetrunoutput. Read the companies from output.structured, citations from output.grounding, and the run cost from costDollars.
  • 1. Call agentwaitforrun with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going. 2. When completed, call agentgetrunoutp…

Key source sections

Read lead-generation through these 5 source sections

Sections are extracted automatically from the pinned SKILL.md and link back to the source.

01

Workflow

Review the “Workflow” section in the pinned source before continuing.

SKILL.md · Workflow
Review and apply the “Workflow” source section.
02

Step 1: Understand the ICP

When the user says something like "Make a list of 200 leads for [company]", first establish the Ideal Customer Profile. If the user already described the ICP, confirm it. If not, run one small Agent run to research it:

SKILL.md · Step 1: Understand the ICP
Is the ICP description accurate?Any companies to exclude (competitors, existing customers)?How many leads do they want? (default 200)
03

Step 2: Create the Lead-Gen Run

Design an outputSchema with a bounded companies array. Keep schemas small, flat, and explicit; always bound arrays with maxItems.

SKILL.md · Step 2: Create the Lead-Gen Run
companyname (string)website (string)productdescription (string, "in 12 words or less")
04

Step 3: Wait and Read Output

1. Call agentwaitforrun with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going. 2. When completed, call agentgetrunoutput. Read the companies from output.structured, citations fro…

SKILL.md · Step 3: Wait and Read Output
Call agentwaitforrun with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going.When completed, call agentgetrunoutput. Read the companies from output.structured, citations from output.grounding, and the run cost from costDollars.1. Call agentwaitforrun with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going. 2. When completed, call agentgetrunoutp…
05

Step 4: Write the CSV

Write output.structured.companies to {targetcompany}leads{YYYY-MM-DD}.csv, sorted by icpfitscore descending. Join any array fields with " | ". Use Python's csv.writer (handles quoting/escaping) via Bash, or Write directly for small lists.

SKILL.md · Step 4: Write the CSV
Write output.structured.companies to {targetcompany}leads{YYYY-MM-DD}.csv, sorted by icpfitscore descending. Join any array fields with " | ". Use Python's csv.writer (handles quoting/escaping) via Bash, or Write direct…

SkillSignal prompt templates

Provide the task, context, and acceptance criteria

These prompts were written by SkillSignal from the source structure; they are not upstream text.

Task-start prompt

Confirm source fit, inputs, and outputs before acting.

Use lead-generation to help me with: [specific task]. Context: [files, data, or background]. Constraints: [environment, scope, and prohibited actions]. Before acting, check the pinned SKILL.md and explain which sections apply, what inputs are still missing, and what you will deliver.

Source-guided execution

Make the Agent explicitly follow the key extracted sections.

Apply the pinned lead-generation source to [task]. Pay particular attention to these source sections: “Workflow”, “Step 1: Understand the ICP”, “Step 2: Create the Lead-Gen Run”, “Step 3: Wait and Read Output”, “Step 4: Write the CSV”. Preserve the important decision at each step. Mark facts not covered by the source as “needs confirmation” instead of inventing them. Then verify the result against my acceptance criteria: [criteria].

Result-review prompt

Check omissions, permissions, and source drift before delivery.

Review the current lead-generation result: (1) does it satisfy the original task; (2) were any applicable steps or limits in the pinned SKILL.md missed; (3) did it perform any unauthorized file, command, network, or data action; and (4) which conclusions remain unverified? List issues first, then fix only what the source or user authorization supports.

Output checklist

Verify each item before delivery

The task matches the purpose documented in the SKILL.md.

The source section “Workflow” has been checked.

The source section “Step 1: Understand the ICP” has been checked.

The source section “Step 2: Create the Lead-Gen Run” has been checked.

The source section “Step 3: Wait and Read Output” has been checked.

Inputs, constraints, and acceptance criteria are explicit.

Unverified facts, compatibility, and outcome claims are clearly marked.

Any file, command, network, or data action has been reviewed.

Choose a different workflow

When another Skill is the better fit

dask

Distributed computing for larger-than-RAM pandas/NumPy workflows. Use when you need to scale existing pandas/NumPy code beyond memory or across clusters. Best for parallel file processing, distributed ML, integration with existing pandas code. For out-of-core analytics on single machine use vaex; for in-memory speed use polars.

A separate implementation from K-Dense-AI/scientific-agent-skills; compare its source, maintenance signals, and permission requirements.

Open source detail

neuropixels-analysis

Analyze Neuropixels extracellular recordings end-to-end with SpikeInterface. Covers loading SpikeGLX/Open Ephys/NWB data, preprocessing, drift/motion correction, Kilosort4 (and CPU) spike sorting, quality metrics, and unit curation (threshold-based, model-based UnitRefine, and AI-assisted visual review). Use when working with Neuropixels 1.0/2.0 recordings, spike sorting, or extracellular electrophysiology analysis.

A separate implementation from K-Dense-AI/scientific-agent-skills; compare its source, maintenance signals, and permission requirements.

Open source detail

scanpy

Standard single-cell RNA-seq analysis pipeline. Use for QC, normalization, dimensionality reduction (PCA/UMAP/t-SNE), clustering, differential expression, visualization, and converting R-friendly single-cell formats such as Seurat or SingleCellExperiment RDS files into h5ad for Scanpy. Best for exploratory scRNA-seq analysis with established workflows. For deep learning models use scvi-tools; for data format questions use anndata.

A separate implementation from K-Dense-AI/scientific-agent-skills; compare its source, maintenance signals, and permission requirements.

Open source detail

FAQ

What does lead-generation do?

1. Read brand/audience.md, brand/positioning.md, and brand/competitors.md if present to seed ICP + exclusions. All optional. 2. Confirm Exa MCP with Agent tools (agenttools / agentrun) or EXAAPIKEY. Without Agent access, stop and surface the MCP config from this skill. 3. Confir…

How do I start using lead-generation?

The catalog detected this source-specific install command: npx skills add https://github.com/MoizIbnYousaf/marketing-cli --skill "skills/lead-generation". Inspect the command and pinned source before running it.

Which Agent platforms does it declare?

No dedicated Agent platform is declared in the pinned source record.

Repository stars
27
Repository forks
5
Quality
91/100
Source repository last pushed

Quality breakdown

Based on traceable docs and repository signals; stars are not treated as quality.

91/100
Documentation28/30
Specificity20/25
Maintenance20/20
Trust signals23/25

Compare before choosing

Related Agent Skills and source variants

These links are selected from shared tasks, functions, stacks, platforms, and same-name variants. Compare the source owner, documentation, permissions, and maintenance signals.

dask by k-dense-ai

Distributed computing for larger-than-RAM pandas/NumPy workflows. Use when you need to scale existing pandas/NumPy code beyond memory or across clusters. Best for parallel file processing, distributed ML, integration with existing pandas code. For out-of-core analytics on single machine use vaex; for in-memory speed use polars.

neuropixels-analysis by k-dense-ai

Analyze Neuropixels extracellular recordings end-to-end with SpikeInterface. Covers loading SpikeGLX/Open Ephys/NWB data, preprocessing, drift/motion correction, Kilosort4 (and CPU) spike sorting, quality metrics, and unit curation (threshold-based, model-based UnitRefine, and AI-assisted visual review). Use when working with Neuropixels 1.0/2.0 recordings, spike sorting, or extracellular electrophysiology analysis.

scanpy by k-dense-ai

Standard single-cell RNA-seq analysis pipeline. Use for QC, normalization, dimensionality reduction (PCA/UMAP/t-SNE), clustering, differential expression, visualization, and converting R-friendly single-cell formats such as Seurat or SingleCellExperiment RDS files into h5ad for Scanpy. Best for exploratory scRNA-seq analysis with established workflows. For deep learning models use scvi-tools; for data format questions use anndata.

astropy by k-dense-ai

Core Python library for astronomy and astrophysics workflows that need Astropy APIs, including units/quantities, coordinates, FITS I/O, tables, time systems, WCS, and cosmology. Use when implementing or debugging astronomical data analysis code with Astropy.

revops by coreyhaines31

When the user wants help with revenue operations, lead lifecycle management, or marketing-to-sales handoff processes. Also use when the user mentions 'RevOps,' 'revenue operations,' 'lead scoring,' 'lead routing,' 'MQL,' 'SQL,' 'pipeline stages,' 'deal desk,' 'CRM automation,' 'marketing-to-sales handoff,' 'data hygiene,' 'leads aren't getting to sales,' 'pipeline management,' 'lead qualification,' or 'when should marketing hand off to sales.' Use this for anything involving the systems and proc

View original Skill.mdThis page is parsed directly from the repository SKILL.md without editorial rewriting. Collected: Jul 28, 2026 · about 5 min

On Activation

  1. Read brand/audience.md, brand/positioning.md, and brand/competitors.md if present to seed ICP + exclusions. All optional.
  2. Confirm Exa MCP with Agent tools (agent_tools / agent_run) or EXA_API_KEY. Without Agent access, stop and surface the MCP config from this skill.
  3. Confirm ICP with the user before large runs (default 200 leads is expensive).
  4. Write CSV under the project (e.g. marketing/leads/ or cwd). Never write credentials into brand/.

Lead Generation with Exa Agent

mktg runtime note

Prefer Exa MCP when available (tools: web_search_exa, web_search_advanced_exa, web_fetch_exa, agent_run). If MCP Agent tools use the older create/wait/get names (agent_create_run, agent_wait_for_run, agent_get_run_output), use those equivalently. Without MCP, call the HTTP API with x-api-key: $EXA_API_KEY (POST https://api.exa.ai/search, /contents, /agent). Firecrawl remains the path for deep scrape of a known URL after Exa discovery.

Generate enriched lead lists using the Exa Agent API. An Agent run is an asynchronous, multi-step web research task: you describe the list you want plus an output schema, and Exa handles query decomposition, searching, verification, enrichment, and structured output internally. You do NOT need to orchestrate parallel searches, subagents, or manual deduplication.

For very large or continuously maintained lead lists with per-item verification, consider Exa Websets instead: https://docs.exa.ai/websets/api/overview

Prerequisites

This skill requires the Exa MCP server with the Agent tools enabled (agent_tools): agent_create_run, agent_wait_for_run, agent_get_run_output, agent_cancel_run.

If the Agent tools are not available, tell the user:

You need the Exa MCP server installed with the Agent tools and your API key. Instructions: https://docs.exa.ai/reference/exa-mcp

Then stop.

Tool Restriction

Use the Exa Agent tools (agent_create_run, agent_wait_for_run, agent_get_run_output, agent_cancel_run), plus Write and Bash (for CSV output). Do NOT use generic web search for the lead list itself.

Workflow

1. Confirm the ICP with the user (one small Agent run if research is needed)
2. Create the lead-gen Agent run(s) with an outputSchema
3. Wait for completion (agent_wait_for_run)
4. Read output.structured (agent_get_run_output)
5. Write the CSV
6. Optional: expand with follow-up runs (previousRunId + input.exclusion)

Step 1: Understand the ICP

When the user says something like "Make a list of 200 leads for [company]", first establish the Ideal Customer Profile. If the user already described the ICP, confirm it. If not, run one small Agent run to research it:

agent_create_run {
  "query": "Research {company_name}: what they sell, who their existing customers are, and what their ideal customer profile is.",
  "effort": "low",
  "outputSchema": {
    "type": "object",
    "properties": {
      "company_description": { "type": "string", "description": "What the company does in 2 sentences or less" },
      "icp_description": { "type": "string", "description": "Concise ICP description that clearly defines target companies" },
      "sub_verticals": { "type": "array", "maxItems": 10, "items": { "type": "string" }, "description": "Sub-verticals breaking down the ICP" },
      "useful_enrichments": { "type": "array", "maxItems": 8, "items": { "type": "string" }, "description": "Enrichment columns useful for filtering high-signal companies" }
    },
    "required": ["company_description", "icp_description", "sub_verticals", "useful_enrichments"]
  }
}

Present the ICP to the user and confirm:

  • Is the ICP description accurate?
  • Any companies to exclude (competitors, existing customers)?
  • How many leads do they want? (default 200)
  • Any specific enrichment columns they care about?

Step 2: Create the Lead-Gen Run

Design an outputSchema with a bounded companies array. Keep schemas small, flat, and explicit; always bound arrays with maxItems.

Core fields to always include:

  • company_name (string)
  • website (string)
  • product_description (string, "in 12 words or less")
  • icp_fit_score (integer, 1-10)
  • icp_fit_reasoning (string, "compelling one-liner in 20 words or less")

Add enrichment fields tailored to the campaign (funding stage, headcount range, headquarters, hiring signals, etc.). Give string fields a length hint in their description to keep CSV output clean.

Use the run inputs for the pieces the old manual pipeline handled by hand:

  • query - describe the list: the ICP, geography, stage, and how many companies you want
  • outputSchema - the exact structure back, with maxItems bounding the companies array
  • systemPrompt - scoring rules, source preferences, dedup/exclusion emphasis
  • input.exclusion - companies to avoid (competitors, existing customers, results from earlier runs)
  • effort - "auto" by default; "high" or "xhigh" for large or hard lists

Example:

agent_create_run {
  "query": "Find 100 companies matching this ICP: {icp_description}. Prioritize {sub_verticals}. For each company, score ICP fit 1-10 for {user_company}.",
  "effort": "auto",
  "systemPrompt": "Prefer official company sites and recent funding announcements. Do not include duplicates or subsidiaries of the same parent company.",
  "input": {
    "exclusion": ["{competitor_1}", "{existing_customer_1}"]
  },
  "outputSchema": {
    "type": "object",
    "properties": {
      "companies": {
        "type": "array",
        "maxItems": 100,
        "items": {
          "type": "object",
          "properties": {
            "company_name": { "type": "string" },
            "website": { "type": "string", "format": "uri" },
            "product_description": { "type": "string", "description": "in 12 words or less" },
            "icp_fit_score": { "type": "integer", "description": "1-10" },
            "icp_fit_reasoning": { "type": "string", "description": "one-liner in 20 words or less" }
          },
          "required": ["company_name", "website", "product_description", "icp_fit_score", "icp_fit_reasoning"]
        }
      }
    },
    "required": ["companies"]
  }
}

agent_create_run returns an agent_run_... ID immediately. Save it.

Step 3: Wait and Read Output

  1. Call agent_wait_for_run with the run ID. It polls until the run reaches a terminal status (completed, failed, or cancelled) or times out - call it again if the run is still going.
  2. When completed, call agent_get_run_output. Read the companies from output.structured, citations from output.grounding, and the run cost from costDollars.

Do not paste the full raw output into the conversation - go straight to CSV.

Step 4: Write the CSV

Write output.structured.companies to {target_company}_leads_{YYYY-MM-DD}.csv, sorted by icp_fit_score descending. Join any array fields with " | ". Use Python's csv.writer (handles quoting/escaping) via Bash, or Write directly for small lists.

Print a summary:

## Lead Generation Complete

- Total leads: {count}
- ICP score distribution: 8-10: {N} | 5-7: {N} | 1-4: {N}
- Run ID: {agent_run_id}
- Cost: ${costDollars}
- Output: {filename}

Step 5: Expanding the List

If the user wants more leads than one run returned:

  • Create a follow-up run with previousRunId set to the completed run's ID, asking for additional companies
  • Put the company names already collected into input.exclusion so the new run avoids them
  • Append the new results to the CSV and re-deduplicate by normalized company name (strip "Inc"/"Ltd"/etc., case-insensitive)

For lists in the many hundreds, run a few runs sequentially this way rather than one giant run, and confirm scope with the user first: "This will require ~{N} Agent runs. Proceed?"

Handling Failures

  • If a run ends failed, read the error from agent_get_run_output, adjust the query or schema, and retry once with different wording
  • Use agent_cancel_run if a run is clearly researching the wrong thing
  • If results are consistently below the requested count, narrow the ICP into 2-3 sub-vertical runs instead of one broad run

MCP Configuration

Requires an Exa API key. Get yours at https://dashboard.exa.ai/api-keys

{
  "servers": {
    "exa": {
      "type": "http",
      "url": "https://mcp.exa.ai/mcp?tools=agent_tools",
      "headers": {
        "x-api-key": "YOUR_EXA_API_KEY"
      }
    }
  }
}

References

Anti-Patterns

Anti-patternWhy it failsInstead
Using Claude native WebSearch instead of ExaMisses niche competitors, companies, and cited sources Exa ranks highly.Use this skill (or Exa MCP) for all open-ended web research.
Calling Exa without EXA_API_KEY / MCP authRequests 401 and the agent invents results.Set EXA_API_KEY (dashboard.exa.ai) or configure .mcp.json; surface the fix via mktg doctor.
Dumping raw result JSON into the user chatBurns context and hides the answer.Synthesize; cite URLs from grounding / result lists.

Attribution

Ported from exa-labs/agent-skills - adapted for mktg's drop-in contract on 2026-07-18.

Upstream commit: 390ffee2d7e1d0dce2ed8efe4994c2b3c1c0173b

Drift detection: if the upstream skill changes, re-run mktg-steal https://github.com/exa-labs/agent-skills to evaluate the diff.

Skill path
skills/lead-generation/SKILL.md
Commit SHA
f12fbcbe4929
Repository license
MIT
Data collected