Protocol Server di Contesto del Modello Pinecone per Claude Desktop.
Protocollo del server del contesto del modello per consentire la lettura e la scrittura da Pinecone. RAG rudimentale
Panoramica
Che cos'è MCP-Pinecone?
MCP-Pinecone è un server del Protocollo di Contesto del Modello progettato per facilitare le operazioni di lettura e scrittura da Pinecone, un servizio di database vettoriale. Questo server fornisce una capacità rudimentale di Generazione Aumentata da Recupero (RAG), consentendo agli sviluppatori di integrare funzionalità avanzate di intelligenza artificiale nelle loro applicazioni senza problemi. Sfruttando MCP-Pinecone, gli utenti possono migliorare i loro processi di recupero dei dati, rendendo più facile accedere e utilizzare le informazioni memorizzate in Pinecone.
Caratteristiche di MCP-Pinecone
- Integrazione con Pinecone: Si connette direttamente a Pinecone, consentendo una gestione e un recupero dei dati efficienti.
- Capacità RAG: Supporta la Generazione Aumentata da Recupero, migliorando la qualità delle risposte generate utilizzando dati esterni.
- Open Source: Disponibile per uso pubblico, consentendo agli sviluppatori di contribuire e modificare il codice secondo necessità.
- Interfaccia User-Friendly: Progettata con facilità d'uso in mente, rendendola accessibile sia per sviluppatori principianti che esperti.
- Comunità Attiva: Supportata da una comunità di collaboratori, garantendo miglioramenti e supporto continui.
Come utilizzare MCP-Pinecone
-
Installazione: Clona il repository da GitHub e installa le dipendenze necessarie.
git clone https://github.com/sirmews/mcp-pinecone.git cd mcp-pinecone npm install -
Configurazione: Imposta la tua chiave API di Pinecone e altre configurazioni nelle variabili di ambiente o nei file di configurazione.
-
Esecuzione del Server: Avvia il server per iniziare a interagire con Pinecone.
npm start -
Effettuare Richieste: Utilizza gli endpoint API forniti per leggere e scrivere dati su Pinecone. Consulta la documentazione per istruzioni dettagliate sugli endpoint disponibili e sul loro utilizzo.
-
Contribuire: Se desideri contribuire al progetto, sentiti libero di forkare il repository, apportare le tue modifiche e inviare una pull request.
Domande Frequenti
Che cos'è Pinecone?
Pinecone è un database vettoriale completamente gestito progettato per applicazioni di machine learning. Consente agli utenti di memorizzare e interrogare vettori ad alta dimensione in modo efficiente, rendendolo ideale per applicazioni che coinvolgono intelligenza artificiale e scienza dei dati.
Come migliora MCP-Pinecone il recupero dei dati?
Implementando la Generazione Aumentata da Recupero (RAG), MCP-Pinecone consente alle applicazioni di generare risposte basate sia sull'addestramento del modello che sui dati in tempo reale provenienti da Pinecone, portando a output più accurati e contestualmente rilevanti.
MCP-Pinecone è gratuito da usare?
Sì, MCP-Pinecone è un progetto open-source e puoi usarlo gratuitamente. Tuttavia, l'utilizzo di Pinecone potrebbe comportare costi in base al tuo utilizzo dei loro servizi.
Posso contribuire al progetto MCP-Pinecone?
Assolutamente! I contributi sono benvenuti. Puoi forkare il repository, apportare miglioramenti e inviare una pull request per condividere le tue migliorie con la comunità.
Dove posso trovare la documentazione per MCP-Pinecone?
La documentazione è solitamente inclusa nel repository. Puoi anche controllare il file README per le istruzioni di configurazione e le linee guida per l'uso.
Dettaglio
Pinecone Model Context Protocol Server for Claude Desktop.
Read and write to a Pinecone index.
Components
flowchart TB
subgraph Client["MCP Client (e.g., Claude Desktop)"]
UI[User Interface]
end
subgraph MCPServer["MCP Server (pinecone-mcp)"]
Server[Server Class]
subgraph Handlers["Request Handlers"]
ListRes[list_resources]
ReadRes[read_resource]
ListTools[list_tools]
CallTool[call_tool]
GetPrompt[get_prompt]
ListPrompts[list_prompts]
end
subgraph Tools["Implemented Tools"]
SemSearch[semantic-search]
ReadDoc[read-document]
ListDocs[list-documents]
PineconeStats[pinecone-stats]
ProcessDoc[process-document]
end
end
subgraph PineconeService["Pinecone Service"]
PC[Pinecone Client]
subgraph PineconeFunctions["Pinecone Operations"]
Search[search_records]
Upsert[upsert_records]
Fetch[fetch_records]
List[list_records]
Embed[generate_embeddings]
end
Index[(Pinecone Index)]
end
%% Connections
UI --> Server
Server --> Handlers
ListTools --> Tools
CallTool --> Tools
Tools --> PC
PC --> PineconeFunctions
PineconeFunctions --> Index
%% Data flow for semantic search
SemSearch --> Search
Search --> Embed
Embed --> Index
%% Data flow for document operations
UpsertDoc --> Upsert
ReadDoc --> Fetch
ListRes --> List
classDef primary fill:#2563eb,stroke:#1d4ed8,color:white
classDef secondary fill:#4b5563,stroke:#374151,color:white
classDef storage fill:#059669,stroke:#047857,color:white
class Server,PC primary
class Tools,Handlers secondary
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:
npx -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
"mcpServers": {
"mcp-pinecone": {
"command": "uv",
"args": [
"--directory",
"{project_dir}",
"run",
"mcp-pinecone"
]
}
}
Published Servers Configuration
"mcpServers": {
"mcp-pinecone": {
"command": "uvx",
"args": [
"--index-name",
"{your-index-name}",
"--api-key",
"{your-secret-api-key}",
"mcp-pinecone"
]
}
}
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:
- Sync dependencies and update lockfile:
uv sync
- Build package distributions:
uv build
This will create source and wheel distributions in the dist/ directory.
- Publish to PyPI:
uv publish
Note: You'll need to set PyPI credentials via environment variables or command flags:
- Token:
--tokenorUV_PUBLISH_TOKEN - Or username/password:
--username/UV_PUBLISH_USERNAMEand--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:
npx @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.
Configurazione Server
{
"mcpServers": {
"mcp-pinecone": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/metorial/mcp-container--sirmews--mcp-pinecone--mcp-pinecone",
"mcp-pinecone --index-name index-name --api-key api-key"
],
"env": {}
}
}
}