Pinecone MCP Server

Integrate Pinecone with your AI assistants using the Model Context Protocol (MCP) for enhanced vector database interactions.

GitHub starsnpm versionnpm downloads

Overview

The Pinecone MCP Server allows AI assistants to interact with Pinecone, a leading vector database, through the Model Context Protocol (MCP). This integration enables AI tools to leverage Pinecone's capabilities for tasks such as semantic search, data upsertion, index management, and documentation retrieval. There are two main types of Pinecone MCP servers: the Pinecone Assistant MCP Server, designed for retrieving information from Pinecone Assistants, and the Pinecone Developer MCP Server, focused on improving the experience of developers working with Pinecone.

Official Server:

Developed and maintained by Pinecone

Key Features

🔍

Semantic Search

Perform advanced semantic searches within Pinecone indexes to retrieve relevant information.

🗄️

Index Management

Create, describe, and manage Pinecone indexes directly through AI assistants.

⬆️

Data Upsertion

Insert and update records in Pinecone indexes, including integrated inference for embeddings.

📚

Documentation Retrieval

Search official Pinecone documentation to answer questions and get guidance.

🧠

Contextual Assistance

Provide AI assistants with relevant context sourced from your Pinecone knowledge base.

⚙️

Flexible Deployment

Deploy as a Docker container or integrate directly into AI assistant configurations.

Available Tools

Quick Reference

ToolPurposeCategory
assistant_contextRetrieves relevant document snippets from your Pinecone Assistant knowledge base.Retrieval
search-docsSearch the official Pinecone documentation.Documentation
list-indexesLists all Pinecone indexes.Index Management
describe-indexDescribes the configuration of an index.Index Management
describe-index-statsProvides statistics about the data in the index, including the number of records and available namespaces.Index Management
create-index-for-modelCreates a new index that uses an integrated inference model to embed text as vectors.Index Management
upsert-recordsInserts or updates records in an index with integrated inference.Data Management
search-recordsSearches for records in an index based on a text query, using integrated inference for embedding.Search
cascading-searchSearches for records across multiple indexes, deduplicating and reranking the results.Search
rerank-documentsReranks a collection of records or text documents using a specialized reranking model.AI/ML

Detailed Usage

assistant_context

Retrieves relevant document snippets from your Pinecone Assistant knowledge base. This tool is part of the Pinecone Assistant MCP Server.

use_mcp_tool({
  server_name: "pinecone-assistant",
  tool_name: "assistant_context",
  arguments: {
    assistant_name: "my-assistant",
    query: "What is Pinecone?",
    top_k: 5
  }
});
search-docs

Search the official Pinecone documentation.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "search-docs",
  arguments: {
    query: "how to create an index"
  }
});
create-index-for-model

Creates a new index that uses an integrated inference model to embed text as vectors.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "create-index-for-model",
  arguments: {
    name: "my-new-index",
    dimension: 1536,
    metric: "cosine",
    model: "text-embedding-ada-002"
  }
});
upsert-records

Inserts or updates records in an index with integrated inference.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "upsert-records",
  arguments: {
    index: "my-new-index",
    records: [
      { id: "doc1", text: "This is the first document." },
      { id: "doc2", text: "This is the second document." }
    ]
  }
});
search-records

Searches for records in an index based on a text query, using integrated inference for embedding.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "search-records",
  arguments: {
    index: "my-new-index",
    query: "first document",
    top_k: 1
  }
});
cascading-search

Searches for records across multiple indexes, deduplicating and reranking the results.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "cascading-search",
  arguments: {
    indexes: ["index1", "index2"],
    query: "important information",
    top_k: 3
  }
});
rerank-documents

Reranks a collection of records or text documents using a specialized reranking model.

use_mcp_tool({
  server_name: "pinecone",
  tool_name: "rerank-documents",
  arguments: {
    query: "best programming languages",
    documents: [
      { id: "docA", text: "Python is a versatile language." },
      { id: "docB", text: "JavaScript is essential for web development." }
    ]
  }
});

Installation

{
  "mcpServers": {
    "pinecone": {
      "command": "npx",
      "args": [
        "-y", "@pinecone-database/mcp"
      ],
      "env": {
        "PINECONE_API_KEY": "<your pinecone api key>"
      }
    }
  }
}

Common Use Cases

  • AI-powered Knowledge Retrieval: Integrate Pinecone with AI assistants to provide highly relevant and contextual information from your knowledge bases.
  • Automated Index Management: Use AI tools to programmatically create, update, and monitor Pinecone indexes for various applications.
  • Enhanced Developer Workflows: Streamline the development process by allowing AI assistants to generate code, search documentation, and test queries against Pinecone indexes.
  • Multi-agent Workflows: Combine Pinecone MCP servers with other tools in multi-agent systems to build sophisticated AI applications that leverage vector search capabilities.
  • Real-time Context for LLMs: Provide Large Language Models (LLMs) with up-to-date and specific context from Pinecone to improve the accuracy and relevance of their responses.

Sources