ElasticSearchVectorStore
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:45
ElasticSearchVectorStore provides vector storage and similarity search capabilities using Elasticsearch. It extends BaseVectorStore to implement vector storage operations with Elasticsearch as the backend.
Extends
Section titled “Extends”BaseVectorStore
Constructors
Section titled “Constructors”Constructor
Section titled “Constructor”new ElasticSearchVectorStore(
init
):ElasticSearchVectorStore
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:66
Creates a new instance of ElasticSearchVectorStore
Parameters
Section titled “Parameters”ElasticSearchParams
Configuration parameters for Elasticsearch connection and indexing
Returns
Section titled “Returns”ElasticSearchVectorStore
Overrides
Section titled “Overrides”BaseVectorStore.constructor
Properties
Section titled “Properties”storesText
Section titled “storesText”storesText:
boolean
=true
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:46
Overrides
Section titled “Overrides”BaseVectorStore.storesText
Methods
Section titled “Methods”client()
Section titled “client()”client():
Client
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:99
Returns the Elasticsearch client instance
Returns
Section titled “Returns”Client
The configured Elasticsearch client
Overrides
Section titled “Overrides”BaseVectorStore.client
add(
nodes
):Promise
<string
[]>
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:145
Adds nodes to the vector store
Parameters
Section titled “Parameters”BaseNode
<Metadata
>[]
Array of BaseNode objects to store
Returns
Section titled “Returns”Promise
<string
[]>
Array of node IDs that were successfully stored
Throws
Section titled “Throws”Error if nodes don’t have embeddings
Overrides
Section titled “Overrides”BaseVectorStore.add
delete()
Section titled “delete()”delete(
refDocId
,deleteOptions?
):Promise
<void
>
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:189
Deletes nodes from the vector store by reference document ID
Parameters
Section titled “Parameters”refDocId
Section titled “refDocId”string
Reference document ID to delete
deleteOptions?
Section titled “deleteOptions?”object
Optional deletion parameters
Returns
Section titled “Returns”Promise
<void
>
Overrides
Section titled “Overrides”BaseVectorStore.delete
query()
Section titled “query()”query(
query
,options?
):Promise
<VectorStoreQueryResult
>
Defined in: .build/typescript/packages/providers/storage/elastic-search/src/ElasticSearchVector.ts:255
Performs a vector similarity search query
Parameters
Section titled “Parameters”VectorStoreQuery
Vector store query parameters
options?
Section titled “options?”object
Optional query parameters
Returns
Section titled “Returns”Promise
<VectorStoreQueryResult
>
Query results containing matching nodes, similarities, and IDs
Throws
Section titled “Throws”Error if query embedding is not provided
Overrides
Section titled “Overrides”BaseVectorStore.query