
Node Details
- Name: Elasticsearch_VectorStores
- Type: Elasticsearch
- Version: 2.0
- Category: Vector Stores
Base Classes
- Elasticsearch
- VectorStoreRetriever
- BaseRetriever
Credentials
The node requires one of the following credentials:- elasticsearchApi
- elasticSearchUserPassword
Input Parameters
-
Document (optional, list)
- Type: Document
- Description: List of documents to be added to the vector store
-
Embeddings
- Type: Embeddings
- Description: Embedding model to use for vectorizing documents
-
Record Manager (optional)
- Type: RecordManager
- Description: Manages records to prevent duplication
-
Index Name
- Type: string
- Description: Name of the Elasticsearch index to use
-
Top K (optional)
- Type: number
- Default: 4
- Description: Number of top results to fetch
-
Similarity (optional)
- Type: options
- Default: l2_norm
- Options: l2_norm, dot_product, cosine
- Description: Similarity measure used in Elasticsearch
Outputs
-
Elasticsearch Retriever
- Type: retriever
- Base Classes: [Elasticsearch, VectorStoreRetriever, BaseRetriever]
-
Elasticsearch Vector Store
- Type: vectorStore
- Base Classes: [Elasticsearch, ElasticVectorSearch]
Functionality
Upsert Method
- Adds or updates documents in the Elasticsearch index
- Handles document flattening and metadata cleaning
- Supports record management to prevent duplication
Delete Method
- Deletes documents from the Elasticsearch index
- Supports deletion by IDs or using a record manager
Init Method
- Initializes the Elasticsearch vector store
- Creates a retriever or returns the vector store based on the output type
Usage
This node is used for:- Storing document embeddings in Elasticsearch
- Performing similarity searches on stored embeddings
- Retrieving relevant documents based on vector similarity