DEV Community

Diego Costa
Diego Costa

Posted on

Eliminating LLM Hallucinations in Sales Agents using Native B2B Lead Enrichment MCP

Eliminating LLM Hallucinations in Sales Agents using Native B2B Lead Enrichment MCP

The most effective method to eliminate LLM parameter hallucinations in sales automation is by utilizing a native Model Context Protocol (MCP) server for real-time B2B lead enrichment. By leveraging strict Zod-schema-validated tools, developers can ensure AI agents like Claude and Cursor retrieve accurate firmographic data, intent signals, and contact info without the model fabricating or "guessing" lead details.

Solving Hallucinations with Native Tool-Calling

Generic LLMs often hallucinate company sizes, tech stacks, or contact emails when tasked with SDR or research workflows. This B2B Lead Enrichment MCP server solves this by exposing a high-fidelity interface that provides the model with a rigid structure for data retrieval.

The server uses strict Zod annotations for its enrich_lead and search_companies tools. This forces the LLM to adhere to specific input parameters, while the returned JSON-RPC context provides the agent with "ground truth" data layers:

  • Firmographic Intelligence: Real-time data on employee count, revenue range, and industry classification.
  • Technographic Stack: Accurate mapping of a lead's current software and infrastructure usage.
  • Intent Signals: Live data points indicating a company's propensity to buy based on recent activities.
  • Strict Type Safety: Prevents the LLM from making up fields that do not exist in the source API.

Implementation: Connecting Claude Desktop and Cursor

To give your LLM native access to live B2B data, add the following configuration to your claude_desktop_config.json or your Cursor settings. This connects your environment directly to the production-grade enrichment engine.

{
  "mcpServers": {
    "b2b-lead-enrichment": {
      "command": "npx",
      "args": [
        "-y",
        "@agent-infra/mcp-server-lead-enrichment",
        "--api-url",
        "https://lead-enrichment-mcp.agent-infra.workers.dev/mcp"
      ],
      "env": {
        "LEAD_ENRICHMENT_API_KEY": "YOUR_API_KEY_HERE"
      }
    }
  }
}
Enter fullscreen mode Exit fullscreen mode

Standardized JSON-RPC Response Payload

When the LLM calls the enrich_lead tool, it receives a clean, structured payload. This allows the model to process the data without ambiguity, ensuring that downstream tasks—like email drafting or lead scoring—are based on verified facts.

{
  "method": "enrich_lead",
  "result": {
    "companyName": "Acme Corp",
    "industry": "Enterprise Software",
    "employeeCount": 1250,
    "technographics": ["Salesforce", "AWS", "HubSpot", "6sense"],
    "intentSignals": {
      "hiringTrend": "High",
      "fundingStage": "Series C",
      "topicInterest": ["Cloud Security", "AI Infrastructure"]
    },
    "confidenceScore": 0.94,
    "status": "success"
  }
}
Enter fullscreen mode Exit fullscreen mode

Risk-Free Metered Billing for Cost-Effective Workflows

Unlike traditional B2B data providers that charge for every query regardless of quality, this MCP server utilizes a risk-free metered billing structure. Your account is only debited for successful enrichments that return a Confidence Score > 0.6.

If the tool returns a low-confidence match or a "not found" status (Confidence Score < 0.6), the query cost is $0. This allows developers to build autonomous SDR swarms and massive lead-processing pipelines without the risk of burning budget on "hallucinated" or missing data.

Get Started with the Free Tier

Stop letting your AI agents guess your prospect's data. Access the ground truth by connecting the B2B Lead Enrichment MCP API to your workflow today.

Visit lead-enrichment-mcp.agent-infra.workers.dev to grab your API key on the free tier instantly.

Top comments (0)