n8n-nodes-openai-vectorstore
v1.0.1
Published
n8n community node to manage OpenAI Vector Stores - Create, search, and manage vector stores for semantic search and RAG applications
Maintainers
Readme
n8n-nodes-openai-vectorstore
This is an n8n community node to manage OpenAI Vector Stores for semantic search and RAG (Retrieval-Augmented Generation) applications.
n8n is a fair-code licensed workflow automation platform.
Features
Full implementation of OpenAI Vector Stores API:
🗃️ Vector Store
| Operation | Description | |-----------|-------------| | Create | Create a new vector store with custom chunking strategy | | Get | Retrieve vector store details | | Get Many | List all vector stores with pagination | | Update | Modify name, description, expiration policies | | Delete | Remove a vector store | | Search | Semantic search with filters, ranking, and score threshold |
📄 Vector Store Files
| Operation | Description | |-----------|-------------| | Create | Add a file with custom attributes for filtering | | Get | Retrieve file information | | Get Content | Get parsed content of a file | | Get Many | List files with status filter | | Update | Update file attributes/metadata | | Delete | Remove file from vector store |
📦 File Batches
| Operation | Description | |-----------|-------------| | Create | Add multiple files in batch | | Get | Check batch status | | Cancel | Cancel batch operation | | List Files | List files in a batch |
Installation
Community Nodes (Recommended)
- Go to Settings > Community Nodes
- Select Install
- Enter
n8n-nodes-openai-vectorstore - Click Install
Manual Installation
# In your n8n installation directory
npm install n8n-nodes-openai-vectorstoreCredentials
You need an OpenAI API key:
- Go to OpenAI API Keys
- Create a new API key
- In n8n, create new credentials for "OpenAI Vector Store API"
- Enter your API key
Usage Examples
Create a Vector Store
{
"resource": "vectorStore",
"operation": "create",
"name": "Knowledge Base",
"additionalFields": {
"description": "Support documentation",
"expiresAfterDays": 30
}
}Semantic Search
{
"resource": "vectorStore",
"operation": "search",
"vectorStoreId": "vs_abc123",
"query": "How to reset password?",
"searchOptions": {
"max_num_results": 5,
"score_threshold": 0.7,
"rewrite_query": true
}
}Add File with Attributes
{
"resource": "vectorStoreFile",
"operation": "create",
"vectorStoreId": "vs_abc123",
"fileId": "file-xyz789",
"additionalFields": {
"attributes": {
"category": "support",
"language": "en"
}
}
}Search with Filters
{
"searchOptions": {
"filters": {
"type": "eq",
"key": "category",
"value": "support"
}
}
}Use Cases
- RAG Chatbots: Provide relevant context to AI assistants
- Support Systems: Search documentation with natural language
- Knowledge Management: Build enterprise knowledge bases
- Document Analysis: Extract information from large document sets
Example Workflow
[Webhook] → [Vector Store: Search] → [OpenAI: Chat] → [Respond]- Receive user question
- Search for relevant documents
- Generate response with context
- Send answer
