Back to Langflow

Elastic

docs/versioned_docs/version-1.9.0/Components/bundles-elastic.mdx

1.10.0.dev2010.2 KB
Original Source

import Icon from "@site/src/components/icon"; import PartialParams from '@site/docs/_partial-hidden-params.mdx'; import PartialConditionalParams from '@site/docs/_partial-conditional-params.mdx'; import PartialVectorSearchResults from '@site/docs/_partial-vector-search-results.mdx'; import PartialVectorStoreInstance from '@site/docs/_partial-vector-store-instance.mdx';

<Icon name="Blocks" aria-hidden="true" /> Bundles contain custom components that support specific third-party integrations with Langflow.

This page describes the components that are available in the Elastic bundle.

Elasticsearch

The Elasticsearch component reads and writes to an Elasticsearch instance using ElasticsearchStore.

<details> <summary>About vector store instances</summary> <PartialVectorStoreInstance /> </details> <PartialVectorSearchResults />

Elasticsearch parameters

You can inspect a vector store component's parameters to learn more about the inputs it accepts, the features it supports, and how to configure it.

<PartialParams /> <PartialConditionalParams />

For information about accepted values and functionality, see the Elasticsearch documentation or inspect component code.

NameTypeDescription
elasticsearch_urlStringInput parameter. Elasticsearch server URL.
cloud_idStringInput parameter. Elasticsearch Cloud ID.
index_nameStringInput parameter. Name of the Elasticsearch index.
ingest_dataJSONInput parameter. Records to load into the vector store.
search_queryStringInput parameter. Query string for similarity search.
cache_vector_storeBooleanInput parameter. If true, the component caches the vector store in memory for faster reads. Default: Enabled (true).
usernameStringInput parameter. Username for Elasticsearch authentication. Required for all local deployments. Required for cloud deployments if api_key is empty.
passwordSecretStringInput parameter. Password for Elasticsearch authentication. Required for all local deployments. Required for cloud deployments if api_key is empty
embeddingEmbeddingsInput parameter. The embedding model to use.
search_typeStringInput parameter. The type of search to perform. Options are similarity (default) or mmr.
number_of_resultsIntegerInput parameter. Number of search results to return. Default: 4.
search_score_thresholdFloatInput parameter. The minimum similarity score threshold for search results. Default: 0.
api_keySecretStringInput parameter. API key for Elastic Cloud authentication. If provided, username and password aren't required.
verify_certsBooleanInput parameter. Whether to verify SSL certificates when connecting to Elasticsearch. Default: Enabled (true).

OpenSearch

The OpenSearch component reads and writes to OpenSearch instances using OpenSearchVectorSearch.

<details> <summary>About vector store instances</summary> <PartialVectorStoreInstance /> </details>

OpenSearch parameters

You can inspect a vector store component's parameters to learn more about the inputs it accepts, the features it supports, and how to configure it.;

<PartialParams /> <PartialConditionalParams />

For information about accepted values and functionality, see the OpenSearch documentation or inspect component code.

NameTypeDescription
opensearch_urlStringInput parameter. URL for OpenSearch cluster, such as https://192.168.1.1:9200.
index_nameStringInput parameter. The index name where the vectors are stored in OpenSearch cluster. Default: langflow.
ingest_dataJSONInput parameter. The data to be ingested into the vector store.
search_inputStringInput parameter. Enter a search query. Leave empty to retrieve all documents or if hybrid search is being used.
cache_vector_storeBooleanInput parameter. If true, the component caches the vector store in memory for faster reads. Default: Enabled (true).
embeddingEmbeddingsInput parameter. Attach an embedding model component to use to generate an embedding from the search query.
search_typeStringInput parameter. The type of search to perform. Options are similarity (default), similarity_score_threshold, mmr.
number_of_resultsIntegerInput parameter. The number of results to return in search. Default: 4.
search_score_thresholdFloatInput parameter. The minimum similarity score threshold for search results. Default: 0.
usernameStringInput parameter. The username for the OpenSearch cluster. Default: admin.
passwordSecretStringInput parameter. The password for the OpenSearch cluster.
use_sslBooleanInput parameter. Whether to use SSL. Default: Enabled (true).
verify_certsBooleanInput parameter. Whether to verify SSL certificates. Default: Disabled (false).
hybrid_search_queryStringInput parameter. Provide a custom hybrid search query in JSON format. This allows you to combine vector similarity and keyword matching.

