MCP Now
Pinecone

Pinecone

by sirmews
GitHub

MCP server for searching and uploading records to Pinecone. Allows for simple RAG features, leveraging Pinecone's Inference API.

pinecone
index
server
tool
subgraph

Pinecone Model Context Protocol Server for Claude Desktop.

smithery badge

PyPI - Downloads

Read and write to a Pinecone index.

Components

1flowchart TB 2 subgraph Client["MCP Client (e.g., Claude Desktop)"] 3 UI[User Interface] 4 end 5 6 subgraph MCPServer["MCP Server (pinecone-mcp)"] 7 Server[Server Class] 8 9 subgraph Handlers["Request Handlers"] 10 ListRes[list_resources] 11 ReadRes[read_resource] 12 ListTools[list_tools] 13 CallTool[call_tool] 14 GetPrompt[get_prompt] 15 ListPrompts[list_prompts] 16 end 17 18 subgraph Tools["Implemented Tools"] 19 SemSearch[semantic-search] 20 ReadDoc[read-document] 21 ListDocs[list-documents] 22 PineconeStats[pinecone-stats] 23 ProcessDoc[process-document] 24 end 25 end 26 27 subgraph PineconeService["Pinecone Service"] 28 PC[Pinecone Client] 29 subgraph PineconeFunctions["Pinecone Operations"] 30 Search[search_records] 31 Upsert[upsert_records] 32 Fetch[fetch_records] 33 List[list_records] 34 Embed[generate_embeddings] 35 end 36 Index[(Pinecone Index)] 37 end 38 39 %% Connections 40 UI --> Server 41 Server --> Handlers 42 43 ListTools --> Tools 44 CallTool --> Tools 45 46 Tools --> PC 47 PC --> PineconeFunctions 48 PineconeFunctions --> Index 49 50 %% Data flow for semantic search 51 SemSearch --> Search 52 Search --> Embed 53 Embed --> Index 54 55 %% Data flow for document operations 56 UpsertDoc --> Upsert 57 ReadDoc --> Fetch 58 ListRes --> List 59 60 classDef primary fill:#2563eb,stroke:#1d4ed8,color:white 61 classDef secondary fill:#4b5563,stroke:#374151,color:white 62 classDef storage fill:#059669,stroke:#047857,color:white 63 64 class Server,PC primary 65 class Tools,Handlers secondary 66 class Index storage

Resources

The server implements the ability to read and write to a Pinecone index.

Tools

  • semantic-search: Search for records in the Pinecone index.
  • read-document: Read a document from the Pinecone index.
  • list-documents: List all documents in the Pinecone index.
  • pinecone-stats: Get stats about the Pinecone index, including the number of records, dimensions, and namespaces.
  • process-document: Process a document into chunks and upsert them into the Pinecone index. This performs the overall steps of chunking, embedding, and upserting.

Note: embeddings are generated via Pinecone's inference API and chunking is done with a token-based chunker. Written by copying a lot from langchain and debugging with Claude.

Quickstart

Installing via Smithery

To install Pinecone MCP Server for Claude Desktop automatically via Smithery:

1npx -y @smithery/cli install mcp-pinecone --client claude

Install the server

Recommend using uv to install the server locally for Claude.

uvx install mcp-pinecone

OR

uv pip install mcp-pinecone

Add your config as described below.

Claude Desktop

On MacOS: ~/Library/Application\ Support/Claude/claude_desktop_config.json On Windows: %APPDATA%/Claude/claude_desktop_config.json

Note: You might need to use the direct path to uv. Use which uv to find the path.

Development/Unpublished Servers Configuration

1"mcpServers": { 2 "mcp-pinecone": { 3 "command": "uv", 4 "args": [ 5 "--directory", 6 "{project_dir}", 7 "run", 8 "mcp-pinecone" 9 ] 10 } 11}

Published Servers Configuration

1"mcpServers": { 2 "mcp-pinecone": { 3 "command": "uvx", 4 "args": [ 5 "--index-name", 6 "{your-index-name}", 7 "--api-key", 8 "{your-secret-api-key}", 9 "mcp-pinecone" 10 ] 11 } 12}

Sign up to Pinecone

You can sign up for a Pinecone account here.

Get an API key

Create a new index in Pinecone, replacing {your-index-name} and get an API key from the Pinecone dashboard, replacing {your-secret-api-key} in the config.

Development

Building and Publishing

To prepare the package for distribution:

  1. Sync dependencies and update lockfile:
1uv sync
  1. Build package distributions:
1uv build

This will create source and wheel distributions in the dist/ directory.

  1. Publish to PyPI:
1uv publish

Note: You'll need to set PyPI credentials via environment variables or command flags:

  • Token: --token or UV_PUBLISH_TOKEN
  • Or username/password: --username/UV_PUBLISH_USERNAME and --password/UV_PUBLISH_PASSWORD

Debugging

Since MCP servers run over stdio, debugging can be challenging. For the best debugging experience, we strongly recommend using the MCP Inspector.

You can launch the MCP Inspector via npm with this command:

1npx @modelcontextprotocol/inspector uv --directory {project_dir} run mcp-pinecone

Upon launching, the Inspector will display a URL that you can access in your browser to begin debugging.

License

This project is licensed under the MIT License. See the LICENSE file for details.

Source Code

The source code is available on GitHub.

Contributing

Send your ideas and feedback to me on Bluesky or by opening an issue.