1. Get API keys
Your n8n workflow will need API keys for Pinecone and OpenAI.1
Get a Pinecone API key
Create a new API key in the Pinecone console, or use the widget below to generate a key. If you don’t have a Pinecone account, the widget will sign you up for the free Starter plan.Your generated API key:
2
Get an OpenAI API key
Create a new API key in the OpenAI console.
2. Create an assistant
Create an assistant in the Pinecone console:- Name your assistant
n8n-assistant.
3. Set up n8n
1
Install the Pinecone Assistant node
In your n8n account, install the Pinecone Assistant node using the nodes panel.
Restart your n8n instance if the Pinecone Assistant node doesn’t appear in the nodes panel.
2
Create a new workflow
In your n8n account, create a new workflow.
3
Import a workflow template
Copy this workflow template URL:Paste the URL anywhere in the workflow editor and then click Import to add the workflow.
4
Add credentials to the workflow
-
Add your Pinecone credentials:
- In the Upload file to Assistant node, select Credential to connect with > Create new credential and paste in your Pinecone API key.
-
Add your OpenAI credentials:
- In the OpenAI Chat Model node, select Credential to connect with > Create new credential and paste in your OpenAI API key.
5
Execute the workflow
By default, the workflow downloads recent Pinecone release notes and uploads them to your assistant. Click Execute workflow to start uploading documents.
4. Chat with your docs
Once the documents are uploaded, you can chat with your assistant. In the n8n workflow, use the Chat input node to ask questions like:Next steps
- Customize the workflow for your own use case:
- Change the urls in the Set file urls node to use your own files.
- Customize the system message on the AI Agent node to indicate what kind of knowledge is stored in Pinecone Assistant.
- To help manage token consumption, add the Top K and/or Snippet Size parameters to the Get context from Assistant node.
- Filter the context snippets even further by adding metadata filters to the Get context from Assistant node.
- Use n8n, Pinecone Assistant, and OpenAI to chat with your Google Drive documents.
- Learn more about Pinecone Assistant.
- Get help in the Pinecone Discord community.