OpenSearch output

<PartialVectorSearchResults /> <details> <summary>Vector Store Connection port</summary>

The OpenSearch component has an additional deprecated Vector Store Connection output. This output can only connect to a VectorStore input port, and it was intended for use with dedicated Graph RAG components.

The OpenSearch component doesn't require a separate Graph RAG component because OpenSearch instances support Graph traversal through built-in RAG functionality and plugins.

</details>

OpenSearch (Multi-Model Multi-Embedding)

The OpenSearch (Multi-Model Multi-Embedding) component reads and writes to OpenSearch while supporting multiple embedding models in the same index. It creates dynamic embedding fields per model, detects which models are available in the index, and combines semantic and keyword search for hybrid retrieval.

<details> <summary>About vector store instances</summary> <PartialVectorStoreInstance /> </details>

OpenSearch (Multi-Model Multi-Embedding) parameters

You can inspect a vector store component's parameters to learn more about the inputs it accepts, the features it supports, and how to configure it.

<PartialParams /> <PartialConditionalParams />

For information about accepted values and functionality, see the OpenSearch documentation or inspect component code.

NameTypeDescription
docs_metadataTableInput parameter. Additional metadata key-value pairs to attach to every ingested document.
opensearch_urlStringInput parameter. URL for the OpenSearch cluster. Default: http://localhost:9200.
index_nameStringInput parameter. Name of the index to create or query. Default: langflow.
engineStringInput parameter. Vector engine to use. Options are nmslib, faiss, lucene, or jvector (default).
space_typeStringInput parameter. Distance metric for vector similarity. Options are l2 (default), l1, cosinesimil, linf, or innerproduct.
ef_constructionIntegerInput parameter. HNSW index-construction candidate list size. Default: 512.
mIntegerInput parameter. HNSW graph connection count. Default: 16.
num_candidatesIntegerInput parameter. Approximate-nearest-neighbor candidate pool size for KNN search. Set to 0 to disable it. Default: 1000.
ingest_dataJSONInput parameter. Data to ingest into the vector store.
search_queryStringInput parameter. Query string used by search_documents. Leave empty to ingest without searching.
should_cache_vector_storeBooleanInput parameter. If true, the component caches the vector store for the current build. Default: Enabled (true).
embeddingEmbeddingsInput parameter. One or more embedding components used for ingestion and search.
embedding_model_nameStringInput parameter. Selects which embedding model to use for ingestion. If omitted, the component uses the first available embedding.
vector_fieldStringInput parameter. Legacy vector field name used for backward compatibility. Default: chunk_embedding.
number_of_resultsIntegerInput parameter. Default maximum number of search results to return. Default: 10.
filter_expressionStringInput parameter. JSON filter, limit, and score-threshold configuration for search and raw search.
auth_modeStringInput parameter. Authentication mode. Options are basic or jwt. Default: jwt.
usernameStringInput parameter. Username for basic authentication. Default: admin.
passwordSecretStringInput parameter. Password for basic authentication. Default: admin.
jwt_tokenSecretStringInput parameter. JWT token for token-based authentication.
jwt_headerStringInput parameter. Header name used for JWT authentication. Default: Authorization.
bearer_prefixBooleanInput parameter. If enabled, prefixes the JWT token with Bearer . Default: Disabled (false).
use_sslBooleanInput parameter. Whether to use SSL/TLS for the connection. Default: Enabled (true).
verify_certsBooleanInput parameter. Whether to verify SSL certificates. Default: Disabled (false).
request_timeoutStringInput parameter. Timeout in seconds for OpenSearch requests. Default: 60.
max_retriesStringInput parameter. Number of retries for failed requests. Default: 3.

OpenSearch (Multi-Model Multi-Embedding) output

The component exposes:

  • search_results: Returns hybrid search results as a table of documents and metadata.
  • raw_search: Executes a raw OpenSearch query or a text query and returns the raw response.