From c9323c6d1da883f9953b221c8807aa5555946ef0 Mon Sep 17 00:00:00 2001 From: "github-merge-queue[bot]" Date: Fri, 1 Aug 2025 21:51:45 +0000 Subject: [PATCH] deploy: 21f678dd903588deba8fb973e52fc04c4b8f5ba3 --- 404.html | 4 +- about-langflow.html | 4 +- agent-tutorial.html | 4 +- agents-tools.html | 4 +- agents.html | 4 +- api-build.html | 4 +- api-files.html | 4 +- api-flows-run.html | 4 +- api-flows.html | 4 +- api-keys-and-authentication.html | 4 +- api-logs.html | 4 +- api-monitor.html | 4 +- api-projects.html | 4 +- api-reference-api-examples.html | 4 +- api-users.html | 4 +- api.html | 4 +- api/add-server.html | 4 +- api/add-user.html | 4 +- api/auto-login.html | 4 +- api/build-flow.html | 4 +- api/build-public-tmp.html | 4 +- api/build-vertex-stream.html | 4 +- api/build-vertex.html | 4 +- api/cancel-build.html | 4 +- api/check-if-store-has-api-key.html | 4 +- api/check-if-store-is-enabled.html | 4 +- api/check-installed-mcp-servers.html | 4 +- api/create-api-key-route.html | 4 +- api/create-flow.html | 4 +- api/create-flows.html | 4 +- api/create-folder-redirect.html | 4 +- api/create-project.html | 4 +- api/create-upload-file.html | 4 +- api/create-variable.html | 4 +- api/custom-component-update.html | 4 +- api/custom-component.html | 4 +- api/delete-all-files-1.html | 4 +- api/delete-all-files.html | 4 +- api/delete-api-key-route.html | 4 +- api/delete-file-1.html | 4 +- api/delete-file.html | 4 +- api/delete-files-batch.html | 4 +- api/delete-flow.html | 4 +- api/delete-folder-redirect.html | 4 +- api/delete-messages-session.html | 4 +- api/delete-messages.html | 4 +- api/delete-multiple-flows.html | 4 +- api/delete-project.html | 4 +- api/delete-server.html | 4 +- api/delete-user.html | 4 +- api/delete-variable.html | 4 +- api/delete-vertex-builds.html | 4 +- api/download-component.html | 4 +- api/download-file-1.html | 4 +- api/download-file-2.html | 4 +- api/download-file-redirect.html | 4 +- api/download-file.html | 4 +- api/download-files-batch.html | 4 +- api/download-image.html | 4 +- api/download-multiple-file.html | 4 +- api/download-profile-picture.html | 4 +- api/edit-file-name.html | 4 +- api/experimental-run-flow.html | 4 +- api/get-all.html | 4 +- api/get-api-keys-route.html | 4 +- api/get-build-events.html | 4 +- api/get-components.html | 4 +- api/get-config.html | 4 +- api/get-elevenlabs-voice-ids.html | 4 +- api/get-list-of-components-liked-by-user.html | 4 +- api/get-message-sessions.html | 4 +- api/get-messages.html | 4 +- api/get-server-endpoint.html | 4 +- api/get-servers.html | 4 +- api/get-starter-projects.html | 4 +- api/get-tags.html | 4 +- api/get-task-status.html | 4 +- api/get-transactions.html | 4 +- api/get-version.html | 4 +- api/get-vertex-builds.html | 4 +- api/handle-messages-1.html | 4 +- api/handle-messages.html | 4 +- api/handle-project-messages-with-slash.html | 4 +- api/handle-project-messages.html | 4 +- api/handle-project-sse.html | 4 +- api/handle-sse-1.html | 4 +- api/handle-sse.html | 4 +- api/health-check.html | 4 +- api/health.html | 4 +- api/install-mcp-config.html | 4 +- api/like-component.html | 4 +- api/list-files-1.html | 4 +- api/list-files-2.html | 4 +- api/list-files.html | 4 +- api/list-profile-pictures.html | 4 +- api/list-project-tools.html | 4 +- api/login-to-get-access-token.html | 4 +- api/logout.html | 4 +- api/logs.html | 4 +- api/patch-user.html | 4 +- api/post-validate-code.html | 4 +- api/post-validate-prompt.html | 4 +- api/process-1.html | 4 +- api/process.html | 4 +- api/read-all-users.html | 4 +- api/read-basic-examples.html | 4 +- api/read-current-user.html | 4 +- api/read-flow.html | 4 +- api/read-flows.html | 4 +- api/read-folder-redirect.html | 4 +- api/read-folders-redirect.html | 4 +- api/read-project.html | 4 +- api/read-projects.html | 4 +- api/read-public-flow.html | 4 +- api/read-variables.html | 4 +- api/refresh-token.html | 4 +- api/reset-password.html | 4 +- api/retrieve-vertices-order.html | 4 +- api/save-store-api-key.html | 4 +- api/share-component.html | 4 +- api/simplified-run-flow.html | 4 +- api/stream-logs.html | 4 +- api/update-flow.html | 4 +- api/update-folder-redirect.html | 4 +- api/update-message.html | 4 +- api/update-project-mcp-settings.html | 4 +- api/update-project.html | 4 +- api/update-server-endpoint.html | 4 +- api/update-session-id.html | 4 +- api/update-shared-component.html | 4 +- api/update-variable.html | 4 +- api/upload-file-1.html | 4 +- api/upload-file-2.html | 4 +- api/upload-file-redirect.html | 4 +- api/upload-file.html | 4 +- api/upload-user-file-1.html | 4 +- api/upload-user-file.html | 4 +- api/webhook-run-flow.html | 4 +- assets/js/22dd74f7.5c39e0ad.js | 1 + assets/js/22dd74f7.6caa28b6.js | 1 - assets/js/2ab0d4f5.6e2f93d4.js | 1 - assets/js/2ab0d4f5.92a2d9ce.js | 1 + assets/js/2fed9fb3.d5bcbbb1.js | 1 - assets/js/2fed9fb3.fe18abd0.js | 1 + assets/js/453ae64a.82652dcf.js | 1 + assets/js/453ae64a.df8bb663.js | 1 - assets/js/47e58a89.60c6ebd1.js | 1 + assets/js/47e58a89.c862fb63.js | 1 - ...80a8a.07520397.js => 54980a8a.4ff06e8d.js} | 2 +- assets/js/56350599.6d836350.js | 1 + assets/js/56350599.fe58209b.js | 1 - assets/js/8cd0650d.5c230804.js | 1 - assets/js/8cd0650d.6337b7d2.js | 1 + assets/js/b37620f5.0af3186e.js | 1 - assets/js/b37620f5.28b34199.js | 1 + assets/js/bb45d4f9.88866337.js | 1 + assets/js/bb45d4f9.e32f398c.js | 1 - assets/js/d1f3cfe5.9b2b9b3e.js | 1 + assets/js/db4f3bbd.b937b0b2.js | 1 + assets/js/db4f3bbd.f25781b8.js | 1 - ...6a4d2.7d1513d4.js => e6c6a4d2.109611fc.js} | 2 +- assets/js/f0eeb72e.13f39c9c.js | 1 + assets/js/main.926a9998.js | 2 - assets/js/main.b26e5fa1.js | 2 + ...CENSE.txt => main.b26e5fa1.js.LICENSE.txt} | 0 ...n.01971d94.js => runtime~main.a0c27da5.js} | 2 +- bundles-aiml.html | 4 +- bundles-amazon.html | 4 +- bundles-anthropic.html | 4 +- bundles-arxiv.html | 4 +- bundles-azure.html | 4 +- bundles-baidu.html | 4 +- bundles-bing.html | 4 +- bundles-cloudflare.html | 4 +- bundles-cohere.html | 4 +- bundles-datastax.html | 4 +- bundles-deepseek.html | 4 +- bundles-duckduckgo.html | 4 +- bundles-exa.html | 4 +- bundles-glean.html | 4 +- bundles-google.html | 4 +- bundles-groq.html | 4 +- bundles-huggingface.html | 4 +- bundles-ibm.html | 6 +- bundles-icosacomputing.html | 4 +- bundles-langchain.html | 4 +- bundles-lmstudio.html | 4 +- bundles-maritalk.html | 4 +- bundles-mem0.html | 4 +- bundles-mistralai.html | 4 +- bundles-novita.html | 4 +- bundles-nvidia.html | 4 +- bundles-ollama.html | 4 +- bundles-openai.html | 4 +- bundles-openrouter.html | 4 +- bundles-perplexity.html | 4 +- bundles-redis.html | 4 +- bundles-sambanova.html | 4 +- bundles-searchapi.html | 4 +- bundles-vertexai.html | 4 +- bundles-wikipedia.html | 4 +- bundles-xai.html | 4 +- chat-with-files.html | 4 +- chat-with-rag.html | 4 +- components-agents.html | 4 +- components-bundle-components.html | 4 +- components-custom-components.html | 4 +- components-data.html | 4 +- components-embedding-models.html | 4 +- components-helpers.html | 4 +- components-io.html | 4 +- components-logic.html | 4 +- components-memories.html | 4 +- components-models.html | 4 +- components-processing.html | 4 +- components-prompts.html | 4 +- components-tools.html | 4 +- components-vector-stores.html | 4 +- concepts-components.html | 4 +- concepts-file-management.html | 6 +- concepts-flows-import.html | 4 +- concepts-flows.html | 4 +- concepts-overview.html | 4 +- concepts-playground.html | 4 +- concepts-publish.html | 4 +- concepts-voice-mode.html | 4 +- configuration-cli.html | 4 +- configuration-custom-database.html | 9 +- configuration-global-variables.html | 4 +- contributing-bundles.html | 4 +- contributing-community.html | 4 +- contributing-component-tests.html | 4 +- contributing-components.html | 4 +- contributing-github-issues.html | 4 +- contributing-how-to-contribute.html | 4 +- contributing-telemetry.html | 4 +- contributing-templates.html | 4 +- data-types.html | 4 +- deployment-architecture.html | 118 +++++++++ deployment-caddyfile.html | 8 +- deployment-docker.html | 6 +- deployment-gcp.html | 4 +- deployment-hugging-face-spaces.html | 4 +- deployment-kubernetes-dev.html | 71 +++--- deployment-kubernetes-prod.html | 140 +++++----- deployment-overview.html | 4 +- deployment-prod-best-practices.html | 141 ++++++---- deployment-public-server.html | 4 +- deployment-railway.html | 4 +- deployment-render.html | 4 +- develop-application.html | 8 +- enterprise-database-guide.html | 241 ++++++++++++++++++ environment-variables.html | 4 +- get-started-installation.html | 4 +- get-started-quickstart.html | 4 +- index.html | 4 +- install-custom-dependencies.html | 4 +- integrations-apify.html | 4 +- integrations-arize.html | 4 +- integrations-assemblyai.html | 4 +- integrations-cleanlab.html | 4 +- integrations-composio.html | 4 +- integrations-docling.html | 4 +- integrations-google-big-query.html | 4 +- integrations-langfuse.html | 4 +- integrations-langsmith.html | 4 +- integrations-langwatch.html | 4 +- integrations-nvidia-g-assist.html | 4 +- integrations-nvidia-ingest-wsl2.html | 4 +- integrations-nvidia-ingest.html | 4 +- integrations-opik.html | 4 +- .../notion/notion-agent-conversational.html | 4 +- .../notion/notion-agent-meeting-notes.html | 4 +- integrations/notion/setup.html | 4 +- logging.html | 6 +- luna-for-langflow.html | 4 +- mcp-client.html | 4 +- mcp-component-astra.html | 4 +- mcp-server.html | 4 +- mcp-tutorial.html | 4 +- memory.html | 14 +- release-notes.html | 4 +- search.html | 4 +- session-id.html | 6 +- sitemap.xml | 2 +- troubleshoot.html | 4 +- typescript-client.html | 4 +- webhook.html | 4 +- 288 files changed, 1114 insertions(+), 680 deletions(-) create mode 100644 assets/js/22dd74f7.5c39e0ad.js delete mode 100644 assets/js/22dd74f7.6caa28b6.js delete mode 100644 assets/js/2ab0d4f5.6e2f93d4.js create mode 100644 assets/js/2ab0d4f5.92a2d9ce.js delete mode 100644 assets/js/2fed9fb3.d5bcbbb1.js create mode 100644 assets/js/2fed9fb3.fe18abd0.js create mode 100644 assets/js/453ae64a.82652dcf.js delete mode 100644 assets/js/453ae64a.df8bb663.js create mode 100644 assets/js/47e58a89.60c6ebd1.js delete mode 100644 assets/js/47e58a89.c862fb63.js rename assets/js/{54980a8a.07520397.js => 54980a8a.4ff06e8d.js} (98%) create mode 100644 assets/js/56350599.6d836350.js delete mode 100644 assets/js/56350599.fe58209b.js delete mode 100644 assets/js/8cd0650d.5c230804.js create mode 100644 assets/js/8cd0650d.6337b7d2.js delete mode 100644 assets/js/b37620f5.0af3186e.js create mode 100644 assets/js/b37620f5.28b34199.js create mode 100644 assets/js/bb45d4f9.88866337.js delete mode 100644 assets/js/bb45d4f9.e32f398c.js create mode 100644 assets/js/d1f3cfe5.9b2b9b3e.js create mode 100644 assets/js/db4f3bbd.b937b0b2.js delete mode 100644 assets/js/db4f3bbd.f25781b8.js rename assets/js/{e6c6a4d2.7d1513d4.js => e6c6a4d2.109611fc.js} (56%) create mode 100644 assets/js/f0eeb72e.13f39c9c.js delete mode 100644 assets/js/main.926a9998.js create mode 100644 assets/js/main.b26e5fa1.js rename assets/js/{main.926a9998.js.LICENSE.txt => main.b26e5fa1.js.LICENSE.txt} (100%) rename assets/js/{runtime~main.01971d94.js => runtime~main.a0c27da5.js} (66%) create mode 100644 deployment-architecture.html create mode 100644 enterprise-database-guide.html diff --git a/404.html b/404.html index da06f88695..5aab8d56d9 100644 --- a/404.html +++ b/404.html @@ -23,8 +23,8 @@ - - + + diff --git a/about-langflow.html b/about-langflow.html index 9aba8b02a8..fca70abf97 100644 --- a/about-langflow.html +++ b/about-langflow.html @@ -23,8 +23,8 @@ - - + + diff --git a/agent-tutorial.html b/agent-tutorial.html index 80d51d954d..1335099754 100644 --- a/agent-tutorial.html +++ b/agent-tutorial.html @@ -23,8 +23,8 @@ - - + + diff --git a/agents-tools.html b/agents-tools.html index 8de8bbfc34..a3b6267723 100644 --- a/agents-tools.html +++ b/agents-tools.html @@ -23,8 +23,8 @@ - - + + diff --git a/agents.html b/agents.html index 0764526f5c..45bec5cd2c 100644 --- a/agents.html +++ b/agents.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-build.html b/api-build.html index 475689cd9a..39323ef961 100644 --- a/api-build.html +++ b/api-build.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-files.html b/api-files.html index 3b6615502c..d2bb3ab0fb 100644 --- a/api-files.html +++ b/api-files.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-flows-run.html b/api-flows-run.html index 4bb11dff08..24cea23098 100644 --- a/api-flows-run.html +++ b/api-flows-run.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-flows.html b/api-flows.html index 87fe2ebd38..f8c32cddba 100644 --- a/api-flows.html +++ b/api-flows.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-keys-and-authentication.html b/api-keys-and-authentication.html index 33bdf68593..0e16594ab4 100644 --- a/api-keys-and-authentication.html +++ b/api-keys-and-authentication.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-logs.html b/api-logs.html index 7bf587fbb9..e321707933 100644 --- a/api-logs.html +++ b/api-logs.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-monitor.html b/api-monitor.html index fc8d1a2bad..0c5e1a6ea0 100644 --- a/api-monitor.html +++ b/api-monitor.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-projects.html b/api-projects.html index 6e4d849a3c..0d5b706789 100644 --- a/api-projects.html +++ b/api-projects.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-reference-api-examples.html b/api-reference-api-examples.html index b4c95fe8a7..6bf2f20205 100644 --- a/api-reference-api-examples.html +++ b/api-reference-api-examples.html @@ -23,8 +23,8 @@ - - + + diff --git a/api-users.html b/api-users.html index 225db93404..aedb2962c5 100644 --- a/api-users.html +++ b/api-users.html @@ -23,8 +23,8 @@ - - + + diff --git a/api.html b/api.html index adc95b9078..8f9714c835 100644 --- a/api.html +++ b/api.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/add-server.html b/api/add-server.html index 2bb8de1112..369f7b3432 100644 --- a/api/add-server.html +++ b/api/add-server.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/add-user.html b/api/add-user.html index 01bcd28430..58a52f6547 100644 --- a/api/add-user.html +++ b/api/add-user.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/auto-login.html b/api/auto-login.html index b39292f94a..f20ed1248e 100644 --- a/api/auto-login.html +++ b/api/auto-login.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/build-flow.html b/api/build-flow.html index e3e410b408..2bf962377c 100644 --- a/api/build-flow.html +++ b/api/build-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/build-public-tmp.html b/api/build-public-tmp.html index a05e0d3730..02908052a1 100644 --- a/api/build-public-tmp.html +++ b/api/build-public-tmp.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/build-vertex-stream.html b/api/build-vertex-stream.html index 14b24d9590..73ecb63022 100644 --- a/api/build-vertex-stream.html +++ b/api/build-vertex-stream.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/build-vertex.html b/api/build-vertex.html index f00f86eb09..146483f0c5 100644 --- a/api/build-vertex.html +++ b/api/build-vertex.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/cancel-build.html b/api/cancel-build.html index a2a5a6d2b9..daf98f410c 100644 --- a/api/cancel-build.html +++ b/api/cancel-build.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/check-if-store-has-api-key.html b/api/check-if-store-has-api-key.html index 82ae690696..3e69a40d55 100644 --- a/api/check-if-store-has-api-key.html +++ b/api/check-if-store-has-api-key.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/check-if-store-is-enabled.html b/api/check-if-store-is-enabled.html index cd8fccdd09..1ef3d064b7 100644 --- a/api/check-if-store-is-enabled.html +++ b/api/check-if-store-is-enabled.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/check-installed-mcp-servers.html b/api/check-installed-mcp-servers.html index 0718c01c49..5ba9ce5d2d 100644 --- a/api/check-installed-mcp-servers.html +++ b/api/check-installed-mcp-servers.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-api-key-route.html b/api/create-api-key-route.html index c09c63a1cc..3056633978 100644 --- a/api/create-api-key-route.html +++ b/api/create-api-key-route.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-flow.html b/api/create-flow.html index a30e54d36a..c84b87dd8c 100644 --- a/api/create-flow.html +++ b/api/create-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-flows.html b/api/create-flows.html index 3acb09f39c..a9a4b00c49 100644 --- a/api/create-flows.html +++ b/api/create-flows.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-folder-redirect.html b/api/create-folder-redirect.html index efdc41dc2b..d164c184c8 100644 --- a/api/create-folder-redirect.html +++ b/api/create-folder-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-project.html b/api/create-project.html index 4d3d254c24..77c1de750d 100644 --- a/api/create-project.html +++ b/api/create-project.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-upload-file.html b/api/create-upload-file.html index 942b0592db..4beb1b4be8 100644 --- a/api/create-upload-file.html +++ b/api/create-upload-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/create-variable.html b/api/create-variable.html index 7394e3c296..5da6329f33 100644 --- a/api/create-variable.html +++ b/api/create-variable.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/custom-component-update.html b/api/custom-component-update.html index be6897fe4b..71d0aafe42 100644 --- a/api/custom-component-update.html +++ b/api/custom-component-update.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/custom-component.html b/api/custom-component.html index d3a2ef7144..00dffa1b17 100644 --- a/api/custom-component.html +++ b/api/custom-component.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-all-files-1.html b/api/delete-all-files-1.html index d0a683a7be..a27ba67ade 100644 --- a/api/delete-all-files-1.html +++ b/api/delete-all-files-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-all-files.html b/api/delete-all-files.html index db8c31f8a4..ffe45680d2 100644 --- a/api/delete-all-files.html +++ b/api/delete-all-files.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-api-key-route.html b/api/delete-api-key-route.html index 3f36b057bc..893bc43e27 100644 --- a/api/delete-api-key-route.html +++ b/api/delete-api-key-route.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-file-1.html b/api/delete-file-1.html index 7c5c4acfee..b175a16484 100644 --- a/api/delete-file-1.html +++ b/api/delete-file-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-file.html b/api/delete-file.html index fe4fda6c11..c5b30de7eb 100644 --- a/api/delete-file.html +++ b/api/delete-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-files-batch.html b/api/delete-files-batch.html index b934ed42a0..b100e9a578 100644 --- a/api/delete-files-batch.html +++ b/api/delete-files-batch.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-flow.html b/api/delete-flow.html index d0f963703f..9de9885785 100644 --- a/api/delete-flow.html +++ b/api/delete-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-folder-redirect.html b/api/delete-folder-redirect.html index c7d27f6e3c..57438a1fae 100644 --- a/api/delete-folder-redirect.html +++ b/api/delete-folder-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-messages-session.html b/api/delete-messages-session.html index 2dd9e3699b..d26f710c2f 100644 --- a/api/delete-messages-session.html +++ b/api/delete-messages-session.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-messages.html b/api/delete-messages.html index 83493ce1b0..0f6b94463e 100644 --- a/api/delete-messages.html +++ b/api/delete-messages.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-multiple-flows.html b/api/delete-multiple-flows.html index d956284d62..0f4ca3f8ff 100644 --- a/api/delete-multiple-flows.html +++ b/api/delete-multiple-flows.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-project.html b/api/delete-project.html index 2fcfdc2f9d..cbcaa8afb2 100644 --- a/api/delete-project.html +++ b/api/delete-project.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-server.html b/api/delete-server.html index f04f52c6f8..1b449ad3c8 100644 --- a/api/delete-server.html +++ b/api/delete-server.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-user.html b/api/delete-user.html index 423e5e9f0c..67e8726582 100644 --- a/api/delete-user.html +++ b/api/delete-user.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-variable.html b/api/delete-variable.html index 6a6007f099..64db736aad 100644 --- a/api/delete-variable.html +++ b/api/delete-variable.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/delete-vertex-builds.html b/api/delete-vertex-builds.html index 9f828818a1..3525b9630e 100644 --- a/api/delete-vertex-builds.html +++ b/api/delete-vertex-builds.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-component.html b/api/download-component.html index 377dabbd73..278e6c3553 100644 --- a/api/download-component.html +++ b/api/download-component.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-file-1.html b/api/download-file-1.html index 7168c8ea5a..6f32e5658c 100644 --- a/api/download-file-1.html +++ b/api/download-file-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-file-2.html b/api/download-file-2.html index 7bd7b79a95..28ebcdfce4 100644 --- a/api/download-file-2.html +++ b/api/download-file-2.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-file-redirect.html b/api/download-file-redirect.html index 3e25b4420b..1ca5f3c20c 100644 --- a/api/download-file-redirect.html +++ b/api/download-file-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-file.html b/api/download-file.html index 14e225d135..564dbdcd7a 100644 --- a/api/download-file.html +++ b/api/download-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-files-batch.html b/api/download-files-batch.html index dcf1c250b9..c4d1935779 100644 --- a/api/download-files-batch.html +++ b/api/download-files-batch.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-image.html b/api/download-image.html index 8d8c84f87b..e60f1c6ce2 100644 --- a/api/download-image.html +++ b/api/download-image.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-multiple-file.html b/api/download-multiple-file.html index 9b4f91ba12..f3f87f504a 100644 --- a/api/download-multiple-file.html +++ b/api/download-multiple-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/download-profile-picture.html b/api/download-profile-picture.html index 4fe8404db2..86e97b195b 100644 --- a/api/download-profile-picture.html +++ b/api/download-profile-picture.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/edit-file-name.html b/api/edit-file-name.html index 39afd71178..7b5a898260 100644 --- a/api/edit-file-name.html +++ b/api/edit-file-name.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/experimental-run-flow.html b/api/experimental-run-flow.html index efc6f268fe..410cd7bb36 100644 --- a/api/experimental-run-flow.html +++ b/api/experimental-run-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-all.html b/api/get-all.html index 4b1c849ed6..d34c0d8873 100644 --- a/api/get-all.html +++ b/api/get-all.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-api-keys-route.html b/api/get-api-keys-route.html index 66d862f9aa..e2f608c7c0 100644 --- a/api/get-api-keys-route.html +++ b/api/get-api-keys-route.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-build-events.html b/api/get-build-events.html index 3bd3125226..b37ddafeaa 100644 --- a/api/get-build-events.html +++ b/api/get-build-events.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-components.html b/api/get-components.html index d8b8515e7d..18490322dd 100644 --- a/api/get-components.html +++ b/api/get-components.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-config.html b/api/get-config.html index 6eec0ed5e0..aa3f7b47ff 100644 --- a/api/get-config.html +++ b/api/get-config.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-elevenlabs-voice-ids.html b/api/get-elevenlabs-voice-ids.html index a2a5a132d7..7d1aa3eb4e 100644 --- a/api/get-elevenlabs-voice-ids.html +++ b/api/get-elevenlabs-voice-ids.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-list-of-components-liked-by-user.html b/api/get-list-of-components-liked-by-user.html index ae7a1dcec5..ed1c432743 100644 --- a/api/get-list-of-components-liked-by-user.html +++ b/api/get-list-of-components-liked-by-user.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-message-sessions.html b/api/get-message-sessions.html index 3b5c4fdba6..6462bcf057 100644 --- a/api/get-message-sessions.html +++ b/api/get-message-sessions.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-messages.html b/api/get-messages.html index df312e45fa..b04869a8e4 100644 --- a/api/get-messages.html +++ b/api/get-messages.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-server-endpoint.html b/api/get-server-endpoint.html index b114944898..58f044bac0 100644 --- a/api/get-server-endpoint.html +++ b/api/get-server-endpoint.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-servers.html b/api/get-servers.html index 2b41fc7031..cdc222fe9d 100644 --- a/api/get-servers.html +++ b/api/get-servers.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-starter-projects.html b/api/get-starter-projects.html index 7ebc2b9729..acd9fd6e75 100644 --- a/api/get-starter-projects.html +++ b/api/get-starter-projects.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-tags.html b/api/get-tags.html index 485fef025c..7a51d49dbf 100644 --- a/api/get-tags.html +++ b/api/get-tags.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-task-status.html b/api/get-task-status.html index 1862dd899b..805fa25b5e 100644 --- a/api/get-task-status.html +++ b/api/get-task-status.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-transactions.html b/api/get-transactions.html index b388ce4adc..3c8f230b73 100644 --- a/api/get-transactions.html +++ b/api/get-transactions.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-version.html b/api/get-version.html index 3cc0e746b7..7ed53d3768 100644 --- a/api/get-version.html +++ b/api/get-version.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/get-vertex-builds.html b/api/get-vertex-builds.html index 089cf52447..1c4fb8a218 100644 --- a/api/get-vertex-builds.html +++ b/api/get-vertex-builds.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-messages-1.html b/api/handle-messages-1.html index 81616e18fc..a3d65abe64 100644 --- a/api/handle-messages-1.html +++ b/api/handle-messages-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-messages.html b/api/handle-messages.html index a6ae8fa48f..a8d8f4c0e3 100644 --- a/api/handle-messages.html +++ b/api/handle-messages.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-project-messages-with-slash.html b/api/handle-project-messages-with-slash.html index d852ebb2f5..3e0fd7ec67 100644 --- a/api/handle-project-messages-with-slash.html +++ b/api/handle-project-messages-with-slash.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-project-messages.html b/api/handle-project-messages.html index 1522e7d2aa..4e38d3b034 100644 --- a/api/handle-project-messages.html +++ b/api/handle-project-messages.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-project-sse.html b/api/handle-project-sse.html index 6ebfa7c63c..cd03b70f19 100644 --- a/api/handle-project-sse.html +++ b/api/handle-project-sse.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-sse-1.html b/api/handle-sse-1.html index 8dc67bdbd9..044ede43f5 100644 --- a/api/handle-sse-1.html +++ b/api/handle-sse-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/handle-sse.html b/api/handle-sse.html index 4556cc6abe..187666d7a5 100644 --- a/api/handle-sse.html +++ b/api/handle-sse.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/health-check.html b/api/health-check.html index f9ae994968..0373563e33 100644 --- a/api/health-check.html +++ b/api/health-check.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/health.html b/api/health.html index 9825e128e6..7f3984ce5d 100644 --- a/api/health.html +++ b/api/health.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/install-mcp-config.html b/api/install-mcp-config.html index d60327fd83..0ccf07082e 100644 --- a/api/install-mcp-config.html +++ b/api/install-mcp-config.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/like-component.html b/api/like-component.html index 604dabc964..d8c13eaf67 100644 --- a/api/like-component.html +++ b/api/like-component.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/list-files-1.html b/api/list-files-1.html index 1c3066381e..ce52d1be0a 100644 --- a/api/list-files-1.html +++ b/api/list-files-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/list-files-2.html b/api/list-files-2.html index b5da4b48a7..ca6b4b574b 100644 --- a/api/list-files-2.html +++ b/api/list-files-2.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/list-files.html b/api/list-files.html index aa09ca2b87..7a19ec769c 100644 --- a/api/list-files.html +++ b/api/list-files.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/list-profile-pictures.html b/api/list-profile-pictures.html index b169426446..38d7446f1d 100644 --- a/api/list-profile-pictures.html +++ b/api/list-profile-pictures.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/list-project-tools.html b/api/list-project-tools.html index db02aff299..655355f303 100644 --- a/api/list-project-tools.html +++ b/api/list-project-tools.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/login-to-get-access-token.html b/api/login-to-get-access-token.html index 8e096b4357..5d7d94b031 100644 --- a/api/login-to-get-access-token.html +++ b/api/login-to-get-access-token.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/logout.html b/api/logout.html index fb2b6bfac1..dd9c67a7a4 100644 --- a/api/logout.html +++ b/api/logout.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/logs.html b/api/logs.html index 72cf88e139..4daf5897ff 100644 --- a/api/logs.html +++ b/api/logs.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/patch-user.html b/api/patch-user.html index 46aae11557..e126feb49b 100644 --- a/api/patch-user.html +++ b/api/patch-user.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/post-validate-code.html b/api/post-validate-code.html index 8609fabe8b..22cdf8b3f2 100644 --- a/api/post-validate-code.html +++ b/api/post-validate-code.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/post-validate-prompt.html b/api/post-validate-prompt.html index ef70577163..a8bc9865dd 100644 --- a/api/post-validate-prompt.html +++ b/api/post-validate-prompt.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/process-1.html b/api/process-1.html index 9f0ebd8c7a..5b4a9604b3 100644 --- a/api/process-1.html +++ b/api/process-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/process.html b/api/process.html index 1d06d1a1b2..38bdc9b3bc 100644 --- a/api/process.html +++ b/api/process.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-all-users.html b/api/read-all-users.html index f7529c572e..dd7ee60ab3 100644 --- a/api/read-all-users.html +++ b/api/read-all-users.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-basic-examples.html b/api/read-basic-examples.html index be4c83a71f..5753e5bb4f 100644 --- a/api/read-basic-examples.html +++ b/api/read-basic-examples.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-current-user.html b/api/read-current-user.html index 6e0af8726e..9c39988b01 100644 --- a/api/read-current-user.html +++ b/api/read-current-user.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-flow.html b/api/read-flow.html index 81a4009a17..27a269878c 100644 --- a/api/read-flow.html +++ b/api/read-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-flows.html b/api/read-flows.html index 5888dd896b..572e2d3703 100644 --- a/api/read-flows.html +++ b/api/read-flows.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-folder-redirect.html b/api/read-folder-redirect.html index 68f912edd9..6c813e8869 100644 --- a/api/read-folder-redirect.html +++ b/api/read-folder-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-folders-redirect.html b/api/read-folders-redirect.html index 4bf177d539..676f4b9703 100644 --- a/api/read-folders-redirect.html +++ b/api/read-folders-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-project.html b/api/read-project.html index 7addab8bbd..ae9f5a357e 100644 --- a/api/read-project.html +++ b/api/read-project.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-projects.html b/api/read-projects.html index 72f09265e2..6b7d0c81b7 100644 --- a/api/read-projects.html +++ b/api/read-projects.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-public-flow.html b/api/read-public-flow.html index ffce3987dc..1e686691d2 100644 --- a/api/read-public-flow.html +++ b/api/read-public-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/read-variables.html b/api/read-variables.html index 452816e1e7..939967c046 100644 --- a/api/read-variables.html +++ b/api/read-variables.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/refresh-token.html b/api/refresh-token.html index b11ad98586..35cc87c6e6 100644 --- a/api/refresh-token.html +++ b/api/refresh-token.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/reset-password.html b/api/reset-password.html index ca139971e5..ac277d2e60 100644 --- a/api/reset-password.html +++ b/api/reset-password.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/retrieve-vertices-order.html b/api/retrieve-vertices-order.html index 51f19e20bc..fa31b0c5c2 100644 --- a/api/retrieve-vertices-order.html +++ b/api/retrieve-vertices-order.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/save-store-api-key.html b/api/save-store-api-key.html index 41b569e09a..9aa4938916 100644 --- a/api/save-store-api-key.html +++ b/api/save-store-api-key.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/share-component.html b/api/share-component.html index 3d5ea3fca5..f43aef9cbe 100644 --- a/api/share-component.html +++ b/api/share-component.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/simplified-run-flow.html b/api/simplified-run-flow.html index 635f0a1ea1..8433eee05b 100644 --- a/api/simplified-run-flow.html +++ b/api/simplified-run-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/stream-logs.html b/api/stream-logs.html index 61f6b73c1e..f6638f3b40 100644 --- a/api/stream-logs.html +++ b/api/stream-logs.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-flow.html b/api/update-flow.html index 4da2fd4b52..b1af0315f5 100644 --- a/api/update-flow.html +++ b/api/update-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-folder-redirect.html b/api/update-folder-redirect.html index 3ca1a39cf3..5f649b65a0 100644 --- a/api/update-folder-redirect.html +++ b/api/update-folder-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-message.html b/api/update-message.html index df0f4ac068..4b1d3f422b 100644 --- a/api/update-message.html +++ b/api/update-message.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-project-mcp-settings.html b/api/update-project-mcp-settings.html index 30f754cee4..a44ba0e116 100644 --- a/api/update-project-mcp-settings.html +++ b/api/update-project-mcp-settings.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-project.html b/api/update-project.html index 1f024902cb..f0ddfa0766 100644 --- a/api/update-project.html +++ b/api/update-project.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-server-endpoint.html b/api/update-server-endpoint.html index adca51f8f6..82bf98796c 100644 --- a/api/update-server-endpoint.html +++ b/api/update-server-endpoint.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-session-id.html b/api/update-session-id.html index 6f650a7b6d..3ad1813045 100644 --- a/api/update-session-id.html +++ b/api/update-session-id.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-shared-component.html b/api/update-shared-component.html index c57d390aed..1b5f741ca3 100644 --- a/api/update-shared-component.html +++ b/api/update-shared-component.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/update-variable.html b/api/update-variable.html index d58e9eef78..c651ba91f3 100644 --- a/api/update-variable.html +++ b/api/update-variable.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-file-1.html b/api/upload-file-1.html index 45cc9d7fc8..f82d1b6e0f 100644 --- a/api/upload-file-1.html +++ b/api/upload-file-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-file-2.html b/api/upload-file-2.html index 805859e904..0c63b86ca6 100644 --- a/api/upload-file-2.html +++ b/api/upload-file-2.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-file-redirect.html b/api/upload-file-redirect.html index c303b25188..50394c7512 100644 --- a/api/upload-file-redirect.html +++ b/api/upload-file-redirect.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-file.html b/api/upload-file.html index b48ab7832c..3fcbd175dd 100644 --- a/api/upload-file.html +++ b/api/upload-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-user-file-1.html b/api/upload-user-file-1.html index 23f3f898f9..3a4f8da91e 100644 --- a/api/upload-user-file-1.html +++ b/api/upload-user-file-1.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/upload-user-file.html b/api/upload-user-file.html index 396e247d00..2200228bda 100644 --- a/api/upload-user-file.html +++ b/api/upload-user-file.html @@ -23,8 +23,8 @@ - - + + diff --git a/api/webhook-run-flow.html b/api/webhook-run-flow.html index 38e61a8c78..dda6878382 100644 --- a/api/webhook-run-flow.html +++ b/api/webhook-run-flow.html @@ -23,8 +23,8 @@ - - + + diff --git a/assets/js/22dd74f7.5c39e0ad.js b/assets/js/22dd74f7.5c39e0ad.js new file mode 100644 index 0000000000..aa42784a17 --- /dev/null +++ b/assets/js/22dd74f7.5c39e0ad.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1567],{55226:e=>{e.exports=JSON.parse('{"version":{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"noIndex":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"docs":[{"type":"link","label":"Welcome to Langflow","href":"/","docId":"Get-Started/welcome-to-langflow","unlisted":false},{"type":"category","label":"Get started","items":[{"type":"link","label":"About Langflow","href":"/about-langflow","docId":"Get-Started/about-langflow","unlisted":false},{"type":"link","label":"Install Langflow","href":"/get-started-installation","docId":"Get-Started/get-started-installation","unlisted":false},{"type":"link","label":"Quickstart","href":"/get-started-quickstart","docId":"Get-Started/get-started-quickstart","unlisted":false},{"type":"category","label":"Tutorials","items":[{"type":"link","label":"Create a vector RAG chatbot","href":"/chat-with-rag","docId":"Tutorials/chat-with-rag","unlisted":false},{"type":"link","label":"Create a chatbot that can ingest files","href":"/chat-with-files","docId":"Tutorials/chat-with-files","unlisted":false},{"type":"link","label":"Connect applications to agents","href":"/agent-tutorial","docId":"Tutorials/agent","unlisted":false},{"type":"link","label":"Connect to MCP servers from your application","href":"/mcp-tutorial","docId":"Tutorials/mcp-tutorial","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Flows","items":[{"type":"link","label":"Use the visual editor","href":"/concepts-overview","docId":"Concepts/concepts-overview","unlisted":false},{"type":"link","label":"Build flows","href":"/concepts-flows","docId":"Concepts/concepts-flows","unlisted":false},{"type":"category","label":"Run flows","items":[{"type":"link","label":"Trigger flows with the Langflow API","href":"/concepts-publish","docId":"Concepts/concepts-publish","unlisted":false},{"type":"link","label":"Trigger flows with webhooks","href":"/webhook","docId":"Develop/webhook","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Test flows","href":"/concepts-playground","docId":"Concepts/concepts-playground","unlisted":false},{"type":"link","label":"Import and export flows","href":"/concepts-flows-import","docId":"Concepts/concepts-flows-import","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Agents","items":[{"type":"link","label":"Use Langflow agents","href":"/agents","docId":"Agents/agents","unlisted":false},{"type":"link","label":"Configure tools for agents","href":"/agents-tools","docId":"Agents/agents-tools","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Model Context Protocol (MCP)","items":[{"type":"link","label":"Use Langflow as an MCP client","href":"/mcp-client","docId":"Components/mcp-client","unlisted":false},{"type":"link","label":"Use Langflow as an MCP server","href":"/mcp-server","docId":"Concepts/mcp-server","unlisted":false},{"type":"link","label":"Connect an Astra DB MCP server to Langflow","href":"/mcp-component-astra","docId":"Integrations/mcp-component-astra","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Develop","items":[{"type":"link","label":"API keys and authentication","href":"/api-keys-and-authentication","docId":"Configuration/api-keys-and-authentication","unlisted":false},{"type":"link","label":"Install custom dependencies","href":"/install-custom-dependencies","docId":"Develop/install-custom-dependencies","unlisted":false},{"type":"link","label":"Global variables","href":"/configuration-global-variables","docId":"Configuration/configuration-global-variables","unlisted":false},{"type":"link","label":"Environment variables","href":"/environment-variables","docId":"Configuration/environment-variables","unlisted":false},{"type":"category","label":"Storage and memory","items":[{"type":"link","label":"Manage files","href":"/concepts-file-management","docId":"Concepts/concepts-file-management","unlisted":false},{"type":"link","label":"Manage memory","href":"/memory","docId":"Develop/memory","unlisted":false},{"type":"link","label":"Use Session IDs","href":"/session-id","docId":"Develop/session-id","unlisted":false},{"type":"link","label":"Configure an external PostgreSQL database","href":"/configuration-custom-database","docId":"Configuration/configuration-custom-database","unlisted":false},{"type":"link","label":"Database guide for enterprise administrators","href":"/enterprise-database-guide","docId":"Develop/enterprise-database-guide","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Observability","items":[{"type":"link","label":"Logs","href":"/logging","docId":"Develop/logging","unlisted":false},{"type":"category","label":"Monitoring","items":[{"type":"link","label":"Arize","href":"/integrations-arize","docId":"Integrations/Arize/integrations-arize","unlisted":false},{"type":"link","label":"Langfuse","href":"/integrations-langfuse","docId":"Integrations/integrations-langfuse","unlisted":false},{"type":"link","label":"LangSmith","href":"/integrations-langsmith","docId":"Integrations/integrations-langsmith","unlisted":false},{"type":"link","label":"LangWatch","href":"/integrations-langwatch","docId":"Integrations/integrations-langwatch","unlisted":false},{"type":"link","label":"Opik","href":"/integrations-opik","docId":"Integrations/integrations-opik","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Telemetry","href":"/contributing-telemetry","docId":"Contributing/contributing-telemetry","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Use Langflow data types","href":"/data-types","docId":"Concepts/data-types","unlisted":false},{"type":"link","label":"Use voice mode","href":"/concepts-voice-mode","docId":"Concepts/concepts-voice-mode","unlisted":false},{"type":"link","label":"Use the Langflow CLI","href":"/configuration-cli","docId":"Configuration/configuration-cli","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Deploy","items":[{"type":"link","label":"Langflow deployment overview","href":"/deployment-overview","docId":"Deployment/deployment-overview","unlisted":false},{"type":"link","label":"Deploy a public Langflow server","href":"/deployment-public-server","docId":"Deployment/deployment-public-server","unlisted":false},{"type":"category","label":"Containerized deployments","items":[{"type":"link","label":"Containerize a Langflow application","href":"/develop-application","docId":"Develop/develop-application","unlisted":false},{"type":"link","label":"Langflow Docker images","href":"/deployment-docker","docId":"Deployment/deployment-docker","unlisted":false},{"type":"link","label":"Deploy Langflow on a remote server","href":"/deployment-caddyfile","docId":"Deployment/deployment-caddyfile","unlisted":false},{"type":"category","label":"Kubernetes","items":[{"type":"link","label":"Deployment architecture","href":"/deployment-architecture","docId":"Deployment/deployment-architecture","unlisted":false},{"type":"link","label":"Best practices","href":"/deployment-prod-best-practices","docId":"Deployment/deployment-prod-best-practices","unlisted":false},{"type":"link","label":"Deploy in development","href":"/deployment-kubernetes-dev","docId":"Deployment/deployment-kubernetes-dev","unlisted":false},{"type":"link","label":"Deploy in production","href":"/deployment-kubernetes-prod","docId":"Deployment/deployment-kubernetes-prod","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Cloud platforms","items":[{"type":"link","label":"Google Cloud Platform","href":"/deployment-gcp","docId":"Deployment/deployment-gcp","unlisted":false},{"type":"link","label":"Hugging Face Spaces","href":"/deployment-hugging-face-spaces","docId":"Deployment/deployment-hugging-face-spaces","unlisted":false},{"type":"link","label":"Railway","href":"/deployment-railway","docId":"Deployment/deployment-railway","unlisted":false},{"type":"link","label":"Render","href":"/deployment-render","docId":"Deployment/deployment-render","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Components reference","items":[{"type":"link","label":"Components overview","href":"/concepts-components","docId":"Concepts/concepts-components","unlisted":false},{"type":"category","label":"Core components","items":[{"type":"link","label":"Input / Output","href":"/components-io","docId":"Components/components-io","unlisted":false},{"type":"link","label":"Agents","href":"/components-agents","docId":"Components/components-agents","unlisted":false},{"type":"category","label":"Models","items":[{"type":"link","label":"Language Model","href":"/components-models","docId":"Components/components-models","unlisted":false},{"type":"link","label":"Embedding Model","href":"/components-embedding-models","docId":"Components/components-embedding-models","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Data","href":"/components-data","docId":"Components/components-data","unlisted":false},{"type":"link","label":"Vector Stores","href":"/components-vector-stores","docId":"Components/components-vector-stores","unlisted":false},{"type":"category","label":"Processing","items":[{"type":"link","label":"Processing components","href":"/components-processing","docId":"Components/components-processing","unlisted":false},{"type":"link","label":"Prompt Template","href":"/components-prompts","docId":"Components/components-prompts","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Logic","href":"/components-logic","docId":"Components/components-logic","unlisted":false},{"type":"link","label":"Helpers","href":"/components-helpers","docId":"Components/components-helpers","unlisted":false},{"type":"link","label":"Tools","href":"/components-tools","docId":"Components/components-tools","unlisted":false},{"type":"link","label":"Memories","href":"/components-memories","docId":"Components/components-memories","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Bundles","items":[{"type":"link","label":"About bundles","href":"/components-bundle-components","docId":"Components/components-bundles","unlisted":false},{"type":"link","label":"AI/ML API","href":"/bundles-aiml","docId":"Components/bundles-aiml","unlisted":false},{"type":"link","label":"Amazon","href":"/bundles-amazon","docId":"Components/bundles-amazon","unlisted":false},{"type":"link","label":"Anthropic","href":"/bundles-anthropic","docId":"Components/bundles-anthropic","unlisted":false},{"type":"link","label":"Apify","href":"/integrations-apify","docId":"Integrations/Apify/integrations-apify","unlisted":false},{"type":"link","label":"arXiv","href":"/bundles-arxiv","docId":"Components/bundles-arxiv","unlisted":false},{"type":"link","label":"AssemblyAI","href":"/integrations-assemblyai","docId":"Integrations/integrations-assemblyai","unlisted":false},{"type":"link","label":"Azure","href":"/bundles-azure","docId":"Components/bundles-azure","unlisted":false},{"type":"link","label":"Baidu","href":"/bundles-baidu","docId":"Components/bundles-baidu","unlisted":false},{"type":"link","label":"Bing","href":"/bundles-bing","docId":"Components/bundles-bing","unlisted":false},{"type":"link","label":"Cleanlab","href":"/integrations-cleanlab","docId":"Integrations/Cleanlab/integrations-cleanlab","unlisted":false},{"type":"link","label":"Cloudflare","href":"/bundles-cloudflare","docId":"Components/bundles-cloudflare","unlisted":false},{"type":"link","label":"Cohere","href":"/bundles-cohere","docId":"Components/bundles-cohere","unlisted":false},{"type":"link","label":"Composio","href":"/integrations-composio","docId":"Integrations/Composio/integrations-composio","unlisted":false},{"type":"link","label":"DataStax","href":"/bundles-datastax","docId":"Components/bundles-datastax","unlisted":false},{"type":"link","label":"DeepSeek","href":"/bundles-deepseek","docId":"Components/bundles-deepseek","unlisted":false},{"type":"link","label":"Docling","href":"/integrations-docling","docId":"Integrations/Docling/integrations-docling","unlisted":false},{"type":"link","label":"DuckDuckGo","href":"/bundles-duckduckgo","docId":"Components/bundles-duckduckgo","unlisted":false},{"type":"link","label":"Exa","href":"/bundles-exa","docId":"Components/bundles-exa","unlisted":false},{"type":"link","label":"Glean","href":"/bundles-glean","docId":"Components/bundles-glean","unlisted":false},{"type":"category","label":"Google","items":[{"type":"link","label":"Google components","href":"/bundles-google","docId":"Components/bundles-google","unlisted":false},{"type":"link","label":"Google BigQuery","href":"/integrations-google-big-query","docId":"Integrations/Google/integrations-google-big-query","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Groq","href":"/bundles-groq","docId":"Components/bundles-groq","unlisted":false},{"type":"link","label":"Hugging Face","href":"/bundles-huggingface","docId":"Components/bundles-huggingface","unlisted":false},{"type":"link","label":"IBM","href":"/bundles-ibm","docId":"Components/bundles-ibm","unlisted":false},{"type":"link","label":"Icosa Computing","href":"/bundles-icosacomputing","docId":"Components/bundles-icosacomputing","unlisted":false},{"type":"link","label":"LangChain","href":"/bundles-langchain","docId":"Components/bundles-langchain","unlisted":false},{"type":"link","label":"LM Studio","href":"/bundles-lmstudio","docId":"Components/bundles-lmstudio","unlisted":false},{"type":"link","label":"MariTalk","href":"/bundles-maritalk","docId":"Components/bundles-maritalk","unlisted":false},{"type":"link","label":"Mem0","href":"/bundles-mem0","docId":"Components/bundles-mem0","unlisted":false},{"type":"link","label":"MistralAI","href":"/bundles-mistralai","docId":"Components/bundles-mistralai","unlisted":false},{"type":"category","label":"Notion","items":[{"type":"link","label":"Set up a Notion App","href":"/integrations/notion/setup","docId":"Integrations/Notion/integrations-notion","unlisted":false},{"type":"link","label":"Notion Conversational Agent","href":"/integrations/notion/notion-agent-conversational","docId":"Integrations/Notion/notion-agent-conversational","unlisted":false},{"type":"link","label":"Notion Meeting Notes Agent","href":"/integrations/notion/notion-agent-meeting-notes","docId":"Integrations/Notion/notion-agent-meeting-notes","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Novita","href":"/bundles-novita","docId":"Components/bundles-novita","unlisted":false},{"type":"category","label":"NVIDIA","items":[{"type":"link","label":"NVIDIA components","href":"/bundles-nvidia","docId":"Components/bundles-nvidia","unlisted":false},{"type":"link","label":"NVIDIA Ingest","href":"/integrations-nvidia-ingest","docId":"Integrations/Nvidia/integrations-nvidia-ingest","unlisted":false},{"type":"link","label":"NVIDIA NIM on WSL2","href":"/integrations-nvidia-ingest-wsl2","docId":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","unlisted":false},{"type":"link","label":"NVIDIA G-Assist","href":"/integrations-nvidia-g-assist","docId":"Integrations/Nvidia/integrations-nvidia-g-assist","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Ollama","href":"/bundles-ollama","docId":"Components/bundles-ollama","unlisted":false},{"type":"link","label":"OpenAI","href":"/bundles-openai","docId":"Components/bundles-openai","unlisted":false},{"type":"link","label":"OpenRouter","href":"/bundles-openrouter","docId":"Components/bundles-openrouter","unlisted":false},{"type":"link","label":"Perplexity","href":"/bundles-perplexity","docId":"Components/bundles-perplexity","unlisted":false},{"type":"link","label":"Redis","href":"/bundles-redis","docId":"Components/bundles-redis","unlisted":false},{"type":"link","label":"SambaNova","href":"/bundles-sambanova","docId":"Components/bundles-sambanova","unlisted":false},{"type":"link","label":"SearchApi","href":"/bundles-searchapi","docId":"Components/bundles-searchapi","unlisted":false},{"type":"link","label":"Vertex AI","href":"/bundles-vertexai","docId":"Components/bundles-vertexai","unlisted":false},{"type":"link","label":"Wikipedia","href":"/bundles-wikipedia","docId":"Components/bundles-wikipedia","unlisted":false},{"type":"link","label":"xAI","href":"/bundles-xai","docId":"Components/bundles-xai","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Create custom Python components","href":"/components-custom-components","docId":"Components/components-custom-components","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"API reference","items":[{"type":"link","label":"Get started with the Langflow API","href":"/api-reference-api-examples","docId":"API-Reference/api-reference-api-examples","unlisted":false},{"type":"link","label":"Use the TypeScript client","href":"/typescript-client","docId":"Develop/Clients/typescript-client","unlisted":false},{"type":"link","label":"Flow trigger endpoints","href":"/api-flows-run","docId":"API-Reference/api-flows-run","unlisted":false},{"type":"link","label":"Flow management endpoints","href":"/api-flows","docId":"API-Reference/api-flows","unlisted":false},{"type":"link","label":"Files endpoints","href":"/api-files","docId":"API-Reference/api-files","unlisted":false},{"type":"link","label":"Projects endpoints","href":"/api-projects","docId":"API-Reference/api-projects","unlisted":false},{"type":"link","label":"Logs endpoints","href":"/api-logs","docId":"API-Reference/api-logs","unlisted":false},{"type":"link","label":"Monitor endpoints","href":"/api-monitor","docId":"API-Reference/api-monitor","unlisted":false},{"type":"link","label":"Build endpoints","href":"/api-build","docId":"API-Reference/api-build","unlisted":false},{"type":"link","label":"Users endpoints","href":"/api-users","docId":"API-Reference/api-users","unlisted":false},{"type":"link","label":"Langflow API specification","href":"/api"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contribute","items":[{"type":"link","label":"Join the Langflow community","href":"/contributing-community","docId":"Contributing/contributing-community","unlisted":false},{"type":"link","label":"Contribute to Langflow","href":"/contributing-how-to-contribute","docId":"Contributing/contributing-how-to-contribute","unlisted":false},{"type":"link","label":"Contribute components","href":"/contributing-components","docId":"Contributing/contributing-components","unlisted":false},{"type":"link","label":"Contribute component tests","href":"/contributing-component-tests","docId":"Contributing/contributing-component-tests","unlisted":false},{"type":"link","label":"Contribute templates","href":"/contributing-templates","docId":"Contributing/contributing-templates","unlisted":false},{"type":"link","label":"Contribute bundles","href":"/contributing-bundles","docId":"Contributing/contributing-bundles","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Release notes","items":[{"type":"link","label":"Release notes","href":"/release-notes","docId":"Support/release-notes","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Support","items":[{"type":"link","label":"Troubleshoot","href":"/troubleshoot","docId":"Support/troubleshooting","unlisted":false},{"type":"link","label":"Get help and request enhancements","href":"/contributing-github-issues","docId":"Contributing/contributing-github-issues","unlisted":false},{"type":"link","label":"Enterprise support","href":"/luna-for-langflow","docId":"Support/luna-for-langflow","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"html","className":"sidebar-ad","value":"\\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n
\\n Get started in minutes\\n Download Langflow Desktop\\n
\\n \\n "}]},"docs":{"Agents/agents":{"id":"Agents/agents","title":"Use Langflow agents","description":"Langflow\'s Agent component is critical for building agent flows.","sidebar":"docs"},"Agents/agents-tools":{"id":"Agents/agents-tools","title":"Configure tools for agents","description":"Configure tools connected to agents to extend their capabilities.","sidebar":"docs"},"API-Reference/api-build":{"id":"API-Reference/api-build","title":"Build endpoints","description":"The /build endpoints are used by Langflow\'s frontend visual editor code.","sidebar":"docs"},"API-Reference/api-files":{"id":"API-Reference/api-files","title":"Files endpoints","description":"Use the /files endpoints to move files between your local machine and Langflow.","sidebar":"docs"},"API-Reference/api-flows":{"id":"API-Reference/api-flows","title":"Flow management endpoints","description":"Use the /flows endpoint to create, read, update, and delete flows.","sidebar":"docs"},"API-Reference/api-flows-run":{"id":"API-Reference/api-flows-run","title":"Flow trigger endpoints","description":"Use the /run and /webhook endpoints to run flows.","sidebar":"docs"},"API-Reference/api-logs":{"id":"API-Reference/api-logs","title":"Logs endpoints","description":"Retrieve logs for your Langflow flow.","sidebar":"docs"},"API-Reference/api-monitor":{"id":"API-Reference/api-monitor","title":"Monitor endpoints","description":"Use the /monitor endpoint to monitor and modify messages passed between Langflow components, vertex builds, and transactions.","sidebar":"docs"},"API-Reference/api-projects":{"id":"API-Reference/api-projects","title":"Projects endpoints","description":"Use the /projects endpoint to create, read, update, and delete Langflow projects.","sidebar":"docs"},"API-Reference/api-reference-api-examples":{"id":"API-Reference/api-reference-api-examples","title":"Get started with the Langflow API","description":"You can use the Langflow API for programmatic interactions with Langflow, such as the following:","sidebar":"docs"},"API-Reference/api-users":{"id":"API-Reference/api-users","title":"Users endpoints","description":"Use the /users endpoint to manage user accounts in Langflow.","sidebar":"docs"},"Components/bundles-aiml":{"id":"Components/bundles-aiml","title":"AI/ML API","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-amazon":{"id":"Components/bundles-amazon","title":"Amazon","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-anthropic":{"id":"Components/bundles-anthropic","title":"Anthropic","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-arxiv":{"id":"Components/bundles-arxiv","title":"arXiv","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-azure":{"id":"Components/bundles-azure","title":"Azure","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-baidu":{"id":"Components/bundles-baidu","title":"Baidu","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-bing":{"id":"Components/bundles-bing","title":"Bing","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-cloudflare":{"id":"Components/bundles-cloudflare","title":"Cloudflare","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-cohere":{"id":"Components/bundles-cohere","title":"Cohere","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-datastax":{"id":"Components/bundles-datastax","title":"DataStax","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-deepseek":{"id":"Components/bundles-deepseek","title":"DeepSeek","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-duckduckgo":{"id":"Components/bundles-duckduckgo","title":"DuckDuckGo","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-exa":{"id":"Components/bundles-exa","title":"Exa","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-glean":{"id":"Components/bundles-glean","title":"Glean","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-google":{"id":"Components/bundles-google","title":"Google components","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-groq":{"id":"Components/bundles-groq","title":"Groq","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-huggingface":{"id":"Components/bundles-huggingface","title":"Hugging Face","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-ibm":{"id":"Components/bundles-ibm","title":"IBM","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-icosacomputing":{"id":"Components/bundles-icosacomputing","title":"Icosa Computing","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-langchain":{"id":"Components/bundles-langchain","title":"LangChain","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-lmstudio":{"id":"Components/bundles-lmstudio","title":"LM Studio","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-maritalk":{"id":"Components/bundles-maritalk","title":"MariTalk","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-mem0":{"id":"Components/bundles-mem0","title":"Mem0","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-mistralai":{"id":"Components/bundles-mistralai","title":"MistralAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-novita":{"id":"Components/bundles-novita","title":"Novita","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-nvidia":{"id":"Components/bundles-nvidia","title":"NVIDIA components","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-ollama":{"id":"Components/bundles-ollama","title":"Ollama","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-openai":{"id":"Components/bundles-openai","title":"OpenAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-openrouter":{"id":"Components/bundles-openrouter","title":"OpenRouter","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-perplexity":{"id":"Components/bundles-perplexity","title":"Perplexity","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-redis":{"id":"Components/bundles-redis","title":"Redis","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-sambanova":{"id":"Components/bundles-sambanova","title":"SambaNova","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-searchapi":{"id":"Components/bundles-searchapi","title":"SearchApi","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-vertexai":{"id":"Components/bundles-vertexai","title":"Vertex AI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-wikipedia":{"id":"Components/bundles-wikipedia","title":"Wikipedia","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-xai":{"id":"Components/bundles-xai","title":"xAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/components-agents":{"id":"Components/components-agents","title":"Agents","description":"Langflow\'s Agent and MCP Tools components are critical for building agent flows.","sidebar":"docs"},"Components/components-bundles":{"id":"Components/components-bundles","title":"About bundles","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/components-custom-components":{"id":"Components/components-custom-components","title":"Create custom Python components","description":"Custom components extend Langflow\'s functionality through Python classes that inherit from Component. This enables integration of new features, data manipulation, external services, and specialized tools.","sidebar":"docs"},"Components/components-data":{"id":"Components/components-data","title":"Data","description":"You can use Langflow\'s Data components to bring data into your flows from various sources like files, API endpoints, and URLs.","sidebar":"docs"},"Components/components-embedding-models":{"id":"Components/components-embedding-models","title":"Embedding Model","description":"Embedding Model components in Langflow generate text embeddings using a specified Large Language Model (LLM).","sidebar":"docs"},"Components/components-helpers":{"id":"Components/components-helpers","title":"Helpers","description":"Helper components provide utility functions to help manage data and perform simple tasks in your flow.","sidebar":"docs"},"Components/components-io":{"id":"Components/components-io","title":"Input / Output","description":"Langflow\'s Input and Output components define where data enters and exits your flow, but they don\'t have identical functionality.","sidebar":"docs"},"Components/components-logic":{"id":"Components/components-logic","title":"Logic","description":"Langflow\'s Logic components provide functionalities for routing, conditional processing, and flow management.","sidebar":"docs"},"Components/components-memories":{"id":"Components/components-memories","title":"Memories","description":"In Langflow version 1.5, the Memory category was removed.","sidebar":"docs"},"Components/components-models":{"id":"Components/components-models","title":"Language Model","description":"Language Model components in Langflow generate text using a specified Large Language Model (LLM).","sidebar":"docs"},"Components/components-processing":{"id":"Components/components-processing","title":"Processing components","description":"Langflow\'s Processing components process and transform data within a flow.","sidebar":"docs"},"Components/components-prompts":{"id":"Components/components-prompts","title":"Prompt Template","description":"Use the Prompt Template core component to create a prompt that supplies instructions and context to an LLM or agent, separate from other input like chat messages and file uploads.","sidebar":"docs"},"Components/components-tools":{"id":"Components/components-tools","title":"Tools","description":"In Langflow version 1.5, the Tools category was deprecated.","sidebar":"docs"},"Components/components-vector-stores":{"id":"Components/components-vector-stores","title":"Vector Stores","description":"Langflow\'s Vector Store components connect to your vector databases or create in-memory vector stores for storing and retrieving vector data in flows.","sidebar":"docs"},"Components/mcp-client":{"id":"Components/mcp-client","title":"Use Langflow as an MCP client","description":"Langflow integrates with the Model Context Protocol (MCP) as both an MCP server and an MCP client.","sidebar":"docs"},"Concepts/concepts-components":{"id":"Concepts/concepts-components","title":"Components overview","description":"Components are the building blocks of your flows.","sidebar":"docs"},"Concepts/concepts-file-management":{"id":"Concepts/concepts-file-management","title":"Manage files","description":"Each Langflow server has a file management system where you can store files that you want to use in your flows.","sidebar":"docs"},"Concepts/concepts-flows":{"id":"Concepts/concepts-flows","title":"Build flows","description":"A flow is a functional representation of an application workflow.","sidebar":"docs"},"Concepts/concepts-flows-import":{"id":"Concepts/concepts-flows-import","title":"Import and export flows","description":"You can export flows to transfer them between Langflow instances, share them with others, or create backups.","sidebar":"docs"},"Concepts/concepts-overview":{"id":"Concepts/concepts-overview","title":"Use the visual editor","description":"You use Langflow\'s visual editor to create, test, and share flows, which are functional representations of application workflows.","sidebar":"docs"},"Concepts/concepts-playground":{"id":"Concepts/concepts-playground","title":"Test flows in the Playground","description":"Langflow\'s Playground is a dynamic interface you can use to test your LLM-based flows in real-time.","sidebar":"docs"},"Concepts/concepts-publish":{"id":"Concepts/concepts-publish","title":"Trigger flows with the Langflow API","description":"After you build a flow, you probably want to run it within an application, such as a chatbot within a mobile app or website.","sidebar":"docs"},"Concepts/concepts-voice-mode":{"id":"Concepts/concepts-voice-mode","title":"Use voice mode","description":"You can use Langflow\'s voice mode to interact with your flows verbally through a microphone and speakers.","sidebar":"docs"},"Concepts/data-types":{"id":"Concepts/data-types","title":"Langflow data types","description":"Langflow components are designed to accept and produce specific types of inputs and outputs.","sidebar":"docs"},"Concepts/mcp-server":{"id":"Concepts/mcp-server","title":"Use Langflow as an MCP server","description":"Langflow integrates with the Model Context Protocol (MCP) as both an MCP server and an MCP client.","sidebar":"docs"},"Configuration/api-keys-and-authentication":{"id":"Configuration/api-keys-and-authentication","title":"API keys and authentication","description":"Never expose Langflow ports directly to the internet without proper security measures.","sidebar":"docs"},"Configuration/configuration-cli":{"id":"Configuration/configuration-cli","title":"Langflow CLI","description":"The Langflow command line interface (Langflow CLI) is the main interface for managing and running the Langflow server.","sidebar":"docs"},"Configuration/configuration-custom-database":{"id":"Configuration/configuration-custom-database","title":"Configure an external PostgreSQL database","description":"Langflow\'s default database is SQLite, but you can configure Langflow to use PostgreSQL instead.","sidebar":"docs"},"Configuration/configuration-global-variables":{"id":"Configuration/configuration-global-variables","title":"Global variables","description":"Global variables let you store and reuse generic input values and credentials across your Langflow projects.","sidebar":"docs"},"Configuration/environment-variables":{"id":"Configuration/environment-variables","title":"Environment variables","description":"Langflow uses environment variables to configure certain settings.","sidebar":"docs"},"Contributing/contributing-bundles":{"id":"Contributing/contributing-bundles","title":"Contribute bundles","description":"Bundles are groups of components that are related to a specific service provider.","sidebar":"docs"},"Contributing/contributing-community":{"id":"Contributing/contributing-community","title":"Join the Langflow community","description":"There are several ways you can interact with the Langflow community and learn more about the Langflow codebase.","sidebar":"docs"},"Contributing/contributing-component-tests":{"id":"Contributing/contributing-component-tests","title":"Contribute component tests","description":"This guide outlines how to structure and implement tests for application components to ensure consistency and adequate coverage.","sidebar":"docs"},"Contributing/contributing-components":{"id":"Contributing/contributing-components","title":"Contribute components","description":"New components are added as objects of the Component class.","sidebar":"docs"},"Contributing/contributing-github-issues":{"id":"Contributing/contributing-github-issues","title":"Get help and request enhancements","description":"The Langflow GitHub repository is an integral part of the Langflow community.","sidebar":"docs"},"Contributing/contributing-how-to-contribute":{"id":"Contributing/contributing-how-to-contribute","title":"Contribute to Langflow","description":"This guide is intended to help you start contributing to Langflow.","sidebar":"docs"},"Contributing/contributing-telemetry":{"id":"Contributing/contributing-telemetry","title":"Telemetry","description":"Langflow uses anonymous telemetry to collect statistics about feature usage and performance.","sidebar":"docs"},"Contributing/contributing-templates":{"id":"Contributing/contributing-templates","title":"Contribute templates","description":"Follow these best practices when submitting a template to Langflow.","sidebar":"docs"},"Deployment/deployment-architecture":{"id":"Deployment/deployment-architecture","title":"Langflow architecture on Kubernetes","description":"There are two broad types of Langflow deployments:","sidebar":"docs"},"Deployment/deployment-caddyfile":{"id":"Deployment/deployment-caddyfile","title":"Deploy Langflow on a remote server","description":"Learn how to deploy Langflow on your own remote server with secure web access.","sidebar":"docs"},"Deployment/deployment-docker":{"id":"Deployment/deployment-docker","title":"Deploy Langflow on Docker","description":"Running applications in Docker containers ensures consistent behavior across different systems and eliminates dependency conflicts.","sidebar":"docs"},"Deployment/deployment-gcp":{"id":"Deployment/deployment-gcp","title":"Deploy Langflow on Google Cloud Platform","description":"This guide demonstrates how to deploy Langflow on Google Cloud Platform with a Cloud Shell script that walks through the process of setting up a Debian-based VM with the Langflow package, Nginx, and the necessary configurations to run the Langflow development environment in GCP.","sidebar":"docs"},"Deployment/deployment-hugging-face-spaces":{"id":"Deployment/deployment-hugging-face-spaces","title":"Deploy Langflow on Hugging Face Spaces","description":"This guide explains how to deploy Langflow on Hugging Face Spaces.","sidebar":"docs"},"Deployment/deployment-kubernetes-dev":{"id":"Deployment/deployment-kubernetes-dev","title":"Deploy the Langflow development environment on Kubernetes","description":"The Langflow integrated development environment (IDE) Helm chart is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the Langflow API and visual editor.","sidebar":"docs"},"Deployment/deployment-kubernetes-prod":{"id":"Deployment/deployment-kubernetes-prod","title":"Deploy the Langflow production environment on Kubernetes","description":"The Langflow runtime Helm chart is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently.","sidebar":"docs"},"Deployment/deployment-overview":{"id":"Deployment/deployment-overview","title":"Langflow deployment overview","description":"This section includes the different ways to bring your locally-built flows to the world.","sidebar":"docs"},"Deployment/deployment-prod-best-practices":{"id":"Deployment/deployment-prod-best-practices","title":"Best practices for Langflow on Kubernetes","description":"This guide provides best practices for deploying Langflow in production environments on Kubernetes.","sidebar":"docs"},"Deployment/deployment-public-server":{"id":"Deployment/deployment-public-server","title":"Deploy a public Langflow server","description":"By default, your Langflow server at http7860 isn\'t exposed to the public internet.","sidebar":"docs"},"Deployment/deployment-railway":{"id":"Deployment/deployment-railway","title":"Deploy Langflow on Railway","description":"Deploy Langflow to Railway using a one-click template","sidebar":"docs"},"Deployment/deployment-render":{"id":"Deployment/deployment-render","title":"Deploy Langflow on Render","description":"This guide explains how to deploy Langflow on Render, a cloud platform for deploying web applications and APIs.","sidebar":"docs"},"Develop/Clients/typescript-client":{"id":"Develop/Clients/typescript-client","title":"Langflow TypeScript client","description":"The Langflow TypeScript client allows your TypeScript applications to programmatically interact with the Langflow API.","sidebar":"docs"},"Develop/develop-application":{"id":"Develop/develop-application","title":"Containerize a Langflow application","description":"Designing flows in the visual editor is only the first step in building an application that uses Langflow.","sidebar":"docs"},"Develop/enterprise-database-guide":{"id":"Develop/enterprise-database-guide","title":"Langflow database guide for enterprise DBAs","description":"The Langflow database stores data that is essential for more Langflow operations, including startup, flow execution, user interactions, and administrative tasks.","sidebar":"docs"},"Develop/install-custom-dependencies":{"id":"Develop/install-custom-dependencies","title":"Install custom dependencies","description":"Langflow provides optional dependency groups and support for custom dependencies to extend Langflow functionality.","sidebar":"docs"},"Develop/logging":{"id":"Develop/logging","title":"Logs","description":"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself.","sidebar":"docs"},"Develop/memory":{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.","sidebar":"docs"},"Develop/session-id":{"id":"Develop/session-id","title":"Use session ID to manage communication between components","description":"Session ID is a unique identifier for client/server connections. A single session equals the duration of a client\'s connection to a server.","sidebar":"docs"},"Develop/webhook":{"id":"Develop/webhook","title":"Trigger flows with webhooks","description":"You can use the Webhook component to start a flow run in response to an external event.","sidebar":"docs"},"Get-Started/about-langflow":{"id":"Get-Started/about-langflow","title":"What is Langflow?","description":"Langflow is an open-source, Python-based, customizable framework for building AI applications.","sidebar":"docs"},"Get-Started/get-started-installation":{"id":"Get-Started/get-started-installation","title":"Install Langflow","description":"Langflow can be installed in multiple ways:","sidebar":"docs"},"Get-Started/get-started-quickstart":{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get started with Langflow by loading a template flow, running it, and then serving it at the /run API endpoint.","sidebar":"docs"},"Get-Started/welcome-to-langflow":{"id":"Get-Started/welcome-to-langflow","title":"Welcome to Langflow","description":"Langflow empowers developers to rapidly prototype and build AI applications with a user-friendly visual interface and support for important AI functionality like agents and the MCP.","sidebar":"docs"},"Integrations/Apify/integrations-apify":{"id":"Integrations/Apify/integrations-apify","title":"Apify","description":"Apify is a web scraping and data extraction platform with more than 3,000 ready-made cloud tools called Actors.","sidebar":"docs"},"Integrations/Arize/integrations-arize":{"id":"Integrations/Arize/integrations-arize","title":"Arize","description":"Arize is a tool built on OpenTelemetry and OpenInference for monitoring and optimizing LLM applications.","sidebar":"docs"},"Integrations/Cleanlab/integrations-cleanlab":{"id":"Integrations/Cleanlab/integrations-cleanlab","title":"Cleanlab","description":"Cleanlab adds automation and trust to every data point going in and every prediction coming out of AI and RAG solutions.","sidebar":"docs"},"Integrations/Composio/integrations-composio":{"id":"Integrations/Composio/integrations-composio","title":"Composio","description":"Composio components in Langflow provide Composio tools to your Agent components.","sidebar":"docs"},"Integrations/Docling/integrations-docling":{"id":"Integrations/Docling/integrations-docling","title":"Docling","description":"Langflow integrates with Docling through a bundle of components for parsing documents.","sidebar":"docs"},"Integrations/Google/integrations-google-big-query":{"id":"Integrations/Google/integrations-google-big-query","title":"Google BigQuery","description":"Langflow integrates with Google BigQuery through the BigQuery component in the Google bundle, allowing you to execute SQL queries and retrieve data from your BigQuery datasets.","sidebar":"docs"},"Integrations/integrations-assemblyai":{"id":"Integrations/integrations-assemblyai","title":"AssemblyAI","description":"The AssemblyAI components allow you to apply powerful Speech AI models to your app for tasks like:","sidebar":"docs"},"Integrations/integrations-langfuse":{"id":"Integrations/integrations-langfuse","title":"Langfuse","description":"Langfuse is an open-source platform for LLM observability. It provides tracing and monitoring capabilities for AI applications, helping developers debug, analyze, and optimize their AI systems. Langfuse integrates with various tools and frameworks, including workflow builders and runtimes like Langflow.","sidebar":"docs"},"Integrations/integrations-langsmith":{"id":"Integrations/integrations-langsmith","title":"LangSmith","description":"LangSmith is a full-lifecycle DevOps service from LangChain that provides monitoring and observability. To integrate with Langflow, add your LangChain API key and configuration as Langflow environment variables, and then start Langflow.","sidebar":"docs"},"Integrations/integrations-langwatch":{"id":"Integrations/integrations-langwatch","title":"LangWatch","description":"LangWatch is an all-in-one LLMOps platform for monitoring, observability, analytics, evaluations and alerting for getting user insights and improve your LLM workflows.","sidebar":"docs"},"Integrations/integrations-opik":{"id":"Integrations/integrations-opik","title":"Opik","description":"Opik is an open-source platform designed for evaluating, testing, and monitoring large language model (LLM) applications. Developed by Comet, it aims to facilitate more intuitive collaboration, testing, and monitoring of LLM-based applications.","sidebar":"docs"},"Integrations/mcp-component-astra":{"id":"Integrations/mcp-component-astra","title":"Connect an Astra DB MCP server to Langflow","description":"This guide demonstrates how to use Langflow as an MCP client by using the MCP Tools component to run a DataStax Astra DB MCP server in an agent flow.","sidebar":"docs"},"Integrations/Notion/integrations-notion":{"id":"Integrations/Notion/integrations-notion","title":"Set up a Notion App","description":"To use Notion components in Langflow, you first need to create a Notion integration and configure it with the necessary capabilities. This guide will walk you through the process of setting up a Notion integration and granting it access to your Notion databases.","sidebar":"docs"},"Integrations/Notion/notion-agent-conversational":{"id":"Integrations/Notion/notion-agent-conversational","title":"Notion Conversational Agent","description":"The Notion Conversational Agent is an AI-powered assistant that interacts with your Notion workspace through natural language conversations. This flow performs Notion-related tasks like creating pages, searching for information, and managing content, all through a chat interface.","sidebar":"docs"},"Integrations/Notion/notion-agent-meeting-notes":{"id":"Integrations/Notion/notion-agent-meeting-notes","title":"Notion Meeting Notes Agent","description":"The Notion Agent for Meeting Notes is an AI-powered tool that automatically processes meeting transcripts and updates your Notion workspace. It identifies tasks, action items, and key points from your meetings, then creates new tasks or updates existing ones in Notion without manual input.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-g-assist":{"id":"Integrations/Nvidia/integrations-nvidia-g-assist","title":"Integrate NVIDIA G-Assist with Langflow","description":"The NVIDIA G-Assist component is available only for Langflow users with NVIDIA GPUs on Windows systems.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-ingest":{"id":"Integrations/Nvidia/integrations-nvidia-ingest","title":"Integrate NVIDIA Retriever Extraction with Langflow","description":"The NVIDIA Retriever Extraction component integrates with the NVIDIA nv-ingest microservice for data ingestion, processing, and extraction of text files.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-nim-wsl2":{"id":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","title":"Integrate NVIDIA NIMs with Langflow","description":"Connect Langflow with NVIDIA NIM on an RTX Windows system with Windows Subsystem for Linux 2 (WSL2) installed.","sidebar":"docs"},"Support/luna-for-langflow":{"id":"Support/luna-for-langflow","title":"Enterprise support for Langflow","description":"With Luna for Langflow support, you can develop and deploy Langflow applications with confidence.","sidebar":"docs"},"Support/release-notes":{"id":"Support/release-notes","title":"Langflow release notes","description":"This page summarizes significant changes to Langflow in each release.","sidebar":"docs"},"Support/troubleshooting":{"id":"Support/troubleshooting","title":"Troubleshoot Langflow","description":"This page provides troubleshooting advice for issues you might encounter when using Langflow or contributing to Langflow.","sidebar":"docs"},"Tutorials/agent":{"id":"Tutorials/agent","title":"Connect applications to agents","description":"This tutorial shows you how to connect a JavaScript application to a Langflow agent.","sidebar":"docs"},"Tutorials/chat-with-files":{"id":"Tutorials/chat-with-files","title":"Create a chatbot that can ingest files","description":"This tutorial shows you how to build a chatbot that can read and answer questions about files you upload, such as meeting notes or job applications.","sidebar":"docs"},"Tutorials/chat-with-rag":{"id":"Tutorials/chat-with-rag","title":"Create a vector RAG chatbot","description":"This tutorial demonstrates how you can use Langflow to create a chatbot application that uses Retrieval Augmented Generation (RAG) to embed your data as vectors in a vector database, and then chat with the data.","sidebar":"docs"},"Tutorials/mcp-tutorial":{"id":"Tutorials/mcp-tutorial","title":"Connect to MCP servers from your application","description":"This tutorial shows you how to connect MCP servers to your applications using Langflow\'s MCP Tools component.","sidebar":"docs"}}}}')}}]); \ No newline at end of file diff --git a/assets/js/22dd74f7.6caa28b6.js b/assets/js/22dd74f7.6caa28b6.js deleted file mode 100644 index 8f0601723d..0000000000 --- a/assets/js/22dd74f7.6caa28b6.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1567],{55226:e=>{e.exports=JSON.parse('{"version":{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"noIndex":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"docs":[{"type":"link","label":"Welcome to Langflow","href":"/","docId":"Get-Started/welcome-to-langflow","unlisted":false},{"type":"category","label":"Get started","items":[{"type":"link","label":"About Langflow","href":"/about-langflow","docId":"Get-Started/about-langflow","unlisted":false},{"type":"link","label":"Install Langflow","href":"/get-started-installation","docId":"Get-Started/get-started-installation","unlisted":false},{"type":"link","label":"Quickstart","href":"/get-started-quickstart","docId":"Get-Started/get-started-quickstart","unlisted":false},{"type":"category","label":"Tutorials","items":[{"type":"link","label":"Create a vector RAG chatbot","href":"/chat-with-rag","docId":"Tutorials/chat-with-rag","unlisted":false},{"type":"link","label":"Create a chatbot that can ingest files","href":"/chat-with-files","docId":"Tutorials/chat-with-files","unlisted":false},{"type":"link","label":"Connect applications to agents","href":"/agent-tutorial","docId":"Tutorials/agent","unlisted":false},{"type":"link","label":"Connect to MCP servers from your application","href":"/mcp-tutorial","docId":"Tutorials/mcp-tutorial","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Flows","items":[{"type":"link","label":"Use the visual editor","href":"/concepts-overview","docId":"Concepts/concepts-overview","unlisted":false},{"type":"link","label":"Build flows","href":"/concepts-flows","docId":"Concepts/concepts-flows","unlisted":false},{"type":"category","label":"Run flows","items":[{"type":"link","label":"Trigger flows with the Langflow API","href":"/concepts-publish","docId":"Concepts/concepts-publish","unlisted":false},{"type":"link","label":"Trigger flows with webhooks","href":"/webhook","docId":"Develop/webhook","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Test flows","href":"/concepts-playground","docId":"Concepts/concepts-playground","unlisted":false},{"type":"link","label":"Import and export flows","href":"/concepts-flows-import","docId":"Concepts/concepts-flows-import","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Agents","items":[{"type":"link","label":"Use Langflow agents","href":"/agents","docId":"Agents/agents","unlisted":false},{"type":"link","label":"Configure tools for agents","href":"/agents-tools","docId":"Agents/agents-tools","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Model Context Protocol (MCP)","items":[{"type":"link","label":"Use Langflow as an MCP client","href":"/mcp-client","docId":"Components/mcp-client","unlisted":false},{"type":"link","label":"Use Langflow as an MCP server","href":"/mcp-server","docId":"Concepts/mcp-server","unlisted":false},{"type":"link","label":"Connect an Astra DB MCP server to Langflow","href":"/mcp-component-astra","docId":"Integrations/mcp-component-astra","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Develop","items":[{"type":"link","label":"API keys and authentication","href":"/api-keys-and-authentication","docId":"Configuration/api-keys-and-authentication","unlisted":false},{"type":"link","label":"Install custom dependencies","href":"/install-custom-dependencies","docId":"Develop/install-custom-dependencies","unlisted":false},{"type":"link","label":"Global variables","href":"/configuration-global-variables","docId":"Configuration/configuration-global-variables","unlisted":false},{"type":"link","label":"Environment variables","href":"/environment-variables","docId":"Configuration/environment-variables","unlisted":false},{"type":"category","label":"Storage and memory","items":[{"type":"link","label":"Manage files","href":"/concepts-file-management","docId":"Concepts/concepts-file-management","unlisted":false},{"type":"link","label":"Manage memory","href":"/memory","docId":"Develop/memory","unlisted":false},{"type":"link","label":"Use Session IDs","href":"/session-id","docId":"Develop/session-id","unlisted":false},{"type":"link","label":"Configure an external PostgreSQL database","href":"/configuration-custom-database","docId":"Configuration/configuration-custom-database","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Observability","items":[{"type":"link","label":"Logs","href":"/logging","docId":"Develop/logging","unlisted":false},{"type":"category","label":"Monitoring","items":[{"type":"link","label":"Arize","href":"/integrations-arize","docId":"Integrations/Arize/integrations-arize","unlisted":false},{"type":"link","label":"Langfuse","href":"/integrations-langfuse","docId":"Integrations/integrations-langfuse","unlisted":false},{"type":"link","label":"LangSmith","href":"/integrations-langsmith","docId":"Integrations/integrations-langsmith","unlisted":false},{"type":"link","label":"LangWatch","href":"/integrations-langwatch","docId":"Integrations/integrations-langwatch","unlisted":false},{"type":"link","label":"Opik","href":"/integrations-opik","docId":"Integrations/integrations-opik","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Telemetry","href":"/contributing-telemetry","docId":"Contributing/contributing-telemetry","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Use Langflow data types","href":"/data-types","docId":"Concepts/data-types","unlisted":false},{"type":"link","label":"Use voice mode","href":"/concepts-voice-mode","docId":"Concepts/concepts-voice-mode","unlisted":false},{"type":"link","label":"Use the Langflow CLI","href":"/configuration-cli","docId":"Configuration/configuration-cli","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Deploy","items":[{"type":"link","label":"Langflow deployment overview","href":"/deployment-overview","docId":"Deployment/deployment-overview","unlisted":false},{"type":"link","label":"Deploy a public Langflow server","href":"/deployment-public-server","docId":"Deployment/deployment-public-server","unlisted":false},{"type":"category","label":"Containerized deployments","items":[{"type":"link","label":"Containerize a Langflow application","href":"/develop-application","docId":"Develop/develop-application","unlisted":false},{"type":"link","label":"Langflow Docker images","href":"/deployment-docker","docId":"Deployment/deployment-docker","unlisted":false},{"type":"link","label":"Deploy Langflow on a remote server","href":"/deployment-caddyfile","docId":"Deployment/deployment-caddyfile","unlisted":false},{"type":"category","label":"Kubernetes","items":[{"type":"link","label":"Langflow architecture and best practices","href":"/deployment-prod-best-practices","docId":"Deployment/deployment-prod-best-practices","unlisted":false},{"type":"link","label":"Deploy in development","href":"/deployment-kubernetes-dev","docId":"Deployment/deployment-kubernetes-dev","unlisted":false},{"type":"link","label":"Deploy in production","href":"/deployment-kubernetes-prod","docId":"Deployment/deployment-kubernetes-prod","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Cloud platforms","items":[{"type":"link","label":"Google Cloud Platform","href":"/deployment-gcp","docId":"Deployment/deployment-gcp","unlisted":false},{"type":"link","label":"Hugging Face Spaces","href":"/deployment-hugging-face-spaces","docId":"Deployment/deployment-hugging-face-spaces","unlisted":false},{"type":"link","label":"Railway","href":"/deployment-railway","docId":"Deployment/deployment-railway","unlisted":false},{"type":"link","label":"Render","href":"/deployment-render","docId":"Deployment/deployment-render","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Components reference","items":[{"type":"link","label":"Components overview","href":"/concepts-components","docId":"Concepts/concepts-components","unlisted":false},{"type":"category","label":"Core components","items":[{"type":"link","label":"Input / Output","href":"/components-io","docId":"Components/components-io","unlisted":false},{"type":"link","label":"Agents","href":"/components-agents","docId":"Components/components-agents","unlisted":false},{"type":"category","label":"Models","items":[{"type":"link","label":"Language Model","href":"/components-models","docId":"Components/components-models","unlisted":false},{"type":"link","label":"Embedding Model","href":"/components-embedding-models","docId":"Components/components-embedding-models","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Data","href":"/components-data","docId":"Components/components-data","unlisted":false},{"type":"link","label":"Vector Stores","href":"/components-vector-stores","docId":"Components/components-vector-stores","unlisted":false},{"type":"category","label":"Processing","items":[{"type":"link","label":"Processing components","href":"/components-processing","docId":"Components/components-processing","unlisted":false},{"type":"link","label":"Prompt Template","href":"/components-prompts","docId":"Components/components-prompts","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Logic","href":"/components-logic","docId":"Components/components-logic","unlisted":false},{"type":"link","label":"Helpers","href":"/components-helpers","docId":"Components/components-helpers","unlisted":false},{"type":"link","label":"Tools","href":"/components-tools","docId":"Components/components-tools","unlisted":false},{"type":"link","label":"Memories","href":"/components-memories","docId":"Components/components-memories","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Bundles","items":[{"type":"link","label":"About bundles","href":"/components-bundle-components","docId":"Components/components-bundles","unlisted":false},{"type":"link","label":"AI/ML API","href":"/bundles-aiml","docId":"Components/bundles-aiml","unlisted":false},{"type":"link","label":"Amazon","href":"/bundles-amazon","docId":"Components/bundles-amazon","unlisted":false},{"type":"link","label":"Anthropic","href":"/bundles-anthropic","docId":"Components/bundles-anthropic","unlisted":false},{"type":"link","label":"Apify","href":"/integrations-apify","docId":"Integrations/Apify/integrations-apify","unlisted":false},{"type":"link","label":"arXiv","href":"/bundles-arxiv","docId":"Components/bundles-arxiv","unlisted":false},{"type":"link","label":"AssemblyAI","href":"/integrations-assemblyai","docId":"Integrations/integrations-assemblyai","unlisted":false},{"type":"link","label":"Azure","href":"/bundles-azure","docId":"Components/bundles-azure","unlisted":false},{"type":"link","label":"Baidu","href":"/bundles-baidu","docId":"Components/bundles-baidu","unlisted":false},{"type":"link","label":"Bing","href":"/bundles-bing","docId":"Components/bundles-bing","unlisted":false},{"type":"link","label":"Cleanlab","href":"/integrations-cleanlab","docId":"Integrations/Cleanlab/integrations-cleanlab","unlisted":false},{"type":"link","label":"Cloudflare","href":"/bundles-cloudflare","docId":"Components/bundles-cloudflare","unlisted":false},{"type":"link","label":"Cohere","href":"/bundles-cohere","docId":"Components/bundles-cohere","unlisted":false},{"type":"link","label":"Composio","href":"/integrations-composio","docId":"Integrations/Composio/integrations-composio","unlisted":false},{"type":"link","label":"DataStax","href":"/bundles-datastax","docId":"Components/bundles-datastax","unlisted":false},{"type":"link","label":"DeepSeek","href":"/bundles-deepseek","docId":"Components/bundles-deepseek","unlisted":false},{"type":"link","label":"Docling","href":"/integrations-docling","docId":"Integrations/Docling/integrations-docling","unlisted":false},{"type":"link","label":"DuckDuckGo","href":"/bundles-duckduckgo","docId":"Components/bundles-duckduckgo","unlisted":false},{"type":"link","label":"Exa","href":"/bundles-exa","docId":"Components/bundles-exa","unlisted":false},{"type":"link","label":"Glean","href":"/bundles-glean","docId":"Components/bundles-glean","unlisted":false},{"type":"category","label":"Google","items":[{"type":"link","label":"Google components","href":"/bundles-google","docId":"Components/bundles-google","unlisted":false},{"type":"link","label":"Google BigQuery","href":"/integrations-google-big-query","docId":"Integrations/Google/integrations-google-big-query","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Groq","href":"/bundles-groq","docId":"Components/bundles-groq","unlisted":false},{"type":"link","label":"Hugging Face","href":"/bundles-huggingface","docId":"Components/bundles-huggingface","unlisted":false},{"type":"link","label":"IBM","href":"/bundles-ibm","docId":"Components/bundles-ibm","unlisted":false},{"type":"link","label":"Icosa Computing","href":"/bundles-icosacomputing","docId":"Components/bundles-icosacomputing","unlisted":false},{"type":"link","label":"LangChain","href":"/bundles-langchain","docId":"Components/bundles-langchain","unlisted":false},{"type":"link","label":"LM Studio","href":"/bundles-lmstudio","docId":"Components/bundles-lmstudio","unlisted":false},{"type":"link","label":"MariTalk","href":"/bundles-maritalk","docId":"Components/bundles-maritalk","unlisted":false},{"type":"link","label":"Mem0","href":"/bundles-mem0","docId":"Components/bundles-mem0","unlisted":false},{"type":"link","label":"MistralAI","href":"/bundles-mistralai","docId":"Components/bundles-mistralai","unlisted":false},{"type":"category","label":"Notion","items":[{"type":"link","label":"Set up a Notion App","href":"/integrations/notion/setup","docId":"Integrations/Notion/integrations-notion","unlisted":false},{"type":"link","label":"Notion Conversational Agent","href":"/integrations/notion/notion-agent-conversational","docId":"Integrations/Notion/notion-agent-conversational","unlisted":false},{"type":"link","label":"Notion Meeting Notes Agent","href":"/integrations/notion/notion-agent-meeting-notes","docId":"Integrations/Notion/notion-agent-meeting-notes","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Novita","href":"/bundles-novita","docId":"Components/bundles-novita","unlisted":false},{"type":"category","label":"NVIDIA","items":[{"type":"link","label":"NVIDIA components","href":"/bundles-nvidia","docId":"Components/bundles-nvidia","unlisted":false},{"type":"link","label":"NVIDIA Ingest","href":"/integrations-nvidia-ingest","docId":"Integrations/Nvidia/integrations-nvidia-ingest","unlisted":false},{"type":"link","label":"NVIDIA NIM on WSL2","href":"/integrations-nvidia-ingest-wsl2","docId":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","unlisted":false},{"type":"link","label":"NVIDIA G-Assist","href":"/integrations-nvidia-g-assist","docId":"Integrations/Nvidia/integrations-nvidia-g-assist","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Ollama","href":"/bundles-ollama","docId":"Components/bundles-ollama","unlisted":false},{"type":"link","label":"OpenAI","href":"/bundles-openai","docId":"Components/bundles-openai","unlisted":false},{"type":"link","label":"OpenRouter","href":"/bundles-openrouter","docId":"Components/bundles-openrouter","unlisted":false},{"type":"link","label":"Perplexity","href":"/bundles-perplexity","docId":"Components/bundles-perplexity","unlisted":false},{"type":"link","label":"Redis","href":"/bundles-redis","docId":"Components/bundles-redis","unlisted":false},{"type":"link","label":"SambaNova","href":"/bundles-sambanova","docId":"Components/bundles-sambanova","unlisted":false},{"type":"link","label":"SearchApi","href":"/bundles-searchapi","docId":"Components/bundles-searchapi","unlisted":false},{"type":"link","label":"Vertex AI","href":"/bundles-vertexai","docId":"Components/bundles-vertexai","unlisted":false},{"type":"link","label":"Wikipedia","href":"/bundles-wikipedia","docId":"Components/bundles-wikipedia","unlisted":false},{"type":"link","label":"xAI","href":"/bundles-xai","docId":"Components/bundles-xai","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Create custom Python components","href":"/components-custom-components","docId":"Components/components-custom-components","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"API reference","items":[{"type":"link","label":"Get started with the Langflow API","href":"/api-reference-api-examples","docId":"API-Reference/api-reference-api-examples","unlisted":false},{"type":"link","label":"Use the TypeScript client","href":"/typescript-client","docId":"Develop/Clients/typescript-client","unlisted":false},{"type":"link","label":"Flow trigger endpoints","href":"/api-flows-run","docId":"API-Reference/api-flows-run","unlisted":false},{"type":"link","label":"Flow management endpoints","href":"/api-flows","docId":"API-Reference/api-flows","unlisted":false},{"type":"link","label":"Files endpoints","href":"/api-files","docId":"API-Reference/api-files","unlisted":false},{"type":"link","label":"Projects endpoints","href":"/api-projects","docId":"API-Reference/api-projects","unlisted":false},{"type":"link","label":"Logs endpoints","href":"/api-logs","docId":"API-Reference/api-logs","unlisted":false},{"type":"link","label":"Monitor endpoints","href":"/api-monitor","docId":"API-Reference/api-monitor","unlisted":false},{"type":"link","label":"Build endpoints","href":"/api-build","docId":"API-Reference/api-build","unlisted":false},{"type":"link","label":"Users endpoints","href":"/api-users","docId":"API-Reference/api-users","unlisted":false},{"type":"link","label":"Langflow API specification","href":"/api"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contribute","items":[{"type":"link","label":"Join the Langflow community","href":"/contributing-community","docId":"Contributing/contributing-community","unlisted":false},{"type":"link","label":"Contribute to Langflow","href":"/contributing-how-to-contribute","docId":"Contributing/contributing-how-to-contribute","unlisted":false},{"type":"link","label":"Contribute components","href":"/contributing-components","docId":"Contributing/contributing-components","unlisted":false},{"type":"link","label":"Contribute component tests","href":"/contributing-component-tests","docId":"Contributing/contributing-component-tests","unlisted":false},{"type":"link","label":"Contribute templates","href":"/contributing-templates","docId":"Contributing/contributing-templates","unlisted":false},{"type":"link","label":"Contribute bundles","href":"/contributing-bundles","docId":"Contributing/contributing-bundles","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Release notes","items":[{"type":"link","label":"Release notes","href":"/release-notes","docId":"Support/release-notes","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Support","items":[{"type":"link","label":"Troubleshoot","href":"/troubleshoot","docId":"Support/troubleshooting","unlisted":false},{"type":"link","label":"Get help and request enhancements","href":"/contributing-github-issues","docId":"Contributing/contributing-github-issues","unlisted":false},{"type":"link","label":"Enterprise support","href":"/luna-for-langflow","docId":"Support/luna-for-langflow","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"html","className":"sidebar-ad","value":"\\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n \\n
\\n Get started in minutes\\n Download Langflow Desktop\\n
\\n
\\n "}]},"docs":{"Agents/agents":{"id":"Agents/agents","title":"Use Langflow agents","description":"Langflow\'s Agent component is critical for building agent flows.","sidebar":"docs"},"Agents/agents-tools":{"id":"Agents/agents-tools","title":"Configure tools for agents","description":"Configure tools connected to agents to extend their capabilities.","sidebar":"docs"},"API-Reference/api-build":{"id":"API-Reference/api-build","title":"Build endpoints","description":"The /build endpoints are used by Langflow\'s frontend visual editor code.","sidebar":"docs"},"API-Reference/api-files":{"id":"API-Reference/api-files","title":"Files endpoints","description":"Use the /files endpoints to move files between your local machine and Langflow.","sidebar":"docs"},"API-Reference/api-flows":{"id":"API-Reference/api-flows","title":"Flow management endpoints","description":"Use the /flows endpoint to create, read, update, and delete flows.","sidebar":"docs"},"API-Reference/api-flows-run":{"id":"API-Reference/api-flows-run","title":"Flow trigger endpoints","description":"Use the /run and /webhook endpoints to run flows.","sidebar":"docs"},"API-Reference/api-logs":{"id":"API-Reference/api-logs","title":"Logs endpoints","description":"Retrieve logs for your Langflow flow.","sidebar":"docs"},"API-Reference/api-monitor":{"id":"API-Reference/api-monitor","title":"Monitor endpoints","description":"Use the /monitor endpoint to monitor and modify messages passed between Langflow components, vertex builds, and transactions.","sidebar":"docs"},"API-Reference/api-projects":{"id":"API-Reference/api-projects","title":"Projects endpoints","description":"Use the /projects endpoint to create, read, update, and delete Langflow projects.","sidebar":"docs"},"API-Reference/api-reference-api-examples":{"id":"API-Reference/api-reference-api-examples","title":"Get started with the Langflow API","description":"You can use the Langflow API for programmatic interactions with Langflow, such as the following:","sidebar":"docs"},"API-Reference/api-users":{"id":"API-Reference/api-users","title":"Users endpoints","description":"Use the /users endpoint to manage user accounts in Langflow.","sidebar":"docs"},"Components/bundles-aiml":{"id":"Components/bundles-aiml","title":"AI/ML API","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-amazon":{"id":"Components/bundles-amazon","title":"Amazon","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-anthropic":{"id":"Components/bundles-anthropic","title":"Anthropic","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-arxiv":{"id":"Components/bundles-arxiv","title":"arXiv","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-azure":{"id":"Components/bundles-azure","title":"Azure","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-baidu":{"id":"Components/bundles-baidu","title":"Baidu","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-bing":{"id":"Components/bundles-bing","title":"Bing","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-cloudflare":{"id":"Components/bundles-cloudflare","title":"Cloudflare","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-cohere":{"id":"Components/bundles-cohere","title":"Cohere","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-datastax":{"id":"Components/bundles-datastax","title":"DataStax","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-deepseek":{"id":"Components/bundles-deepseek","title":"DeepSeek","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-duckduckgo":{"id":"Components/bundles-duckduckgo","title":"DuckDuckGo","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-exa":{"id":"Components/bundles-exa","title":"Exa","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-glean":{"id":"Components/bundles-glean","title":"Glean","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-google":{"id":"Components/bundles-google","title":"Google components","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-groq":{"id":"Components/bundles-groq","title":"Groq","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-huggingface":{"id":"Components/bundles-huggingface","title":"Hugging Face","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-ibm":{"id":"Components/bundles-ibm","title":"IBM","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-icosacomputing":{"id":"Components/bundles-icosacomputing","title":"Icosa Computing","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-langchain":{"id":"Components/bundles-langchain","title":"LangChain","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-lmstudio":{"id":"Components/bundles-lmstudio","title":"LM Studio","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-maritalk":{"id":"Components/bundles-maritalk","title":"MariTalk","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-mem0":{"id":"Components/bundles-mem0","title":"Mem0","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-mistralai":{"id":"Components/bundles-mistralai","title":"MistralAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-novita":{"id":"Components/bundles-novita","title":"Novita","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-nvidia":{"id":"Components/bundles-nvidia","title":"NVIDIA components","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-ollama":{"id":"Components/bundles-ollama","title":"Ollama","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-openai":{"id":"Components/bundles-openai","title":"OpenAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-openrouter":{"id":"Components/bundles-openrouter","title":"OpenRouter","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-perplexity":{"id":"Components/bundles-perplexity","title":"Perplexity","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-redis":{"id":"Components/bundles-redis","title":"Redis","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-sambanova":{"id":"Components/bundles-sambanova","title":"SambaNova","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-searchapi":{"id":"Components/bundles-searchapi","title":"SearchApi","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-vertexai":{"id":"Components/bundles-vertexai","title":"Vertex AI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-wikipedia":{"id":"Components/bundles-wikipedia","title":"Wikipedia","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/bundles-xai":{"id":"Components/bundles-xai","title":"xAI","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/components-agents":{"id":"Components/components-agents","title":"Agents","description":"Langflow\'s Agent and MCP Tools components are critical for building agent flows.","sidebar":"docs"},"Components/components-bundles":{"id":"Components/components-bundles","title":"About bundles","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","sidebar":"docs"},"Components/components-custom-components":{"id":"Components/components-custom-components","title":"Create custom Python components","description":"Custom components extend Langflow\'s functionality through Python classes that inherit from Component. This enables integration of new features, data manipulation, external services, and specialized tools.","sidebar":"docs"},"Components/components-data":{"id":"Components/components-data","title":"Data","description":"You can use Langflow\'s Data components to bring data into your flows from various sources like files, API endpoints, and URLs.","sidebar":"docs"},"Components/components-embedding-models":{"id":"Components/components-embedding-models","title":"Embedding Model","description":"Embedding Model components in Langflow generate text embeddings using a specified Large Language Model (LLM).","sidebar":"docs"},"Components/components-helpers":{"id":"Components/components-helpers","title":"Helpers","description":"Helper components provide utility functions to help manage data and perform simple tasks in your flow.","sidebar":"docs"},"Components/components-io":{"id":"Components/components-io","title":"Input / Output","description":"Langflow\'s Input and Output components define where data enters and exits your flow, but they don\'t have identical functionality.","sidebar":"docs"},"Components/components-logic":{"id":"Components/components-logic","title":"Logic","description":"Langflow\'s Logic components provide functionalities for routing, conditional processing, and flow management.","sidebar":"docs"},"Components/components-memories":{"id":"Components/components-memories","title":"Memories","description":"In Langflow version 1.5, the Memory category was removed.","sidebar":"docs"},"Components/components-models":{"id":"Components/components-models","title":"Language Model","description":"Language Model components in Langflow generate text using a specified Large Language Model (LLM).","sidebar":"docs"},"Components/components-processing":{"id":"Components/components-processing","title":"Processing components","description":"Langflow\'s Processing components process and transform data within a flow.","sidebar":"docs"},"Components/components-prompts":{"id":"Components/components-prompts","title":"Prompt Template","description":"Use the Prompt Template core component to create a prompt that supplies instructions and context to an LLM or agent, separate from other input like chat messages and file uploads.","sidebar":"docs"},"Components/components-tools":{"id":"Components/components-tools","title":"Tools","description":"In Langflow version 1.5, the Tools category was deprecated.","sidebar":"docs"},"Components/components-vector-stores":{"id":"Components/components-vector-stores","title":"Vector Stores","description":"Langflow\'s Vector Store components connect to your vector databases or create in-memory vector stores for storing and retrieving vector data in flows.","sidebar":"docs"},"Components/mcp-client":{"id":"Components/mcp-client","title":"Use Langflow as an MCP client","description":"Langflow integrates with the Model Context Protocol (MCP) as both an MCP server and an MCP client.","sidebar":"docs"},"Concepts/concepts-components":{"id":"Concepts/concepts-components","title":"Components overview","description":"Components are the building blocks of your flows.","sidebar":"docs"},"Concepts/concepts-file-management":{"id":"Concepts/concepts-file-management","title":"Manage files","description":"Each Langflow server has a file management system where you can store files that you want to use in your flows.","sidebar":"docs"},"Concepts/concepts-flows":{"id":"Concepts/concepts-flows","title":"Build flows","description":"A flow is a functional representation of an application workflow.","sidebar":"docs"},"Concepts/concepts-flows-import":{"id":"Concepts/concepts-flows-import","title":"Import and export flows","description":"You can export flows to transfer them between Langflow instances, share them with others, or create backups.","sidebar":"docs"},"Concepts/concepts-overview":{"id":"Concepts/concepts-overview","title":"Use the visual editor","description":"You use Langflow\'s visual editor to create, test, and share flows, which are functional representations of application workflows.","sidebar":"docs"},"Concepts/concepts-playground":{"id":"Concepts/concepts-playground","title":"Test flows in the Playground","description":"Langflow\'s Playground is a dynamic interface you can use to test your LLM-based flows in real-time.","sidebar":"docs"},"Concepts/concepts-publish":{"id":"Concepts/concepts-publish","title":"Trigger flows with the Langflow API","description":"After you build a flow, you probably want to run it within an application, such as a chatbot within a mobile app or website.","sidebar":"docs"},"Concepts/concepts-voice-mode":{"id":"Concepts/concepts-voice-mode","title":"Use voice mode","description":"You can use Langflow\'s voice mode to interact with your flows verbally through a microphone and speakers.","sidebar":"docs"},"Concepts/data-types":{"id":"Concepts/data-types","title":"Langflow data types","description":"Langflow components are designed to accept and produce specific types of inputs and outputs.","sidebar":"docs"},"Concepts/mcp-server":{"id":"Concepts/mcp-server","title":"Use Langflow as an MCP server","description":"Langflow integrates with the Model Context Protocol (MCP) as both an MCP server and an MCP client.","sidebar":"docs"},"Configuration/api-keys-and-authentication":{"id":"Configuration/api-keys-and-authentication","title":"API keys and authentication","description":"Never expose Langflow ports directly to the internet without proper security measures.","sidebar":"docs"},"Configuration/configuration-cli":{"id":"Configuration/configuration-cli","title":"Langflow CLI","description":"The Langflow command line interface (Langflow CLI) is the main interface for managing and running the Langflow server.","sidebar":"docs"},"Configuration/configuration-custom-database":{"id":"Configuration/configuration-custom-database","title":"Configure an external PostgreSQL database","description":"Langflow\'s default database is SQLite, but you can configure Langflow to use PostgreSQL instead.","sidebar":"docs"},"Configuration/configuration-global-variables":{"id":"Configuration/configuration-global-variables","title":"Global variables","description":"Global variables let you store and reuse generic input values and credentials across your Langflow projects.","sidebar":"docs"},"Configuration/environment-variables":{"id":"Configuration/environment-variables","title":"Environment variables","description":"Langflow uses environment variables to configure certain settings.","sidebar":"docs"},"Contributing/contributing-bundles":{"id":"Contributing/contributing-bundles","title":"Contribute bundles","description":"Bundles are groups of components that are related to a specific service provider.","sidebar":"docs"},"Contributing/contributing-community":{"id":"Contributing/contributing-community","title":"Join the Langflow community","description":"There are several ways you can interact with the Langflow community and learn more about the Langflow codebase.","sidebar":"docs"},"Contributing/contributing-component-tests":{"id":"Contributing/contributing-component-tests","title":"Contribute component tests","description":"This guide outlines how to structure and implement tests for application components to ensure consistency and adequate coverage.","sidebar":"docs"},"Contributing/contributing-components":{"id":"Contributing/contributing-components","title":"Contribute components","description":"New components are added as objects of the Component class.","sidebar":"docs"},"Contributing/contributing-github-issues":{"id":"Contributing/contributing-github-issues","title":"Get help and request enhancements","description":"The Langflow GitHub repository is an integral part of the Langflow community.","sidebar":"docs"},"Contributing/contributing-how-to-contribute":{"id":"Contributing/contributing-how-to-contribute","title":"Contribute to Langflow","description":"This guide is intended to help you start contributing to Langflow.","sidebar":"docs"},"Contributing/contributing-telemetry":{"id":"Contributing/contributing-telemetry","title":"Telemetry","description":"Langflow uses anonymous telemetry to collect statistics about feature usage and performance.","sidebar":"docs"},"Contributing/contributing-templates":{"id":"Contributing/contributing-templates","title":"Contribute templates","description":"Follow these best practices when submitting a template to Langflow.","sidebar":"docs"},"Deployment/deployment-caddyfile":{"id":"Deployment/deployment-caddyfile","title":"Deploy Langflow on a remote server","description":"Learn how to deploy Langflow on your own remote server with secure web access.","sidebar":"docs"},"Deployment/deployment-docker":{"id":"Deployment/deployment-docker","title":"Deploy Langflow on Docker","description":"Running applications in Docker containers ensures consistent behavior across different systems and eliminates dependency conflicts.","sidebar":"docs"},"Deployment/deployment-gcp":{"id":"Deployment/deployment-gcp","title":"Deploy Langflow on Google Cloud Platform","description":"This guide demonstrates how to deploy Langflow on Google Cloud Platform with a Cloud Shell script that walks through the process of setting up a Debian-based VM with the Langflow package, Nginx, and the necessary configurations to run the Langflow development environment in GCP.","sidebar":"docs"},"Deployment/deployment-hugging-face-spaces":{"id":"Deployment/deployment-hugging-face-spaces","title":"Deploy Langflow on Hugging Face Spaces","description":"This guide explains how to deploy Langflow on Hugging Face Spaces.","sidebar":"docs"},"Deployment/deployment-kubernetes-dev":{"id":"Deployment/deployment-kubernetes-dev","title":"Deploy the Langflow development environment on Kubernetes","description":"The Langflow Integrated Development Environment (IDE) Helm chart is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the API and the visual editor.","sidebar":"docs"},"Deployment/deployment-kubernetes-prod":{"id":"Deployment/deployment-kubernetes-prod","title":"Deploy the Langflow production environment on Kubernetes","description":"The Langflow Runtime chart is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently.","sidebar":"docs"},"Deployment/deployment-overview":{"id":"Deployment/deployment-overview","title":"Langflow deployment overview","description":"This section includes the different ways to bring your locally-built flows to the world.","sidebar":"docs"},"Deployment/deployment-prod-best-practices":{"id":"Deployment/deployment-prod-best-practices","title":"Langflow architecture and best practices on Kubernetes","description":"Langflow can be deployed in two distinct environments.","sidebar":"docs"},"Deployment/deployment-public-server":{"id":"Deployment/deployment-public-server","title":"Deploy a public Langflow server","description":"By default, your Langflow server at http7860 isn\'t exposed to the public internet.","sidebar":"docs"},"Deployment/deployment-railway":{"id":"Deployment/deployment-railway","title":"Deploy Langflow on Railway","description":"Deploy Langflow to Railway using a one-click template","sidebar":"docs"},"Deployment/deployment-render":{"id":"Deployment/deployment-render","title":"Deploy Langflow on Render","description":"This guide explains how to deploy Langflow on Render, a cloud platform for deploying web applications and APIs.","sidebar":"docs"},"Develop/Clients/typescript-client":{"id":"Develop/Clients/typescript-client","title":"Langflow TypeScript client","description":"The Langflow TypeScript client allows your TypeScript applications to programmatically interact with the Langflow API.","sidebar":"docs"},"Develop/develop-application":{"id":"Develop/develop-application","title":"Containerize a Langflow application","description":"Designing flows in the visual editor is only the first step in building an application that uses Langflow.","sidebar":"docs"},"Develop/install-custom-dependencies":{"id":"Develop/install-custom-dependencies","title":"Install custom dependencies","description":"Langflow provides optional dependency groups and support for custom dependencies to extend Langflow functionality.","sidebar":"docs"},"Develop/logging":{"id":"Develop/logging","title":"Logs","description":"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself.","sidebar":"docs"},"Develop/memory":{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.","sidebar":"docs"},"Develop/session-id":{"id":"Develop/session-id","title":"Use session ID to manage communication between components","description":"Session ID is a unique identifier for client/server connections. A single session equals the duration of a client\'s connection to a server.","sidebar":"docs"},"Develop/webhook":{"id":"Develop/webhook","title":"Trigger flows with webhooks","description":"You can use the Webhook component to start a flow run in response to an external event.","sidebar":"docs"},"Get-Started/about-langflow":{"id":"Get-Started/about-langflow","title":"What is Langflow?","description":"Langflow is an open-source, Python-based, customizable framework for building AI applications.","sidebar":"docs"},"Get-Started/get-started-installation":{"id":"Get-Started/get-started-installation","title":"Install Langflow","description":"Langflow can be installed in multiple ways:","sidebar":"docs"},"Get-Started/get-started-quickstart":{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get started with Langflow by loading a template flow, running it, and then serving it at the /run API endpoint.","sidebar":"docs"},"Get-Started/welcome-to-langflow":{"id":"Get-Started/welcome-to-langflow","title":"Welcome to Langflow","description":"Langflow empowers developers to rapidly prototype and build AI applications with a user-friendly visual interface and support for important AI functionality like agents and the MCP.","sidebar":"docs"},"Integrations/Apify/integrations-apify":{"id":"Integrations/Apify/integrations-apify","title":"Apify","description":"Apify is a web scraping and data extraction platform with more than 3,000 ready-made cloud tools called Actors.","sidebar":"docs"},"Integrations/Arize/integrations-arize":{"id":"Integrations/Arize/integrations-arize","title":"Arize","description":"Arize is a tool built on OpenTelemetry and OpenInference for monitoring and optimizing LLM applications.","sidebar":"docs"},"Integrations/Cleanlab/integrations-cleanlab":{"id":"Integrations/Cleanlab/integrations-cleanlab","title":"Cleanlab","description":"Cleanlab adds automation and trust to every data point going in and every prediction coming out of AI and RAG solutions.","sidebar":"docs"},"Integrations/Composio/integrations-composio":{"id":"Integrations/Composio/integrations-composio","title":"Composio","description":"Composio components in Langflow provide Composio tools to your Agent components.","sidebar":"docs"},"Integrations/Docling/integrations-docling":{"id":"Integrations/Docling/integrations-docling","title":"Docling","description":"Langflow integrates with Docling through a bundle of components for parsing documents.","sidebar":"docs"},"Integrations/Google/integrations-google-big-query":{"id":"Integrations/Google/integrations-google-big-query","title":"Google BigQuery","description":"Langflow integrates with Google BigQuery through the BigQuery component in the Google bundle, allowing you to execute SQL queries and retrieve data from your BigQuery datasets.","sidebar":"docs"},"Integrations/integrations-assemblyai":{"id":"Integrations/integrations-assemblyai","title":"AssemblyAI","description":"The AssemblyAI components allow you to apply powerful Speech AI models to your app for tasks like:","sidebar":"docs"},"Integrations/integrations-langfuse":{"id":"Integrations/integrations-langfuse","title":"Langfuse","description":"Langfuse is an open-source platform for LLM observability. It provides tracing and monitoring capabilities for AI applications, helping developers debug, analyze, and optimize their AI systems. Langfuse integrates with various tools and frameworks, including workflow builders and runtimes like Langflow.","sidebar":"docs"},"Integrations/integrations-langsmith":{"id":"Integrations/integrations-langsmith","title":"LangSmith","description":"LangSmith is a full-lifecycle DevOps service from LangChain that provides monitoring and observability. To integrate with Langflow, add your LangChain API key and configuration as Langflow environment variables, and then start Langflow.","sidebar":"docs"},"Integrations/integrations-langwatch":{"id":"Integrations/integrations-langwatch","title":"LangWatch","description":"LangWatch is an all-in-one LLMOps platform for monitoring, observability, analytics, evaluations and alerting for getting user insights and improve your LLM workflows.","sidebar":"docs"},"Integrations/integrations-opik":{"id":"Integrations/integrations-opik","title":"Opik","description":"Opik is an open-source platform designed for evaluating, testing, and monitoring large language model (LLM) applications. Developed by Comet, it aims to facilitate more intuitive collaboration, testing, and monitoring of LLM-based applications.","sidebar":"docs"},"Integrations/mcp-component-astra":{"id":"Integrations/mcp-component-astra","title":"Connect an Astra DB MCP server to Langflow","description":"This guide demonstrates how to use Langflow as an MCP client by using the MCP Tools component to run a DataStax Astra DB MCP server in an agent flow.","sidebar":"docs"},"Integrations/Notion/integrations-notion":{"id":"Integrations/Notion/integrations-notion","title":"Set up a Notion App","description":"To use Notion components in Langflow, you first need to create a Notion integration and configure it with the necessary capabilities. This guide will walk you through the process of setting up a Notion integration and granting it access to your Notion databases.","sidebar":"docs"},"Integrations/Notion/notion-agent-conversational":{"id":"Integrations/Notion/notion-agent-conversational","title":"Notion Conversational Agent","description":"The Notion Conversational Agent is an AI-powered assistant that interacts with your Notion workspace through natural language conversations. This flow performs Notion-related tasks like creating pages, searching for information, and managing content, all through a chat interface.","sidebar":"docs"},"Integrations/Notion/notion-agent-meeting-notes":{"id":"Integrations/Notion/notion-agent-meeting-notes","title":"Notion Meeting Notes Agent","description":"The Notion Agent for Meeting Notes is an AI-powered tool that automatically processes meeting transcripts and updates your Notion workspace. It identifies tasks, action items, and key points from your meetings, then creates new tasks or updates existing ones in Notion without manual input.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-g-assist":{"id":"Integrations/Nvidia/integrations-nvidia-g-assist","title":"Integrate NVIDIA G-Assist with Langflow","description":"The NVIDIA G-Assist component is available only for Langflow users with NVIDIA GPUs on Windows systems.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-ingest":{"id":"Integrations/Nvidia/integrations-nvidia-ingest","title":"Integrate NVIDIA Retriever Extraction with Langflow","description":"The NVIDIA Retriever Extraction component integrates with the NVIDIA nv-ingest microservice for data ingestion, processing, and extraction of text files.","sidebar":"docs"},"Integrations/Nvidia/integrations-nvidia-nim-wsl2":{"id":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","title":"Integrate NVIDIA NIMs with Langflow","description":"Connect Langflow with NVIDIA NIM on an RTX Windows system with Windows Subsystem for Linux 2 (WSL2) installed.","sidebar":"docs"},"Support/luna-for-langflow":{"id":"Support/luna-for-langflow","title":"Enterprise support for Langflow","description":"With Luna for Langflow support, you can develop and deploy Langflow applications with confidence.","sidebar":"docs"},"Support/release-notes":{"id":"Support/release-notes","title":"Langflow release notes","description":"This page summarizes significant changes to Langflow in each release.","sidebar":"docs"},"Support/troubleshooting":{"id":"Support/troubleshooting","title":"Troubleshoot Langflow","description":"This page provides troubleshooting advice for issues you might encounter when using Langflow or contributing to Langflow.","sidebar":"docs"},"Tutorials/agent":{"id":"Tutorials/agent","title":"Connect applications to agents","description":"This tutorial shows you how to connect a JavaScript application to a Langflow agent.","sidebar":"docs"},"Tutorials/chat-with-files":{"id":"Tutorials/chat-with-files","title":"Create a chatbot that can ingest files","description":"This tutorial shows you how to build a chatbot that can read and answer questions about files you upload, such as meeting notes or job applications.","sidebar":"docs"},"Tutorials/chat-with-rag":{"id":"Tutorials/chat-with-rag","title":"Create a vector RAG chatbot","description":"This tutorial demonstrates how you can use Langflow to create a chatbot application that uses Retrieval Augmented Generation (RAG) to embed your data as vectors in a vector database, and then chat with the data.","sidebar":"docs"},"Tutorials/mcp-tutorial":{"id":"Tutorials/mcp-tutorial","title":"Connect to MCP servers from your application","description":"This tutorial shows you how to connect MCP servers to your applications using Langflow\'s MCP Tools component.","sidebar":"docs"}}}}')}}]); \ No newline at end of file diff --git a/assets/js/2ab0d4f5.6e2f93d4.js b/assets/js/2ab0d4f5.6e2f93d4.js deleted file mode 100644 index 5dc69ea043..0000000000 --- a/assets/js/2ab0d4f5.6e2f93d4.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1845],{28453:(e,n,t)=>{t.d(n,{R:()=>a,x:()=>o});var i=t(96540);const s={},r=i.createContext(s);function a(e){const n=i.useContext(r);return i.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function o(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:a(e.components),i.createElement(r.Provider,{value:n},e.children)}},83640:(e,n,t)=>{t.r(n),t.d(n,{contentTitle:()=>o,default:()=>c,frontMatter:()=>a,metadata:()=>i,toc:()=>l});const i=JSON.parse('{"type":"api","id":"simplified-run-flow","title":"Simplified Run Flow","description":"","slug":"/simplified-run-flow","frontMatter":{},"api":{"tags":["Base"],"description":"Executes a specified flow by ID with support for streaming and telemetry.\\n\\nThis endpoint executes a flow identified by ID or name, with options for streaming the response\\nand tracking execution metrics. It handles both streaming and non-streaming execution modes.\\n\\nArgs:\\n background_tasks (BackgroundTasks): FastAPI background task manager\\n flow (FlowRead | None): The flow to execute, loaded via dependency\\n input_request (SimplifiedAPIRequest | None): Input parameters for the flow\\n stream (bool): Whether to stream the response\\n api_key_user (UserRead): Authenticated user from API key\\n request (Request): The incoming HTTP request\\n\\nReturns:\\n Union[StreamingResponse, RunResponse]: Either a streaming response for real-time results\\n or a RunResponse with the complete execution results\\n\\nRaises:\\n HTTPException: For flow not found (404) or invalid input (400)\\n APIException: For internal execution errors (500)\\n\\nNotes:\\n - Supports both streaming and non-streaming execution modes\\n - Tracks execution time and success/failure via telemetry\\n - Handles graceful client disconnection in streaming mode\\n - Provides detailed error handling with appropriate HTTP status codes\\n - In streaming mode, uses EventManager to handle events:\\n - \\"add_message\\": New messages during execution\\n - \\"token\\": Individual tokens during streaming\\n - \\"end\\": Final execution result","operationId":"simplified_run_flow_api_v1_run__flow_id_or_name__post","security":[{"API key query":[]},{"API key header":[]}],"parameters":[{"name":"flow_id_or_name","in":"path","required":true,"schema":{"type":"string","title":"Flow Id Or Name"}},{"name":"stream","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Stream"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"properties":{"input_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Input Value","description":"The input value"},"input_type":{"anyOf":[{"type":"string","enum":["chat","text","any"]},{"type":"null"}],"title":"Input Type","description":"The input type","default":"chat"},"output_type":{"anyOf":[{"type":"string","enum":["chat","text","any","debug"]},{"type":"null"}],"title":"Output Type","description":"The output type","default":"chat"},"output_component":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Component","description":"If there are multiple output components, you can specify the component to get the output from.","default":""},"tweaks":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"object","title":"Tweaks","description":"A dictionary of tweaks to adjust the flow\'s execution. Allows customizing flow behavior dynamically. All tweaks are overridden by the input values.","examples":[{"Component Name":{"parameter_name":"value"},"component_id":{"parameter_name":"value"},"parameter_name":"value"}]},{"type":"null"}],"description":"The tweaks"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"The session id"}},"type":"object","title":"SimplifiedAPIRequest"},{"type":"null"}],"title":"Input Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"}}}}},"method":"post","path":"/api/v1/run/{flow_id_or_name}","securitySchemes":{"OAuth2PasswordBearer":{"type":"oauth2","flows":{"password":{"scopes":{},"tokenUrl":"api/v1/login"}}},"API key query":{"type":"apiKey","in":"query","name":"x-api-key"},"API key header":{"type":"apiKey","in":"header","name":"x-api-key"}},"info":{"title":"Langflow","version":"1.5.0.post1"},"postman":{"name":"Simplified Run Flow","description":{"content":"Executes a specified flow by ID with support for streaming and telemetry.\\n\\nThis endpoint executes a flow identified by ID or name, with options for streaming the response\\nand tracking execution metrics. It handles both streaming and non-streaming execution modes.\\n\\nArgs:\\n background_tasks (BackgroundTasks): FastAPI background task manager\\n flow (FlowRead | None): The flow to execute, loaded via dependency\\n input_request (SimplifiedAPIRequest | None): Input parameters for the flow\\n stream (bool): Whether to stream the response\\n api_key_user (UserRead): Authenticated user from API key\\n request (Request): The incoming HTTP request\\n\\nReturns:\\n Union[StreamingResponse, RunResponse]: Either a streaming response for real-time results\\n or a RunResponse with the complete execution results\\n\\nRaises:\\n HTTPException: For flow not found (404) or invalid input (400)\\n APIException: For internal execution errors (500)\\n\\nNotes:\\n - Supports both streaming and non-streaming execution modes\\n - Tracks execution time and success/failure via telemetry\\n - Handles graceful client disconnection in streaming mode\\n - Provides detailed error handling with appropriate HTTP status codes\\n - In streaming mode, uses EventManager to handle events:\\n - \\"add_message\\": New messages during execution\\n - \\"token\\": Individual tokens during streaming\\n - \\"end\\": Final execution result","type":"text/plain"},"url":{"path":["api","v1","run",":flow_id_or_name"],"host":["{{baseUrl}}"],"query":[{"disabled":false,"key":"stream","value":"false"},{"disabled":false,"key":"user_id","value":""}],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"flow_id_or_name"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"{\\n \\"input_value\\": \\"\\",\\n \\"input_type\\": \\"\\",\\n \\"output_type\\": \\"\\",\\n \\"output_component\\": \\"\\",\\n \\"tweaks\\": {\\n \\"cillumf9\\": \\"\\",\\n \\"in9f1\\": \\"\\"\\n },\\n \\"session_id\\": \\"\\"\\n}","options":{"raw":{"language":"json"}}},"auth":{"type":"apikey","apikey":[{"type":"any","value":"x-api-key","key":"key"},{"type":"any","value":"{{apiKey}}","key":"value"},{"type":"any","value":"query","key":"in"}]}}},"source":"@site/openapi.json","sourceDirName":".","permalink":"/api/simplified-run-flow","previous":{"title":"Get All","permalink":"/api/get-all"},"next":{"title":"Webhook Run Flow","permalink":"/api/webhook-run-flow"}}');var s=t(74848),r=t(28453);const a={},o="Simplified Run Flow",l=[];function d(e){const n={h1:"h1",header:"header",li:"li",p:"p",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"simplified-run-flow",children:"Simplified Run Flow"})}),"\n",(0,s.jsx)(n.p,{children:"Executes a specified flow by ID with support for streaming and telemetry."}),"\n",(0,s.jsx)(n.p,{children:"This endpoint executes a flow identified by ID or name, with options for streaming the response\nand tracking execution metrics. It handles both streaming and non-streaming execution modes."}),"\n",(0,s.jsx)(n.p,{children:"Args:\nbackground_tasks (BackgroundTasks): FastAPI background task manager\nflow (FlowRead | None): The flow to execute, loaded via dependency\ninput_request (SimplifiedAPIRequest | None): Input parameters for the flow\nstream (bool): Whether to stream the response\napi_key_user (UserRead): Authenticated user from API key\nrequest (Request): The incoming HTTP request"}),"\n",(0,s.jsx)(n.p,{children:"Returns:\nUnion[StreamingResponse, RunResponse]: Either a streaming response for real-time results\nor a RunResponse with the complete execution results"}),"\n",(0,s.jsx)(n.p,{children:"Raises:\nHTTPException: For flow not found (404) or invalid input (400)\nAPIException: For internal execution errors (500)"}),"\n",(0,s.jsx)(n.p,{children:"Notes:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"Supports both streaming and non-streaming execution modes"}),"\n",(0,s.jsx)(n.li,{children:"Tracks execution time and success/failure via telemetry"}),"\n",(0,s.jsx)(n.li,{children:"Handles graceful client disconnection in streaming mode"}),"\n",(0,s.jsx)(n.li,{children:"Provides detailed error handling with appropriate HTTP status codes"}),"\n",(0,s.jsxs)(n.li,{children:["In streaming mode, uses EventManager to handle events:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:'"add_message": New messages during execution'}),"\n",(0,s.jsx)(n.li,{children:'"token": Individual tokens during streaming'}),"\n",(0,s.jsx)(n.li,{children:'"end": Final execution result'}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Path Parameters"})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"flow_id_or_name"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Flow Id Or Name"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-required)"},children:" REQUIRED"})]})})})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Query Parameters"})})}),(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"stream"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Stream"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"user_id"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" User Id"})]})})]})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Request Body "}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("td",{children:(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined"})})})})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Responses"})})}),(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsxs)("div",{style:{display:"flex"},children:[(0,s.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,s.jsx)("code",{children:"200"})}),(0,s.jsx)("div",{children:(0,s.jsx)(n.p,{children:"Successful Response"})})]}),(0,s.jsx)("div",{children:(0,s.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Schema "}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("td",{children:(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined"})})})})]})})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsxs)("div",{style:{display:"flex"},children:[(0,s.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,s.jsx)("code",{children:"422"})}),(0,s.jsx)("div",{children:(0,s.jsx)(n.p,{children:"Validation Error"})})]}),(0,s.jsx)("div",{children:(0,s.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Schema "}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"detail"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" object[]"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"loc"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined[]"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"msg"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Message"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"type"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Error Type"})]})})]})})]})})})]})})]})})]})]})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(d,{...e})}):d(e)}}}]); \ No newline at end of file diff --git a/assets/js/2ab0d4f5.92a2d9ce.js b/assets/js/2ab0d4f5.92a2d9ce.js new file mode 100644 index 0000000000..a409196ce6 --- /dev/null +++ b/assets/js/2ab0d4f5.92a2d9ce.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1845],{28453:(e,n,t)=>{t.d(n,{R:()=>a,x:()=>o});var i=t(96540);const s={},r=i.createContext(s);function a(e){const n=i.useContext(r);return i.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function o(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:a(e.components),i.createElement(r.Provider,{value:n},e.children)}},83640:(e,n,t)=>{t.r(n),t.d(n,{contentTitle:()=>o,default:()=>c,frontMatter:()=>a,metadata:()=>i,toc:()=>l});const i=JSON.parse('{"type":"api","id":"simplified-run-flow","title":"Simplified Run Flow","description":"","slug":"/simplified-run-flow","frontMatter":{},"api":{"tags":["Base"],"description":"Executes a specified flow by ID with support for streaming and telemetry.\\n\\nThis endpoint executes a flow identified by ID or name, with options for streaming the response\\nand tracking execution metrics. It handles both streaming and non-streaming execution modes.\\n\\nArgs:\\n background_tasks (BackgroundTasks): FastAPI background task manager\\n flow (FlowRead | None): The flow to execute, loaded via dependency\\n input_request (SimplifiedAPIRequest | None): Input parameters for the flow\\n stream (bool): Whether to stream the response\\n api_key_user (UserRead): Authenticated user from API key\\n request (Request): The incoming HTTP request\\n\\nReturns:\\n Union[StreamingResponse, RunResponse]: Either a streaming response for real-time results\\n or a RunResponse with the complete execution results\\n\\nRaises:\\n HTTPException: For flow not found (404) or invalid input (400)\\n APIException: For internal execution errors (500)\\n\\nNotes:\\n - Supports both streaming and non-streaming execution modes\\n - Tracks execution time and success/failure via telemetry\\n - Handles graceful client disconnection in streaming mode\\n - Provides detailed error handling with appropriate HTTP status codes\\n - In streaming mode, uses EventManager to handle events:\\n - \\"add_message\\": New messages during execution\\n - \\"token\\": Individual tokens during streaming\\n - \\"end\\": Final execution result","operationId":"simplified_run_flow_api_v1_run__flow_id_or_name__post","security":[{"API key query":[]},{"API key header":[]}],"parameters":[{"name":"flow_id_or_name","in":"path","required":true,"schema":{"type":"string","title":"Flow Id Or Name"}},{"name":"stream","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Stream"}},{"name":"user_id","in":"query","required":false,"schema":{"anyOf":[{"type":"string"},{"type":"string","format":"uuid"},{"type":"null"}],"title":"User Id"}}],"requestBody":{"content":{"application/json":{"schema":{"anyOf":[{"properties":{"input_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Input Value","description":"The input value"},"input_type":{"anyOf":[{"type":"string","enum":["chat","text","any"]},{"type":"null"}],"title":"Input Type","description":"The input type","default":"chat"},"output_type":{"anyOf":[{"type":"string","enum":["chat","text","any","debug"]},{"type":"null"}],"title":"Output Type","description":"The output type","default":"chat"},"output_component":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Output Component","description":"If there are multiple output components, you can specify the component to get the output from.","default":""},"tweaks":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"object","title":"Tweaks","description":"A dictionary of tweaks to adjust the flow\'s execution. Allows customizing flow behavior dynamically. All tweaks are overridden by the input values.","examples":[{"Component Name":{"parameter_name":"value"},"component_id":{"parameter_name":"value"},"parameter_name":"value"}]},{"type":"null"}],"description":"The tweaks"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id","description":"The session id"}},"type":"object","title":"SimplifiedAPIRequest"},{"type":"null"}],"title":"Input Request"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"}}}}},"method":"post","path":"/api/v1/run/{flow_id_or_name}","securitySchemes":{"OAuth2PasswordBearer":{"type":"oauth2","flows":{"password":{"scopes":{},"tokenUrl":"api/v1/login"}}},"API key query":{"type":"apiKey","in":"query","name":"x-api-key"},"API key header":{"type":"apiKey","in":"header","name":"x-api-key"}},"info":{"title":"Langflow","version":"1.5.0.post1"},"postman":{"name":"Simplified Run Flow","description":{"content":"Executes a specified flow by ID with support for streaming and telemetry.\\n\\nThis endpoint executes a flow identified by ID or name, with options for streaming the response\\nand tracking execution metrics. It handles both streaming and non-streaming execution modes.\\n\\nArgs:\\n background_tasks (BackgroundTasks): FastAPI background task manager\\n flow (FlowRead | None): The flow to execute, loaded via dependency\\n input_request (SimplifiedAPIRequest | None): Input parameters for the flow\\n stream (bool): Whether to stream the response\\n api_key_user (UserRead): Authenticated user from API key\\n request (Request): The incoming HTTP request\\n\\nReturns:\\n Union[StreamingResponse, RunResponse]: Either a streaming response for real-time results\\n or a RunResponse with the complete execution results\\n\\nRaises:\\n HTTPException: For flow not found (404) or invalid input (400)\\n APIException: For internal execution errors (500)\\n\\nNotes:\\n - Supports both streaming and non-streaming execution modes\\n - Tracks execution time and success/failure via telemetry\\n - Handles graceful client disconnection in streaming mode\\n - Provides detailed error handling with appropriate HTTP status codes\\n - In streaming mode, uses EventManager to handle events:\\n - \\"add_message\\": New messages during execution\\n - \\"token\\": Individual tokens during streaming\\n - \\"end\\": Final execution result","type":"text/plain"},"url":{"path":["api","v1","run",":flow_id_or_name"],"host":["{{baseUrl}}"],"query":[{"disabled":false,"key":"stream","value":"false"},{"disabled":false,"key":"user_id","value":""}],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"flow_id_or_name"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"{\\n \\"input_value\\": \\"\\",\\n \\"input_type\\": \\"\\",\\n \\"output_type\\": \\"\\",\\n \\"output_component\\": \\"\\",\\n \\"tweaks\\": {\\n \\"in1fe\\": \\"\\",\\n \\"nulla_5e6\\": \\"\\",\\n \\"enim_\\": \\"\\"\\n },\\n \\"session_id\\": \\"\\"\\n}","options":{"raw":{"language":"json"}}},"auth":{"type":"apikey","apikey":[{"type":"any","value":"x-api-key","key":"key"},{"type":"any","value":"{{apiKey}}","key":"value"},{"type":"any","value":"query","key":"in"}]}}},"source":"@site/openapi.json","sourceDirName":".","permalink":"/api/simplified-run-flow","previous":{"title":"Get All","permalink":"/api/get-all"},"next":{"title":"Webhook Run Flow","permalink":"/api/webhook-run-flow"}}');var s=t(74848),r=t(28453);const a={},o="Simplified Run Flow",l=[];function d(e){const n={h1:"h1",header:"header",li:"li",p:"p",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.header,{children:(0,s.jsx)(n.h1,{id:"simplified-run-flow",children:"Simplified Run Flow"})}),"\n",(0,s.jsx)(n.p,{children:"Executes a specified flow by ID with support for streaming and telemetry."}),"\n",(0,s.jsx)(n.p,{children:"This endpoint executes a flow identified by ID or name, with options for streaming the response\nand tracking execution metrics. It handles both streaming and non-streaming execution modes."}),"\n",(0,s.jsx)(n.p,{children:"Args:\nbackground_tasks (BackgroundTasks): FastAPI background task manager\nflow (FlowRead | None): The flow to execute, loaded via dependency\ninput_request (SimplifiedAPIRequest | None): Input parameters for the flow\nstream (bool): Whether to stream the response\napi_key_user (UserRead): Authenticated user from API key\nrequest (Request): The incoming HTTP request"}),"\n",(0,s.jsx)(n.p,{children:"Returns:\nUnion[StreamingResponse, RunResponse]: Either a streaming response for real-time results\nor a RunResponse with the complete execution results"}),"\n",(0,s.jsx)(n.p,{children:"Raises:\nHTTPException: For flow not found (404) or invalid input (400)\nAPIException: For internal execution errors (500)"}),"\n",(0,s.jsx)(n.p,{children:"Notes:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"Supports both streaming and non-streaming execution modes"}),"\n",(0,s.jsx)(n.li,{children:"Tracks execution time and success/failure via telemetry"}),"\n",(0,s.jsx)(n.li,{children:"Handles graceful client disconnection in streaming mode"}),"\n",(0,s.jsx)(n.li,{children:"Provides detailed error handling with appropriate HTTP status codes"}),"\n",(0,s.jsxs)(n.li,{children:["In streaming mode, uses EventManager to handle events:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:'"add_message": New messages during execution'}),"\n",(0,s.jsx)(n.li,{children:'"token": Individual tokens during streaming'}),"\n",(0,s.jsx)(n.li,{children:'"end": Final execution result'}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Path Parameters"})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"flow_id_or_name"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Flow Id Or Name"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-required)"},children:" REQUIRED"})]})})})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Query Parameters"})})}),(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"stream"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Stream"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"user_id"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" User Id"})]})})]})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Request Body "}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("td",{children:(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined"})})})})]}),"\n",(0,s.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("th",{style:{textAlign:"left"},children:"Responses"})})}),(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsxs)("div",{style:{display:"flex"},children:[(0,s.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,s.jsx)("code",{children:"200"})}),(0,s.jsx)("div",{children:(0,s.jsx)(n.p,{children:"Successful Response"})})]}),(0,s.jsx)("div",{children:(0,s.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Schema "}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsx)("td",{children:(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined"})})})})]})})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsxs)("div",{style:{display:"flex"},children:[(0,s.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,s.jsx)("code",{children:"422"})}),(0,s.jsx)("div",{children:(0,s.jsx)(n.p,{children:"Validation Error"})})]}),(0,s.jsx)("div",{children:(0,s.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,s.jsx)("thead",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("th",{style:{textAlign:"left"},children:[(0,s.jsx)("span",{children:"Schema "}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("div",{})]})})}),(0,s.jsx)("tbody",{children:(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"detail"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" object[]"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,s.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,s.jsx)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:(0,s.jsxs)("tbody",{children:[(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"loc"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" undefined[]"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"msg"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Message"})]})}),(0,s.jsx)("tr",{children:(0,s.jsxs)("td",{children:[(0,s.jsx)("code",{children:"type"}),(0,s.jsx)("span",{style:{opacity:"0.6"},children:" Error Type"})]})})]})})]})})})]})})]})})]})]})]})}function c(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(d,{...e})}):d(e)}}}]); \ No newline at end of file diff --git a/assets/js/2fed9fb3.d5bcbbb1.js b/assets/js/2fed9fb3.d5bcbbb1.js deleted file mode 100644 index 5f4b16c734..0000000000 --- a/assets/js/2fed9fb3.d5bcbbb1.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[6108],{9080:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>i,contentTitle:()=>l,default:()=>u,frontMatter:()=>a,metadata:()=>r,toc:()=>c});const r=JSON.parse('{"id":"Deployment/deployment-prod-best-practices","title":"Langflow architecture and best practices on Kubernetes","description":"Langflow can be deployed in two distinct environments.","source":"@site/docs/Deployment/deployment-prod-best-practices.mdx","sourceDirName":"Deployment","slug":"/deployment-prod-best-practices","permalink":"/deployment-prod-best-practices","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Langflow architecture and best practices on Kubernetes","slug":"/deployment-prod-best-practices"},"sidebar":"docs","previous":{"title":"Deploy Langflow on a remote server","permalink":"/deployment-caddyfile"},"next":{"title":"Deploy in development","permalink":"/deployment-kubernetes-dev"}}');var o=t(74848),s=t(28453);t(11470),t(19365);const a={title:"Langflow architecture and best practices on Kubernetes",slug:"/deployment-prod-best-practices"},l=void 0,i={},c=[{value:"Langflow deployment",id:"langflow-deployment",level:2},{value:"Environment isolation",id:"environment-isolation",level:2},{value:"Why is it important to have separate deployments?",id:"why-is-it-important-to-have-separate-deployments",level:2}];function d(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",img:"img",li:"li",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.p,{children:"Langflow can be deployed in two distinct environments."}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.a,{href:"/deployment-kubernetes-dev",children:(0,o.jsx)(n.strong,{children:"Langflow IDE"})}),": The ",(0,o.jsx)(n.strong,{children:"Langflow IDE"})," includes the frontend for visual development of your flow. The default ",(0,o.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow/blob/main/docker_example/docker-compose.yml",children:"docker-compose.yml"})," file hosted in the Langflow repository builds the Langflow IDE image. The Langflow IDE can be deployed on ",(0,o.jsx)(n.a,{href:"/deployment-docker",children:"Docker"})," or ",(0,o.jsx)(n.a,{href:"/deployment-kubernetes-dev",children:"Kubernetes"}),"."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.a,{href:"/deployment-kubernetes-prod",children:(0,o.jsx)(n.strong,{children:"Langflow runtime"})}),": The ",(0,o.jsx)(n.strong,{children:"Langflow runtime"})," is a headless or backend-only mode. The server exposes your flow as an endpoint, and runs only the processes necessary to serve your flow, with PostgreSQL as the database for improved scalability. Use the Langflow ",(0,o.jsx)(n.strong,{children:"runtime"})," to deploy your flows if you don't require the frontend for visual development. The Langflow runtime can be deployed on ",(0,o.jsx)(n.a,{href:"/deployment-docker",children:"Docker"})," or ",(0,o.jsx)(n.a,{href:"/deployment-kubernetes-prod",children:"Kubernetes"}),"."]}),"\n"]}),"\n",(0,o.jsx)(n.admonition,{type:"tip",children:(0,o.jsxs)(n.p,{children:["You can start Langflow in headless mode with the ",(0,o.jsx)(n.code,{children:"LANGFLOW_BACKEND_ONLY"})," ",(0,o.jsx)(n.a,{href:"/environment-variables",children:"environment variable"}),"."]})}),"\n",(0,o.jsx)(n.p,{children:"Deploying on Kubernetes offers the following advantages:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Scalability"}),": Kubernetes allows you to scale the Langflow service to meet the demands of your workload."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Availability and resilience"}),": Kubernetes provides built-in resilience features, such as automatic failover and self-healing, to ensure that the Langflow service is always available."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Security"}),": Kubernetes provides security features, such as role-based access control and network isolation, to protect the Langflow service and its data."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Portability"}),": Kubernetes is a portable platform, which means that you can deploy the Langflow service to any Kubernetes cluster, on-premises or in the cloud."]}),"\n"]}),"\n",(0,o.jsxs)(n.p,{children:["Langflow can be deployed on cloud deployments like ",(0,o.jsx)(n.strong,{children:"AWS EKS, Google GKE, or Azure AKS"}),". For more information about deploying Langflow on AWS EKS, Google GKE, or Azure AKS, see the ",(0,o.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm charts repository"}),"."]}),"\n",(0,o.jsx)(n.h2,{id:"langflow-deployment",children:"Langflow deployment"}),"\n",(0,o.jsx)(n.p,{children:"A typical Langflow deployment includes:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Langflow API and visual editor"}),": The Langflow service is the core part of the Langflow platform. It provides a RESTful API for executing flows."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Kubernetes cluster"}),": The Kubernetes cluster provides a platform for deploying and managing the Langflow service and supporting services."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Persistent storage"}),": Persistent storage is used to store the Langflow service's data, such as models and training data."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Ingress controller"}),": The ingress controller provides a single entry point for traffic to the Langflow service."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Load balancer"}),": Balances traffic across multiple Langflow replicas."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Vector database"}),": If you are using Langflow for RAG, you can integrate with the vector database in Astra Serverless."]}),"\n"]}),"\n",(0,o.jsx)(n.p,{children:(0,o.jsx)(n.img,{alt:"Langflow reference architecture on Kubernetes",src:t(48109).A+"",width:"671",height:"361"})}),"\n",(0,o.jsx)(n.h2,{id:"environment-isolation",children:"Environment isolation"}),"\n",(0,o.jsx)(n.p,{children:"It is recommended to deploy and run two separate environments for Langflow, with one environment reserved for development use and another for production use."}),"\n",(0,o.jsx)(n.p,{children:(0,o.jsx)(n.img,{alt:"Langflow environments",src:t(26023).A+"",width:"601",height:"491"})}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"The Langflow development environment"})," must include the Integrated Development Environment (IDE) for the full experience of Langflow, optimized for prototyping and testing new flows."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"The Langflow production environment"})," executes the flow logic in production and enables Langflow flows as standalone services."]}),"\n"]}),"\n",(0,o.jsx)(n.h2,{id:"why-is-it-important-to-have-separate-deployments",children:"Why is it important to have separate deployments?"}),"\n",(0,o.jsx)(n.p,{children:"This separation is designed to enhance security, optimize resource allocation, and streamline management."}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Security"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Isolation"}),": By separating the development and production environments, you can better isolate different phases of the application lifecycle. This isolation minimizes the risk of development-related issues impacting the production environments."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Access control"}),": Different security policies and access controls can be applied to each environment. Developers may require broader access in the IDE for testing and debugging, while the runtime environment can be locked down with stricter security measures."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Reduced attack surface"}),": The runtime environment is configured to include only essential parts, reducing the attack surface and potential vulnerabilities."]}),"\n"]}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Resource allocation"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Optimized resource usage and cost efficiency"}),": By separating the two environments, you can allocate resources more effectively. Each flow can be deployed independently, providing fine-grained resource control."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Scalability"}),": The runtime environment can be scaled independently based on application load and performance requirements, without affecting the development environment."]}),"\n"]}),"\n"]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(d,{...e})}):d(e)}},11470:(e,n,t)=>{t.d(n,{A:()=>j});var r=t(96540),o=t(18215),s=t(23104),a=t(56347),l=t(205),i=t(57485),c=t(31682),d=t(70679);function u(e){return r.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,r.isValidElement)(e)&&function(e){const{props:n}=e;return!!n&&"object"==typeof n&&"value"in n}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function h(e){const{values:n,children:t}=e;return(0,r.useMemo)(()=>{const e=n??function(e){return u(e).map(({props:{value:e,label:n,attributes:t,default:r}})=>({value:e,label:n,attributes:t,default:r}))}(t);return function(e){const n=(0,c.XI)(e,(e,n)=>e.value===n.value);if(n.length>0)throw new Error(`Docusaurus error: Duplicate values "${n.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[n,t])}function p({value:e,tabValues:n}){return n.some(n=>n.value===e)}function f({queryString:e=!1,groupId:n}){const t=(0,a.W6)(),o=function({queryString:e=!1,groupId:n}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!n)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return n??null}({queryString:e,groupId:n});return[(0,i.aZ)(o),(0,r.useCallback)(e=>{if(!o)return;const n=new URLSearchParams(t.location.search);n.set(o,e),t.replace({...t.location,search:n.toString()})},[o,t])]}function m(e){const{defaultValue:n,queryString:t=!1,groupId:o}=e,s=h(e),[a,i]=(0,r.useState)(()=>function({defaultValue:e,tabValues:n}){if(0===n.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!p({value:e,tabValues:n}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${n.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=n.find(e=>e.default)??n[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:n,tabValues:s})),[c,u]=f({queryString:t,groupId:o}),[m,g]=function({groupId:e}){const n=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,o]=(0,d.Dv)(n);return[t,(0,r.useCallback)(e=>{n&&o.set(e)},[n,o])]}({groupId:o}),b=(()=>{const e=c??m;return p({value:e,tabValues:s})?e:null})();(0,l.A)(()=>{b&&i(b)},[b]);return{selectedValue:a,selectValue:(0,r.useCallback)(e=>{if(!p({value:e,tabValues:s}))throw new Error(`Can't select invalid tab value=${e}`);i(e),u(e),g(e)},[u,g,s]),tabValues:s}}var g=t(92303);const b={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var v=t(74848);function y({className:e,block:n,selectedValue:t,selectValue:r,tabValues:a}){const l=[],{blockElementScrollPositionUntilNextRender:i}=(0,s.a_)(),c=e=>{const n=e.currentTarget,o=l.indexOf(n),s=a[o].value;s!==t&&(i(n),r(s))},d=e=>{let n=null;switch(e.key){case"Enter":c(e);break;case"ArrowRight":{const t=l.indexOf(e.currentTarget)+1;n=l[t]??l[0];break}case"ArrowLeft":{const t=l.indexOf(e.currentTarget)-1;n=l[t]??l[l.length-1];break}}n?.focus()};return(0,v.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,o.A)("tabs",{"tabs--block":n},e),children:a.map(({value:e,label:n,attributes:r})=>(0,v.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{l.push(e)},onKeyDown:d,onClick:c,...r,className:(0,o.A)("tabs__item",b.tabItem,r?.className,{"tabs__item--active":t===e}),children:n??e},e))})}function x({lazy:e,children:n,selectedValue:t}){const s=(Array.isArray(n)?n:[n]).filter(Boolean);if(e){const e=s.find(e=>e.props.value===t);return e?(0,r.cloneElement)(e,{className:(0,o.A)("margin-top--md",e.props.className)}):null}return(0,v.jsx)("div",{className:"margin-top--md",children:s.map((e,n)=>(0,r.cloneElement)(e,{key:n,hidden:e.props.value!==t}))})}function w(e){const n=m(e);return(0,v.jsxs)("div",{className:(0,o.A)("tabs-container",b.tabList),children:[(0,v.jsx)(y,{...n,...e}),(0,v.jsx)(x,{...n,...e})]})}function j(e){const n=(0,g.A)();return(0,v.jsx)(w,{...e,children:u(e.children)},String(n))}},19365:(e,n,t)=>{t.d(n,{A:()=>a});t(96540);var r=t(18215);const o={tabItem:"tabItem_Ymn6"};var s=t(74848);function a({children:e,hidden:n,className:t}){return(0,s.jsx)("div",{role:"tabpanel",className:(0,r.A)(o.tabItem,t),hidden:n,children:e})}},26023:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/langflow-env-f22dcd672ba806af9fec3968171a4700.png"},28453:(e,n,t)=>{t.d(n,{R:()=>a,x:()=>l});var r=t(96540);const o={},s=r.createContext(o);function a(e){const n=r.useContext(s);return r.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:a(e.components),r.createElement(s.Provider,{value:n},e.children)}},48109:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/langflow-reference-architecture-49ff76b7f84ce43f5626edd5cb3fa7fa.png"}}]); \ No newline at end of file diff --git a/assets/js/2fed9fb3.fe18abd0.js b/assets/js/2fed9fb3.fe18abd0.js new file mode 100644 index 0000000000..6c05b6fc4a --- /dev/null +++ b/assets/js/2fed9fb3.fe18abd0.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[6108],{9080:(e,n,t)=>{t.r(n),t.d(n,{CH:()=>d,assets:()=>c,chCodeConfig:()=>p,contentTitle:()=>l,default:()=>g,frontMatter:()=>a,metadata:()=>o,toc:()=>u});const o=JSON.parse('{"id":"Deployment/deployment-prod-best-practices","title":"Best practices for Langflow on Kubernetes","description":"This guide provides best practices for deploying Langflow in production environments on Kubernetes.","source":"@site/docs/Deployment/deployment-prod-best-practices.mdx","sourceDirName":"Deployment","slug":"/deployment-prod-best-practices","permalink":"/deployment-prod-best-practices","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Best practices for Langflow on Kubernetes","slug":"/deployment-prod-best-practices"},"sidebar":"docs","previous":{"title":"Deployment architecture","permalink":"/deployment-architecture"},"next":{"title":"Deploy in development","permalink":"/deployment-kubernetes-dev"}}');var r=t(74848),s=t(28453),i=t(24754);const a={title:"Best practices for Langflow on Kubernetes",slug:"/deployment-prod-best-practices"},l=void 0,c={},d={annotations:i.hk,Code:i.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Resources and scaling",id:"resources-and-scaling",level:2},{value:"Estimate, test, and adjust",id:"estimate-test-and-adjust",level:3},{value:"Use an external PostgreSQL database",id:"use-an-external-postgresql-database",level:3},{value:"Use HPA for dynamic scaling",id:"use-hpa-for-dynamic-scaling",level:3},{value:"Failure points",id:"failure-points",level:2},{value:"Monitoring",id:"monitoring",level:2},{value:"Security",id:"security",level:2},{value:"See also",id:"see-also",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return d||m("CH",!1),d.Code||m("CH.Code",!0),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,r.jsx)(n.p,{children:"This guide provides best practices for deploying Langflow in production environments on Kubernetes."}),"\n",(0,r.jsx)(n.h2,{id:"resources-and-scaling",children:"Resources and scaling"}),"\n",(0,r.jsx)(n.p,{children:"Langflow's minimum resource requirements vary by deployment type:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.strong,{children:"IDE (development)"}),": Deploy both the Langflow visual editor (frontend) and API (backend). Typically, this is used for development environments where developers use the visual editor to create and manage flows before packaging and serving them through a production runtime deployment."]}),"\n",(0,r.jsx)(n.p,{children:"The frontend service requires a minimum of 512Mi RAM and 0.3 CPU per instance with 1 replica."}),"\n",(0,r.jsx)(n.p,{children:"The backend service requires a minimum of 1Gi RAM and 0.5 CPU per instance with 1 replica."}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.strong,{children:"Runtime (production)"}),": Deploy the Langflow runtime for production flows, which is headless (backend only) service focused on serving the Langflow API. This is used for production environments where flows are executed programmatically without the need for the visual editor."]}),"\n",(0,r.jsx)(n.p,{children:"Minimum requirements include 2Gi RAM and 1000m (1 CPU) per instance with 3 replicas."}),"\n"]}),"\n"]}),"\n",(0,r.jsxs)(n.p,{children:["For more information about Langflow deployment types, see ",(0,r.jsx)(n.a,{href:"/deployment-architecture",children:"Langflow architecture on Kubernetes"}),"."]}),"\n",(0,r.jsx)(n.h3,{id:"estimate-test-and-adjust",children:"Estimate, test, and adjust"}),"\n",(0,r.jsx)(n.p,{children:"Start with the minimum recommended resources and replicas, then monitor and scale as needed based on your deployment's requirements and performance testing.\nConsider the following factors in your resource estimation and performance testing:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Flow complexity."}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Volume of concurrent users and requests."}),"\n",(0,r.jsx)(n.p,{children:"For IDE (development) deployments, consider that frontend activity also pings the backend service, so you typically need to scale both the frontend and backend together."}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Request payload content and size, particularly for file uploads in production deployments."}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Storage requirements for cache, file management, and the Langflow database."}),"\n",(0,r.jsxs)(n.p,{children:["An ",(0,r.jsx)(n.a,{href:"#use-an-external-postgresql-database",children:"external PostgreSQL database"})," is recommended for production deployments."]}),"\n"]}),"\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:"Infrastructure options that might require more resources, such as multi-core CPUs."}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h3,{id:"use-an-external-postgresql-database",children:"Use an external PostgreSQL database"}),"\n",(0,r.jsx)(n.p,{children:"An external PostgreSQL database is recommended for production deployments to improve scalability and reliability as compared to the default SQLite database."}),"\n",(0,r.jsxs)(n.p,{children:["Your resource allocation and replication strategy must be able to support the PostgreSQL service and storage.\nFor example, for a runtime (production) deployment, you might allocate 4Gi RAM, 2 CPU, and multiple replicas for high availability.\nTune PostgreSQL parameters, such as ",(0,r.jsx)(n.code,{children:"work_mem"})," and ",(0,r.jsx)(n.code,{children:"shared_buffers"}),", as needed based on resource requirements and usage metrics."]}),"\n",(0,r.jsx)(n.p,{children:"Recommended configurations include:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsx)(n.li,{children:"Persistent storage to prevent data loss on container shutdown"}),"\n",(0,r.jsx)(n.li,{children:"High Availability (HA) or Active-Active for automatic failover, scaling, and load balancing"}),"\n",(0,r.jsx)(n.li,{children:"Shared databases for multi-instance deployments"}),"\n",(0,r.jsxs)(n.li,{children:["Shared storage, such as NFS or cloud storage, for multi-instance deployments to access large files stored on disk, such as in ",(0,r.jsx)(n.code,{children:"/opt/langflow/data/"}),"."]}),"\n"]}),"\n",(0,r.jsxs)(n.p,{children:["For more information, see ",(0,r.jsx)(n.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"})," and ",(0,r.jsx)(n.a,{href:"/enterprise-database-guide",children:"Langflow database guide for enterprise DBAs"}),"."]}),"\n",(0,r.jsx)(n.h3,{id:"use-hpa-for-dynamic-scaling",children:"Use HPA for dynamic scaling"}),"\n",(0,r.jsx)(n.p,{children:"Load balancing and dynamic scaling are recommended for runtime (production) deployments."}),"\n",(0,r.jsx)(n.p,{children:"For example, consider using Horizontal Pod Autoscaler (HPA) in Kubernetes to dynamically scale based on CPU or memory usage.\nThe following example shows a Langflow HPA configuration with CPU-based scaling:"}),"\n",(0,r.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"apiVersion",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"autoscaling/v2",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"kind",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"HorizontalPodAutoscaler",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"metadata",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime-hpa",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"spec",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" scaleTargetRef",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" apiVersion",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"apps/v1",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" kind",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"Deployment",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" minReplicas",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" maxReplicas",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"10",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" metrics",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"type",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"Resource",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" resource",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"cpu",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" target",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" type",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"Utilization",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" averageUtilization",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"80",props:{style:{color:"#79C0FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,r.jsx)(n.h2,{id:"failure-points",children:"Failure points"}),"\n",(0,r.jsx)(n.p,{children:"Langflow's reliability in production depends on mitigating key failure points, particularly around the database, file system, and instance availability:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Database failures"}),": See ",(0,r.jsx)(n.a,{href:"/enterprise-database-guide",children:"Langflow database guide for enterprise DBAs"}),"."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"File system failures"}),": Concurrency issues in file caching, such as ",(0,r.jsx)(n.code,{children:"/app/data/.cache"}),", can cause IO errors in multi-instance setups.\nTo avoid this, use a shared, POSIX-compliant file system or cloud storage.\nUse persistent volumes instead of ramdisk solutions that result in data loss on container shutdown."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Instance failures"}),": Deploy multiple replicas to avoid service disruptions when a single instance fails. Use health checks to detect and replace failed pods."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Network and dependency failures"}),": External APIs or services used in flows may fail, causing flow errors. Implement retry logic and error handling in flows or application code. Monitor network latency and dependency health."]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"monitoring",children:"Monitoring"}),"\n",(0,r.jsx)(n.p,{children:"Effective monitoring ensures Langflow operates reliably and performs well under varying loads:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Database monitoring"}),": See ",(0,r.jsx)(n.a,{href:"/enterprise-database-guide",children:"Langflow database guide for enterprise DBAs"}),"."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Application logs"}),": Collect and analyze logs for errors, warnings, and flow execution issues. Centralize logs using tools like ELK Stack or Fluentd. You can also inspect ",(0,r.jsx)(n.a,{href:"/logging",children:"Langflow logs"}),"."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Resource usage"}),": Track CPU, memory, and disk usage of Langflow instances. Use Prometheus and Grafana for real-time metrics collection and monitoring in Kubernetes."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"API performance"}),": Monitor response times, error rates, and request throughput. Set alerts for high latency or error spikes."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Observability tools"}),": Integrate with ",(0,r.jsx)(n.a,{href:"/integrations-langwatch",children:"LangWatch"})," or ",(0,r.jsx)(n.a,{href:"/integrations-opik",children:"Opik"})," for detailed flow tracing and metrics. Use these tools to debug flow performance and optimize execution."]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"security",children:"Security"}),"\n",(0,r.jsx)(n.p,{children:"Running Langflow in production requires robust security measures to protect the application, data, and users.\nFollow industry best practices and use secure Langflow configurations, such as the following:"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Container security"}),": Apply security best practices for containerized applications. For example, set ",(0,r.jsx)(n.code,{children:"readOnlyRootFilesystem: true"})," in runtime (production) containers to prevent unauthorized modifications. Restrict access to files and codebases containing sensitive data and configuration files that shouldn't be exposed to unauthorized users."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Secrets management"}),": Store sensitive data like API keys and PostgreSQL credentials in Kubernetes secrets or external secrets managers like HashiCorp Vault."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Authentication, authorization, and access control"}),": Start your Langflow server with authentication enabled, as explained in ",(0,r.jsx)(n.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),". Restrict network and resource access with firewalls, network policies, network security groups, or VPCs. For example, restrict PostgreSQL database access to Langflow instances."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Encryption and privacy"}),": Follow industry best practices and legal requirements for data privacy and encryption of data in transit and at rest, including GDPR requirements, HTTPS, TLS, and SSL. For example, configure PostgreSQL with valid SSL certificates and append ",(0,r.jsx)(n.code,{children:"?sslmode=require"})," or ",(0,r.jsx)(n.code,{children:"?sslmode=verify-full"})," to the connection string to enable SSL for database connections."]}),"\n",(0,r.jsxs)(n.li,{children:[(0,r.jsx)(n.strong,{children:"Security posture maintenance"}),": Conduct regular security audits, keep current with software updates, and monitor for suspicious activity using intrusion detection systems."]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsx)(n.li,{children:(0,r.jsx)(n.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"})}),"\n",(0,r.jsx)(n.li,{children:(0,r.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm Charts repository"})}),"\n"]})]})}function g(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}function m(e,n){throw new Error("Expected "+(n?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},28453:(e,n,t)=>{t.d(n,{R:()=>i,x:()=>a});var o=t(96540);const r={},s=o.createContext(r);function i(e){const n=o.useContext(s);return o.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:i(e.components),o.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/453ae64a.82652dcf.js b/assets/js/453ae64a.82652dcf.js new file mode 100644 index 0000000000..f6d3d3d656 --- /dev/null +++ b/assets/js/453ae64a.82652dcf.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9610],{6137:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>l,contentTitle:()=>a,default:()=>x,frontMatter:()=>r,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/bundles-ibm","title":"IBM","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","source":"@site/docs/Components/bundles-ibm.mdx","sourceDirName":"Components","slug":"/bundles-ibm","permalink":"/bundles-ibm","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"IBM","slug":"/bundles-ibm"},"sidebar":"docs","previous":{"title":"Hugging Face","permalink":"/bundles-huggingface"},"next":{"title":"Icosa Computing","permalink":"/bundles-icosacomputing"}}');var i=t(74848),d=t(28453),o=t(17886);const r={title:"IBM",slug:"/bundles-ibm"},a=void 0,l={},c=[{value:"IBM watsonx.ai",id:"ibm-watsonxai",level:2},{value:"IBM watsonx.ai parameters",id:"ibm-watsonxai-parameters",level:3},{value:"IBM watsonx.ai output",id:"ibm-watsonxai-output",level:3},{value:"IBM watsonx.ai Embeddings",id:"ibm-watsonxai-embeddings",level:2},{value:"IBM watsonx.ai Embeddings parameters",id:"ibm-watsonxai-embeddings-parameters",level:3},{value:"Default embedding models",id:"default-embedding-models",level:3},{value:"See also",id:"see-also",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.a,{href:"/components-bundle-components",children:"Bundles"})," contain custom components that support specific third-party integrations with Langflow."]}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM"})," bundle provides access to IBM watsonx.ai models for text and embedding generation.\nThese components require an IBM watsonx.ai deployment and watsonx API credentials."]}),"\n",(0,i.jsx)(n.h2,{id:"ibm-watsonxai",children:"IBM watsonx.ai"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component generates text using ",(0,i.jsx)(n.a,{href:"https://dataplatform.cloud.ibm.com/docs/content/wsj/analyze-data/fm-models.html?context=wx",children:"supported foundation models"})," in ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/products/watsonx-ai",children:"IBM watsonx.ai"}),"."]}),"\n",(0,i.jsx)(n.p,{children:"You can use this component anywhere you need a language model in a flow."}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.img,{alt:"A basic prompting flow using the IBM watsonx.ai component as the central Language Model component.",src:t(68799).A+"",width:"2364",height:"1562"})}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-parameters",children:"IBM watsonx.ai parameters"}),"\n",(0,i.jsxs)(n.p,{children:["Many ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component input parameters are hidden by default in the visual editor.\nYou can toggle parameters through the ",(0,i.jsx)(o.A,{name:"SlidersHorizontal","aria-hidden":"true"})," ",(0,i.jsx)(n.strong,{children:"Controls"})," in the ",(0,i.jsx)(n.a,{href:"/concepts-components#component-menus",children:"component's header menu"}),"."]}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Name"}),(0,i.jsx)(n.th,{children:"Type"}),(0,i.jsx)(n.th,{children:"Description"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"url"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsxs)(n.td,{children:["Input parameter. The ",(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/apidocs/watsonx-ai#endpoint-url",children:"watsonx API base URL"})," for your deployment and region."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"project_id"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsxs)(n.td,{children:["Input parameter. Your ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=projects",children:"watsonx Project ID"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"api_key"}),(0,i.jsx)(n.td,{children:"SecretString"}),(0,i.jsxs)(n.td,{children:["Input parameter. A ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=administration-managing-user-api-key",children:"watsonx API key"})," to authenticate watsonx API access to the specified watsonx.ai deployment and model."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"model_name"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. The name of the watsonx model to use. Options are dynamically fetched from the API."})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"max_tokens"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. The maximum number of tokens to generate. Default: ",(0,i.jsx)(n.code,{children:"1000"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"stop_sequence"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. The sequence where generation should stop."})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"temperature"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls randomness in the output. Default: ",(0,i.jsx)(n.code,{children:"0.1"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"top_p"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls nucleus sampling, which limits the model to tokens whose probability is below the ",(0,i.jsx)(n.code,{children:"top_p"})," value. Range: Default: ",(0,i.jsx)(n.code,{children:"0.9"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"frequency_penalty"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls frequency penalty. A positive value decreases the probability of repeating tokens, and a negative value increases the probability. Range: Default: ",(0,i.jsx)(n.code,{children:"0.5"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"presence_penalty"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls presence penalty. A positive value increases the likelihood of new topics being introduced. Default: ",(0,i.jsx)(n.code,{children:"0.3"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"seed"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. A random seed for the model. Default: ",(0,i.jsx)(n.code,{children:"8"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"logprobs"}),(0,i.jsx)(n.td,{children:"Boolean"}),(0,i.jsxs)(n.td,{children:["Input parameter. Whether to return log probabilities of output tokens or not. Default: ",(0,i.jsx)(n.code,{children:"True"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"top_logprobs"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. The number of most likely tokens to return at each position. Default: ",(0,i.jsx)(n.code,{children:"3"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"logit_bias"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. A JSON string of token IDs to bias or suppress."})]})]})]}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-output",children:"IBM watsonx.ai output"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component can output either a ",(0,i.jsx)(n.strong,{children:"Model Response"})," (",(0,i.jsx)(n.a,{href:"/data-types#message",children:(0,i.jsx)(n.code,{children:"Message"})}),") or a ",(0,i.jsx)(n.strong,{children:"Language Model"})," (",(0,i.jsx)(n.a,{href:"/data-types#languagemodel",children:(0,i.jsx)(n.code,{children:"LanguageModel"})}),")."]}),"\n",(0,i.jsxs)(n.p,{children:["Use the ",(0,i.jsx)(n.strong,{children:"Language Model"})," output when you want to use an IBM watsonx.ai model as the LLM for another LLM-driven component, such as a ",(0,i.jsx)(n.strong,{children:"Language Model"})," or ",(0,i.jsx)(n.strong,{children:"Smart Function"})," component.\nFor more information, see ",(0,i.jsxs)(n.a,{href:"/components-models",children:[(0,i.jsx)(n.strong,{children:"Language Model"})," components"]}),"."]}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.code,{children:"LanguageModel"})," output from the ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component is an instance of ",(0,i.jsx)(n.a,{href:"https://python.langchain.com/docs/integrations/chat/ibm_watsonx/",children:"ChatWatsonx"})," configured according to the ",(0,i.jsx)(n.a,{href:"#ibm-watsonxai-parameters",children:"component's parameters"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"ibm-watsonxai-embeddings",children:"IBM watsonx.ai Embeddings"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component uses the ",(0,i.jsx)(n.a,{href:"https://dataplatform.cloud.ibm.com/docs/content/wsj/analyze-data/fm-models.html?context=wx",children:"supported foundation models"})," in ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/products/watsonx-ai",children:"IBM watsonx.ai"})," for embedding generation."]}),"\n",(0,i.jsxs)(n.p,{children:["The output is ",(0,i.jsx)(n.a,{href:"/data-types#embeddings",children:(0,i.jsx)(n.code,{children:"Embeddings"})})," generated with ",(0,i.jsx)(n.a,{href:"https://python.langchain.com/docs/integrations/text_embedding/ibm_watsonx/",children:(0,i.jsx)(n.code,{children:"WatsonxEmbeddings"})}),"."]}),"\n",(0,i.jsxs)(n.p,{children:["For more information about using embedding model components in flows, see ",(0,i.jsxs)(n.a,{href:"/components-embedding-models",children:[(0,i.jsx)(n.strong,{children:"Embedding Model"})," components"]}),"."]}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.img,{alt:"A basic embedding generation flow using the IBM watsonx.ai Embeddings component",src:t(96425).A+"",width:"1714",height:"1486"})}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-embeddings-parameters",children:"IBM watsonx.ai Embeddings parameters"}),"\n",(0,i.jsxs)(n.p,{children:["Some ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component input parameters are hidden by default in the visual editor.\nYou can toggle parameters through the ",(0,i.jsx)(o.A,{name:"SlidersHorizontal","aria-hidden":"true"})," ",(0,i.jsx)(n.strong,{children:"Controls"})," in the ",(0,i.jsx)(n.a,{href:"/concepts-components#component-menus",children:"component's header menu"}),"."]}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Name"}),(0,i.jsx)(n.th,{children:"Display Name"}),(0,i.jsx)(n.th,{children:"Info"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"url"}),(0,i.jsx)(n.td,{children:"watsonx API Endpoint"}),(0,i.jsxs)(n.td,{children:["Input parameter. The ",(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/apidocs/watsonx-ai#endpoint-url",children:"watsonx API base URL"})," for your deployment and region."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"project_id"}),(0,i.jsx)(n.td,{children:"watsonx project id"}),(0,i.jsxs)(n.td,{children:["Input parameter. Your ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=projects",children:"watsonx Project ID"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"api_key"}),(0,i.jsx)(n.td,{children:"API Key"}),(0,i.jsxs)(n.td,{children:["Input parameter. A ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=administration-managing-user-api-key",children:"watsonx API key"})," to authenticate watsonx API access to the specified watsonx.ai deployment and model."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"model_name"}),(0,i.jsx)(n.td,{children:"Model Name"}),(0,i.jsxs)(n.td,{children:["Input parameter. The name of the embedding model to use. Supports ",(0,i.jsx)(n.a,{href:"#default-embedding-models",children:"default embedding models"})," and automatically updates after connecting to your watsonx.ai deployment."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"truncate_input_tokens"}),(0,i.jsx)(n.td,{children:"Truncate Input Tokens"}),(0,i.jsxs)(n.td,{children:["Input parameter. The maximum number of tokens to process. Default: ",(0,i.jsx)(n.code,{children:"200"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"input_text"}),(0,i.jsx)(n.td,{children:"Include the original text in the output"}),(0,i.jsxs)(n.td,{children:["Input parameter. Determines if the original text is included in the output. Default: ",(0,i.jsx)(n.code,{children:"True"}),"."]})]})]})]}),"\n",(0,i.jsx)(n.h3,{id:"default-embedding-models",children:"Default embedding models"}),"\n",(0,i.jsxs)(n.p,{children:["By default, the ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component supports the following default models:"]}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"sentence-transformers/all-minilm-l12-v2"}),": 384-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"ibm/slate-125m-english-rtrvr-v2"}),": 768-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"ibm/slate-30m-english-rtrvr-v2"}),": 768-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"intfloat/multilingual-e5-large"}),": 1024-dimensional embeddings"]}),"\n"]}),"\n",(0,i.jsx)(n.p,{children:"After entering your API endpoint and credentials, the component automatically fetches the list of available models from your watsonx.ai deployment."}),"\n",(0,i.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/docs",children:"IBM documentation"})}),"\n"]})]})}function x(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(h,{...e})}):h(e)}},17886:(e,n,t)=>{t.d(n,{A:()=>d});t(96540);var s=t(64058),i=t(74848);function d({name:e,...n}){const t=s[e];return t?(0,i.jsx)(t,{...n}):null}},68799:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/component-watsonx-model-2f388a824b49f1c49287f07bc8738d0f.png"},96425:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/component-watsonx-embeddings-chroma-591e45d59ab635d1e1e68ab8036cfed7.png"}}]); \ No newline at end of file diff --git a/assets/js/453ae64a.df8bb663.js b/assets/js/453ae64a.df8bb663.js deleted file mode 100644 index d073499a83..0000000000 --- a/assets/js/453ae64a.df8bb663.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9610],{6137:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>l,contentTitle:()=>a,default:()=>x,frontMatter:()=>r,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/bundles-ibm","title":"IBM","description":"Bundles contain custom components that support specific third-party integrations with Langflow.","source":"@site/docs/Components/bundles-ibm.mdx","sourceDirName":"Components","slug":"/bundles-ibm","permalink":"/bundles-ibm","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"IBM","slug":"/bundles-ibm"},"sidebar":"docs","previous":{"title":"Hugging Face","permalink":"/bundles-huggingface"},"next":{"title":"Icosa Computing","permalink":"/bundles-icosacomputing"}}');var i=t(74848),d=t(28453),o=t(17886);const r={title:"IBM",slug:"/bundles-ibm"},a=void 0,l={},c=[{value:"IBM watsonx.ai",id:"ibm-watsonxai",level:2},{value:"IBM watsonx.ai parameters",id:"ibm-watsonxai-parameters",level:3},{value:"IBM watsonx.ai output",id:"ibm-watsonxai-output",level:3},{value:"IBM watsonx.ai Embeddings",id:"ibm-watsonxai-embeddings",level:2},{value:"IBM watsonx.ai Embeddings parameters",id:"ibm-watsonxai-embeddings-parameters",level:3},{value:"Default embedding models",id:"default-embedding-models",level:3},{value:"See also",id:"see-also",level:2}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.a,{href:"/components-bundle-components",children:"Bundles"})," contain custom components that support specific third-party integrations with Langflow."]}),"\n",(0,i.jsxs)(n.p,{children:[(0,i.jsx)(n.strong,{children:"IBM"})," bundle provides access to IBM watsonx.ai models for text and embedding generation.\nThese components require an IBM watsonx.ai deployment and watsonx API credentials."]}),"\n",(0,i.jsx)(n.h2,{id:"ibm-watsonxai",children:"IBM watsonx.ai"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component generates text using ",(0,i.jsx)(n.a,{href:"https://dataplatform.cloud.ibm.com/docs/content/wsj/analyze-data/fm-models.html?context=wx",children:"supported foundation models"})," in ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/products/watsonx-ai",children:"IBM watsonx.ai"}),"."]}),"\n",(0,i.jsx)(n.p,{children:"You can use this component anywhere you need a language model in a flow."}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.img,{alt:"A basic prompting flow using the IBM watsonx.ai component as the central Language Model component.",src:t(68799).A+"",width:"2364",height:"1562"})}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-parameters",children:"IBM watsonx.ai parameters"}),"\n",(0,i.jsxs)(n.p,{children:["Many ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component input parameters are hidden by default in the visual editor.\nYou can toggle parameters through the ",(0,i.jsx)(o.A,{name:"SlidersHorizontal","aria-hidden":"true"})," ",(0,i.jsx)(n.strong,{children:"Controls"})," in the ",(0,i.jsx)(n.a,{href:"/concepts-components#component-menus",children:"component's header menu"}),"."]}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Name"}),(0,i.jsx)(n.th,{children:"Type"}),(0,i.jsx)(n.th,{children:"Description"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"url"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsxs)(n.td,{children:["Input parameter. The ",(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/apidocs/watsonx-ai#endpoint-url",children:"watsonx API base URL"})," for your deployment and region."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"project_id"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsxs)(n.td,{children:["Input parameter. Your ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=projects",children:"watsonx Project ID"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"api_key"}),(0,i.jsx)(n.td,{children:"SecretString"}),(0,i.jsxs)(n.td,{children:["Input parameter. A ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=administration-managing-user-api-key",children:"watsonx API key"})," to authenticate watsonx API access to the specified watsonx.ai deployment and model."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"model_name"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. The name of the watsonx model to use. Options are dynamically fetched from the API."})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"max_tokens"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. The maximum number of tokens to generate. Default: ",(0,i.jsx)(n.code,{children:"1000"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"stop_sequence"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. The sequence where generation should stop."})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"temperature"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls randomness in the output. Default: ",(0,i.jsx)(n.code,{children:"0.1"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"top_p"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls nucleus sampling, which limits the model to tokens whose probability is below the ",(0,i.jsx)(n.code,{children:"top_p"})," value. Range: Default: ",(0,i.jsx)(n.code,{children:"0.9"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"frequency_penalty"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls frequency penalty. A positive value decreases the probability of repeating tokens, and a negative value increases the probability. Range: Default: ",(0,i.jsx)(n.code,{children:"0.5"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"presence_penalty"}),(0,i.jsx)(n.td,{children:"Float"}),(0,i.jsxs)(n.td,{children:["Input parameter. Controls presence penalty. A positive value increases the likelihood of new topics being introduced. Default: ",(0,i.jsx)(n.code,{children:"0.3"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"seed"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. A random seed for the model. Default: ",(0,i.jsx)(n.code,{children:"8"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"logprobs"}),(0,i.jsx)(n.td,{children:"Boolean"}),(0,i.jsxs)(n.td,{children:["Input parameter. Whether to return log probabilities of output tokens or not. Default: ",(0,i.jsx)(n.code,{children:"True"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"top_logprobs"}),(0,i.jsx)(n.td,{children:"Integer"}),(0,i.jsxs)(n.td,{children:["Input parameter. The number of most likely tokens to return at each position. Default: ",(0,i.jsx)(n.code,{children:"3"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"logit_bias"}),(0,i.jsx)(n.td,{children:"String"}),(0,i.jsx)(n.td,{children:"Input parameter. A JSON string of token IDs to bias or suppress."})]})]})]}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-output",children:"IBM watsonx.ai output"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component can output either a ",(0,i.jsx)(n.strong,{children:"Model Response"})," (",(0,i.jsx)(n.a,{href:"/data-types#message",children:(0,i.jsx)(n.code,{children:"Message"})}),") or a ",(0,i.jsx)(n.strong,{children:"Language Model"})," (",(0,i.jsx)(n.a,{href:"/data-types#languagemodel",children:(0,i.jsx)(n.code,{children:"LanguageModel"})}),")."]}),"\n",(0,i.jsxs)(n.p,{children:["Use the ",(0,i.jsx)(n.strong,{children:"Language Model"})," output when you want to use an IBM watsonx.ai model as the LLM for another LLM-driven component, such as a ",(0,i.jsx)(n.strong,{children:"Language Model"})," or ",(0,i.jsx)(n.strong,{children:"Smart Function"})," component.\nFor more information, see ",(0,i.jsxs)(n.a,{href:"/components-models",children:[(0,i.jsx)(n.strong,{children:"Language Model"})," components"]}),"."]}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.code,{children:"LanguageModel"})," output from the ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai"})," component is an instance of ",(0,i.jsx)(n.a,{href:"https://python.langchain.com/docs/integrations/chat/ibm_watsonx/",children:"ChatWatsonx"})," configured according to the ",(0,i.jsx)(n.a,{href:"#ibm-watsonxai-parameters",children:"component's parameters"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"ibm-watsonxai-embeddings",children:"IBM watsonx.ai Embeddings"}),"\n",(0,i.jsxs)(n.p,{children:["The ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component uses the ",(0,i.jsx)(n.a,{href:"https://dataplatform.cloud.ibm.com/docs/content/wsj/analyze-data/fm-models.html?context=wx",children:"supported foundation models"})," in ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/products/watsonx-ai",children:"IBM watsonx.ai"})," for embedding generation."]}),"\n",(0,i.jsxs)(n.p,{children:["The output is ",(0,i.jsx)(n.a,{href:"/data-types#embeddings",children:(0,i.jsx)(n.code,{children:"Embeddings"})})," generated with ",(0,i.jsx)(n.a,{href:"https://python.langchain.com/docs/integrations/text_embedding/ibm_watsonx/",children:(0,i.jsx)(n.code,{children:"WatsonxEmbeddings"})}),"."]}),"\n",(0,i.jsxs)(n.p,{children:["For more information about using embedding model components in flows, see ",(0,i.jsxs)(n.a,{href:"/components-embedding-models",children:[(0,i.jsx)(n.strong,{children:"Embedding Model"})," components"]}),"."]}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.img,{alt:"A basic embedding generation flow using the IBM watsonx.ai Embeddings component",src:t(96425).A+"",width:"1714",height:"1486"})}),"\n",(0,i.jsx)(n.h3,{id:"ibm-watsonxai-embeddings-parameters",children:"IBM watsonx.ai Embeddings parameters"}),"\n",(0,i.jsxs)(n.p,{children:["Some ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component input parameters are hidden by default in the visual editor.\nYou can toggle parameters through the ",(0,i.jsx)(o.A,{name:"SlidersHorizontal","aria-hidden":"true"})," ",(0,i.jsx)(n.strong,{children:"Controls"})," in the ",(0,i.jsx)(n.a,{href:"/concepts-components#component-menus",children:"component's header menu"}),"."]}),"\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{children:"Name"}),(0,i.jsx)(n.th,{children:"Display Name"}),(0,i.jsx)(n.th,{children:"Info"})]})}),(0,i.jsxs)(n.tbody,{children:[(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"url"}),(0,i.jsx)(n.td,{children:"watsonx API Endpoint"}),(0,i.jsxs)(n.td,{children:["Input parameter. The ",(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/apidocs/watsonx-ai#endpoint-url",children:"watsonx API base URL"})," for your deployment and region."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"project_id"}),(0,i.jsx)(n.td,{children:"watsonx project id"}),(0,i.jsxs)(n.td,{children:["Input parameter. Your ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=projects",children:"watsonx Project ID"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"api_key"}),(0,i.jsx)(n.td,{children:"API Key"}),(0,i.jsxs)(n.td,{children:["Input parameter. A ",(0,i.jsx)(n.a,{href:"https://www.ibm.com/docs/en/watsonx/saas?topic=administration-managing-user-api-key",children:"watsonx API key"})," to authenticate watsonx API access to the specified watsonx.ai deployment and model."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"model_name"}),(0,i.jsx)(n.td,{children:"Model Name"}),(0,i.jsxs)(n.td,{children:["Input parameter. The name of the embedding model to use. Supports ",(0,i.jsx)(n.a,{href:"#default-embedding-models",children:"default embedding models"})," and automatically updates after connecting to your watsonx.ai deployment."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"truncate_input_tokens"}),(0,i.jsx)(n.td,{children:"Truncate Input Tokens"}),(0,i.jsxs)(n.td,{children:["Input parameter. The maximum number of tokens to process. Default: ",(0,i.jsx)(n.code,{children:"200"}),"."]})]}),(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{children:"input_text"}),(0,i.jsx)(n.td,{children:"Include the original text in the output"}),(0,i.jsxs)(n.td,{children:["Input parameter. Determines if the original text is included in the output. Default: ",(0,i.jsx)(n.code,{children:"True"}),"."]})]})]})]}),"\n",(0,i.jsx)(n.h3,{id:"default-embedding-models",children:"Default embedding models"}),"\n",(0,i.jsxs)(n.p,{children:["By default, the ",(0,i.jsx)(n.strong,{children:"IBM watsonx.ai Embeddings"})," component supports the following default models:"]}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"sentence-transformers/all-minilm-l12-v2"}),": 384-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"ibm/slate-125m-english-rtrvr-v2"}),": 768-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"ibm/slate-30m-english-rtrvr-v2"}),": 768-dimensional embeddings"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"intfloat/multilingual-e5-large"}),": 1024-dimensional embeddings"]}),"\n"]}),"\n",(0,i.jsx)(n.p,{children:"After entering your API endpoint and credentials, the component automatically fetches the list of available models from your watsonx.ai deployment."}),"\n",(0,i.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:(0,i.jsx)(n.a,{href:"https://cloud.ibm.com/docs",children:"IBM documentation"})}),"\n"]})]})}function x(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(h,{...e})}):h(e)}},17886:(e,n,t)=>{t.d(n,{A:()=>d});t(96540);var s=t(64058),i=t(74848);function d({name:e,...n}){const t=s[e];return t?(0,i.jsx)(t,{...n}):null}},68799:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/component-watsonx-model-2f388a824b49f1c49287f07bc8738d0f.png"},96425:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/component-watsonx-embeddings-chroma-591e45d59ab635d1e1e68ab8036cfed7.png"}}]); \ No newline at end of file diff --git a/assets/js/47e58a89.60c6ebd1.js b/assets/js/47e58a89.60c6ebd1.js new file mode 100644 index 0000000000..fa7b61330e --- /dev/null +++ b/assets/js/47e58a89.60c6ebd1.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1006],{28453:(e,n,o)=>{o.d(n,{R:()=>a,x:()=>i});var s=o(96540);const t={},r=s.createContext(t);function a(e){const n=s.useContext(r);return s.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:a(e.components),s.createElement(r.Provider,{value:n},e.children)}},33354:(e,n,o)=>{o.r(n),o.d(n,{CH:()=>d,assets:()=>l,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>u,frontMatter:()=>i,metadata:()=>s,toc:()=>m});const s=JSON.parse('{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.","source":"@site/docs/Develop/memory.mdx","sourceDirName":"Develop","slug":"/memory","permalink":"/memory","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Memory management options","slug":"/memory"},"sidebar":"docs","previous":{"title":"Manage files","permalink":"/concepts-file-management"},"next":{"title":"Use Session IDs","permalink":"/session-id"}}');var t=o(74848),r=o(28453),a=o(24754);const i={title:"Memory management options",slug:"/memory"},c=void 0,l={},d={annotations:a.hk,Code:a.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},m=[{value:"Storage options and paths",id:"storage-options-and-paths",level:2},{value:"Local Langflow database tables",id:"local-langflow-database-tables",level:2},{value:"Configure external memory",id:"configure-external-memory",level:2},{value:"Configure the external database connection",id:"configure-the-external-database-connection",level:3},{value:"Configure cache memory",id:"configure-cache-memory",level:2},{value:"Store chat memory",id:"store-chat-memory",level:2},{value:"Session ID and chat memory",id:"session-id-and-chat-memory",level:3},{value:"Chat memory options",id:"chat-memory-options",level:3},{value:"See also",id:"see-also",level:2}];function g(e){const n={a:"a",code:"code",em:"em",h2:"h2",h3:"h3",li:"li",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components},{Details:o}=n;return d||f("CH",!1),d.Code||f("CH.Code",!0),o||f("Details",!0),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,t.jsx)(n.p,{children:"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.\nThis includes essential Langflow database tables, file management, and caching, as well as chat memory."}),"\n",(0,t.jsx)(n.h2,{id:"storage-options-and-paths",children:"Storage options and paths"}),"\n",(0,t.jsx)(n.p,{children:"Langflow supports both local memory and external memory options."}),"\n",(0,t.jsxs)(n.p,{children:["Langflow's default storage option is a ",(0,t.jsx)(n.a,{href:"https://www.sqlite.org/",children:"SQLite"})," database stored in your system's cache directory.\nThe default storage path depends on your operation system and installation method:"]}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.strong,{children:"macOS Desktop"}),": ",(0,t.jsx)(n.code,{children:"/Users//.langflow/data/database.db"})]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.strong,{children:"Windows Desktop"}),": ",(0,t.jsx)(n.code,{children:"C:\\Users\\\\AppData\\Roaming\\com.Langflow\\data\\langflow.db"})]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,t.jsx)(n.code,{children:"uv pip install"}),")"]}),": ",(0,t.jsx)(n.code,{children:"/lib/python3.12/site-packages/langflow/langflow.db"})," (Python version may vary)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,t.jsx)(n.code,{children:"git clone"}),")"]}),": ",(0,t.jsx)(n.code,{children:"/src/backend/base/langflow/langflow.db"})]}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["Alternatively, you can use an external PostgreSQL database for all of your Langflow storage.\nYou can also selectively use external storage for chat memory, separate from other Langflow storage.\nFor more information, see ",(0,t.jsx)(n.a,{href:"#configure-external-memory",children:"Configure external memory"})," and ",(0,t.jsx)(n.a,{href:"#store-chat-memory",children:"Store chat memory"}),"."]}),"\n",(0,t.jsx)(n.h2,{id:"local-langflow-database-tables",children:"Local Langflow database tables"}),"\n",(0,t.jsxs)(n.p,{children:["The following tables are stored in ",(0,t.jsx)(n.code,{children:"langflow.db"}),":"]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"User"}),": Stores user account information including credentials, permissions, profiles, and user management settings. For more information, see ",(0,t.jsx)(n.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"Flow"}),": Contains flow definitions, including nodes, edges, and components, stored as JSON or database records. For more information, see ",(0,t.jsx)(n.a,{href:"/concepts-flows",children:"Build flows"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"Message"}),": Stores chat messages and interactions that occur between components. For more information, see ",(0,t.jsx)(n.a,{href:"/data-types#message",children:"Message objects"})," and ",(0,t.jsx)(n.a,{href:"#store-chat-memory",children:"Store chat memory"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"Transaction"}),": Records execution history and results of flow runs. This information is used for ",(0,t.jsx)(n.a,{href:"/logging",children:"logging"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"ApiKey"}),": Manages Langflow API authentication keys. Component API keys are stored in the ",(0,t.jsx)(n.strong,{children:"Variables"})," table. For more information, see ",(0,t.jsx)(n.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"Project"}),": Provides a structure for flow storage, including single-user projects and shared projects accessed by multiple users. For more information, see ",(0,t.jsx)(n.a,{href:"/concepts-flows#projects",children:"Manage flows in projects"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"Variables"}),": Stores global encrypted values and credentials. For more information, see ",(0,t.jsx)(n.a,{href:"/configuration-global-variables",children:"Global variables"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"VertexBuild"}),": Tracks the build status of individual nodes within flows. For more information, see ",(0,t.jsx)(n.a,{href:"/concepts-playground",children:"Test flows in the Playground"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["For more information, see the database models in the ",(0,t.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow/tree/main/src/backend/base/langflow/services/database/models",children:"source code"}),"."]}),"\n",(0,t.jsx)(n.h2,{id:"configure-external-memory",children:"Configure external memory"}),"\n",(0,t.jsxs)(n.p,{children:["To replace the default Langflow SQLite database with another database, modify the ",(0,t.jsx)(n.code,{children:"LANGFLOW_DATABASE_URL"})," environment variable, and then start Langflow with your ",(0,t.jsx)(n.code,{children:".env"})," file:"]}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_DATABASE_URL=postgresql://user:password@localhost:5432/langflow",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(n.p,{children:["For an example, see ",(0,t.jsx)(n.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"}),"."]}),"\n",(0,t.jsx)(n.h3,{id:"configure-the-external-database-connection",children:"Configure the external database connection"}),"\n",(0,t.jsx)(n.p,{children:"The following settings allow you to fine-tune your database connection pool and timeout settings:"}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'LANGFLOW_DB_CONNECTION_SETTINGS=\'{"pool_size": 20, "max_overflow": 30, "pool_timeout": 30, "pool_pre_ping": true, "pool_recycle": 1800, "echo": false}\'',props:{}}]},{tokens:[{content:"LANGFLOW_DB_CONNECT_TIMEOUT=20",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"pool_size"}),": Maximum number of database connections to keep in the pool (default: 20)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"max_overflow"}),": Maximum number of connections that can be created beyond the pool_size (default: 30)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"pool_timeout"}),": Number of seconds to wait before timing out on getting a connection from the pool (default: 30)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"pool_pre_ping"}),": If true, the pool tests connections for liveness upon each checkout (default: true)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"pool_recycle"}),": Number of seconds after which a connection is automatically recycled (default: 1800, or 30 minutes)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"echo"}),": If true, SQL queries are logged for debugging purposes (default: false)"]}),"\n",(0,t.jsxs)(n.li,{children:[(0,t.jsx)(n.code,{children:"LANGFLOW_DB_CONNECT_TIMEOUT"}),": Maximum number of seconds to wait when establishing a new database connection (default: 20)"]}),"\n"]}),"\n",(0,t.jsx)(n.h2,{id:"configure-cache-memory",children:"Configure cache memory"}),"\n",(0,t.jsx)(n.p,{children:"The default Langflow caching behavior is an asynchronous, in-memory cache."}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_LANGCHAIN_CACHE=InMemoryCache",props:{}}]},{tokens:[{content:"LANGFLOW_CACHE_TYPE=Async",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsx)(n.p,{children:"Alternative caching options can be configured, but options other than the default asynchronous, in-memory cache aren't supported.\nThe default behavior is suitable for most use cases."}),"\n",(0,t.jsxs)(n.p,{children:["For other options, see the ",(0,t.jsx)(n.code,{children:"LANGFLOW_CACHE_TYPE"})," ",(0,t.jsx)(n.a,{href:"/environment-variables",children:"environment variable"}),"."]}),"\n",(0,t.jsx)(n.h2,{id:"store-chat-memory",children:"Store chat memory"}),"\n",(0,t.jsxs)(n.p,{children:["Chat-based flows with a ",(0,t.jsx)(n.strong,{children:"Language Model"})," or ",(0,t.jsx)(n.strong,{children:"Agent"})," component have built-in chat memory that is enabled by default.\nThis memory allows them to retrieve and reference messages from previous conversations associated with the same session ID."]}),"\n",(0,t.jsxs)(n.p,{children:["Built-in chat memory stores memories in the Langflow ",(0,t.jsx)(n.code,{children:"messages"})," table."]}),"\n",(0,t.jsxs)(o,{children:[(0,t.jsx)("summary",{children:"How does chat memory work?"}),(0,t.jsx)(n.p,{children:"Chat memory is a cache for the LLM or agent to preserve past conversations to retain and reference that context in future interactions.\nFor example, if a user has already told the LLM their name, the LLM can retrieve that information from chat memory rather than asking the user to repeat themselves in future conversations or messages."}),(0,t.jsx)(n.p,{children:"Chat memory is distinct from vector store memory because it is built specifically for storing and retrieving chat messages from databases."}),(0,t.jsxs)(n.p,{children:["Components that support chat memory (such as the ",(0,t.jsx)(n.strong,{children:"Agent"}),", ",(0,t.jsx)(n.strong,{children:"Language Model"}),", ",(0,t.jsx)(n.strong,{children:"Message History"}),", or third-party ",(0,t.jsx)(n.strong,{children:"Chat Memory"})," components) provide access to their respective databases ",(0,t.jsx)(n.em,{children:"as memory"}),".\nRetrieval as memory is an important distinction for LLMs and agents because this storage and retrieval mechanism is specifically designed to recall context from past conversations.\nUnlike vector stores, which are designed for semantic search and retrieval of text chunks, chat memory is designed to store and retrieve chat messages in a way that is optimized for conversation history."]})]}),"\n",(0,t.jsx)(n.h3,{id:"session-id-and-chat-memory",children:"Session ID and chat memory"}),"\n",(0,t.jsxs)(n.p,{children:["Chat memories are grouped by ",(0,t.jsxs)(n.a,{href:"/session-id",children:["session ID (",(0,t.jsx)(n.code,{children:"session_id"}),")"]}),"."]}),"\n",(0,t.jsx)(n.p,{children:"The default session ID is the flow ID, which means that all chat messages for a flow are stored under the same session ID as one large chat session."}),"\n",(0,t.jsx)(n.p,{children:"For better segregation of chat memory, especially in flows used by multiple users, consider using custom session IDs.\nFor example, if you use user IDs as session IDs, then each user's chat history is stored separately, isolating the context of their chats from other users' chats."}),"\n",(0,t.jsx)(n.h3,{id:"chat-memory-options",children:"Chat memory options"}),"\n",(0,t.jsx)(n.p,{children:"Where and how chat memory is stored depends on the components used in your flow:"}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:[(0,t.jsx)(n.strong,{children:"Language Model and Agent components"}),": All messages are stored in ",(0,t.jsx)(n.a,{href:"#storage-options-and-paths",children:"Langflow storage"}),".\nThe ",(0,t.jsx)(n.strong,{children:"Agent"})," component provides some memory configuration options, such as ",(0,t.jsx)(n.strong,{children:"Number of Chat History Messages"}),"."]}),"\n",(0,t.jsxs)(n.p,{children:["The ",(0,t.jsx)(n.strong,{children:"Language Model"})," and ",(0,t.jsx)(n.strong,{children:"Agent"})," component's built-in chat memory are sufficient for most use cases."]}),"\n",(0,t.jsxs)(n.p,{children:["If you prefer to use dedicated, external chat memory storage, or you need to retrieve memories outside the context of a chat, you can add ",(0,t.jsx)(n.strong,{children:"Message History"})," and ",(0,t.jsx)(n.strong,{children:"Chat Memory"})," components to your flow."]}),"\n"]}),"\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:[(0,t.jsx)(n.strong,{children:"Message History component"}),": By default, this component stores and retrieves memories from Langflow storage, unless you attach a ",(0,t.jsx)(n.strong,{children:"Chat Memory"})," component. It provides a few more options for sorting and filtering memories, although most of these options are built-in to the ",(0,t.jsx)(n.strong,{children:"Agent"})," component as configurable or fixed parameters."]}),"\n",(0,t.jsxs)(n.p,{children:["You can use the ",(0,t.jsx)(n.strong,{children:"Message History"})," component with or without a ",(0,t.jsx)(n.strong,{children:"Language Model"})," or ",(0,t.jsx)(n.strong,{children:"Agent"})," component.\nFor example, if you need to retrieve data from memories outside of chat, you can use the ",(0,t.jsx)(n.strong,{children:"Message History"})," component to fetch that data directly from your chat memory database without feeding it into a chat."]}),"\n"]}),"\n",(0,t.jsxs)(n.li,{children:["\n",(0,t.jsxs)(n.p,{children:[(0,t.jsx)(n.strong,{children:"Third-party Chat Memory components"}),": Use one of these components only if you need to specifically store or retrieve chat memories from a dedicated chat memory database.\nTypically, this is necessary only if you have specific storage needs that aren't met by Langflow storage.\nFor example, if you want to manage chat memory data by directly working with the database, or if you want to use a different database than the default Langflow storage."]}),"\n"]}),"\n"]}),"\n",(0,t.jsxs)(n.p,{children:["For more information and examples, see ",(0,t.jsxs)(n.a,{href:"/components-helpers#message-history",children:[(0,t.jsx)(n.strong,{children:"Message History"})," component"]})," and ",(0,t.jsx)(n.a,{href:"/agents#agent-memory",children:"Agent memory"}),"."]}),"\n",(0,t.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,t.jsxs)(n.ul,{children:["\n",(0,t.jsx)(n.li,{children:(0,t.jsx)(n.a,{href:"/concepts-file-management",children:"Langflow file management"})}),"\n",(0,t.jsx)(n.li,{children:(0,t.jsx)(n.a,{href:"/logging",children:"Langflow logs"})}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(g,{...e})}):g(e)}function f(e,n){throw new Error("Expected "+(n?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/47e58a89.c862fb63.js b/assets/js/47e58a89.c862fb63.js deleted file mode 100644 index ff26b83b1f..0000000000 --- a/assets/js/47e58a89.c862fb63.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1006],{28453:(e,o,n)=>{n.d(o,{R:()=>a,x:()=>i});var s=n(96540);const t={},r=s.createContext(t);function a(e){const o=s.useContext(r);return s.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function i(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:a(e.components),s.createElement(r.Provider,{value:o},e.children)}},33354:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>d,assets:()=>l,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>f,frontMatter:()=>i,metadata:()=>s,toc:()=>m});const s=JSON.parse('{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.","source":"@site/docs/Develop/memory.mdx","sourceDirName":"Develop","slug":"/memory","permalink":"/memory","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Memory management options","slug":"/memory"},"sidebar":"docs","previous":{"title":"Manage files","permalink":"/concepts-file-management"},"next":{"title":"Use Session IDs","permalink":"/session-id"}}');var t=n(74848),r=n(28453),a=n(24754);const i={title:"Memory management options",slug:"/memory"},c=void 0,l={},d={annotations:a.hk,Code:a.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},m=[{value:"Storage options and paths",id:"storage-options-and-paths",level:2},{value:"Local Langflow database tables",id:"local-langflow-database-tables",level:2},{value:"Configure external memory",id:"configure-external-memory",level:2},{value:"Configure the external database connection",id:"configure-the-external-database-connection",level:3},{value:"Configure cache memory",id:"configure-cache-memory",level:2},{value:"Store chat memory",id:"store-chat-memory",level:2},{value:"Session ID and chat memory",id:"session-id-and-chat-memory",level:3},{value:"Chat memory options",id:"chat-memory-options",level:3},{value:"See also",id:"see-also",level:2}];function g(e){const o={a:"a",code:"code",em:"em",h2:"h2",h3:"h3",li:"li",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components},{Details:n}=o;return d||u("CH",!1),d.Code||u("CH.Code",!0),n||u("Details",!0),(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,t.jsx)(o.p,{children:"Langflow provides flexible memory management options for storage and retrieval of data relevant to your flows and your Langflow server.\nThis includes essential Langflow database tables, file management, and caching, as well as chat memory."}),"\n",(0,t.jsx)(o.h2,{id:"storage-options-and-paths",children:"Storage options and paths"}),"\n",(0,t.jsx)(o.p,{children:"Langflow supports both local memory and external memory options."}),"\n",(0,t.jsxs)(o.p,{children:["Langflow's default storage option is a ",(0,t.jsx)(o.a,{href:"https://www.sqlite.org/",children:"SQLite"})," database stored in your system's cache directory.\nThe default storage path depends on your operation system and installation method:"]}),"\n",(0,t.jsxs)(o.ul,{children:["\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.strong,{children:"macOS Desktop"}),": ",(0,t.jsx)(o.code,{children:"/Users//.langflow/data/database.db"})]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.strong,{children:"Windows Desktop"}),": ",(0,t.jsx)(o.code,{children:"C:\\Users\\\\AppData\\Roaming\\com.Langflow\\data\\langflow.db"})]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsxs)(o.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,t.jsx)(o.code,{children:"uv pip install"}),")"]}),": ",(0,t.jsx)(o.code,{children:"/lib/python3.12/site-packages/langflow/langflow.db"})," (Python version may vary)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsxs)(o.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,t.jsx)(o.code,{children:"git clone"}),")"]}),": ",(0,t.jsx)(o.code,{children:"/src/backend/base/langflow/langflow.db"})]}),"\n"]}),"\n",(0,t.jsxs)(o.p,{children:["Alternatively, you can use an external PostgreSQL database for all of your Langflow storage.\nYou can also selectively use external storage for chat memory, separate from other Langflow storage.\nFor more information, see ",(0,t.jsx)(o.a,{href:"#configure-external-memory",children:"Configure external memory"})," and ",(0,t.jsx)(o.a,{href:"#store-chat-memory",children:"Store chat memory"}),"."]}),"\n",(0,t.jsx)(o.h2,{id:"local-langflow-database-tables",children:"Local Langflow database tables"}),"\n",(0,t.jsxs)(o.p,{children:["The following tables are stored in ",(0,t.jsx)(o.code,{children:"langflow.db"}),":"]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"User"}),": Stores user account information including credentials, permissions, and profiles. For more information, see ",(0,t.jsx)(o.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"Flow"}),": Contains flow configurations. For more information, see ",(0,t.jsx)(o.a,{href:"/concepts-flows",children:"Build flows"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"Message"}),": Stores chat messages and interactions that occur between components. For more information, see ",(0,t.jsx)(o.a,{href:"/data-types#message",children:"Message objects"})," and ",(0,t.jsx)(o.a,{href:"#store-chat-memory",children:"Store chat memory"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"Transaction"}),": Records execution history and results of flow runs. This information is used for ",(0,t.jsx)(o.a,{href:"/logging",children:"logging"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"ApiKey"}),": Manages API authentication keys for Langflow users. Component API keys are stored in the ",(0,t.jsx)(o.strong,{children:"Variables"})," table. For more information, see ",(0,t.jsx)(o.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"Project"}),": Provides a structure for flow storage. For more information, see ",(0,t.jsx)(o.a,{href:"/concepts-flows#projects",children:"Manage flows in projects"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"Variables"}),": Stores global encrypted values and credentials. For more information, see ",(0,t.jsx)(o.a,{href:"/configuration-global-variables",children:"Global variables"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["\u2022 ",(0,t.jsx)(o.strong,{children:"VertexBuild"}),": Tracks the build status of individual nodes within flows. For more information, see ",(0,t.jsx)(o.a,{href:"/concepts-playground",children:"Test flows in the Playground"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["For more information, see the database models in the ",(0,t.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow/tree/main/src/backend/base/langflow/services/database/models",children:"source code"}),"."]}),"\n",(0,t.jsx)(o.h2,{id:"configure-external-memory",children:"Configure external memory"}),"\n",(0,t.jsxs)(o.p,{children:["To replace the default Langflow SQLite database with another database, modify the ",(0,t.jsx)(o.code,{children:"LANGFLOW_DATABASE_URL"})," environment variable, and then start Langflow with your ",(0,t.jsx)(o.code,{children:".env"})," file:"]}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_DATABASE_URL=postgresql://user:password@localhost:5432/langflow",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(o.p,{children:["For an example, see ",(0,t.jsx)(o.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"}),"."]}),"\n",(0,t.jsx)(o.h3,{id:"configure-the-external-database-connection",children:"Configure the external database connection"}),"\n",(0,t.jsx)(o.p,{children:"The following settings allow you to fine-tune your database connection pool and timeout settings:"}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'LANGFLOW_DB_CONNECTION_SETTINGS=\'{"pool_size": 20, "max_overflow": 30, "pool_timeout": 30, "pool_pre_ping": true, "pool_recycle": 1800, "echo": false}\'',props:{}}]},{tokens:[{content:"LANGFLOW_DB_CONNECT_TIMEOUT=20",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(o.ul,{children:["\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"pool_size"}),": Maximum number of database connections to keep in the pool (default: 20)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"max_overflow"}),": Maximum number of connections that can be created beyond the pool_size (default: 30)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"pool_timeout"}),": Number of seconds to wait before timing out on getting a connection from the pool (default: 30)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"pool_pre_ping"}),": If true, the pool tests connections for liveness upon each checkout (default: true)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"pool_recycle"}),": Number of seconds after which a connection is automatically recycled (default: 1800, or 30 minutes)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"echo"}),": If true, SQL queries are logged for debugging purposes (default: false)"]}),"\n",(0,t.jsxs)(o.li,{children:[(0,t.jsx)(o.code,{children:"LANGFLOW_DB_CONNECT_TIMEOUT"}),": Maximum number of seconds to wait when establishing a new database connection (default: 20)"]}),"\n"]}),"\n",(0,t.jsx)(o.h2,{id:"configure-cache-memory",children:"Configure cache memory"}),"\n",(0,t.jsx)(o.p,{children:"The default Langflow caching behavior is an asynchronous, in-memory cache."}),"\n",(0,t.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_LANGCHAIN_CACHE=InMemoryCache",props:{}}]},{tokens:[{content:"LANGFLOW_CACHE_TYPE=Async",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsx)(o.p,{children:"Alternative caching options can be configured, but options other than the default asynchronous, in-memory cache aren't supported.\nThe default behavior is suitable for most use cases."}),"\n",(0,t.jsxs)(o.p,{children:["For other options, see the ",(0,t.jsx)(o.code,{children:"LANGFLOW_CACHE_TYPE"})," ",(0,t.jsx)(o.a,{href:"/environment-variables",children:"environment variable"}),"."]}),"\n",(0,t.jsx)(o.h2,{id:"store-chat-memory",children:"Store chat memory"}),"\n",(0,t.jsxs)(o.p,{children:["Chat-based flows with a ",(0,t.jsx)(o.strong,{children:"Language Model"})," or ",(0,t.jsx)(o.strong,{children:"Agent"})," component have built-in chat memory that is enabled by default.\nThis memory allows them to retrieve and reference messages from previous conversations associated with the same session ID."]}),"\n",(0,t.jsxs)(o.p,{children:["Built-in chat memory stores memories in the Langflow ",(0,t.jsx)(o.code,{children:"messages"})," table."]}),"\n",(0,t.jsxs)(n,{children:[(0,t.jsx)("summary",{children:"How does chat memory work?"}),(0,t.jsx)(o.p,{children:"Chat memory is a cache for the LLM or agent to preserve past conversations to retain and reference that context in future interactions.\nFor example, if a user has already told the LLM their name, the LLM can retrieve that information from chat memory rather than asking the user to repeat themselves in future conversations or messages."}),(0,t.jsx)(o.p,{children:"Chat memory is distinct from vector store memory because it is built specifically for storing and retrieving chat messages from databases."}),(0,t.jsxs)(o.p,{children:["Components that support chat memory (such as the ",(0,t.jsx)(o.strong,{children:"Agent"}),", ",(0,t.jsx)(o.strong,{children:"Language Model"}),", ",(0,t.jsx)(o.strong,{children:"Message History"}),", or third-party ",(0,t.jsx)(o.strong,{children:"Chat Memory"})," components) provide access to their respective databases ",(0,t.jsx)(o.em,{children:"as memory"}),".\nRetrieval as memory is an important distinction for LLMs and agents because this storage and retrieval mechanism is specifically designed to recall context from past conversations.\nUnlike vector stores, which are designed for semantic search and retrieval of text chunks, chat memory is designed to store and retrieve chat messages in a way that is optimized for conversation history."]})]}),"\n",(0,t.jsx)(o.h3,{id:"session-id-and-chat-memory",children:"Session ID and chat memory"}),"\n",(0,t.jsxs)(o.p,{children:["Chat memories are grouped by ",(0,t.jsxs)(o.a,{href:"/session-id",children:["session ID (",(0,t.jsx)(o.code,{children:"session_id"}),")"]}),"."]}),"\n",(0,t.jsx)(o.p,{children:"The default session ID is the flow ID, which means that all chat messages for a flow are stored under the same session ID as one large chat session."}),"\n",(0,t.jsx)(o.p,{children:"For better segregation of chat memory, especially in flows used by multiple users, consider using custom session IDs.\nFor example, if you use user IDs as session IDs, then each user's chat history is stored separately, isolating the context of their chats from other users' chats."}),"\n",(0,t.jsx)(o.h3,{id:"chat-memory-options",children:"Chat memory options"}),"\n",(0,t.jsx)(o.p,{children:"Where and how chat memory is stored depends on the components used in your flow:"}),"\n",(0,t.jsxs)(o.ul,{children:["\n",(0,t.jsxs)(o.li,{children:["\n",(0,t.jsxs)(o.p,{children:[(0,t.jsx)(o.strong,{children:"Language Model and Agent components"}),": All messages are stored in ",(0,t.jsx)(o.a,{href:"#storage-options-and-paths",children:"Langflow storage"}),".\nThe ",(0,t.jsx)(o.strong,{children:"Agent"})," component provides some memory configuration options, such as ",(0,t.jsx)(o.strong,{children:"Number of Chat History Messages"}),"."]}),"\n",(0,t.jsxs)(o.p,{children:["The ",(0,t.jsx)(o.strong,{children:"Language Model"})," and ",(0,t.jsx)(o.strong,{children:"Agent"})," component's built-in chat memory are sufficient for most use cases."]}),"\n",(0,t.jsxs)(o.p,{children:["If you prefer to use dedicated, external chat memory storage, or you need to retrieve memories outside the context of a chat, you can add ",(0,t.jsx)(o.strong,{children:"Message History"})," and ",(0,t.jsx)(o.strong,{children:"Chat Memory"})," components to your flow."]}),"\n"]}),"\n",(0,t.jsxs)(o.li,{children:["\n",(0,t.jsxs)(o.p,{children:[(0,t.jsx)(o.strong,{children:"Message History component"}),": By default, this component stores and retrieves memories from Langflow storage, unless you attach a ",(0,t.jsx)(o.strong,{children:"Chat Memory"})," component. It provides a few more options for sorting and filtering memories, although most of these options are built-in to the ",(0,t.jsx)(o.strong,{children:"Agent"})," component as configurable or fixed parameters."]}),"\n",(0,t.jsxs)(o.p,{children:["You can use the ",(0,t.jsx)(o.strong,{children:"Message History"})," component with or without a ",(0,t.jsx)(o.strong,{children:"Language Model"})," or ",(0,t.jsx)(o.strong,{children:"Agent"})," component.\nFor example, if you need to retrieve data from memories outside of chat, you can use the ",(0,t.jsx)(o.strong,{children:"Message History"})," component to fetch that data directly from your chat memory database without feeding it into a chat."]}),"\n"]}),"\n",(0,t.jsxs)(o.li,{children:["\n",(0,t.jsxs)(o.p,{children:[(0,t.jsx)(o.strong,{children:"Third-party Chat Memory components"}),": Use one of these components only if you need to specifically store or retrieve chat memories from a dedicated chat memory database.\nTypically, this is necessary only if you have specific storage needs that aren't met by Langflow storage.\nFor example, if you want to manage chat memory data by directly working with the database, or if you want to use a different database than the default Langflow storage."]}),"\n"]}),"\n"]}),"\n",(0,t.jsxs)(o.p,{children:["For more information and examples, see ",(0,t.jsxs)(o.a,{href:"/components-helpers#message-history",children:[(0,t.jsx)(o.strong,{children:"Message History"})," component"]})," and ",(0,t.jsx)(o.a,{href:"/agents#agent-memory",children:"Agent memory"}),"."]}),"\n",(0,t.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,t.jsxs)(o.ul,{children:["\n",(0,t.jsx)(o.li,{children:(0,t.jsx)(o.a,{href:"/concepts-file-management",children:"Langflow file management"})}),"\n",(0,t.jsx)(o.li,{children:(0,t.jsx)(o.a,{href:"/logging",children:"Langflow logs"})}),"\n"]})]})}function f(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,t.jsx)(o,{...e,children:(0,t.jsx)(g,{...e})}):g(e)}function u(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/54980a8a.07520397.js b/assets/js/54980a8a.4ff06e8d.js similarity index 98% rename from assets/js/54980a8a.07520397.js rename to assets/js/54980a8a.4ff06e8d.js index 27275b8cb4..66d9fd1f4c 100644 --- a/assets/js/54980a8a.07520397.js +++ b/assets/js/54980a8a.4ff06e8d.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9839],{28453:(e,o,n)=>{n.d(o,{R:()=>l,x:()=>i});var t=n(96540);const s={},r=t.createContext(s);function l(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function i(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:l(e.components),t.createElement(r.Provider,{value:o},e.children)}},43578:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>d,assets:()=>a,chCodeConfig:()=>p,contentTitle:()=>c,default:()=>u,frontMatter:()=>i,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Develop/develop-application","title":"Containerize a Langflow application","description":"Designing flows in the visual editor is only the first step in building an application that uses Langflow.","source":"@site/docs/Develop/develop-application.mdx","sourceDirName":"Develop","slug":"/develop-application","permalink":"/develop-application","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Containerize a Langflow application","slug":"/develop-application"},"sidebar":"docs","previous":{"title":"Deploy a public Langflow server","permalink":"/deployment-public-server"},"next":{"title":"Langflow Docker images","permalink":"/deployment-docker"}}');var s=n(74848),r=n(28453),l=n(24754);const i={title:"Containerize a Langflow application",slug:"/develop-application"},c=void 0,a={},d={annotations:l.hk,Code:l.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Directory structure",id:"directory-structure",level:2},{value:"Package management",id:"package-management",level:3},{value:"Environment variables",id:"docker-env",level:3},{value:"Secrets",id:"secrets",level:3},{value:"Storage",id:"storage",level:3},{value:"Flows",id:"flows",level:3},{value:"Components",id:"components",level:3},{value:"Langflow Dockerfile",id:"dockerfile",level:2},{value:"Backend-only mode",id:"backend-only-mode",level:3},{value:"Test your Langflow Docker image",id:"test-your-langflow-docker-image",level:2},{value:"Deploy to Docker Hub and Kubernetes",id:"deploy-docker",level:2}];function f(e){const o={a:"a",code:"code",em:"em",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components},{Details:n}=o;return d||y("CH",!1),d.Code||y("CH.Code",!0),n||y("Details",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsx)(o.p,{children:"Designing flows in the visual editor is only the first step in building an application that uses Langflow."}),"\n",(0,s.jsx)(o.p,{children:"Once you have a functional flow, you can use that flow in a larger application, such as a website or mobile app.\nBecause Langflow is both an IDE and a runtime, you can use Langflow to build and test your flows locally, and then package and serve your flows in a production environment."}),"\n",(0,s.jsx)(o.p,{children:"This guide introduces application development with Langflow from initial setup through packaging and deployment.\nThis documentation doesn't explain how to write a complete application; it only describes how to include Langflow in the context of a larger application."}),"\n",(0,s.jsx)(o.h2,{id:"directory-structure",children:"Directory structure"}),"\n",(0,s.jsx)(o.p,{children:"The following example describes the directory structure for a minimal Langflow application:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW-APPLICATION/",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 docker.env",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 Dockerfile",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 flows/",props:{}}]},{tokens:[{content:"\u2502 \u251c\u2500\u2500 flow1.json",props:{}}]},{tokens:[{content:"\u2502 \u2514\u2500\u2500 flow2.json",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 langflow-config-dir/",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 README.md",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"This directory contains the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#docker-env",children:(0,s.jsx)(o.code,{children:"docker.env"})}),": This file is copied to the Docker image as a ",(0,s.jsx)(o.code,{children:".env"})," file in the container root."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#dockerfile",children:(0,s.jsx)(o.code,{children:"Dockerfile"})}),": This file controls how your Langflow image is built."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#flows",children:(0,s.jsx)(o.code,{children:"/flows"})}),": This folder holds the flows you want to host, which are the flows that your application uses."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"/langflow-config-dir"}),": This folder is referenced in the Dockerfile as the location for your Langflow deployment's configuration files, database, and logs."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"README.md"}),": This is a typical README file for your application's documentation."]}),"\n"]}),"\n",(0,s.jsxs)(o.p,{children:["This is a minimal example of a Langflow application directory.\nYour application might have additional files and folders, such as a ",(0,s.jsx)(o.code,{children:"/components"})," folder for custom components, or a ",(0,s.jsx)(o.code,{children:"pyproject.toml"})," file for additional dependencies."]}),"\n",(0,s.jsx)(o.h3,{id:"package-management",children:"Package management"}),"\n",(0,s.jsxs)(o.p,{children:["The base Langflow Docker image includes the Langflow core dependencies because it uses ",(0,s.jsx)(o.code,{children:"langflowai/langflow:latest"})," as the parent image."]}),"\n",(0,s.jsxs)(o.p,{children:["If your application requires additional dependencies, create a ",(0,s.jsx)(o.a,{href:"https://packaging.python.org/en/latest/guides/writing-pyproject-toml",children:(0,s.jsx)(o.code,{children:"pyproject.toml"})})," file for the additional dependencies.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/install-custom-dependencies",children:"Install custom dependencies"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["To deploy an application with additional dependencies to Docker, you must copy the ",(0,s.jsx)(o.code,{children:"pyproject.toml"})," and ",(0,s.jsx)(o.code,{children:"uv.lock"})," files to the Docker image.\nTo do this, add the following to your Langflow application's Dockerfile:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"COPY pyproject.toml uv.lock /app/",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(o.h3,{id:"docker-env",children:"Environment variables"}),"\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.code,{children:"docker.env"})," file is a ",(0,s.jsx)(o.code,{children:".env"})," file loaded into your Docker image.\nIt contains environment variables that control Langflow's behavior, such as authentication, database storage, API keys, and server configurations.\nFor example:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_AUTO_LOGIN=true",props:{}}]},{tokens:[{content:"LANGFLOW_SAVE_DB_IN_CONFIG_DIR=true",props:{}}]},{tokens:[{content:"LANGFLOW_BASE_URL=http://0.0.0.0:7860",props:{}}]},{tokens:[{content:"OPENAI_API_KEY=sk-...",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The specific values you include depend on your application's needs and how you want to configure Langflow.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/environment-variables",children:"Langflow environment variables"})," and ",(0,s.jsx)(o.a,{href:"/configuration-global-variables",children:"Global variables"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["You can also set environment variables in the Dockerfile.\nHowever, if you set an environment variable in both ",(0,s.jsx)(o.code,{children:"docker.env"})," and the Dockerfile, Langflow uses the value set in ",(0,s.jsx)(o.code,{children:"docker.env"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"secrets",children:"Secrets"}),"\n",(0,s.jsx)(o.p,{children:"For simplicity, the examples in the Langflow documentation might use direct references to API keys and other sensitive values.\nIn your own applications, you should always follow industry best practices for managing secrets, such as using environment variables or secret management tools."}),"\n",(0,s.jsxs)(o.p,{children:["For information about generating authentication keys and managing secrets in Langflow, see ",(0,s.jsx)(o.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"storage",children:"Storage"}),"\n",(0,s.jsxs)(o.p,{children:["By default, Langflow uses an ",(0,s.jsx)(o.a,{href:"https://www.sqlite.org/",children:"SQLite"})," database for storage.\nIf you prefer to use PostgreSQL, see ",(0,s.jsx)(o.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For more information about storage, including cache and memory, see ",(0,s.jsx)(o.a,{href:"/memory",children:"Memory management options"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"flows",children:"Flows"}),"\n",(0,s.jsx)(o.p,{children:"Your local Langflow instance might have many flows for different applications.\nWhen you package Langflow as a dependency of an application, you only want to include the flows your application uses."}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:[(0,s.jsx)(o.a,{href:"/concepts-flows-import",children:"Export flows"})," that are relevant to your application."]}),"\n",(0,s.jsxs)(o.p,{children:["If you have chained flows (flows that trigger other flows), make sure you export ",(0,s.jsx)(o.em,{children:"all"})," necessary flows."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the exported Langflow JSON files to the ",(0,s.jsx)(o.code,{children:"/flows"})," folder in your application directory."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h3,{id:"components",children:"Components"}),"\n",(0,s.jsx)(o.p,{children:"The core components and bundles that you see in the Langflow visual editor are automatically included in the base Langflow Docker image."}),"\n",(0,s.jsxs)(o.p,{children:["If you have any ",(0,s.jsx)(o.a,{href:"/components-custom-components",children:"custom components"})," that you created for your application, you must include these components in your application directory:"]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["Create a ",(0,s.jsx)(o.code,{children:"/components"})," folder in your application directory."]}),"\n",(0,s.jsxs)(o.li,{children:["Add your custom component files to the ",(0,s.jsx)(o.code,{children:"/components"})," folder."]}),"\n",(0,s.jsxs)(o.li,{children:["Specify the path to ",(0,s.jsx)(o.code,{children:"/components"})," in your ",(0,s.jsx)(o.code,{children:"docker.env"}),"."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"dockerfile",children:"Langflow Dockerfile"}),"\n",(0,s.jsx)(o.p,{children:"The Dockerfile determines how your Langflow image is built, including the dependencies, flows, components, and configuration files."}),"\n",(0,s.jsx)(o.p,{children:"At minimum, you need to specify the base Langflow image, create the necessary folders in the container, copy folders and files to the container, and provide a startup command."}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"# Use the latest version of the base Langflow image",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"FROM",props:{style:{color:"#FF7B72"}}},{content:" langflowai/langflow:latest",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Create folders and set the working directory in the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"RUN",props:{style:{color:"#FF7B72"}}},{content:" mkdir /app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"RUN",props:{style:{color:"#FF7B72"}}},{content:" mkdir /app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"WORKDIR",props:{style:{color:"#FF7B72"}}},{content:" /app",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Copy flows, langflow-config-dir, and docker.env to the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" flows /app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" langflow-config-dir /app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" docker.env /app/.env",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Optional: Copy custom components to the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" components /app/components",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Optional: Use custom dependencies",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" pyproject.toml uv.lock /app/",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Set environment variables if not set in docker.env",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" PYTHONPATH=/app",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_LOAD_FLOWS_PATH=/app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_CONFIG_DIR=/app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_COMPONENTS_PATH=/app/components",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_LOG_ENV=container",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Command to run the Langflow server on port 7860",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"EXPOSE",props:{style:{color:"#FF7B72"}}},{content:" 7860",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"CMD",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"run"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--backend-only"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--env-file"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}},{content:'"/app/.env"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}},{content:'"--host"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"0.0.0.0"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--port"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"7860"',props:{style:{color:"#A5D6FF"}}},{content:"]",props:{style:{color:"#C9D1D9"}}}]}],lang:"dockerfile"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The environment variables set directly in this Dockerfile specify resource paths for Langflow.\nIf these variables are also set in ",(0,s.jsx)(o.code,{children:"docker.env"}),", the values in ",(0,s.jsx)(o.code,{children:"docker.env"})," override the values set in the Dockerfile."]}),"\n",(0,s.jsxs)(o.p,{children:["In this example, ",(0,s.jsx)(o.code,{children:"ENV LANGFLOW_LOG_ENV=container"})," sets the logging behavior for serialized JSON to ",(0,s.jsx)(o.code,{children:"stdout"})," to track the application's behavior in a containerized environment. For more information, see ",(0,s.jsx)(o.a,{href:"/logging",children:"Logging"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"backend-only-mode",children:"Backend-only mode"}),"\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.code,{children:"--backend-only"})," flag in ",(0,s.jsx)(o.code,{children:"CMD"})," starts Langflow in backend-only mode, which provides programmatic access only.\nThis is recommended when running Langflow as a dependency of an application where you don't need access to the visual editor."]}),"\n",(0,s.jsxs)(o.p,{children:["If you want to serve the Langflow visual editor ",(0,s.jsx)(o.em,{children:"and"})," backend, then omit ",(0,s.jsx)(o.code,{children:"--backend-only"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For more information, see ",(0,s.jsx)(o.a,{href:"/deployment-docker",children:"Deploy Langflow on Docker"}),"."]}),"\n",(0,s.jsx)(o.h2,{id:"test-your-langflow-docker-image",children:"Test your Langflow Docker image"}),"\n",(0,s.jsx)(o.p,{children:"Build and run your Langflow Docker image to test it."}),"\n",(0,s.jsxs)(o.p,{children:["This example runs the container locally.\nFor information about publishing your image on Docker Hub and running a Langflow container remotely, see ",(0,s.jsx)(o.a,{href:"#deploy-docker",children:"Deploy to Docker Hub and Kubernetes"}),"."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Build the Docker image:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"build ",props:{style:{color:"#A5D6FF"}}},{content:"-t ",props:{style:{color:"#79C0FF"}}},{content:"langflow-pokedex:",props:{style:{color:"#A5D6FF"}}},{content:"1.2.0 ",props:{style:{color:"#79C0FF"}}},{content:".",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Run the Docker container to start your Langflow server:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"run ",props:{style:{color:"#A5D6FF"}}},{content:"-p ",props:{style:{color:"#79C0FF"}}},{content:"7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860 ",props:{style:{color:"#79C0FF"}}},{content:"langflow-pokedex:",props:{style:{color:"#A5D6FF"}}},{content:"1.2.0",props:{style:{color:"#79C0FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"To confirm that the container is serving your flows as expected, use the Langflow API to run a flow:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Open one of the JSON files in your application's ",(0,s.jsx)(o.code,{children:"/flows"})," folder, and then find the flow's ",(0,s.jsx)(o.code,{children:"id"})," in the ",(0,s.jsx)(o.a,{href:"/concepts-flows-import#additional-metadata-and-project-information",children:"additional metadata and project information"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["There are many ",(0,s.jsx)(o.code,{children:"id"})," values; make sure you get the ID for the entire flow, not the ID for an individual component.\nIf your flow is complex, try searching for the flow's name, which is typically near the flow's ",(0,s.jsx)(o.code,{children:"id"}),"."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'"name"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"Basic Prompting"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:'"description"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"Perform basic prompting with an OpenAI model."',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:'"id"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"e4167236-938f-4aca-845b-21de3f399858"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]}],lang:"json"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Send a POST request to the ",(0,s.jsx)(o.a,{href:"/api-flows-run#run-flow",children:(0,s.jsx)(o.code,{children:"/v1/run/$FLOW_ID"})})," endpoint using the flow ID from the previous step ."]}),"\n",(0,s.jsxs)(o.p,{children:["The following example runs a simple LLM chat flow that responds to a chat input string.\nIf necessary, modify the payload for your flow.\nFor example, if your flow doesn't have a ",(0,s.jsx)(o.strong,{children:"Chat Input"})," component, you must modify the payload to provide the expected input for your flow."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"--request ",props:{style:{color:"#79C0FF"}}},{content:"POST ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --url ",props:{style:{color:"#79C0FF"}}},{content:"'http://localhost:7860/api/v1/run/e4167236-938f-4aca-845b-21de3f399858?stream=true' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --header ",props:{style:{color:"#79C0FF"}}},{content:"'Content-Type: application/json' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --data ",props:{style:{color:"#79C0FF"}}},{content:"'{",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_value": "Tell me about Charizard.",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "output_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "session_id": "charizard_test_request"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"}'",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsxs)(n,{children:[(0,s.jsx)("summary",{children:"About this example"}),(0,s.jsxs)(o.p,{children:["This command runs the ",(0,s.jsx)(o.strong,{children:"Pok\xe9dex"})," template flow.\nIt provides chat input about a specific Pok\xe9mon, uses an optional custom ",(0,s.jsx)(o.code,{children:"session_id"}),", and enables response streaming with ",(0,s.jsx)(o.code,{children:"?stream=true"}),"."]}),(0,s.jsxs)(o.p,{children:["The default ",(0,s.jsx)(o.a,{href:"/session-id",children:"session ID"})," is the flow ID.\nCustom session IDs can help isolate unique conversation threads to keep the LLM's context clean, and they can help identify specific conversations in flow logs to make debugging easier."]}),(0,s.jsxs)(o.p,{children:["This command uses response streaming because the Pok\xe9dex flow can return a large amount of text.\nTo use batching, set ",(0,s.jsx)(o.code,{children:"?stream=false"}),"."]})]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Verify that the request succeeds and the response is valid, depending on the specific flow you ran."}),"\n",(0,s.jsx)(o.p,{children:"This confirms that your Langflow Docker image is correctly configured and this flow is accessible through the Langflow API server that is hosted on the container.\nWhen you build and test your entire application stack, your front-end application can use Langflow API requests to trigger the flows served by your Langflow container in the same way you manually tested the flow in the previous step."}),"\n",(0,s.jsxs)(o.p,{children:["This example triggered a flow by sending chat input to the ",(0,s.jsx)(o.code,{children:"/v1/run/$FLOW_ID"})," endpoint.\nFor more examples of flow triggers, see ",(0,s.jsx)(o.a,{href:"/webhook",children:"Trigger flows with webhooks"})," and the tutorial to ",(0,s.jsx)(o.a,{href:"/chat-with-files",children:"Create a chatbot that can ingest files"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-docker",children:"Deploy to Docker Hub and Kubernetes"}),"\n",(0,s.jsx)(o.p,{children:"When you're ready to share your application with the world, you need to serve Langflow in a production environment.\nFor more information about deploying Langflow, see the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-overview",children:"Learn about Langflow deployments"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-docker",children:"Deploy Langflow on Docker"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-kubernetes-prod",children:"Deploy your application to Kubernetes"})}),"\n"]})]})}function u(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(f,{...e})}):f(e)}function y(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9839],{28453:(e,o,n)=>{n.d(o,{R:()=>l,x:()=>i});var t=n(96540);const s={},r=t.createContext(s);function l(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function i(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:l(e.components),t.createElement(r.Provider,{value:o},e.children)}},43578:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>d,assets:()=>a,chCodeConfig:()=>p,contentTitle:()=>c,default:()=>u,frontMatter:()=>i,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Develop/develop-application","title":"Containerize a Langflow application","description":"Designing flows in the visual editor is only the first step in building an application that uses Langflow.","source":"@site/docs/Develop/develop-application.mdx","sourceDirName":"Develop","slug":"/develop-application","permalink":"/develop-application","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Containerize a Langflow application","slug":"/develop-application"},"sidebar":"docs","previous":{"title":"Deploy a public Langflow server","permalink":"/deployment-public-server"},"next":{"title":"Langflow Docker images","permalink":"/deployment-docker"}}');var s=n(74848),r=n(28453),l=n(24754);const i={title:"Containerize a Langflow application",slug:"/develop-application"},c=void 0,a={},d={annotations:l.hk,Code:l.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Directory structure",id:"directory-structure",level:2},{value:"Package management",id:"package-management",level:3},{value:"Environment variables",id:"docker-env",level:3},{value:"Secrets",id:"secrets",level:3},{value:"Storage",id:"storage",level:3},{value:"Flows",id:"flows",level:3},{value:"Components",id:"components",level:3},{value:"Langflow Dockerfile",id:"dockerfile",level:2},{value:"Backend-only mode",id:"backend-only-mode",level:3},{value:"Test your Langflow Docker image",id:"test-your-langflow-docker-image",level:2},{value:"Deploy to Docker Hub and Kubernetes",id:"deploy-docker",level:2}];function f(e){const o={a:"a",code:"code",em:"em",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components},{Details:n}=o;return d||y("CH",!1),d.Code||y("CH.Code",!0),n||y("Details",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsx)(o.p,{children:"Designing flows in the visual editor is only the first step in building an application that uses Langflow."}),"\n",(0,s.jsx)(o.p,{children:"Once you have a functional flow, you can use that flow in a larger application, such as a website or mobile app.\nBecause Langflow is both an IDE and a runtime, you can use Langflow to build and test your flows locally, and then package and serve your flows in a production environment."}),"\n",(0,s.jsx)(o.p,{children:"This guide introduces application development with Langflow from initial setup through packaging and deployment.\nThis documentation doesn't explain how to write a complete application; it only describes how to include Langflow in the context of a larger application."}),"\n",(0,s.jsx)(o.h2,{id:"directory-structure",children:"Directory structure"}),"\n",(0,s.jsx)(o.p,{children:"The following example describes the directory structure for a minimal Langflow application:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW-APPLICATION/",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 docker.env",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 Dockerfile",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 flows/",props:{}}]},{tokens:[{content:"\u2502 \u251c\u2500\u2500 flow1.json",props:{}}]},{tokens:[{content:"\u2502 \u2514\u2500\u2500 flow2.json",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 langflow-config-dir/",props:{}}]},{tokens:[{content:"\u251c\u2500\u2500 README.md",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"This directory contains the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#docker-env",children:(0,s.jsx)(o.code,{children:"docker.env"})}),": This file is copied to the Docker image as a ",(0,s.jsx)(o.code,{children:".env"})," file in the container root."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#dockerfile",children:(0,s.jsx)(o.code,{children:"Dockerfile"})}),": This file controls how your Langflow image is built."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.a,{href:"#flows",children:(0,s.jsx)(o.code,{children:"/flows"})}),": This folder holds the flows you want to host, which are the flows that your application uses."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"/langflow-config-dir"}),": This folder is referenced in the Dockerfile as the location for your Langflow deployment's configuration files, database, and logs."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"README.md"}),": This is a typical README file for your application's documentation."]}),"\n"]}),"\n",(0,s.jsxs)(o.p,{children:["This is a minimal example of a Langflow application directory.\nYour application might have additional files and folders, such as a ",(0,s.jsx)(o.code,{children:"/components"})," folder for custom components, or a ",(0,s.jsx)(o.code,{children:"pyproject.toml"})," file for additional dependencies."]}),"\n",(0,s.jsx)(o.h3,{id:"package-management",children:"Package management"}),"\n",(0,s.jsxs)(o.p,{children:["The base Langflow Docker image includes the Langflow core dependencies because it uses ",(0,s.jsx)(o.code,{children:"langflowai/langflow:latest"})," as the parent image."]}),"\n",(0,s.jsxs)(o.p,{children:["If your application requires additional dependencies, create a ",(0,s.jsx)(o.a,{href:"https://packaging.python.org/en/latest/guides/writing-pyproject-toml",children:(0,s.jsx)(o.code,{children:"pyproject.toml"})})," file for the additional dependencies.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/install-custom-dependencies",children:"Install custom dependencies"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["To deploy an application with additional dependencies to Docker, you must copy the ",(0,s.jsx)(o.code,{children:"pyproject.toml"})," and ",(0,s.jsx)(o.code,{children:"uv.lock"})," files to the Docker image.\nTo do this, add the following to your Langflow application's Dockerfile:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"COPY pyproject.toml uv.lock /app/",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(o.h3,{id:"docker-env",children:"Environment variables"}),"\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.code,{children:"docker.env"})," file is a ",(0,s.jsx)(o.code,{children:".env"})," file loaded into your Docker image.\nIt contains environment variables that control Langflow's behavior, such as authentication, database storage, API keys, and server configurations.\nFor example:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"LANGFLOW_AUTO_LOGIN=true",props:{}}]},{tokens:[{content:"LANGFLOW_SAVE_DB_IN_CONFIG_DIR=true",props:{}}]},{tokens:[{content:"LANGFLOW_BASE_URL=http://0.0.0.0:7860",props:{}}]},{tokens:[{content:"OPENAI_API_KEY=sk-...",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The specific values you include depend on your application's needs and how you want to configure Langflow.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/environment-variables",children:"Langflow environment variables"})," and ",(0,s.jsx)(o.a,{href:"/configuration-global-variables",children:"Global variables"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["You can also set environment variables in the Dockerfile.\nHowever, if you set an environment variable in both ",(0,s.jsx)(o.code,{children:"docker.env"})," and the Dockerfile, Langflow uses the value set in ",(0,s.jsx)(o.code,{children:"docker.env"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"secrets",children:"Secrets"}),"\n",(0,s.jsx)(o.p,{children:"For simplicity, the examples in the Langflow documentation might use direct references to API keys and other sensitive values.\nIn your own applications, you should always follow industry best practices for managing secrets, such as using environment variables or secret management tools."}),"\n",(0,s.jsxs)(o.p,{children:["For information about generating authentication keys and managing secrets in Langflow, see ",(0,s.jsx)(o.a,{href:"/api-keys-and-authentication",children:"API keys and authentication"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"storage",children:"Storage"}),"\n",(0,s.jsxs)(o.p,{children:["By default, Langflow uses an ",(0,s.jsx)(o.a,{href:"https://www.sqlite.org/",children:"SQLite"})," database for storage.\nIf you prefer to use PostgreSQL, see ",(0,s.jsx)(o.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For more information about storage, including cache and memory, see ",(0,s.jsx)(o.a,{href:"/memory",children:"Memory management options"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"flows",children:"Flows"}),"\n",(0,s.jsx)(o.p,{children:"Your local Langflow instance might have many flows for different applications.\nWhen you package Langflow as a dependency of an application, you only want to include the flows your application uses."}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:[(0,s.jsx)(o.a,{href:"/concepts-flows-import",children:"Export flows"})," that are relevant to your application."]}),"\n",(0,s.jsxs)(o.p,{children:["If you have chained flows (flows that trigger other flows), make sure you export ",(0,s.jsx)(o.em,{children:"all"})," necessary flows."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the exported Langflow JSON files to the ",(0,s.jsx)(o.code,{children:"/flows"})," folder in your application directory."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h3,{id:"components",children:"Components"}),"\n",(0,s.jsx)(o.p,{children:"The core components and bundles that you see in the Langflow visual editor are automatically included in the base Langflow Docker image."}),"\n",(0,s.jsxs)(o.p,{children:["If you have any ",(0,s.jsx)(o.a,{href:"/components-custom-components",children:"custom components"})," that you created for your application, you must include these components in your application directory:"]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["Create a ",(0,s.jsx)(o.code,{children:"/components"})," folder in your application directory."]}),"\n",(0,s.jsxs)(o.li,{children:["Add your custom component files to the ",(0,s.jsx)(o.code,{children:"/components"})," folder."]}),"\n",(0,s.jsxs)(o.li,{children:["Specify the path to ",(0,s.jsx)(o.code,{children:"/components"})," in your ",(0,s.jsx)(o.code,{children:"docker.env"}),"."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"dockerfile",children:"Langflow Dockerfile"}),"\n",(0,s.jsx)(o.p,{children:"The Dockerfile determines how your Langflow image is built, including the dependencies, flows, components, and configuration files."}),"\n",(0,s.jsx)(o.p,{children:"At minimum, you need to specify the base Langflow image, create the necessary folders in the container, copy folders and files to the container, and provide a startup command."}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"# Use the latest version of the base Langflow image",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"FROM",props:{style:{color:"#FF7B72"}}},{content:" langflowai/langflow:latest",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Create folders and set the working directory in the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"RUN",props:{style:{color:"#FF7B72"}}},{content:" mkdir /app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"RUN",props:{style:{color:"#FF7B72"}}},{content:" mkdir /app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"WORKDIR",props:{style:{color:"#FF7B72"}}},{content:" /app",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Copy flows, langflow-config-dir, and docker.env to the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" flows /app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" langflow-config-dir /app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" docker.env /app/.env",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Optional: Copy custom components to the container",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" components /app/components",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Optional: Use custom dependencies",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"COPY",props:{style:{color:"#FF7B72"}}},{content:" pyproject.toml uv.lock /app/",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Set environment variables if not set in docker.env",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" PYTHONPATH=/app",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_LOAD_FLOWS_PATH=/app/flows",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_CONFIG_DIR=/app/langflow-config-dir",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_COMPONENTS_PATH=/app/components",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"ENV",props:{style:{color:"#FF7B72"}}},{content:" LANGFLOW_LOG_ENV=container",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Command to run the Langflow server on port 7860",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"EXPOSE",props:{style:{color:"#FF7B72"}}},{content:" 7860",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"CMD",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"run"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--backend-only"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--env-file"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}},{content:'"/app/.env"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}},{content:'"--host"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"0.0.0.0"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"--port"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:'"7860"',props:{style:{color:"#A5D6FF"}}},{content:"]",props:{style:{color:"#C9D1D9"}}}]}],lang:"dockerfile"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The environment variables set directly in this Dockerfile specify resource paths for Langflow.\nIf these variables are also set in ",(0,s.jsx)(o.code,{children:"docker.env"}),", the values in ",(0,s.jsx)(o.code,{children:"docker.env"})," override the values set in the Dockerfile."]}),"\n",(0,s.jsxs)(o.p,{children:["In this example, ",(0,s.jsx)(o.code,{children:"ENV LANGFLOW_LOG_ENV=container"})," sets the logging behavior for serialized JSON to ",(0,s.jsx)(o.code,{children:"stdout"})," to track the application's behavior in a containerized environment. For more information, see ",(0,s.jsx)(o.a,{href:"/logging",children:"Logging"}),"."]}),"\n",(0,s.jsx)(o.h3,{id:"backend-only-mode",children:"Backend-only mode"}),"\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.code,{children:"--backend-only"})," flag in ",(0,s.jsx)(o.code,{children:"CMD"})," starts Langflow in backend-only mode, which provides programmatic access only.\nThis is recommended when running Langflow as a dependency of an application where you don't need access to the visual editor."]}),"\n",(0,s.jsxs)(o.p,{children:["If you want to serve the Langflow visual editor ",(0,s.jsx)(o.em,{children:"and"})," backend, then omit ",(0,s.jsx)(o.code,{children:"--backend-only"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For more information, see ",(0,s.jsx)(o.a,{href:"/deployment-docker",children:"Deploy Langflow on Docker"}),"."]}),"\n",(0,s.jsx)(o.h2,{id:"test-your-langflow-docker-image",children:"Test your Langflow Docker image"}),"\n",(0,s.jsx)(o.p,{children:"Build and run your Langflow Docker image to test it."}),"\n",(0,s.jsxs)(o.p,{children:["This example runs the container locally.\nFor information about publishing your image on Docker Hub and running a Langflow container remotely, see ",(0,s.jsx)(o.a,{href:"#deploy-docker",children:"Deploy to Docker Hub and Kubernetes"}),"."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Build the Docker image:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"build ",props:{style:{color:"#A5D6FF"}}},{content:"-t ",props:{style:{color:"#79C0FF"}}},{content:"langflow-pokedex:",props:{style:{color:"#A5D6FF"}}},{content:"1.2.0 ",props:{style:{color:"#79C0FF"}}},{content:".",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Run the Docker container to start your Langflow server:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"run ",props:{style:{color:"#A5D6FF"}}},{content:"-p ",props:{style:{color:"#79C0FF"}}},{content:"7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860 ",props:{style:{color:"#79C0FF"}}},{content:"langflow-pokedex:",props:{style:{color:"#A5D6FF"}}},{content:"1.2.0",props:{style:{color:"#79C0FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"To confirm that the container is serving your flows as expected, use the Langflow API to run a flow:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Open one of the JSON files in your application's ",(0,s.jsx)(o.code,{children:"/flows"})," folder, and then find the flow's ",(0,s.jsx)(o.code,{children:"id"})," in the ",(0,s.jsx)(o.a,{href:"/concepts-flows-import#additional-metadata-and-project-information",children:"additional metadata and project information"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["There are many ",(0,s.jsx)(o.code,{children:"id"})," values; make sure you get the ID for the entire flow, not the ID for an individual component.\nIf your flow is complex, try searching for the flow's name, which is typically near the flow's ",(0,s.jsx)(o.code,{children:"id"}),"."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'"name"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"Basic Prompting"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:'"description"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"Perform basic prompting with an OpenAI model."',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:'"id"',props:{style:{color:"#A5D6FF"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"e4167236-938f-4aca-845b-21de3f399858"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]}],lang:"json"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Send a POST request to the ",(0,s.jsx)(o.a,{href:"/api-flows-run#run-flow",children:(0,s.jsx)(o.code,{children:"/v1/run/$FLOW_ID"})})," endpoint using the flow ID from the previous step ."]}),"\n",(0,s.jsxs)(o.p,{children:["The following example runs a simple LLM chat flow that responds to a chat input string.\nIf necessary, modify the payload for your flow.\nFor example, if your flow doesn't have a ",(0,s.jsx)(o.strong,{children:"Chat Input"})," component, you must modify the payload to provide the expected input for your flow."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"--request ",props:{style:{color:"#79C0FF"}}},{content:"POST ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --url ",props:{style:{color:"#79C0FF"}}},{content:"'http://localhost:7860/api/v1/run/e4167236-938f-4aca-845b-21de3f399858?stream=true' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --header ",props:{style:{color:"#79C0FF"}}},{content:"'Content-Type: application/json' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --data ",props:{style:{color:"#79C0FF"}}},{content:"'{",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_value": "Tell me about Charizard.",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "output_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "session_id": "charizard_test_request"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"}'",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsxs)(n,{children:[(0,s.jsx)("summary",{children:"About this example"}),(0,s.jsxs)(o.p,{children:["This command runs the ",(0,s.jsx)(o.strong,{children:"Pok\xe9dex"})," template flow.\nIt provides chat input about a specific Pok\xe9mon, uses an optional custom ",(0,s.jsx)(o.code,{children:"session_id"}),", and enables response streaming with ",(0,s.jsx)(o.code,{children:"?stream=true"}),"."]}),(0,s.jsxs)(o.p,{children:["The default ",(0,s.jsx)(o.a,{href:"/session-id",children:"session ID"})," is the flow ID.\nCustom session IDs can help isolate unique conversation threads to keep the LLM's context clean, and they can help identify specific conversations in flow logs to make debugging easier."]}),(0,s.jsxs)(o.p,{children:["This command uses response streaming because the Pok\xe9dex flow can return a large amount of text.\nTo use batching, set ",(0,s.jsx)(o.code,{children:"?stream=false"}),"."]})]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Verify that the request succeeds and the response is valid, depending on the specific flow you ran."}),"\n",(0,s.jsx)(o.p,{children:"This confirms that your Langflow Docker image is correctly configured and this flow is accessible through the Langflow API server that is hosted on the container.\nWhen you build and test your entire application stack, your front-end application can use Langflow API requests to trigger the flows served by your Langflow container in the same way you manually tested the flow in the previous step."}),"\n",(0,s.jsxs)(o.p,{children:["This example triggered a flow by sending chat input to the ",(0,s.jsx)(o.code,{children:"/v1/run/$FLOW_ID"})," endpoint.\nFor more examples of flow triggers, see ",(0,s.jsx)(o.a,{href:"/webhook",children:"Trigger flows with webhooks"})," and the tutorial to ",(0,s.jsx)(o.a,{href:"/chat-with-files",children:"Create a chatbot that can ingest files"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-docker",children:"Deploy to Docker Hub and Kubernetes"}),"\n",(0,s.jsx)(o.p,{children:"When you're ready to share your application with the world, you need to serve Langflow in a production environment.\nFor more information about deploying Langflow, see the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-overview",children:"Learn about Langflow deployments"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-docker",children:"Deploy Langflow on Docker"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"})}),"\n"]})]})}function u(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(f,{...e})}):f(e)}function y(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/56350599.6d836350.js b/assets/js/56350599.6d836350.js new file mode 100644 index 0000000000..83245fb8f2 --- /dev/null +++ b/assets/js/56350599.6d836350.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8593],{17886:(e,n,o)=>{o.d(n,{A:()=>i});o(96540);var t=o(64058),s=o(74848);function i({name:e,...n}){const o=t[e];return o?(0,s.jsx)(o,{...n}):null}},77232:(e,n,o)=>{o.d(n,{A:()=>t});const t=o.p+"assets/images/logs-cc30f076e63a5e443cf04855559703a3.png"},88262:(e,n,o)=>{o.r(n),o.d(n,{CH:()=>h,assets:()=>d,chCodeConfig:()=>g,contentTitle:()=>a,default:()=>f,frontMatter:()=>c,metadata:()=>t,toc:()=>u});const t=JSON.parse('{"id":"Develop/logging","title":"Logs","description":"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself.","source":"@site/docs/Develop/logging.mdx","sourceDirName":"Develop","slug":"/logging","permalink":"/logging","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Logs","slug":"/logging"},"sidebar":"docs","previous":{"title":"Database guide for enterprise administrators","permalink":"/enterprise-database-guide"},"next":{"title":"Arize","permalink":"/integrations-arize"}}');var s=o(74848),i=o(28453),r=o(24754),l=o(17886);const c={title:"Logs",slug:"/logging"},a=void 0,d={},h={annotations:r.hk,Code:r.Cy},g={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Log storage",id:"log-storage",level:2},{value:"Configure log options",id:"configure-log-options",level:2},{value:"Flow and component logs",id:"flow-and-component-logs",level:2},{value:"View flow logs",id:"view-flow-logs",level:3},{value:"View chat logs",id:"view-chat-logs",level:3},{value:"View output from a single component",id:"view-output-from-a-single-component",level:3},{value:"See also",id:"see-also",level:2}];function p(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",p:"p",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return h||x("CH",!1),h.Code||x("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsx)(n.p,{children:"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself."}),"\n",(0,s.jsxs)(n.p,{children:["Langflow uses the ",(0,s.jsx)(n.code,{children:"loguru"})," library for logging."]}),"\n",(0,s.jsxs)(n.p,{children:["The default logfile is named ",(0,s.jsx)(n.code,{children:"langflow.log"}),".\nLangflow also produces logfiles for flows."]}),"\n",(0,s.jsx)(n.h2,{id:"log-storage",children:"Log storage"}),"\n",(0,s.jsx)(n.p,{children:"The default logfile storage location depends on your operating system:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"macOS Desktop"}),":",(0,s.jsx)(n.code,{children:"/Users//.langflow/cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Windows Desktop"}),":",(0,s.jsx)(n.code,{children:"C:\\Users\\\\AppData\\Roaming\\com.Langflow\\cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,s.jsx)(n.code,{children:"uv pip install"}),")"]}),": ",(0,s.jsx)(n.code,{children:"/lib/python3.12/site-packages/langflow/cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,s.jsx)(n.code,{children:"git clone"}),")"]}),": ",(0,s.jsx)(n.code,{children:"/src/backend/base/langflow/cache"})]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["To customize log storage, see ",(0,s.jsx)(n.a,{href:"#configure-log-options",children:"Configure log options"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"configure-log-options",children:"Configure log options"}),"\n",(0,s.jsxs)(n.p,{children:["Use ",(0,s.jsx)(n.a,{href:"/environment-variables",children:"Langflow environment variables"})," to configure logging options in your Langflow ",(0,s.jsx)(n.code,{children:".env"})," file, and then start Langflow with ",(0,s.jsx)(n.code,{children:"uv run langflow run --env-file .env"}),"."]}),"\n",(0,s.jsx)(n.p,{children:"The following environment variables are available to configure logging:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_LEVEL"}),": Sets the log level as one of ",(0,s.jsx)(n.code,{children:"DEBUG"}),", ",(0,s.jsx)(n.code,{children:"ERROR"})," (default), ",(0,s.jsx)(n.code,{children:"INFO"}),", ",(0,s.jsx)(n.code,{children:"WARNING"}),", and ",(0,s.jsx)(n.code,{children:"CRITICAL"}),". For example, ",(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_LEVEL=DEBUG"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_FILE"}),": Sets the log file storage location if you want to use a non-default location.\nFor example, ",(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_FILE=path/to/logfile.log"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV"}),": Controls log output and formatting."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=container"}),": Outputs serialized JSON to stdout."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=container_csv"}),": Outputs CSV-formatted plain text to stdout."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=default"})," or unset: Outputs prettified output with ",(0,s.jsx)(n.a,{href:"https://rich.readthedocs.io/en/stable/reference/logging.html",children:"RichHandler"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ROTATION"})," controls when the log file is rotated, either based on time or file size. By default, logs are rotated every 1 day."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:'Time-based rotation: "1 day", "12 hours", "1 week"'}),"\n",(0,s.jsx)(n.li,{children:'Size-based rotation: "10 MB", "1 GB"'}),"\n",(0,s.jsx)(n.li,{children:'Disable rotation: "None" (log files will grow without limit)'}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["A complete example ",(0,s.jsx)(n.code,{children:".env"})," file is available in the ",(0,s.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow/blob/main/.env.example",children:"Langflow repository"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"flow-and-component-logs",children:"Flow and component logs"}),"\n",(0,s.jsxs)(n.p,{children:["After you run a flow, you can inspect the logs for the each component and flow run.\nFor example, you can inspect ",(0,s.jsx)(n.code,{children:"Message"})," objects ingested and generated by ",(0,s.jsxs)(n.a,{href:"/components-io",children:[(0,s.jsx)(n.strong,{children:"Input and Output"})," components"]}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-flow-logs",children:"View flow logs"}),"\n",(0,s.jsxs)(n.p,{children:["In the visual editor, click ",(0,s.jsx)(n.strong,{children:"Logs"})," to view logs for the entire flow:"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{alt:"Logs pane",src:o(77232).A+"",width:"4000",height:"2180"})}),"\n",(0,s.jsxs)(n.p,{children:["Then, click the cells in the ",(0,s.jsx)(n.strong,{children:"inputs"})," and ",(0,s.jsx)(n.strong,{children:"outputs"})," columns to inspect the ",(0,s.jsx)(n.code,{children:"Message"})," objects.\nFor example, the following ",(0,s.jsx)(n.code,{children:"Message"})," data could be the output from a ",(0,s.jsx)(n.strong,{children:"Chat Input"})," component:"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:g,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:' "messages": [',props:{}}]},{tokens:[{content:" {",props:{}}]},{tokens:[{content:' "message": "What\'s the recommended way to install Docker on Mac M1?",',props:{}}]},{tokens:[{content:' "sender": "User",',props:{}}]},{tokens:[{content:' "sender_name": "User",',props:{}}]},{tokens:[{content:' "session_id": "Session Apr 21, 17:37:04",',props:{}}]},{tokens:[{content:' "stream_url": null,',props:{}}]},{tokens:[{content:' "component_id": "ChatInput-4WKag",',props:{}}]},{tokens:[{content:' "files": [],',props:{}}]},{tokens:[{content:' "type": "text"',props:{}}]},{tokens:[{content:" }",props:{}}]},{tokens:[{content:" ],",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(n.p,{children:["In the case of Input/Output components, the original input might not be structured as a ",(0,s.jsx)(n.code,{children:"Message"})," object.\nFor example, a ",(0,s.jsx)(n.strong,{children:"Language Model"})," component might pass a raw text response to a ",(0,s.jsx)(n.strong,{children:"Chat Output"})," component that is then transformed into a ",(0,s.jsx)(n.code,{children:"Message"})," object."]}),"\n",(0,s.jsxs)(n.p,{children:["You can find ",(0,s.jsx)(n.code,{children:".log"})," files for flows at your Langflow installation's log storage location.\nFor filepaths, see ",(0,s.jsx)(n.a,{href:"#log-storage",children:"Log storage"}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-chat-logs",children:"View chat logs"}),"\n",(0,s.jsxs)(n.p,{children:["In the ",(0,s.jsx)(n.strong,{children:"Playground"}),", you can inspect the chat history for each chat session.\nFor more information, see ",(0,s.jsx)(n.a,{href:"/concepts-playground#view-chat-history",children:"View chat history"}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-output-from-a-single-component",children:"View output from a single component"}),"\n",(0,s.jsx)(n.p,{children:"When debugging issues with the format or content of a flow's output, it can help to inspect each component's output to determine where data is being lost or malformed."}),"\n",(0,s.jsxs)(n.p,{children:["To view the output produced by a single component during the most recent run, click ",(0,s.jsx)(l.A,{name:"TextSearch","aria-hidden":"true"})," ",(0,s.jsx)(n.strong,{children:"Inspect output"})," on the component in the visual editor."]}),"\n",(0,s.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/memory",children:"Memory management options"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"})}),"\n"]})]})}function f(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(p,{...e})}):p(e)}function x(e,n){throw new Error("Expected "+(n?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/56350599.fe58209b.js b/assets/js/56350599.fe58209b.js deleted file mode 100644 index 4fee65f04a..0000000000 --- a/assets/js/56350599.fe58209b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8593],{17886:(e,n,o)=>{o.d(n,{A:()=>i});o(96540);var t=o(64058),s=o(74848);function i({name:e,...n}){const o=t[e];return o?(0,s.jsx)(o,{...n}):null}},77232:(e,n,o)=>{o.d(n,{A:()=>t});const t=o.p+"assets/images/logs-cc30f076e63a5e443cf04855559703a3.png"},88262:(e,n,o)=>{o.r(n),o.d(n,{CH:()=>h,assets:()=>d,chCodeConfig:()=>g,contentTitle:()=>a,default:()=>f,frontMatter:()=>c,metadata:()=>t,toc:()=>u});const t=JSON.parse('{"id":"Develop/logging","title":"Logs","description":"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself.","source":"@site/docs/Develop/logging.mdx","sourceDirName":"Develop","slug":"/logging","permalink":"/logging","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Logs","slug":"/logging"},"sidebar":"docs","previous":{"title":"Configure an external PostgreSQL database","permalink":"/configuration-custom-database"},"next":{"title":"Arize","permalink":"/integrations-arize"}}');var s=o(74848),i=o(28453),r=o(24754),l=o(17886);const c={title:"Logs",slug:"/logging"},a=void 0,d={},h={annotations:r.hk,Code:r.Cy},g={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Log storage",id:"log-storage",level:2},{value:"Configure log options",id:"configure-log-options",level:2},{value:"Flow and component logs",id:"flow-and-component-logs",level:2},{value:"View flow logs",id:"view-flow-logs",level:3},{value:"View chat logs",id:"view-chat-logs",level:3},{value:"View output from a single component",id:"view-output-from-a-single-component",level:3},{value:"See also",id:"see-also",level:2}];function p(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",p:"p",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return h||x("CH",!1),h.Code||x("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsx)(n.p,{children:"This page provides information about Langflow logs, including logs for individual flows and the Langflow application itself."}),"\n",(0,s.jsxs)(n.p,{children:["Langflow uses the ",(0,s.jsx)(n.code,{children:"loguru"})," library for logging."]}),"\n",(0,s.jsxs)(n.p,{children:["The default logfile is named ",(0,s.jsx)(n.code,{children:"langflow.log"}),".\nLangflow also produces logfiles for flows."]}),"\n",(0,s.jsx)(n.h2,{id:"log-storage",children:"Log storage"}),"\n",(0,s.jsx)(n.p,{children:"The default logfile storage location depends on your operating system:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"macOS Desktop"}),":",(0,s.jsx)(n.code,{children:"/Users//.langflow/cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Windows Desktop"}),":",(0,s.jsx)(n.code,{children:"C:\\Users\\\\AppData\\Roaming\\com.Langflow\\cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,s.jsx)(n.code,{children:"uv pip install"}),")"]}),": ",(0,s.jsx)(n.code,{children:"/lib/python3.12/site-packages/langflow/cache"})]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsxs)(n.strong,{children:["OSS macOS/Windows/Linux/WSL (",(0,s.jsx)(n.code,{children:"git clone"}),")"]}),": ",(0,s.jsx)(n.code,{children:"/src/backend/base/langflow/cache"})]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["To customize log storage, see ",(0,s.jsx)(n.a,{href:"#configure-log-options",children:"Configure log options"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"configure-log-options",children:"Configure log options"}),"\n",(0,s.jsxs)(n.p,{children:["Use ",(0,s.jsx)(n.a,{href:"/environment-variables",children:"Langflow environment variables"})," to configure logging options in your Langflow ",(0,s.jsx)(n.code,{children:".env"})," file, and then start Langflow with ",(0,s.jsx)(n.code,{children:"uv run langflow run --env-file .env"}),"."]}),"\n",(0,s.jsx)(n.p,{children:"The following environment variables are available to configure logging:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_LEVEL"}),": Sets the log level as one of ",(0,s.jsx)(n.code,{children:"DEBUG"}),", ",(0,s.jsx)(n.code,{children:"ERROR"})," (default), ",(0,s.jsx)(n.code,{children:"INFO"}),", ",(0,s.jsx)(n.code,{children:"WARNING"}),", and ",(0,s.jsx)(n.code,{children:"CRITICAL"}),". For example, ",(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_LEVEL=DEBUG"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_FILE"}),": Sets the log file storage location if you want to use a non-default location.\nFor example, ",(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_FILE=path/to/logfile.log"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV"}),": Controls log output and formatting."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=container"}),": Outputs serialized JSON to stdout."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=container_csv"}),": Outputs CSV-formatted plain text to stdout."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ENV=default"})," or unset: Outputs prettified output with ",(0,s.jsx)(n.a,{href:"https://rich.readthedocs.io/en/stable/reference/logging.html",children:"RichHandler"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"LANGFLOW_LOG_ROTATION"})," controls when the log file is rotated, either based on time or file size. By default, logs are rotated every 1 day."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:'Time-based rotation: "1 day", "12 hours", "1 week"'}),"\n",(0,s.jsx)(n.li,{children:'Size-based rotation: "10 MB", "1 GB"'}),"\n",(0,s.jsx)(n.li,{children:'Disable rotation: "None" (log files will grow without limit)'}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["A complete example ",(0,s.jsx)(n.code,{children:".env"})," file is available in the ",(0,s.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow/blob/main/.env.example",children:"Langflow repository"}),"."]}),"\n",(0,s.jsx)(n.h2,{id:"flow-and-component-logs",children:"Flow and component logs"}),"\n",(0,s.jsxs)(n.p,{children:["After you run a flow, you can inspect the logs for the each component and flow run.\nFor example, you can inspect ",(0,s.jsx)(n.code,{children:"Message"})," objects ingested and generated by ",(0,s.jsxs)(n.a,{href:"/components-io",children:[(0,s.jsx)(n.strong,{children:"Input and Output"})," components"]}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-flow-logs",children:"View flow logs"}),"\n",(0,s.jsxs)(n.p,{children:["In the visual editor, click ",(0,s.jsx)(n.strong,{children:"Logs"})," to view logs for the entire flow:"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{alt:"Logs pane",src:o(77232).A+"",width:"4000",height:"2180"})}),"\n",(0,s.jsxs)(n.p,{children:["Then, click the cells in the ",(0,s.jsx)(n.strong,{children:"inputs"})," and ",(0,s.jsx)(n.strong,{children:"outputs"})," columns to inspect the ",(0,s.jsx)(n.code,{children:"Message"})," objects.\nFor example, the following ",(0,s.jsx)(n.code,{children:"Message"})," data could be the output from a ",(0,s.jsx)(n.strong,{children:"Chat Input"})," component:"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:g,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:' "messages": [',props:{}}]},{tokens:[{content:" {",props:{}}]},{tokens:[{content:' "message": "What\'s the recommended way to install Docker on Mac M1?",',props:{}}]},{tokens:[{content:' "sender": "User",',props:{}}]},{tokens:[{content:' "sender_name": "User",',props:{}}]},{tokens:[{content:' "session_id": "Session Apr 21, 17:37:04",',props:{}}]},{tokens:[{content:' "stream_url": null,',props:{}}]},{tokens:[{content:' "component_id": "ChatInput-4WKag",',props:{}}]},{tokens:[{content:' "files": [],',props:{}}]},{tokens:[{content:' "type": "text"',props:{}}]},{tokens:[{content:" }",props:{}}]},{tokens:[{content:" ],",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(n.p,{children:["In the case of Input/Output components, the original input might not be structured as a ",(0,s.jsx)(n.code,{children:"Message"})," object.\nFor example, a ",(0,s.jsx)(n.strong,{children:"Language Model"})," component might pass a raw text response to a ",(0,s.jsx)(n.strong,{children:"Chat Output"})," component that is then transformed into a ",(0,s.jsx)(n.code,{children:"Message"})," object."]}),"\n",(0,s.jsxs)(n.p,{children:["You can find ",(0,s.jsx)(n.code,{children:".log"})," files for flows at your Langflow installation's log storage location.\nFor filepaths, see ",(0,s.jsx)(n.a,{href:"#log-storage",children:"Log storage"}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-chat-logs",children:"View chat logs"}),"\n",(0,s.jsxs)(n.p,{children:["In the ",(0,s.jsx)(n.strong,{children:"Playground"}),", you can inspect the chat history for each chat session.\nFor more information, see ",(0,s.jsx)(n.a,{href:"/concepts-playground#view-chat-history",children:"View chat history"}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"view-output-from-a-single-component",children:"View output from a single component"}),"\n",(0,s.jsx)(n.p,{children:"When debugging issues with the format or content of a flow's output, it can help to inspect each component's output to determine where data is being lost or malformed."}),"\n",(0,s.jsxs)(n.p,{children:["To view the output produced by a single component during the most recent run, click ",(0,s.jsx)(l.A,{name:"TextSearch","aria-hidden":"true"})," ",(0,s.jsx)(n.strong,{children:"Inspect output"})," on the component in the visual editor."]}),"\n",(0,s.jsx)(n.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/memory",children:"Memory management options"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"})}),"\n"]})]})}function f(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(p,{...e})}):p(e)}function x(e,n){throw new Error("Expected "+(n?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/8cd0650d.5c230804.js b/assets/js/8cd0650d.5c230804.js deleted file mode 100644 index 352c0a52dd..0000000000 --- a/assets/js/8cd0650d.5c230804.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[2651],{28453:(e,o,n)=>{n.d(o,{R:()=>c,x:()=>l});var t=n(96540);const s={},r=t.createContext(s);function c(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function l(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:c(e.components),t.createElement(r.Provider,{value:o},e.children)}},51588:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>d,assets:()=>a,chCodeConfig:()=>p,contentTitle:()=>i,default:()=>u,frontMatter:()=>l,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Deployment/deployment-caddyfile","title":"Deploy Langflow on a remote server","description":"Learn how to deploy Langflow on your own remote server with secure web access.","source":"@site/docs/Deployment/deployment-caddyfile.mdx","sourceDirName":"Deployment","slug":"/deployment-caddyfile","permalink":"/deployment-caddyfile","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy Langflow on a remote server","slug":"/deployment-caddyfile"},"sidebar":"docs","previous":{"title":"Langflow Docker images","permalink":"/deployment-docker"},"next":{"title":"Langflow architecture and best practices","permalink":"/deployment-prod-best-practices"}}');var s=n(74848),r=n(28453),c=n(24754);const l={title:"Deploy Langflow on a remote server",slug:"/deployment-caddyfile"},i=void 0,a={},d={annotations:c.hk,Code:c.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Connect to your remote server with SSH",id:"connect-to-your-remote-server-with-ssh",level:2},{value:"Deploy Langflow on your server",id:"deploy-langflow-on-your-server",level:2},{value:"See also",id:"see-also",level:2}];function y(e){const o={a:"a",admonition:"admonition",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return d||f("CH",!1),d.Code||f("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsxs)(o.p,{children:["Learn how to deploy Langflow on your own remote server with secure web access.\nThis guide walks you through setting up Langflow on a remote server using ",(0,s.jsx)(o.a,{href:"https://docs.docker.com/",children:"Docker"})," and configuring secure web access with ",(0,s.jsx)(o.a,{href:"https://caddyserver.com/docs/",children:"Caddy"}),"."]}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A server with a dual-core CPU and at least 2 GB of RAM.\nThis example uses ",(0,s.jsx)(o.a,{href:"https://www.hetzner.com/",children:"Hetzner cloud"})," for hosting. Your deployment may vary."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"connect-to-your-remote-server-with-ssh",children:"Connect to your remote server with SSH"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create an SSH key.\nThis key allows you to connect to your server remotely.\nReplace ",(0,s.jsx)(o.code,{children:"DANA@EXAMPLE.COM"})," with the email address you want to associate with the SSH key."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"ssh-keygen ",props:{style:{color:"#FFA657"}}},{content:"-t ",props:{style:{color:"#79C0FF"}}},{content:"ed25519 ",props:{style:{color:"#A5D6FF"}}},{content:"-C ",props:{style:{color:"#79C0FF"}}},{content:'"DANA@EXAMPLE.COM"',props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"In your terminal, follow the instructions to create your SSH key pair.\nThis creates both a private and public key.\nTo copy the public key from your terminal, enter the following command:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"cat ",props:{style:{color:"#FFA657"}}},{content:"~/Downloads/host-lf.pub ",props:{style:{color:"#A5D6FF"}}},{content:"| ",props:{style:{color:"#FF7B72"}}},{content:"pbcopy",props:{style:{color:"#FFA657"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["In your remote server, add the SSH key you copied in the previous step.\nFor example, if you are using a Hetzner cloud server, click ",(0,s.jsx)(o.strong,{children:"Server"}),", and then select ",(0,s.jsx)(o.strong,{children:"SSH keys"})," to add an SSH key."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"To connect to your server with SSH, enter the following command."}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"ssh ",props:{style:{color:"#FFA657"}}},{content:"-i ",props:{style:{color:"#79C0FF"}}},{content:"PATH_TO_PRIVATE_KEY/PRIVATE_KEY_NAME root@SERVER_IP_ADDRESS",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"Replace the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"PATH_TO_PRIVATE_KEY/PRIVATE_KEY_NAME"}),": The path to your private SSH key file that matches the public key you added to your server"]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"SERVER_IP_ADDRESS"}),": Your server's IP address"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["When prompted for a key fingerprint, type ",(0,s.jsx)(o.code,{children:"yes"}),".\nThe terminal output indicates if the connection succeeds or fails.\nThe following response was returned after connecting to a Hetzner cloud server:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:" System information as of Mon May 19 04:34:44 PM UTC 2025",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:" System load: 0.0 Processes: 129",props:{}}]},{tokens:[{content:" Usage of /: 1.5% of 74.79GB Users logged in: 0",props:{}}]},{tokens:[{content:" Memory usage: 5% IPv4 address for eth0: 5.161.250.132",props:{}}]},{tokens:[{content:" Swap usage: 0% IPv6 address for eth0: 2a01:4ff:f0:4de7::1",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-langflow-on-your-server",children:"Deploy Langflow on your server"}),"\n",(0,s.jsxs)(o.p,{children:["Now that your local machine is connected to your remote server with SSH, you can install Docker, create a ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," file, and serve it publicly with a reverse proxy, such as Caddy."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Install Docker on your server.\nSince this example server is an Ubuntu server, it can install snap packages.\nIf you aren't using Ubuntu or you prefer a different installation method, see the ",(0,s.jsx)(o.a,{href:"https://docs.docker.com/get-started/get-docker/",children:"official Docker installation guide"})," for instructions for your operating system."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"snap ",props:{style:{color:"#FFA657"}}},{content:"install docker",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a file called ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),", and then open it in a text editor:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch ",props:{style:{color:"#FFA657"}}},{content:"docker-compose.yml",props:{style:{color:"#A5D6FF"}}},{content:" && ",props:{style:{color:"#C9D1D9"}}},{content:"nano ",props:{style:{color:"#FFA657"}}},{content:"docker-compose.yml",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The following example defines the Langflow service from the ",(0,s.jsx)(o.code,{children:"langflow:latest"})," image and a Caddy service to expose Langflow through a reverse proxy."]}),"\n",(0,s.jsx)(o.admonition,{type:"tip",children:(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.a,{href:"https://github.com/datastax/host-langflow",children:"host-langflow"})," repository offers pre-built copies of this ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," and ",(0,s.jsx)(o.code,{children:"Caddyfile"}),", if you prefer to fork the repository to your server."]})}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the following values to ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),", and then save the file."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"version",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"3.8"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"services",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"7860:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=0.0.0.0",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"caddy:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"80:80"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"443:443"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"./Caddyfile:/etc/caddy/Caddyfile",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"caddy_data:/data",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"caddy_config:/config",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy_data",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy_config",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]}],lang:"yml"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a file called ",(0,s.jsx)(o.code,{children:"Caddyfile"}),"."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch ",props:{style:{color:"#FFA657"}}},{content:"Caddyfile",props:{style:{color:"#A5D6FF"}}},{content:" && ",props:{style:{color:"#C9D1D9"}}},{content:"nano ",props:{style:{color:"#FFA657"}}},{content:"Caddyfile",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the following values to ",(0,s.jsx)(o.code,{children:"Caddyfile"}),", and then save the file.\nThe Caddyfile configures Caddy to listen on port 80, and forward all incoming requests to port 80 to the Langflow service at port 7860."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:":80 {",props:{}}]},{tokens:[{content:" reverse_proxy langflow:7860",props:{}}]},{tokens:[{content:"}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To deploy your server, run ",(0,s.jsx)(o.code,{children:"docker-compose up"}),".\nWhen the ",(0,s.jsx)(o.code,{children:"Welcome to Langflow"})," message appears, Langflow is running and accessible internally at ",(0,s.jsx)(o.code,{children:"http://0.0.0.0:7860"})," inside the Docker network."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To access your Langflow server over the public internet, navigate to your server's public IP address, such as ",(0,s.jsx)(o.code,{children:"http://5.161.250.132"}),".\nThis address uses HTTP because HTTPS isn't enabled yet."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Recommended: Enable HTTPS:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Modify your domain's A record to point to your server's IP address. For example:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Type: A",props:{}}]},{tokens:[{content:"Name: langflow",props:{}}]},{tokens:[{content:"Value: 5.161.250.132 # Set to your server's IP address",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Stop your server."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Modify your Caddyfile to include port ",(0,s.jsx)(o.code,{children:"443"})," so Caddy can forward both HTTP (port 80) and HTTPS (port 443) requests to the Langflow service:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:":80, :443 {",props:{}}]},{tokens:[{content:" reverse_proxy langflow:7860",props:{}}]},{tokens:[{content:"}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Start your server."}),"\n",(0,s.jsx)(o.p,{children:"When users visit your domain, Caddy recognizes the incoming traffic and automatically routes it to your server with a secure, encrypted connection."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To exit your SSH session, type ",(0,s.jsx)(o.code,{children:"exit"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.p,{children:["To package your local flows into a custom Docker image, see ",(0,s.jsx)(o.a,{href:"/develop-application",children:"Containerize a Langflow application"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For a step-by-step guide to deploying Langflow, including deployments to ",(0,s.jsx)(o.a,{href:"https://fly.io/",children:"fly.io"})," and ",(0,s.jsx)(o.a,{href:"https://www.flightcontrol.dev/",children:"Flightcontrol.dev"}),", see ",(0,s.jsx)(o.a,{href:"https://www.youtube.com/watch?v=q4qt5hSnte4",children:"How to Host Langflow Anywhere"}),"."]})]})}function u(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(y,{...e})}):y(e)}function f(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/8cd0650d.6337b7d2.js b/assets/js/8cd0650d.6337b7d2.js new file mode 100644 index 0000000000..580f787c07 --- /dev/null +++ b/assets/js/8cd0650d.6337b7d2.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[2651],{28453:(e,o,n)=>{n.d(o,{R:()=>c,x:()=>l});var t=n(96540);const s={},r=t.createContext(s);function c(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function l(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:c(e.components),t.createElement(r.Provider,{value:o},e.children)}},51588:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>d,assets:()=>a,chCodeConfig:()=>p,contentTitle:()=>i,default:()=>u,frontMatter:()=>l,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Deployment/deployment-caddyfile","title":"Deploy Langflow on a remote server","description":"Learn how to deploy Langflow on your own remote server with secure web access.","source":"@site/docs/Deployment/deployment-caddyfile.mdx","sourceDirName":"Deployment","slug":"/deployment-caddyfile","permalink":"/deployment-caddyfile","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy Langflow on a remote server","slug":"/deployment-caddyfile"},"sidebar":"docs","previous":{"title":"Langflow Docker images","permalink":"/deployment-docker"},"next":{"title":"Deployment architecture","permalink":"/deployment-architecture"}}');var s=n(74848),r=n(28453),c=n(24754);const l={title:"Deploy Langflow on a remote server",slug:"/deployment-caddyfile"},i=void 0,a={},d={annotations:c.hk,Code:c.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Connect to your remote server with SSH",id:"connect-to-your-remote-server-with-ssh",level:2},{value:"Deploy Langflow on your server",id:"deploy-langflow-on-your-server",level:2},{value:"See also",id:"see-also",level:2}];function y(e){const o={a:"a",admonition:"admonition",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return d||f("CH",!1),d.Code||f("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsxs)(o.p,{children:["Learn how to deploy Langflow on your own remote server with secure web access.\nThis guide walks you through setting up Langflow on a remote server using ",(0,s.jsx)(o.a,{href:"https://docs.docker.com/",children:"Docker"})," and configuring secure web access with ",(0,s.jsx)(o.a,{href:"https://caddyserver.com/docs/",children:"Caddy"}),"."]}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A server with a dual-core CPU and at least 2 GB of RAM.\nThis example uses ",(0,s.jsx)(o.a,{href:"https://www.hetzner.com/",children:"Hetzner cloud"})," for hosting. Your deployment may vary."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"connect-to-your-remote-server-with-ssh",children:"Connect to your remote server with SSH"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create an SSH key.\nThis key allows you to connect to your server remotely.\nReplace ",(0,s.jsx)(o.code,{children:"DANA@EXAMPLE.COM"})," with the email address you want to associate with the SSH key."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"ssh-keygen ",props:{style:{color:"#FFA657"}}},{content:"-t ",props:{style:{color:"#79C0FF"}}},{content:"ed25519 ",props:{style:{color:"#A5D6FF"}}},{content:"-C ",props:{style:{color:"#79C0FF"}}},{content:'"DANA@EXAMPLE.COM"',props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"In your terminal, follow the instructions to create your SSH key pair.\nThis creates both a private and public key.\nTo copy the public key from your terminal, enter the following command:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"cat ",props:{style:{color:"#FFA657"}}},{content:"~/Downloads/host-lf.pub ",props:{style:{color:"#A5D6FF"}}},{content:"| ",props:{style:{color:"#FF7B72"}}},{content:"pbcopy",props:{style:{color:"#FFA657"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["In your remote server, add the SSH key you copied in the previous step.\nFor example, if you are using a Hetzner cloud server, click ",(0,s.jsx)(o.strong,{children:"Server"}),", and then select ",(0,s.jsx)(o.strong,{children:"SSH keys"})," to add an SSH key."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"To connect to your server with SSH, enter the following command."}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"ssh ",props:{style:{color:"#FFA657"}}},{content:"-i ",props:{style:{color:"#79C0FF"}}},{content:"PATH_TO_PRIVATE_KEY/PRIVATE_KEY_NAME root@SERVER_IP_ADDRESS",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"Replace the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"PATH_TO_PRIVATE_KEY/PRIVATE_KEY_NAME"}),": The path to your private SSH key file that matches the public key you added to your server"]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.code,{children:"SERVER_IP_ADDRESS"}),": Your server's IP address"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["When prompted for a key fingerprint, type ",(0,s.jsx)(o.code,{children:"yes"}),".\nThe terminal output indicates if the connection succeeds or fails.\nThe following response was returned after connecting to a Hetzner cloud server:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:" System information as of Mon May 19 04:34:44 PM UTC 2025",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:" System load: 0.0 Processes: 129",props:{}}]},{tokens:[{content:" Usage of /: 1.5% of 74.79GB Users logged in: 0",props:{}}]},{tokens:[{content:" Memory usage: 5% IPv4 address for eth0: 5.161.250.132",props:{}}]},{tokens:[{content:" Swap usage: 0% IPv6 address for eth0: 2a01:4ff:f0:4de7::1",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-langflow-on-your-server",children:"Deploy Langflow on your server"}),"\n",(0,s.jsxs)(o.p,{children:["Now that your local machine is connected to your remote server with SSH, you can install Docker, create a ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," file, and serve it publicly with a reverse proxy, such as Caddy."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Install Docker on your server.\nSince this example server is an Ubuntu server, it can install snap packages.\nIf you aren't using Ubuntu or you prefer a different installation method, see the ",(0,s.jsx)(o.a,{href:"https://docs.docker.com/get-started/get-docker/",children:"official Docker installation guide"})," for instructions for your operating system."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"snap ",props:{style:{color:"#FFA657"}}},{content:"install docker",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a file called ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),", and then open it in a text editor:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch ",props:{style:{color:"#FFA657"}}},{content:"docker-compose.yml",props:{style:{color:"#A5D6FF"}}},{content:" && ",props:{style:{color:"#C9D1D9"}}},{content:"nano ",props:{style:{color:"#FFA657"}}},{content:"docker-compose.yml",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The following example defines the Langflow service from the ",(0,s.jsx)(o.code,{children:"langflow:latest"})," image and a Caddy service to expose Langflow through a reverse proxy."]}),"\n",(0,s.jsx)(o.admonition,{type:"tip",children:(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.a,{href:"https://github.com/datastax/host-langflow",children:"host-langflow"})," repository offers pre-built copies of this ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," and ",(0,s.jsx)(o.code,{children:"Caddyfile"}),", if you prefer to fork the repository to your server."]})}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the following values to ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),", and then save the file."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"version",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"3.8"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"services",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"7860:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=0.0.0.0",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"caddy:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"80:80"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"443:443"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"./Caddyfile:/etc/caddy/Caddyfile",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"caddy_data:/data",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"caddy_config:/config",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy_data",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" caddy_config",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]}],lang:"yml"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a file called ",(0,s.jsx)(o.code,{children:"Caddyfile"}),"."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch ",props:{style:{color:"#FFA657"}}},{content:"Caddyfile",props:{style:{color:"#A5D6FF"}}},{content:" && ",props:{style:{color:"#C9D1D9"}}},{content:"nano ",props:{style:{color:"#FFA657"}}},{content:"Caddyfile",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the following values to ",(0,s.jsx)(o.code,{children:"Caddyfile"}),", and then save the file.\nThe Caddyfile configures Caddy to listen on port 80, and forward all incoming requests to port 80 to the Langflow service at port 7860."]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:":80 {",props:{}}]},{tokens:[{content:" reverse_proxy langflow:7860",props:{}}]},{tokens:[{content:"}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To deploy your server, run ",(0,s.jsx)(o.code,{children:"docker-compose up"}),".\nWhen the ",(0,s.jsx)(o.code,{children:"Welcome to Langflow"})," message appears, Langflow is running and accessible internally at ",(0,s.jsx)(o.code,{children:"http://0.0.0.0:7860"})," inside the Docker network."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To access your Langflow server over the public internet, navigate to your server's public IP address, such as ",(0,s.jsx)(o.code,{children:"http://5.161.250.132"}),".\nThis address uses HTTP because HTTPS isn't enabled yet."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Recommended: Enable HTTPS:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Modify your domain's A record to point to your server's IP address. For example:"}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Type: A",props:{}}]},{tokens:[{content:"Name: langflow",props:{}}]},{tokens:[{content:"Value: 5.161.250.132 # Set to your server's IP address",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Stop your server."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Modify your Caddyfile to include port ",(0,s.jsx)(o.code,{children:"443"})," so Caddy can forward both HTTP (port 80) and HTTPS (port 443) requests to the Langflow service:"]}),"\n",(0,s.jsx)(d.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:":80, :443 {",props:{}}]},{tokens:[{content:" reverse_proxy langflow:7860",props:{}}]},{tokens:[{content:"}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Start your server."}),"\n",(0,s.jsx)(o.p,{children:"When users visit your domain, Caddy recognizes the incoming traffic and automatically routes it to your server with a secure, encrypted connection."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To exit your SSH session, type ",(0,s.jsx)(o.code,{children:"exit"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.p,{children:["To package your local flows into a custom Docker image, see ",(0,s.jsx)(o.a,{href:"/develop-application",children:"Containerize a Langflow application"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For a step-by-step guide to deploying Langflow, including deployments to ",(0,s.jsx)(o.a,{href:"https://fly.io/",children:"fly.io"})," and ",(0,s.jsx)(o.a,{href:"https://www.flightcontrol.dev/",children:"Flightcontrol.dev"}),", see ",(0,s.jsx)(o.a,{href:"https://www.youtube.com/watch?v=q4qt5hSnte4",children:"How to Host Langflow Anywhere"}),"."]})]})}function u(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(y,{...e})}):y(e)}function f(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/b37620f5.0af3186e.js b/assets/js/b37620f5.0af3186e.js deleted file mode 100644 index ae69727c5e..0000000000 --- a/assets/js/b37620f5.0af3186e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4656],{16009:(o,e,n)=>{n.r(e),n.d(e,{CH:()=>p,assets:()=>i,chCodeConfig:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Configuration/configuration-custom-database","title":"Configure an external PostgreSQL database","description":"Langflow\'s default database is SQLite, but you can configure Langflow to use PostgreSQL instead.","source":"@site/docs/Configuration/configuration-custom-database.mdx","sourceDirName":"Configuration","slug":"/configuration-custom-database","permalink":"/configuration-custom-database","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Configure an external PostgreSQL database","slug":"/configuration-custom-database"},"sidebar":"docs","previous":{"title":"Use Session IDs","permalink":"/session-id"},"next":{"title":"Logs","permalink":"/logging"}}');var s=n(74848),r=n(28453),l=n(24754);const c={title:"Configure an external PostgreSQL database",slug:"/configuration-custom-database"},a=void 0,i={},p={annotations:l.hk,Code:l.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Connect Langflow to a local PostgreSQL database",id:"connect-langflow-to-a-local-postgresql-database",level:2},{value:"Deploy Langflow and PostgreSQL containers with docker-compose.yml",id:"deploy-langflow-and-postgresql-containers-with-docker-composeyml",level:2},{value:"Deploy multiple Langflow instances with a shared PostgreSQL database",id:"deploy-multiple-langflow-instances-with-a-shared-postgresql-database",level:2},{value:"See also",id:"see-also",level:2}];function g(o){const e={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",ul:"ul",...(0,r.R)(),...o.components};return p||f("CH",!1),p.Code||f("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsxs)(e.p,{children:["Langflow's default database is ",(0,s.jsx)(e.a,{href:"https://www.sqlite.org/docs.html",children:"SQLite"}),", but you can configure Langflow to use PostgreSQL instead."]}),"\n",(0,s.jsxs)(e.p,{children:["This guide walks you through setting up an external database for Langflow by replacing the default SQLite connection string ",(0,s.jsx)(e.code,{children:"sqlite:///./langflow.db"})," with PostgreSQL, both in local and containerized environments."]}),"\n",(0,s.jsx)(e.p,{children:"In this configuration, all structured application data from Langflow, including flows, message history, and logs, is instead managed by PostgreSQL.\nPostgreSQL is better suited for production environments due to its robust support for concurrent users, advanced data integrity features, and scalability.\nLangflow can more efficiently handle multiple users and larger workloads by using PostgreSQL as the database."}),"\n",(0,s.jsx)(e.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(e.ul,{children:["\n",(0,s.jsxs)(e.li,{children:["A ",(0,s.jsx)(e.a,{href:"https://www.pgadmin.org/download/",children:"PostgreSQL"})," database"]}),"\n"]}),"\n",(0,s.jsx)(e.h2,{id:"connect-langflow-to-a-local-postgresql-database",children:"Connect Langflow to a local PostgreSQL database"}),"\n",(0,s.jsxs)(e.ol,{children:["\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["If Langflow is running, stop Langflow with ",(0,s.jsx)("kbd",{children:"Ctrl+C"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Find your PostgreSQL database's connection string in the format ",(0,s.jsx)(e.code,{children:"postgresql://user:password@host:port/dbname"}),"."]}),"\n",(0,s.jsx)(e.p,{children:"The hostname in your connection string depends on how you're running PostgreSQL:"}),"\n",(0,s.jsxs)(e.ul,{children:["\n",(0,s.jsxs)(e.li,{children:["If you're running PostgreSQL directly on your machine, use ",(0,s.jsx)(e.code,{children:"localhost"}),"."]}),"\n",(0,s.jsxs)(e.li,{children:["If you're running PostgreSQL in Docker Compose, use the service name, such as ",(0,s.jsx)(e.code,{children:"postgres"}),"."]}),"\n",(0,s.jsxs)(e.li,{children:["If you're running PostgreSQL in a separate Docker container with ",(0,s.jsx)(e.code,{children:"docker run"}),", use the container's IP address or network alias."]}),"\n",(0,s.jsx)(e.li,{children:"If you're running a cloud-hosted PostgreSQL, your provider will share your connection string, which includes a username and password."}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Create a Langflow ",(0,s.jsx)(e.code,{children:".env"})," file:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch .env",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(e.p,{children:["You can use the ",(0,s.jsx)(e.a,{href:"https://github.com/langflow-ai/langflow/blob/main/.env.example",children:(0,s.jsx)(e.code,{children:".env.example"})})," file in the Langflow repository as a template for your own ",(0,s.jsx)(e.code,{children:".env"})," file."]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["In your ",(0,s.jsx)(e.code,{children:".env"})," file, set ",(0,s.jsx)(e.code,{children:"LANGFLOW_DATABASE_URL"})," to your PostgreSQL connection string:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'LANGFLOW_DATABASE_URL="postgresql://user:password@localhost:5432/dbname"',props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Save your changes, and then start Langflow with your ",(0,s.jsx)(e.code,{children:".env"})," file:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"uv ",props:{style:{color:"#FFA657"}}},{content:"run langflow run ",props:{style:{color:"#A5D6FF"}}},{content:"--env-file ",props:{style:{color:"#79C0FF"}}},{content:".env",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsx)(e.p,{children:"In Langflow, run any flow to create traffic."}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsx)(e.p,{children:"Inspect your PostgreSQL database's tables and activity to verify that new tables and traffic were created after you ran a flow."}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(e.h2,{id:"deploy-langflow-and-postgresql-containers-with-docker-composeyml",children:"Deploy Langflow and PostgreSQL containers with docker-compose.yml"}),"\n",(0,s.jsxs)(e.p,{children:["Launching Langflow and PostgreSQL containers in the same Docker network ensures proper connectivity between services.\nFor an example, see the ",(0,s.jsx)(e.a,{href:"https://github.com/langflow-ai/langflow/blob/main/docker_example/docker-compose.yml",children:(0,s.jsx)(e.code,{children:"docker-compose.yml"})})," file in the Langflow repository."]}),"\n",(0,s.jsxs)(e.p,{children:["The configuration in the example ",(0,s.jsx)(e.code,{children:"docker-compose.yml"})," also sets up persistent volumes for both Langflow and PostgreSQL data.\nPersistent volumes map directories inside of containers to storage on the host machine, so data persists through container restarts."]}),"\n",(0,s.jsxs)(e.p,{children:["Docker Compose creates an isolated network for all services defined in ",(0,s.jsx)(e.code,{children:"docker-compose.yml"}),". This ensures that the services can communicate with each other using their service names as hostnames, such as ",(0,s.jsx)(e.code,{children:"postgres"})," in the database URL.\nIn contrast, if you run PostgreSQL separately with ",(0,s.jsx)(e.code,{children:"docker run"}),", it launches in a different network than the Langflow container, and this prevents Langflow from connecting to PostgreSQL using the service name."]}),"\n",(0,s.jsxs)(e.p,{children:["To start the Langflow and PostgreSQL services with the example Docker Compose file, navigate to the ",(0,s.jsx)(e.code,{children:"langflow/docker_example"})," directory, and then run ",(0,s.jsx)(e.code,{children:"docker-compose up"}),".\nIf you're using a different ",(0,s.jsx)(e.code,{children:"docker-compose.yml"})," file, run the ",(0,s.jsx)(e.code,{children:"docker-compose up"})," command from the same directory as your ",(0,s.jsx)(e.code,{children:"docker-compose.yml"})," file."]}),"\n",(0,s.jsx)(e.h2,{id:"deploy-multiple-langflow-instances-with-a-shared-postgresql-database",children:"Deploy multiple Langflow instances with a shared PostgreSQL database"}),"\n",(0,s.jsxs)(e.p,{children:["To configure multiple Langflow instances that share the same PostgreSQL database, modify your ",(0,s.jsx)(e.code,{children:"docker-compose.yml"})," file to include multiple Langflow services."]}),"\n",(0,s.jsxs)(e.p,{children:["This example populates the values in ",(0,s.jsx)(e.code,{children:"docker-compose.yml"})," with values from your Langflow ",(0,s.jsx)(e.code,{children:".env"})," file.\nThis approach means you only have to manage deployment variables in one file, instead of copying values across multiple files."]}),"\n",(0,s.jsxs)(e.ol,{children:["\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Update your ",(0,s.jsx)(e.code,{children:".env"})," file with values for your PostgreSQL database:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"POSTGRES_USER=langflow",props:{}}]},{tokens:[{content:"POSTGRES_PASSWORD=your_secure_password",props:{}}]},{tokens:[{content:"POSTGRES_DB=langflow",props:{}}]},{tokens:[{content:"POSTGRES_HOST=postgres",props:{}}]},{tokens:[{content:"POSTGRES_PORT=5432",props:{}}]},{tokens:[{content:"LANGFLOW_CONFIG_DIR=app/langflow",props:{}}]},{tokens:[{content:"LANGFLOW_PORT_1=7860",props:{}}]},{tokens:[{content:"LANGFLOW_PORT_2=7861",props:{}}]},{tokens:[{content:"LANGFLOW_HOST=0.0.0.0",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Reference these variables in your ",(0,s.jsx)(e.code,{children:"docker-compose.yml"}),".\nFor example:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"services",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"postgres:16",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_USER=${POSTGRES_USER}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_PASSWORD=${POSTGRES_PASSWORD}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_DB=${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${POSTGRES_PORT}:5432"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-postgres:/var/lib/postgresql/data",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-1",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" pull_policy",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"always",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${LANGFLOW_PORT_1}:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"postgres",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_CONFIG_DIR=${LANGFLOW_CONFIG_DIR}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=${LANGFLOW_HOST}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-data-1:/app/langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-2",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" pull_policy",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"always",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${LANGFLOW_PORT_2}:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"postgres",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_CONFIG_DIR=${LANGFLOW_CONFIG_DIR}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=${LANGFLOW_HOST}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-data-2:/app/langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-data-1",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-data-2",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]}],lang:"yaml"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Deploy the file with ",(0,s.jsx)(e.code,{children:"docker-compose up"}),".\nYou can access the first Langflow instance at ",(0,s.jsx)(e.code,{children:"http://localhost:7860"}),", and the second Langflow instance at ",(0,s.jsx)(e.code,{children:"http://localhost:7861"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["To confirm both instances are using the same database, run the ",(0,s.jsx)(e.code,{children:"docker exec"})," command to start ",(0,s.jsx)(e.code,{children:"psql"})," in your PostgreSQL container.\nYour container name may vary."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"exec ",props:{style:{color:"#A5D6FF"}}},{content:"-it ",props:{style:{color:"#79C0FF"}}},{content:"docker-test-postgres-1 psql ",props:{style:{color:"#A5D6FF"}}},{content:"-U ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"-d ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsx)(e.p,{children:"Query the database for active connections:"}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"# ",props:{style:{color:"#C9D1D9"}}},{content:"SELECT * FROM",props:{style:{color:"#FF7B72"}}},{content:" pg_stat_activity ",props:{style:{color:"#C9D1D9"}}},{content:"WHERE",props:{style:{color:"#FF7B72"}}},{content:" datname ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"'langflow'",props:{style:{color:"#A5D6FF"}}},{content:";",props:{style:{color:"#C9D1D9"}}}]}],lang:"sql"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["Examine the query results for multiple connections with different ",(0,s.jsx)(e.code,{children:"client_addr"})," values, for example ",(0,s.jsx)(e.code,{children:"172.21.0.3"})," and ",(0,s.jsx)(e.code,{children:"172.21.0.4"}),".\nSince each Langflow instance runs in its own container on the Docker network, using different incoming IP addresses confirms that both instances are actively connected to the PostgreSQL database."]}),"\n"]}),"\n",(0,s.jsxs)(e.li,{children:["\n",(0,s.jsxs)(e.p,{children:["To quit psql, type ",(0,s.jsx)(e.code,{children:"quit"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(e.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(e.ul,{children:["\n",(0,s.jsx)(e.li,{children:(0,s.jsx)(e.a,{href:"/memory",children:"Memory management options"})}),"\n",(0,s.jsx)(e.li,{children:(0,s.jsx)(e.a,{href:"/logging",children:"Logs"})}),"\n"]})]})}function u(o={}){const{wrapper:e}={...(0,r.R)(),...o.components};return e?(0,s.jsx)(e,{...o,children:(0,s.jsx)(g,{...o})}):g(o)}function f(o,e){throw new Error("Expected "+(e?"component":"object")+" `"+o+"` to be defined: you likely forgot to import, pass, or provide it.")}},28453:(o,e,n)=>{n.d(e,{R:()=>l,x:()=>c});var t=n(96540);const s={},r=t.createContext(s);function l(o){const e=t.useContext(r);return t.useMemo(function(){return"function"==typeof o?o(e):{...e,...o}},[e,o])}function c(o){let e;return e=o.disableParentContext?"function"==typeof o.components?o.components(s):o.components||s:l(o.components),t.createElement(r.Provider,{value:e},o.children)}}}]); \ No newline at end of file diff --git a/assets/js/b37620f5.28b34199.js b/assets/js/b37620f5.28b34199.js new file mode 100644 index 0000000000..7aa4e025d8 --- /dev/null +++ b/assets/js/b37620f5.28b34199.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4656],{16009:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>p,assets:()=>i,chCodeConfig:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>t,toc:()=>h});const t=JSON.parse('{"id":"Configuration/configuration-custom-database","title":"Configure an external PostgreSQL database","description":"Langflow\'s default database is SQLite, but you can configure Langflow to use PostgreSQL instead.","source":"@site/docs/Configuration/configuration-custom-database.mdx","sourceDirName":"Configuration","slug":"/configuration-custom-database","permalink":"/configuration-custom-database","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Configure an external PostgreSQL database","slug":"/configuration-custom-database"},"sidebar":"docs","previous":{"title":"Use Session IDs","permalink":"/session-id"},"next":{"title":"Database guide for enterprise administrators","permalink":"/enterprise-database-guide"}}');var s=n(74848),r=n(28453),l=n(24754);const c={title:"Configure an external PostgreSQL database",slug:"/configuration-custom-database"},a=void 0,i={},p={annotations:l.hk,Code:l.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Connect Langflow to a local PostgreSQL database",id:"connect-langflow-to-a-local-postgresql-database",level:2},{value:"Deploy Langflow and PostgreSQL containers with docker-compose.yml",id:"deploy-langflow-and-postgresql-containers-with-docker-composeyml",level:2},{value:"Deploy multiple Langflow instances with a shared PostgreSQL database",id:"deploy-multiple-langflow-instances-with-a-shared-postgresql-database",level:2},{value:"See also",id:"see-also",level:2}];function g(e){const o={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",ul:"ul",...(0,r.R)(),...e.components};return p||f("CH",!1),p.Code||f("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n",(0,s.jsxs)(o.p,{children:["Langflow's default database is ",(0,s.jsx)(o.a,{href:"https://www.sqlite.org/docs.html",children:"SQLite"}),", but you can configure Langflow to use PostgreSQL instead."]}),"\n",(0,s.jsxs)(o.p,{children:["This guide walks you through setting up an external database for Langflow by replacing the default SQLite connection string ",(0,s.jsx)(o.code,{children:"sqlite:///./langflow.db"})," with PostgreSQL, both in local and containerized environments."]}),"\n",(0,s.jsx)(o.p,{children:"In this configuration, all structured application data from Langflow, including flows, message history, and logs, is instead managed by PostgreSQL.\nPostgreSQL is better suited for production environments due to its robust support for concurrent users, advanced data integrity features, and scalability.\nLangflow can more efficiently handle multiple users and larger workloads by using PostgreSQL as the database."}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A ",(0,s.jsx)(o.a,{href:"https://www.pgadmin.org/download/",children:"PostgreSQL"})," database"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"connect-langflow-to-a-local-postgresql-database",children:"Connect Langflow to a local PostgreSQL database"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["If Langflow is running, stop Langflow with ",(0,s.jsx)("kbd",{children:"Ctrl+C"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Find your PostgreSQL database's connection string in the format ",(0,s.jsx)(o.code,{children:"postgresql://user:password@host:port/dbname"}),"."]}),"\n",(0,s.jsx)(o.p,{children:"The hostname in your connection string depends on how you're running PostgreSQL:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["If you're running PostgreSQL directly on your machine, use ",(0,s.jsx)(o.code,{children:"localhost"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["If you're running PostgreSQL in Docker Compose, use the service name, such as ",(0,s.jsx)(o.code,{children:"postgres"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["If you're running PostgreSQL in a separate Docker container with ",(0,s.jsx)(o.code,{children:"docker run"}),", use the container's IP address or network alias."]}),"\n",(0,s.jsx)(o.li,{children:"If you're running a cloud-hosted PostgreSQL, your provider will share your connection string, which includes a username and password."}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a Langflow ",(0,s.jsx)(o.code,{children:".env"})," file:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch .env",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["You can use the ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow/blob/main/.env.example",children:(0,s.jsx)(o.code,{children:".env.example"})})," file in the Langflow repository as a template for your own ",(0,s.jsx)(o.code,{children:".env"})," file."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["In your ",(0,s.jsx)(o.code,{children:".env"})," file, set ",(0,s.jsx)(o.code,{children:"LANGFLOW_DATABASE_URL"})," to your PostgreSQL connection string:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'LANGFLOW_DATABASE_URL="postgresql://user:password@localhost:5432/dbname"',props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Save your changes, and then start Langflow with your ",(0,s.jsx)(o.code,{children:".env"})," file:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"uv ",props:{style:{color:"#FFA657"}}},{content:"run langflow run ",props:{style:{color:"#A5D6FF"}}},{content:"--env-file ",props:{style:{color:"#79C0FF"}}},{content:".env",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"In Langflow, run any flow to create traffic."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Inspect your PostgreSQL database's tables and activity to verify that new tables and traffic were created after you ran a flow."}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-langflow-and-postgresql-containers-with-docker-composeyml",children:"Deploy Langflow and PostgreSQL containers with docker-compose.yml"}),"\n",(0,s.jsxs)(o.p,{children:["Launching Langflow and PostgreSQL containers in the same Docker network ensures proper connectivity between services.\nFor an example, see the ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow/blob/main/docker_example/docker-compose.yml",children:(0,s.jsx)(o.code,{children:"docker-compose.yml"})})," file in the Langflow repository."]}),"\n",(0,s.jsxs)(o.p,{children:["The configuration in the example ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," also sets up persistent volumes for both Langflow and PostgreSQL data.\nPersistent volumes map directories inside of containers to storage on the host machine, so data persists through container restarts."]}),"\n",(0,s.jsxs)(o.p,{children:["Docker Compose creates an isolated network for all services defined in ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),". This ensures that the services can communicate with each other using their service names as hostnames, such as ",(0,s.jsx)(o.code,{children:"postgres"})," in the database URL.\nIn contrast, if you run PostgreSQL separately with ",(0,s.jsx)(o.code,{children:"docker run"}),", it launches in a different network than the Langflow container, and this prevents Langflow from connecting to PostgreSQL using the service name."]}),"\n",(0,s.jsxs)(o.p,{children:["To start the Langflow and PostgreSQL services with the example Docker Compose file, navigate to the ",(0,s.jsx)(o.code,{children:"langflow/docker_example"})," directory, and then run ",(0,s.jsx)(o.code,{children:"docker-compose up"}),".\nIf you're using a different ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," file, run the ",(0,s.jsx)(o.code,{children:"docker-compose up"})," command from the same directory as your ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," file."]}),"\n",(0,s.jsx)(o.h2,{id:"deploy-multiple-langflow-instances-with-a-shared-postgresql-database",children:"Deploy multiple Langflow instances with a shared PostgreSQL database"}),"\n",(0,s.jsxs)(o.p,{children:["To configure multiple Langflow instances that share the same PostgreSQL database, modify your ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," file to include multiple Langflow services."]}),"\n",(0,s.jsxs)(o.p,{children:["This example populates the values in ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," with values from your Langflow ",(0,s.jsx)(o.code,{children:".env"})," file.\nThis approach means you only have to manage deployment variables in one file, instead of copying values across multiple files."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Update your ",(0,s.jsx)(o.code,{children:".env"})," file with values for your PostgreSQL database:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"POSTGRES_USER=langflow",props:{}}]},{tokens:[{content:"POSTGRES_PASSWORD=your_secure_password",props:{}}]},{tokens:[{content:"POSTGRES_DB=langflow",props:{}}]},{tokens:[{content:"POSTGRES_HOST=postgres",props:{}}]},{tokens:[{content:"POSTGRES_PORT=5432",props:{}}]},{tokens:[{content:"LANGFLOW_CONFIG_DIR=app/langflow",props:{}}]},{tokens:[{content:"LANGFLOW_PORT_1=7860",props:{}}]},{tokens:[{content:"LANGFLOW_PORT_2=7861",props:{}}]},{tokens:[{content:"LANGFLOW_HOST=0.0.0.0",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Reference these variables in your ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),".\nFor example:"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"services",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"postgres:16",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_USER=${POSTGRES_USER}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_PASSWORD=${POSTGRES_PASSWORD}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_DB=${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${POSTGRES_PORT}:5432"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-postgres:/var/lib/postgresql/data",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-1",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" pull_policy",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"always",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${LANGFLOW_PORT_1}:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"postgres",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_CONFIG_DIR=${LANGFLOW_CONFIG_DIR}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=${LANGFLOW_HOST}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-data-1:/app/langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-2",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" pull_policy",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"always",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"${LANGFLOW_PORT_2}:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" depends_on",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"postgres",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL=postgresql://${POSTGRES_USER}:${POSTGRES_PASSWORD}@${POSTGRES_HOST}:${POSTGRES_PORT}/${POSTGRES_DB}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_CONFIG_DIR=${LANGFLOW_CONFIG_DIR}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_HOST=${LANGFLOW_HOST}",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"PORT=7860",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-data-2:/app/langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-data-1",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow-data-2",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]}],lang:"yaml"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Deploy the file with ",(0,s.jsx)(o.code,{children:"docker-compose up"}),".\nYou can access the first Langflow instance at ",(0,s.jsx)(o.code,{children:"http://localhost:7860"}),", and the second Langflow instance at ",(0,s.jsx)(o.code,{children:"http://localhost:7861"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To confirm both instances are using the same database, run the ",(0,s.jsx)(o.code,{children:"docker exec"})," command to start ",(0,s.jsx)(o.code,{children:"psql"})," in your PostgreSQL container.\nYour container name may vary."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker ",props:{style:{color:"#FFA657"}}},{content:"exec ",props:{style:{color:"#A5D6FF"}}},{content:"-it ",props:{style:{color:"#79C0FF"}}},{content:"docker-test-postgres-1 psql ",props:{style:{color:"#A5D6FF"}}},{content:"-U ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"-d ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Query the database for active connections:"}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"# ",props:{style:{color:"#C9D1D9"}}},{content:"SELECT * FROM",props:{style:{color:"#FF7B72"}}},{content:" pg_stat_activity ",props:{style:{color:"#C9D1D9"}}},{content:"WHERE",props:{style:{color:"#FF7B72"}}},{content:" datname ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"'langflow'",props:{style:{color:"#A5D6FF"}}},{content:";",props:{style:{color:"#C9D1D9"}}}]}],lang:"sql"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Examine the query results for multiple connections with different ",(0,s.jsx)(o.code,{children:"client_addr"})," values, for example ",(0,s.jsx)(o.code,{children:"172.21.0.3"})," and ",(0,s.jsx)(o.code,{children:"172.21.0.4"}),".\nSince each Langflow instance runs in its own container on the Docker network, using different incoming IP addresses confirms that both instances are actively connected to the PostgreSQL database."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["To quit psql, type ",(0,s.jsx)(o.code,{children:"quit"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/enterprise-database-guide",children:"Langflow database guide for enterprise DBAs"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/memory",children:"Memory management options"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/logging",children:"Logs"})}),"\n"]})]})}function u(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(g,{...e})}):g(e)}function f(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},28453:(e,o,n)=>{n.d(o,{R:()=>l,x:()=>c});var t=n(96540);const s={},r=t.createContext(s);function l(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function c(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:l(e.components),t.createElement(r.Provider,{value:o},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/bb45d4f9.88866337.js b/assets/js/bb45d4f9.88866337.js new file mode 100644 index 0000000000..40ee211dff --- /dev/null +++ b/assets/js/bb45d4f9.88866337.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[253],{11470:(e,o,t)=>{t.d(o,{A:()=>x});var n=t(96540),s=t(18215),l=t(23104),r=t(56347),c=t(205),a=t(57485),i=t(31682),p=t(70679);function d(e){return n.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,n.isValidElement)(e)&&function(e){const{props:o}=e;return!!o&&"object"==typeof o&&"value"in o}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function u(e){const{values:o,children:t}=e;return(0,n.useMemo)(()=>{const e=o??function(e){return d(e).map(({props:{value:e,label:o,attributes:t,default:n}})=>({value:e,label:o,attributes:t,default:n}))}(t);return function(e){const o=(0,i.XI)(e,(e,o)=>e.value===o.value);if(o.length>0)throw new Error(`Docusaurus error: Duplicate values "${o.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[o,t])}function h({value:e,tabValues:o}){return o.some(o=>o.value===e)}function f({queryString:e=!1,groupId:o}){const t=(0,r.W6)(),s=function({queryString:e=!1,groupId:o}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!o)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return o??null}({queryString:e,groupId:o});return[(0,a.aZ)(s),(0,n.useCallback)(e=>{if(!s)return;const o=new URLSearchParams(t.location.search);o.set(s,e),t.replace({...t.location,search:o.toString()})},[s,t])]}function y(e){const{defaultValue:o,queryString:t=!1,groupId:s}=e,l=u(e),[r,a]=(0,n.useState)(()=>function({defaultValue:e,tabValues:o}){if(0===o.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!h({value:e,tabValues:o}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${o.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=o.find(e=>e.default)??o[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:o,tabValues:l})),[i,d]=f({queryString:t,groupId:s}),[y,g]=function({groupId:e}){const o=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,s]=(0,p.Dv)(o);return[t,(0,n.useCallback)(e=>{o&&s.set(e)},[o,s])]}({groupId:s}),m=(()=>{const e=i??y;return h({value:e,tabValues:l})?e:null})();(0,c.A)(()=>{m&&a(m)},[m]);return{selectedValue:r,selectValue:(0,n.useCallback)(e=>{if(!h({value:e,tabValues:l}))throw new Error(`Can't select invalid tab value=${e}`);a(e),d(e),g(e)},[d,g,l]),tabValues:l}}var g=t(92303);const m={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var b=t(74848);function D({className:e,block:o,selectedValue:t,selectValue:n,tabValues:r}){const c=[],{blockElementScrollPositionUntilNextRender:a}=(0,l.a_)(),i=e=>{const o=e.currentTarget,s=c.indexOf(o),l=r[s].value;l!==t&&(a(o),n(l))},p=e=>{let o=null;switch(e.key){case"Enter":i(e);break;case"ArrowRight":{const t=c.indexOf(e.currentTarget)+1;o=c[t]??c[0];break}case"ArrowLeft":{const t=c.indexOf(e.currentTarget)-1;o=c[t]??c[c.length-1];break}}o?.focus()};return(0,b.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,s.A)("tabs",{"tabs--block":o},e),children:r.map(({value:e,label:o,attributes:n})=>(0,b.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{c.push(e)},onKeyDown:p,onClick:i,...n,className:(0,s.A)("tabs__item",m.tabItem,n?.className,{"tabs__item--active":t===e}),children:o??e},e))})}function k({lazy:e,children:o,selectedValue:t}){const l=(Array.isArray(o)?o:[o]).filter(Boolean);if(e){const e=l.find(e=>e.props.value===t);return e?(0,n.cloneElement)(e,{className:(0,s.A)("margin-top--md",e.props.className)}):null}return(0,b.jsx)("div",{className:"margin-top--md",children:l.map((e,o)=>(0,n.cloneElement)(e,{key:o,hidden:e.props.value!==t}))})}function v(e){const o=y(e);return(0,b.jsxs)("div",{className:(0,s.A)("tabs-container",m.tabList),children:[(0,b.jsx)(D,{...o,...e}),(0,b.jsx)(k,{...o,...e})]})}function x(e){const o=(0,g.A)();return(0,b.jsx)(v,{...e,children:d(e.children)},String(o))}},19365:(e,o,t)=>{t.d(o,{A:()=>r});t(96540);var n=t(18215);const s={tabItem:"tabItem_Ymn6"};var l=t(74848);function r({children:e,hidden:o,className:t}){return(0,l.jsx)("div",{role:"tabpanel",className:(0,n.A)(s.tabItem,t),hidden:o,children:e})}},28453:(e,o,t)=>{t.d(o,{R:()=>r,x:()=>c});var n=t(96540);const s={},l=n.createContext(s);function r(e){const o=n.useContext(l);return n.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function c(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:r(e.components),n.createElement(l.Provider,{value:o},e.children)}},66908:(e,o,t)=>{t.r(o),t.d(o,{CH:()=>u,assets:()=>d,chCodeConfig:()=>h,contentTitle:()=>p,default:()=>g,frontMatter:()=>i,metadata:()=>n,toc:()=>f});const n=JSON.parse('{"id":"Deployment/deployment-kubernetes-dev","title":"Deploy the Langflow development environment on Kubernetes","description":"The Langflow integrated development environment (IDE) Helm chart is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the Langflow API and visual editor.","source":"@site/docs/Deployment/deployment-kubernetes-dev.mdx","sourceDirName":"Deployment","slug":"/deployment-kubernetes-dev","permalink":"/deployment-kubernetes-dev","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy the Langflow development environment on Kubernetes","slug":"/deployment-kubernetes-dev"},"sidebar":"docs","previous":{"title":"Best practices","permalink":"/deployment-prod-best-practices"},"next":{"title":"Deploy in production","permalink":"/deployment-kubernetes-prod"}}');var s=t(74848),l=t(28453),r=t(24754),c=t(11470),a=t(19365);const i={title:"Deploy the Langflow development environment on Kubernetes",slug:"/deployment-kubernetes-dev"},p=void 0,d={},u={annotations:r.hk,Code:r.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},f=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Prepare a Kubernetes cluster",id:"prepare-a-kubernetes-cluster",level:2},{value:"Install the Langflow IDE Helm chart",id:"install-the-langflow-ide-helm-chart",level:2},{value:"Access the Langflow IDE",id:"access-the-langflow-ide",level:2},{value:"Modify your Langflow IDE deployment",id:"modify-your-langflow-ide-deployment",level:2},{value:"Deploy a different Langflow version",id:"deploy-a-different-langflow-version",level:3},{value:"Use external storage for the Langflow database",id:"use-external-storage-for-the-langflow-database",level:3},{value:"Configure scaling",id:"configure-scaling",level:3},{value:"See also",id:"see-also",level:2}];function y(e){const o={a:"a",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",ul:"ul",...(0,l.R)(),...e.components};return u||m("CH",!1),u.Code||m("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/tree/main/charts/langflow-ide",children:"Langflow integrated development environment (IDE) Helm chart"})," is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the Langflow API and visual editor."]}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A ",(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/setup/",children:"Kubernetes"})," cluster"]}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/tools/#kubectl",children:"kubectl"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://helm.sh/docs/intro/install/",children:"Helm"})}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"prepare-a-kubernetes-cluster",children:"Prepare a Kubernetes cluster"}),"\n",(0,s.jsxs)(o.p,{children:["This example uses ",(0,s.jsx)(o.a,{href:"https://minikube.sigs.k8s.io/docs/start/",children:"Minikube"}),", but you can use any Kubernetes cluster."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Create a Kubernetes cluster on Minikube:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"minikube ",props:{style:{color:"#FFA657"}}},{content:"start",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Set ",(0,s.jsx)(o.code,{children:"kubectl"})," to use Minikube:"]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"config use-context minikube",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"install-the-langflow-ide-helm-chart",children:"Install the Langflow IDE Helm chart"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Add the repository to Helm, and then update it:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo add langflow https://langflow-ai.github.io/langflow-helm-charts",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo update",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Install Langflow with the default options in the ",(0,s.jsx)(o.code,{children:"langflow"})," namespace:"]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install langflow-ide langflow/langflow-ide ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"--create-namespace",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Check the status of the pods:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get pods ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"access-the-langflow-ide",children:"Access the Langflow IDE"}),"\n",(0,s.jsx)(o.p,{children:"Enable local port forwarding to access Langflow from your local machine:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Make the Langflow API accessible from your local machine at port 7860:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/langflow-service-backend 7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Make the visual editor accessible from your local machine at port 8080:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/langflow-service 8080:",props:{style:{color:"#A5D6FF"}}},{content:"8080",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.p,{children:"Now you can do the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Access the Langflow API at ",(0,s.jsx)(o.code,{children:"http://localhost:7860"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Access the visual editor at ",(0,s.jsx)(o.code,{children:"http://localhost:8080"}),"."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"modify-your-langflow-ide-deployment",children:"Modify your Langflow IDE deployment"}),"\n",(0,s.jsxs)(o.p,{children:["You can modify the Langflow IDE Helm chart's ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-ide/values.yaml",children:(0,s.jsx)(o.code,{children:"values.yaml"})})," file to customize your deployment.\nThe following sections describe some common modifications."]}),"\n",(0,s.jsx)(o.p,{children:"If you need to set secrets, Kubernetes secrets are recommended."}),"\n",(0,s.jsx)(o.h3,{id:"deploy-a-different-langflow-version",children:"Deploy a different Langflow version"}),"\n",(0,s.jsx)(o.p,{children:"The Langflow IDE Helm chart deploys the latest Langflow version by default."}),"\n",(0,s.jsxs)(o.p,{children:["To specify a different Langflow version, set the ",(0,s.jsx)(o.code,{children:"langflow.backend.image.tag"})," and ",(0,s.jsx)(o.code,{children:"langflow.frontend.image.tag"})," values to your preferred version.\nFor example:"]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tag",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1.0.0a59"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" frontend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tag",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1.0.0a59"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.h3,{id:"use-external-storage-for-the-langflow-database",children:"Use external storage for the Langflow database"}),"\n",(0,s.jsx)(o.p,{children:"The Langflow IDE Helm chart uses the default Langflow database configuration, specifically a SQLite database stored in a local persistent disk."}),"\n",(0,s.jsxs)(o.p,{children:["If you want to use an ",(0,s.jsx)(o.a,{href:"/configuration-custom-database",children:"external PostgreSQL database"}),", use ",(0,s.jsx)(o.code,{children:"postgresql"})," chart or ",(0,s.jsx)(o.code,{children:"externalDatabase"})," to configure the database connection in ",(0,s.jsx)(o.code,{children:"values.yaml"}),"."]}),"\n",(0,s.jsxs)(c.A,{children:[(0,s.jsxs)(a.A,{value:"postgresql",label:"postgresql",default:!0,children:[(0,s.jsx)(o.p,{children:"Use the built-in PostgreSQL chart:"}),(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"postgresql",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" auth",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" username",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" password",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-postgres"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" database",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-db"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]})]}),(0,s.jsxs)(a.A,{value:"externaldatabase",label:"externalDatabase",children:[(0,s.jsxs)(o.p,{children:["If you don't want to use the built-in PostgreSQL chart, set ",(0,s.jsx)(o.code,{children:"postgresql.enabled"})," to ",(0,s.jsx)(o.code,{children:"false"}),", and then configure the database connection in ",(0,s.jsx)(o.code,{children:"langflow.backend.externalDatabase"}),":"]}),(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"postgresql",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"false",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" externalDatabase",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" driver",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"postgresql"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" port",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"5432"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" user",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" password",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" valueFrom",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" secretKeyRef",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" key",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"password"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"your-secret-name"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" database",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-db"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" sqlite",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"false",props:{style:{color:"#79C0FF"}}}]}],lang:"yaml"},annotations:[]}]})]})]}),"\n",(0,s.jsx)(o.h3,{id:"configure-scaling",children:"Configure scaling"}),"\n",(0,s.jsxs)(o.p,{children:["To configure scaling for the Langflow IDE Helm chart deployment, you must set ",(0,s.jsx)(o.code,{children:"replicaCount"})," (horizontal scaling) and ",(0,s.jsx)(o.code,{children:"resources"})," (vertical scaling) for both the ",(0,s.jsx)(o.code,{children:"langflow.backend"})," and ",(0,s.jsx)(o.code,{children:"langflow.frontend"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["If your flows rely on a shared state, such as ",(0,s.jsx)(o.a,{href:"/memory",children:"built-in chat memory"}),", you must also set up a shared database when scaling horizontally."]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"0.5",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1Gi",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" # limits:",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # cpu: 0.5",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # memory: 1Gi",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" frontend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"0.3",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"512Mi",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" # limits:",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # cpu: 0.3",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # memory: 512Mi",props:{style:{color:"#8B949E"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-prod-best-practices",children:"Best practices for Langflow on Kubernetes"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm Charts repository"})}),"\n"]})]})}function g(e={}){const{wrapper:o}={...(0,l.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(y,{...e})}):y(e)}function m(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/bb45d4f9.e32f398c.js b/assets/js/bb45d4f9.e32f398c.js deleted file mode 100644 index e6da59d211..0000000000 --- a/assets/js/bb45d4f9.e32f398c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[253],{11470:(e,o,t)=>{t.d(o,{A:()=>E});var n=t(96540),s=t(18215),l=t(23104),r=t(56347),c=t(205),a=t(57485),i=t(31682),p=t(70679);function d(e){return n.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,n.isValidElement)(e)&&function(e){const{props:o}=e;return!!o&&"object"==typeof o&&"value"in o}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function u(e){const{values:o,children:t}=e;return(0,n.useMemo)(()=>{const e=o??function(e){return d(e).map(({props:{value:e,label:o,attributes:t,default:n}})=>({value:e,label:o,attributes:t,default:n}))}(t);return function(e){const o=(0,i.XI)(e,(e,o)=>e.value===o.value);if(o.length>0)throw new Error(`Docusaurus error: Duplicate values "${o.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[o,t])}function h({value:e,tabValues:o}){return o.some(o=>o.value===e)}function f({queryString:e=!1,groupId:o}){const t=(0,r.W6)(),s=function({queryString:e=!1,groupId:o}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!o)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return o??null}({queryString:e,groupId:o});return[(0,a.aZ)(s),(0,n.useCallback)(e=>{if(!s)return;const o=new URLSearchParams(t.location.search);o.set(s,e),t.replace({...t.location,search:o.toString()})},[s,t])]}function y(e){const{defaultValue:o,queryString:t=!1,groupId:s}=e,l=u(e),[r,a]=(0,n.useState)(()=>function({defaultValue:e,tabValues:o}){if(0===o.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!h({value:e,tabValues:o}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${o.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=o.find(e=>e.default)??o[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:o,tabValues:l})),[i,d]=f({queryString:t,groupId:s}),[y,g]=function({groupId:e}){const o=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,s]=(0,p.Dv)(o);return[t,(0,n.useCallback)(e=>{o&&s.set(e)},[o,s])]}({groupId:s}),m=(()=>{const e=i??y;return h({value:e,tabValues:l})?e:null})();(0,c.A)(()=>{m&&a(m)},[m]);return{selectedValue:r,selectValue:(0,n.useCallback)(e=>{if(!h({value:e,tabValues:l}))throw new Error(`Can't select invalid tab value=${e}`);a(e),d(e),g(e)},[d,g,l]),tabValues:l}}var g=t(92303);const m={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var b=t(74848);function D({className:e,block:o,selectedValue:t,selectValue:n,tabValues:r}){const c=[],{blockElementScrollPositionUntilNextRender:a}=(0,l.a_)(),i=e=>{const o=e.currentTarget,s=c.indexOf(o),l=r[s].value;l!==t&&(a(o),n(l))},p=e=>{let o=null;switch(e.key){case"Enter":i(e);break;case"ArrowRight":{const t=c.indexOf(e.currentTarget)+1;o=c[t]??c[0];break}case"ArrowLeft":{const t=c.indexOf(e.currentTarget)-1;o=c[t]??c[c.length-1];break}}o?.focus()};return(0,b.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,s.A)("tabs",{"tabs--block":o},e),children:r.map(({value:e,label:o,attributes:n})=>(0,b.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{c.push(e)},onKeyDown:p,onClick:i,...n,className:(0,s.A)("tabs__item",m.tabItem,n?.className,{"tabs__item--active":t===e}),children:o??e},e))})}function k({lazy:e,children:o,selectedValue:t}){const l=(Array.isArray(o)?o:[o]).filter(Boolean);if(e){const e=l.find(e=>e.props.value===t);return e?(0,n.cloneElement)(e,{className:(0,s.A)("margin-top--md",e.props.className)}):null}return(0,b.jsx)("div",{className:"margin-top--md",children:l.map((e,o)=>(0,n.cloneElement)(e,{key:o,hidden:e.props.value!==t}))})}function v(e){const o=y(e);return(0,b.jsxs)("div",{className:(0,s.A)("tabs-container",m.tabList),children:[(0,b.jsx)(D,{...o,...e}),(0,b.jsx)(k,{...o,...e})]})}function E(e){const o=(0,g.A)();return(0,b.jsx)(v,{...e,children:d(e.children)},String(o))}},19365:(e,o,t)=>{t.d(o,{A:()=>r});t(96540);var n=t(18215);const s={tabItem:"tabItem_Ymn6"};var l=t(74848);function r({children:e,hidden:o,className:t}){return(0,l.jsx)("div",{role:"tabpanel",className:(0,n.A)(s.tabItem,t),hidden:o,children:e})}},28453:(e,o,t)=>{t.d(o,{R:()=>r,x:()=>c});var n=t(96540);const s={},l=n.createContext(s);function r(e){const o=n.useContext(l);return n.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function c(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:r(e.components),n.createElement(l.Provider,{value:o},e.children)}},66908:(e,o,t)=>{t.r(o),t.d(o,{CH:()=>p,assets:()=>i,chCodeConfig:()=>d,contentTitle:()=>a,default:()=>f,frontMatter:()=>c,metadata:()=>n,toc:()=>u});const n=JSON.parse('{"id":"Deployment/deployment-kubernetes-dev","title":"Deploy the Langflow development environment on Kubernetes","description":"The Langflow Integrated Development Environment (IDE) Helm chart is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the API and the visual editor.","source":"@site/docs/Deployment/deployment-kubernetes-dev.mdx","sourceDirName":"Deployment","slug":"/deployment-kubernetes-dev","permalink":"/deployment-kubernetes-dev","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy the Langflow development environment on Kubernetes","slug":"/deployment-kubernetes-dev"},"sidebar":"docs","previous":{"title":"Langflow architecture and best practices","permalink":"/deployment-prod-best-practices"},"next":{"title":"Deploy in production","permalink":"/deployment-kubernetes-prod"}}');var s=t(74848),l=t(28453),r=t(24754);t(11470),t(19365);const c={title:"Deploy the Langflow development environment on Kubernetes",slug:"/deployment-kubernetes-dev"},a=void 0,i={},p={annotations:r.hk,Code:r.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Prepare a Kubernetes cluster",id:"prepare-a-kubernetes-cluster",level:2},{value:"Install the Langflow IDE Helm chart",id:"install-the-langflow-ide-helm-chart",level:2},{value:"Access the Langflow IDE",id:"access-the-langflow-ide",level:2},{value:"Configure the Langflow version",id:"configure-the-langflow-version",level:2},{value:"Configure external storage",id:"configure-external-storage",level:2},{value:"Configure scaling",id:"configure-scaling",level:2},{value:"See also",id:"see-also",level:2}];function h(e){const o={a:"a",code:"code",h2:"h2",li:"li",ol:"ol",p:"p",ul:"ul",...(0,l.R)(),...e.components};return p||y("CH",!1),p.Code||y("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/tree/main/charts/langflow-ide",children:"Langflow Integrated Development Environment (IDE)"})," Helm chart is designed to provide a complete environment for developers to create, test, and debug their flows. It includes both the API and the visual editor."]}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A ",(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/setup/",children:"Kubernetes"})," cluster"]}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/tools/#kubectl",children:"kubectl"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://helm.sh/docs/intro/install/",children:"Helm"})}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"prepare-a-kubernetes-cluster",children:"Prepare a Kubernetes cluster"}),"\n",(0,s.jsxs)(o.p,{children:["This example uses ",(0,s.jsx)(o.a,{href:"https://minikube.sigs.k8s.io/docs/start/",children:"Minikube"}),", but you can use any Kubernetes cluster."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Create a Kubernetes cluster on Minikube."}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"minikube ",props:{style:{color:"#FFA657"}}},{content:"start",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Set ",(0,s.jsx)(o.code,{children:"kubectl"})," to use Minikube."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"config use-context minikube",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"install-the-langflow-ide-helm-chart",children:"Install the Langflow IDE Helm chart"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Add the repository to Helm and update it."}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo add langflow https://langflow-ai.github.io/langflow-helm-charts",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo update",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Install Langflow with the default options in the ",(0,s.jsx)(o.code,{children:"langflow"})," namespace."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install langflow-ide langflow/langflow-ide ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"--create-namespace",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Check the status of the pods."}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get pods ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"access-the-langflow-ide",children:"Access the Langflow IDE"}),"\n",(0,s.jsx)(o.p,{children:"Enable local port forwarding to access Langflow from your local machine."}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsx)(o.li,{children:"To make the Langflow API accessible from your local machine at port 7860:"}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/langflow-service-backend 7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsxs)(o.ol,{start:"2",children:["\n",(0,s.jsx)(o.li,{children:"To make the visual editor accessible from your local machine at port 8080:"}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/langflow-service 8080:",props:{style:{color:"#A5D6FF"}}},{content:"8080",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"Now you can do the following:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Access the Langflow API at ",(0,s.jsx)(o.code,{children:"http://localhost:7860"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Access the visual editor at ",(0,s.jsx)(o.code,{children:"http://localhost:8080"}),"."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"configure-the-langflow-version",children:"Configure the Langflow version"}),"\n",(0,s.jsxs)(o.p,{children:["Langflow is deployed with the ",(0,s.jsx)(o.code,{children:"latest"})," version by default."]}),"\n",(0,s.jsxs)(o.p,{children:["To specify a different Langflow version, set the ",(0,s.jsx)(o.code,{children:"langflow.backend.image.tag"})," and ",(0,s.jsx)(o.code,{children:"langflow.frontend.image.tag"})," values in the ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-ide/values.yaml",children:"values.yaml"})," file."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tag",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1.0.0a59"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" frontend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tag",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1.0.0a59"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.h2,{id:"configure-external-storage",children:"Configure external storage"}),"\n",(0,s.jsx)(o.p,{children:"By default, the chart deploys a SQLite database stored in a local persistent disk. If you want to use an external PostgreSQL database, you can configure it in two ways:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:"Use the built-in PostgreSQL chart:"}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"postgresql",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" auth",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" username",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" password",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-postgres"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" database",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-db"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:"Use an external database:"}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"postgresql",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"false",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" externalDatabase",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" driver",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"postgresql"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" port",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"5432"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" user",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" password",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" valueFrom",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" secretKeyRef",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" key",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"password"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"your-secret-name"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" database",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"langflow-db"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" sqlite",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"false",props:{style:{color:"#79C0FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.h2,{id:"configure-scaling",children:"Configure scaling"}),"\n",(0,s.jsx)(o.p,{children:"Scale the number of replicas and resources for both frontend and backend services:"}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" backend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"0.5",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1Gi",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" # limits:",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # cpu: 0.5",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # memory: 1Gi",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" frontend",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" enabled",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"true",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"1",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"0.3",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"512Mi",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" # limits:",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # cpu: 0.3",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" # memory: 512Mi",props:{style:{color:"#8B949E"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"If your flow relies on a shared state, such as built-in chat memory, you need to set up a shared database when scaling horizontally."}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.p,{children:["For more examples of ",(0,s.jsx)(o.code,{children:"langflow-ide"})," deployment, see the ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/tree/main/examples/langflow-ide",children:"Langflow Helm Charts repository"}),"."]})]})}function f(e={}){const{wrapper:o}={...(0,l.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(h,{...e})}):h(e)}function y(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/d1f3cfe5.9b2b9b3e.js b/assets/js/d1f3cfe5.9b2b9b3e.js new file mode 100644 index 0000000000..6c2fbb41ff --- /dev/null +++ b/assets/js/d1f3cfe5.9b2b9b3e.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9986],{4392:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>i,contentTitle:()=>a,default:()=>u,frontMatter:()=>l,metadata:()=>r,toc:()=>c});const r=JSON.parse('{"id":"Deployment/deployment-architecture","title":"Langflow architecture on Kubernetes","description":"There are two broad types of Langflow deployments:","source":"@site/docs/Deployment/deployment-architecture.mdx","sourceDirName":"Deployment","slug":"/deployment-architecture","permalink":"/deployment-architecture","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Langflow architecture on Kubernetes","slug":"/deployment-architecture"},"sidebar":"docs","previous":{"title":"Deploy Langflow on a remote server","permalink":"/deployment-caddyfile"},"next":{"title":"Best practices","permalink":"/deployment-prod-best-practices"}}');var o=t(74848),s=t(28453);t(11470),t(19365);const l={title:"Langflow architecture on Kubernetes",slug:"/deployment-architecture"},a=void 0,i={},c=[{value:"Benefits of deploying Langflow on Kubernetes",id:"benefits-of-deploying-langflow-on-kubernetes",level:2},{value:"Langflow deployment",id:"langflow-deployment",level:2},{value:"Environment isolation",id:"environment-isolation",level:2},{value:"Next steps",id:"next-steps",level:2}];function d(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",img:"img",li:"li",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.p,{children:"There are two broad types of Langflow deployments:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Langflow IDE (development)"}),": Deploy both the Langflow visual editor (frontend) and API (backend). Typically, this is used for development environments where developers use the visual editor to create and manage flows before packaging and serving them through a production runtime deployment."]}),"\n",(0,o.jsxs)(n.p,{children:["The Langflow repository's example ",(0,o.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow/blob/main/docker_example/docker-compose.yml",children:(0,o.jsx)(n.code,{children:"docker-compose.yml"})})," file builds a Langflow IDE image."]}),"\n",(0,o.jsxs)(n.p,{children:["For information about IDE deployments on Kubernetes, see ",(0,o.jsx)(n.a,{href:"/deployment-kubernetes-dev",children:"Deploy the Langflow development environment on Kubernetes"}),"."]}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Langflow runtime (production)"}),": Deploy the Langflow runtime for production flows, which is headless (backend only) service focused on serving the Langflow API. This is used for production environments where flows are executed programmatically without the need for the visual editor. The server exposes your flows as endpoints, and then runs only the processes necessary to serve each flow."]}),"\n",(0,o.jsx)(n.p,{children:"An external PostgreSQL database is strongly recommended with this deployment type to improve scalability and reliability as compared to the default SQLite database."}),"\n",(0,o.jsxs)(n.p,{children:["For information about runtime deployments on Kubernetes, see ",(0,o.jsx)(n.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"}),"."]}),"\n",(0,o.jsx)(n.admonition,{type:"tip",children:(0,o.jsxs)(n.p,{children:["You can start Langflow in headless mode with the ",(0,o.jsx)(n.code,{children:"LANGFLOW_BACKEND_ONLY"})," ",(0,o.jsx)(n.a,{href:"/environment-variables",children:"environment variable"}),"."]})}),"\n"]}),"\n"]}),"\n",(0,o.jsxs)(n.p,{children:["You can also ",(0,o.jsx)(n.a,{href:"/deployment-docker",children:"deploy the Langflow IDE and runtime on Docker"}),"."]}),"\n",(0,o.jsx)(n.h2,{id:"benefits-of-deploying-langflow-on-kubernetes",children:"Benefits of deploying Langflow on Kubernetes"}),"\n",(0,o.jsx)(n.p,{children:"Deploying on Kubernetes offers the following advantages:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Scalability"}),": Kubernetes allows you to scale the Langflow service to meet the demands of your workload."]}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Availability and resilience"}),": Kubernetes provides built-in resilience features, such as automatic failover and self-healing, to ensure that the Langflow service is always available."]}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Security"}),": Kubernetes provides security features, such as role-based access control and network isolation, to protect the Langflow service and its data."]}),"\n"]}),"\n",(0,o.jsxs)(n.li,{children:["\n",(0,o.jsxs)(n.p,{children:[(0,o.jsx)(n.strong,{children:"Portability"}),": Kubernetes is a portable platform, which means that you can deploy the Langflow service to any Kubernetes cluster, on-premises or in the cloud."]}),"\n",(0,o.jsxs)(n.p,{children:["Langflow can be deployed on cloud platforms like AWS EKS, Google GKE, or Azure AKS. For more information, see the ",(0,o.jsx)(n.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm charts repository"}),"."]}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(n.h2,{id:"langflow-deployment",children:"Langflow deployment"}),"\n",(0,o.jsx)(n.p,{children:"A typical Langflow deployment includes:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Langflow services"}),": The Langflow API and, for IDE deployments, the visual editor."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Kubernetes cluster"}),": The Kubernetes cluster provides a platform for deploying and managing Langflow and its supporting services."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Persistent storage"}),": Persistent storage is used to store the Langflow service's data, such as models and training data."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Ingress controller"}),": The ingress controller provides a single entry point for traffic to the Langflow service."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Load balancer"}),": Balances traffic across multiple Langflow replicas."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Vector database"}),": If you are using Langflow for RAG, you can integrate with the vector database in Astra Serverless."]}),"\n"]}),"\n",(0,o.jsx)(n.p,{children:(0,o.jsx)(n.img,{alt:"Langflow reference architecture on Kubernetes",src:t(48109).A+"",width:"671",height:"361"})}),"\n",(0,o.jsx)(n.h2,{id:"environment-isolation",children:"Environment isolation"}),"\n",(0,o.jsx)(n.p,{children:"It is recommended to deploy and run separate development and production environments for Langflow:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsx)(n.li,{children:"Deploy the IDE in your development environment where your developers prototype and test new flows."}),"\n",(0,o.jsx)(n.li,{children:"Deploy the runtime in your production environment to serve flows as standalone services."}),"\n"]}),"\n",(0,o.jsx)(n.p,{children:(0,o.jsx)(n.img,{alt:"Langflow environments",src:t(26023).A+"",width:"601",height:"491"})}),"\n",(0,o.jsx)(n.p,{children:"This separation is designed to enhance security, support an organized software development pipeline, and optimize infrastructure resource allocation:"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Isolation"}),": By separating the development and production environments, you can better isolate different phases of the application lifecycle. This isolation minimizes the risk of development-related issues impacting the production environments."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Access control"}),": Different security policies and access controls can be applied to each environment. Developers may require broader access in the IDE for testing and debugging, while the runtime environment can be locked down with stricter security measures."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Reduced attack surface"}),": The runtime environment is configured to include only essential components, reducing the attack surface and potential vulnerabilities."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Optimized resource usage and cost efficiency"}),": By separating the two environments, you can allocate resources more effectively. Each flow can be deployed independently, providing fine-grained resource control."]}),"\n",(0,o.jsxs)(n.li,{children:[(0,o.jsx)(n.strong,{children:"Scalability"}),": The runtime environment can be scaled independently based on application load and performance requirements, without affecting the development environment."]}),"\n"]}),"\n",(0,o.jsx)(n.h2,{id:"next-steps",children:"Next steps"}),"\n",(0,o.jsxs)(n.ul,{children:["\n",(0,o.jsx)(n.li,{children:(0,o.jsx)(n.a,{href:"/deployment-prod-best-practices",children:"Best practices for Langflow on Kubernetes"})}),"\n",(0,o.jsx)(n.li,{children:(0,o.jsx)(n.a,{href:"/deployment-kubernetes-dev",children:"Deploy the Langflow development environment on Kubernetes"})}),"\n",(0,o.jsx)(n.li,{children:(0,o.jsx)(n.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"})}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(d,{...e})}):d(e)}},11470:(e,n,t)=>{t.d(n,{A:()=>j});var r=t(96540),o=t(18215),s=t(23104),l=t(56347),a=t(205),i=t(57485),c=t(31682),d=t(70679);function u(e){return r.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,r.isValidElement)(e)&&function(e){const{props:n}=e;return!!n&&"object"==typeof n&&"value"in n}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function h(e){const{values:n,children:t}=e;return(0,r.useMemo)(()=>{const e=n??function(e){return u(e).map(({props:{value:e,label:n,attributes:t,default:r}})=>({value:e,label:n,attributes:t,default:r}))}(t);return function(e){const n=(0,c.XI)(e,(e,n)=>e.value===n.value);if(n.length>0)throw new Error(`Docusaurus error: Duplicate values "${n.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[n,t])}function p({value:e,tabValues:n}){return n.some(n=>n.value===e)}function f({queryString:e=!1,groupId:n}){const t=(0,l.W6)(),o=function({queryString:e=!1,groupId:n}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!n)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return n??null}({queryString:e,groupId:n});return[(0,i.aZ)(o),(0,r.useCallback)(e=>{if(!o)return;const n=new URLSearchParams(t.location.search);n.set(o,e),t.replace({...t.location,search:n.toString()})},[o,t])]}function m(e){const{defaultValue:n,queryString:t=!1,groupId:o}=e,s=h(e),[l,i]=(0,r.useState)(()=>function({defaultValue:e,tabValues:n}){if(0===n.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!p({value:e,tabValues:n}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${n.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=n.find(e=>e.default)??n[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:n,tabValues:s})),[c,u]=f({queryString:t,groupId:o}),[m,g]=function({groupId:e}){const n=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,o]=(0,d.Dv)(n);return[t,(0,r.useCallback)(e=>{n&&o.set(e)},[n,o])]}({groupId:o}),b=(()=>{const e=c??m;return p({value:e,tabValues:s})?e:null})();(0,a.A)(()=>{b&&i(b)},[b]);return{selectedValue:l,selectValue:(0,r.useCallback)(e=>{if(!p({value:e,tabValues:s}))throw new Error(`Can't select invalid tab value=${e}`);i(e),u(e),g(e)},[u,g,s]),tabValues:s}}var g=t(92303);const b={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var v=t(74848);function y({className:e,block:n,selectedValue:t,selectValue:r,tabValues:l}){const a=[],{blockElementScrollPositionUntilNextRender:i}=(0,s.a_)(),c=e=>{const n=e.currentTarget,o=a.indexOf(n),s=l[o].value;s!==t&&(i(n),r(s))},d=e=>{let n=null;switch(e.key){case"Enter":c(e);break;case"ArrowRight":{const t=a.indexOf(e.currentTarget)+1;n=a[t]??a[0];break}case"ArrowLeft":{const t=a.indexOf(e.currentTarget)-1;n=a[t]??a[a.length-1];break}}n?.focus()};return(0,v.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,o.A)("tabs",{"tabs--block":n},e),children:l.map(({value:e,label:n,attributes:r})=>(0,v.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{a.push(e)},onKeyDown:d,onClick:c,...r,className:(0,o.A)("tabs__item",b.tabItem,r?.className,{"tabs__item--active":t===e}),children:n??e},e))})}function x({lazy:e,children:n,selectedValue:t}){const s=(Array.isArray(n)?n:[n]).filter(Boolean);if(e){const e=s.find(e=>e.props.value===t);return e?(0,r.cloneElement)(e,{className:(0,o.A)("margin-top--md",e.props.className)}):null}return(0,v.jsx)("div",{className:"margin-top--md",children:s.map((e,n)=>(0,r.cloneElement)(e,{key:n,hidden:e.props.value!==t}))})}function w(e){const n=m(e);return(0,v.jsxs)("div",{className:(0,o.A)("tabs-container",b.tabList),children:[(0,v.jsx)(y,{...n,...e}),(0,v.jsx)(x,{...n,...e})]})}function j(e){const n=(0,g.A)();return(0,v.jsx)(w,{...e,children:u(e.children)},String(n))}},19365:(e,n,t)=>{t.d(n,{A:()=>l});t(96540);var r=t(18215);const o={tabItem:"tabItem_Ymn6"};var s=t(74848);function l({children:e,hidden:n,className:t}){return(0,s.jsx)("div",{role:"tabpanel",className:(0,r.A)(o.tabItem,t),hidden:n,children:e})}},26023:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/langflow-env-f22dcd672ba806af9fec3968171a4700.png"},28453:(e,n,t)=>{t.d(n,{R:()=>l,x:()=>a});var r=t(96540);const o={},s=r.createContext(o);function l(e){const n=r.useContext(s);return r.useMemo(function(){return"function"==typeof e?e(n):{...n,...e}},[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:l(e.components),r.createElement(s.Provider,{value:n},e.children)}},48109:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/langflow-reference-architecture-49ff76b7f84ce43f5626edd5cb3fa7fa.png"}}]); \ No newline at end of file diff --git a/assets/js/db4f3bbd.b937b0b2.js b/assets/js/db4f3bbd.b937b0b2.js new file mode 100644 index 0000000000..607392a0cd --- /dev/null +++ b/assets/js/db4f3bbd.b937b0b2.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[598],{11470:(e,o,t)=>{t.d(o,{A:()=>w});var n=t(96540),s=t(18215),l=t(23104),r=t(56347),c=t(205),a=t(57485),i=t(31682),d=t(70679);function p(e){return n.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,n.isValidElement)(e)&&function(e){const{props:o}=e;return!!o&&"object"==typeof o&&"value"in o}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function h(e){const{values:o,children:t}=e;return(0,n.useMemo)(()=>{const e=o??function(e){return p(e).map(({props:{value:e,label:o,attributes:t,default:n}})=>({value:e,label:o,attributes:t,default:n}))}(t);return function(e){const o=(0,i.XI)(e,(e,o)=>e.value===o.value);if(o.length>0)throw new Error(`Docusaurus error: Duplicate values "${o.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[o,t])}function u({value:e,tabValues:o}){return o.some(o=>o.value===e)}function f({queryString:e=!1,groupId:o}){const t=(0,r.W6)(),s=function({queryString:e=!1,groupId:o}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!o)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return o??null}({queryString:e,groupId:o});return[(0,a.aZ)(s),(0,n.useCallback)(e=>{if(!s)return;const o=new URLSearchParams(t.location.search);o.set(s,e),t.replace({...t.location,search:o.toString()})},[s,t])]}function m(e){const{defaultValue:o,queryString:t=!1,groupId:s}=e,l=h(e),[r,a]=(0,n.useState)(()=>function({defaultValue:e,tabValues:o}){if(0===o.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!u({value:e,tabValues:o}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${o.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=o.find(e=>e.default)??o[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:o,tabValues:l})),[i,p]=f({queryString:t,groupId:s}),[m,y]=function({groupId:e}){const o=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,s]=(0,d.Dv)(o);return[t,(0,n.useCallback)(e=>{o&&s.set(e)},[o,s])]}({groupId:s}),g=(()=>{const e=i??m;return u({value:e,tabValues:l})?e:null})();(0,c.A)(()=>{g&&a(g)},[g]);return{selectedValue:r,selectValue:(0,n.useCallback)(e=>{if(!u({value:e,tabValues:l}))throw new Error(`Can't select invalid tab value=${e}`);a(e),p(e),y(e)},[p,y,l]),tabValues:l}}var y=t(92303);const g={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var F=t(74848);function b({className:e,block:o,selectedValue:t,selectValue:n,tabValues:r}){const c=[],{blockElementScrollPositionUntilNextRender:a}=(0,l.a_)(),i=e=>{const o=e.currentTarget,s=c.indexOf(o),l=r[s].value;l!==t&&(a(o),n(l))},d=e=>{let o=null;switch(e.key){case"Enter":i(e);break;case"ArrowRight":{const t=c.indexOf(e.currentTarget)+1;o=c[t]??c[0];break}case"ArrowLeft":{const t=c.indexOf(e.currentTarget)-1;o=c[t]??c[c.length-1];break}}o?.focus()};return(0,F.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,s.A)("tabs",{"tabs--block":o},e),children:r.map(({value:e,label:o,attributes:n})=>(0,F.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{c.push(e)},onKeyDown:d,onClick:i,...n,className:(0,s.A)("tabs__item",g.tabItem,n?.className,{"tabs__item--active":t===e}),children:o??e},e))})}function x({lazy:e,children:o,selectedValue:t}){const l=(Array.isArray(o)?o:[o]).filter(Boolean);if(e){const e=l.find(e=>e.props.value===t);return e?(0,n.cloneElement)(e,{className:(0,s.A)("margin-top--md",e.props.className)}):null}return(0,F.jsx)("div",{className:"margin-top--md",children:l.map((e,o)=>(0,n.cloneElement)(e,{key:o,hidden:e.props.value!==t}))})}function v(e){const o=m(e);return(0,F.jsxs)("div",{className:(0,s.A)("tabs-container",g.tabList),children:[(0,F.jsx)(b,{...o,...e}),(0,F.jsx)(x,{...o,...e})]})}function w(e){const o=(0,y.A)();return(0,F.jsx)(v,{...e,children:p(e.children)},String(o))}},19365:(e,o,t)=>{t.d(o,{A:()=>r});t(96540);var n=t(18215);const s={tabItem:"tabItem_Ymn6"};var l=t(74848);function r({children:e,hidden:o,className:t}){return(0,l.jsx)("div",{role:"tabpanel",className:(0,n.A)(s.tabItem,t),hidden:o,children:e})}},28453:(e,o,t)=>{t.d(o,{R:()=>r,x:()=>c});var n=t(96540);const s={},l=n.createContext(s);function r(e){const o=n.useContext(l);return n.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function c(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:r(e.components),n.createElement(l.Provider,{value:o},e.children)}},74598:(e,o,t)=>{t.r(o),t.d(o,{CH:()=>h,assets:()=>p,chCodeConfig:()=>u,contentTitle:()=>d,default:()=>y,frontMatter:()=>i,metadata:()=>n,toc:()=>f});const n=JSON.parse('{"id":"Deployment/deployment-kubernetes-prod","title":"Deploy the Langflow production environment on Kubernetes","description":"The Langflow runtime Helm chart is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently.","source":"@site/docs/Deployment/deployment-kubernetes-prod.mdx","sourceDirName":"Deployment","slug":"/deployment-kubernetes-prod","permalink":"/deployment-kubernetes-prod","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy the Langflow production environment on Kubernetes","slug":"/deployment-kubernetes-prod"},"sidebar":"docs","previous":{"title":"Deploy in development","permalink":"/deployment-kubernetes-dev"},"next":{"title":"Google Cloud Platform","permalink":"/deployment-gcp"}}');var s=t(74848),l=t(28453),r=t(24754),c=t(11470),a=t(19365);const i={title:"Deploy the Langflow production environment on Kubernetes",slug:"/deployment-kubernetes-prod"},d=void 0,p={},h={annotations:r.hk,Code:r.Cy},u={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},f=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Install the Langflow runtime Helm chart",id:"install-the-langflow-runtime-helm-chart",level:2},{value:"Access the Langflow runtime",id:"access-the-langflow-runtime",level:2},{value:"Configure secrets and environment variables",id:"configure-secrets-and-environment-variables",level:2},{value:"Set secrets",id:"set-secrets",level:3},{value:"Set the log level and other configuration variables",id:"set-the-log-level-and-other-configuration-variables",level:3},{value:"Configure scaling",id:"configure-scaling",level:2},{value:"See also",id:"see-also",level:2}];function m(e){const o={a:"a",admonition:"admonition",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,l.R)(),...e.components},{Details:t}=o;return h||g("CH",!1),h.Code||g("CH.Code",!0),t||g("Details",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsxs)(o.p,{children:["The ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime",children:"Langflow runtime Helm chart"})," is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently."]}),"\n",(0,s.jsxs)(o.admonition,{type:"important",children:[(0,s.jsxs)(o.p,{children:["For security reasons, the default Langflow runtime Helm chart sets ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml#L46",children:(0,s.jsx)(o.code,{children:"readOnlyRootFilesystem: true"})}),". This setting prevents modifications to the container's root filesystem at runtime, which is a recommended security measure in production environments."]}),(0,s.jsxs)(o.p,{children:["If ",(0,s.jsx)(o.code,{children:"readOnlyRootFilesystem"})," is disabled (",(0,s.jsx)(o.code,{children:"false"}),"), it degrades your deployment's security posture. Only disable this setting if you understand the security implications and you have implemented other security measures."]}),(0,s.jsxs)(o.p,{children:["For more information, see the ",(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/configure-pod-container/security-context/",children:"Kubernetes documentation"}),"."]})]}),"\n",(0,s.jsx)(o.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["A ",(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/setup/",children:"Kubernetes"})," server"]}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/tools/#kubectl",children:"kubectl"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://helm.sh/docs/intro/install/",children:"Helm"})}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"install-the-langflow-runtime-helm-chart",children:"Install the Langflow runtime Helm chart"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Add the repository to Helm:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo add langflow https://langflow-ai.github.io/langflow-helm-charts",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo update",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Install the Langflow app with the default options in the ",(0,s.jsx)(o.code,{children:"langflow"})," namespace."]}),"\n",(0,s.jsxs)(c.A,{groupId:"",children:[(0,s.jsxs)(a.A,{value:"Install chart with custom image",label:"Install chart with custom image",default:!0,children:[(0,s.jsxs)(o.p,{children:["If you have a ",(0,s.jsx)(o.a,{href:"/deployment-docker#package-your-flow-as-a-docker-image",children:"custom image with packaged flows"}),", you can deploy Langflow by overriding the default ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:(0,s.jsx)(o.code,{children:"values.yaml"})})," with the ",(0,s.jsx)(o.code,{children:"--set"})," flag:"]}),(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install my-langflow-app langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"--create-namespace --set ",props:{style:{color:"#79C0FF"}}},{content:"image.repository=myuser/langflow-hello-world ",props:{style:{color:"#A5D6FF"}}},{content:"--set ",props:{style:{color:"#79C0FF"}}},{content:"image.tag=",props:{style:{color:"#A5D6FF"}}},{content:"1.0.0",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]})]}),(0,s.jsxs)(a.A,{value:"Install chart and download flow",label:"Install chart and download flow",children:[(0,s.jsxs)(o.p,{children:["Install the chart and download flows from a URL with the ",(0,s.jsx)(o.code,{children:"--set"})," flag:"]}),(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install my-langflow-app-with-flow langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --create-namespace \\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:"'downloadFlows.flows[0].url=https://raw.githubusercontent.com/langflow-ai/langflow/dev/tests/data/basic_example.json'",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),(0,s.jsxs)(o.p,{children:["If your shell requires escaping square brackets, modify the ",(0,s.jsx)(o.code,{children:"--set"})," path as needed.\nFor example, ",(0,s.jsx)(o.code,{children:"--set 'downloadFlows.flows\\[0\\].url=https://raw.githubusercontent.com/langflow-ai/langflow/dev/tests/data/basic_example.json'"}),"."]})]})]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Check the status of the pods:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get pods ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"access-the-langflow-runtime",children:"Access the Langflow runtime"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Get your service name:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get svc ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsxs)(o.p,{children:["The service name is your release name suffixed by ",(0,s.jsx)(o.code,{children:"-langflow-runtime"}),". For example, if you used ",(0,s.jsx)(o.code,{children:"helm install my-langflow-app-with-flow"}),", then the service name is ",(0,s.jsx)(o.code,{children:"my-langflow-app-with-flow-langflow-runtime"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Enable port forwarding to access Langflow from your local machine:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/my-langflow-app-with-flow-langflow-runtime 7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Confirm you can access the API by calling ",(0,s.jsx)(o.code,{children:"http://localhost:7860/api/v1/flows/"}),":"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-v ",props:{style:{color:"#79C0FF"}}},{content:"http://localhost:7860/api/v1/flows/",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"A successful request returns a list of flows."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Run a packaged flow.\nThe following example gets the first flow ID from the flows list, and then runs the flow:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"# Get flow ID",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"id",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"$(",props:{style:{color:"#A5D6FF"}}},{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-s",props:{style:{color:"#79C0FF"}}},{content:' "http://localhost:7860/api/v1/flows/" ',props:{style:{color:"#A5D6FF"}}},{content:"| ",props:{style:{color:"#FF7B72"}}},{content:"jq ",props:{style:{color:"#FFA657"}}},{content:"-r",props:{style:{color:"#79C0FF"}}},{content:" '.[0].id')",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Run flow",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-X ",props:{style:{color:"#79C0FF"}}},{content:"POST ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:' "http://localhost:7860/api/v1/run/',props:{style:{color:"#A5D6FF"}}},{content:"$id",props:{style:{color:"#C9D1D9"}}},{content:'?stream=false" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -H ",props:{style:{color:"#79C0FF"}}},{content:"'Content-Type: application/json' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -d ",props:{style:{color:"#79C0FF"}}},{content:"'{",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_value": "Hello!",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "output_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_type": "chat"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" }'",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"configure-secrets-and-environment-variables",children:"Configure secrets and environment variables"}),"\n",(0,s.jsxs)(o.p,{children:["Use the ",(0,s.jsx)(o.code,{children:".env"})," section of the Langflow runtime Helm chart's ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:(0,s.jsx)(o.code,{children:"values.yaml"})})," file to define environment variables for your Langflow deployment.\nThis includes built-in ",(0,s.jsx)(o.a,{href:"/environment-variables",children:"Langflow environment variables"}),", as well as ",(0,s.jsx)(o.a,{href:"/configuration-global-variables",children:"global variables"})," used by your flows."]}),"\n",(0,s.jsxs)(o.p,{children:["Langflow can source global variables from your runtime environment, such as Kubernetes secrets referenced in ",(0,s.jsx)(o.code,{children:"values.yaml"}),".\nFor example, the Langflow runtime Helm chart's ",(0,s.jsx)(o.a,{href:"https://raw.githubusercontent.com/langflow-ai/langflow-helm-charts/refs/heads/main/examples/flows/basic-prompting-hello-world.json",children:"example flow JSON"})," uses a global variable that is a secret.\nIf you want to run this flow in your Langflow deployment on Kubernetes, you need to include the secret in your runtime configuration."]}),"\n",(0,s.jsx)(o.admonition,{type:"tip",children:(0,s.jsxs)(o.p,{children:["When you export flows as JSON files, it's recommended to omit secrets.\nWhether or not a secret is included depends on how you declare the secret in your flow and whether you use the ",(0,s.jsx)(o.strong,{children:"Save with my API keys"})," option.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/concepts-flows-import",children:"Import and export flows"}),"."]})}),"\n",(0,s.jsx)(o.h3,{id:"set-secrets",children:"Set secrets"}),"\n",(0,s.jsx)(o.p,{children:"Kubernetes secrets are the recommended way to store sensitive values and credentials."}),"\n",(0,s.jsxs)(o.p,{children:["Use ",(0,s.jsx)(o.code,{children:"secretKeyRef"})," to reference a Kubernetes secret in ",(0,s.jsx)(o.code,{children:"values.yaml"}),":"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"OPENAI_API_KEY",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" valueFrom",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" secretKeyRef",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai-credentials",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" key",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai-key",props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsxs)(t,{children:[(0,s.jsxs)("summary",{children:["Create and set secrets with ",(0,s.jsx)(o.code,{children:"kubectl"})," and ",(0,s.jsx)(o.code,{children:"helm"})]}),(0,s.jsxs)(o.p,{children:["You can use ",(0,s.jsx)(o.code,{children:"kubectl"})," and ",(0,s.jsx)(o.code,{children:"helm"})," commands to create and set secrets:"]}),(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Create a secret:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"create secret generic openai-credentials ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --namespace ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --from-literal=OPENAI_API_KEY=sk...",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Verify the secret exists:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get secrets ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow openai-credentials",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"The result is encrypted."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Upgrade the Helm release to use the secret:"}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"upgrade my-langflow-app-image langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --reuse-values \\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].name=OPENAI_API_KEY" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].valueFrom.secretKeyRef.name=openai-credentials" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].valueFrom.secretKeyRef.key=OPENAI_API_KEY"',props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,s.jsx)(o.p,{children:"Escape square brackets if required by your shell."}),"\n"]}),"\n"]})]}),"\n",(0,s.jsx)(o.h3,{id:"set-the-log-level-and-other-configuration-variables",children:"Set the log level and other configuration variables"}),"\n",(0,s.jsxs)(o.p,{children:["For non-sensitive variables, such as ",(0,s.jsx)(o.code,{children:"LANGFLOW_LOG_LEVEL"}),", you can set the value directly in ",(0,s.jsx)(o.code,{children:"values.yaml"}),":"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_LOG_LEVEL",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"INFO"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,s.jsx)(o.h2,{id:"configure-scaling",children:"Configure scaling"}),"\n",(0,s.jsxs)(o.p,{children:["Use ",(0,s.jsx)(o.code,{children:"replicaCount"})," and ",(0,s.jsx)(o.code,{children:"resources"})," in the Langflow runtime Helm chart's ",(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:(0,s.jsx)(o.code,{children:"values.yaml"})})," file to configure scaling:"]}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:[(0,s.jsx)(o.strong,{children:"Horizontal scaling"}),": Use ",(0,s.jsx)(o.code,{children:"replicaCount"})," to set the number of replicas for your Langflow deployment."]}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"3",props:{style:{color:"#79C0FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:[(0,s.jsx)(o.strong,{children:"Vertical scaling"}),": Use the ",(0,s.jsx)(o.code,{children:"resources"})," section to adjust pod resources depending on your application's needs."]}),"\n",(0,s.jsx)(h.Code,{codeConfig:u,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"2Gi"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1000m"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-prod-best-practices",children:"Best practices for Langflow on Kubernetes"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm Charts repository"})}),"\n"]})]})}function y(e={}){const{wrapper:o}={...(0,l.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(m,{...e})}):m(e)}function g(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/db4f3bbd.f25781b8.js b/assets/js/db4f3bbd.f25781b8.js deleted file mode 100644 index 26b5359800..0000000000 --- a/assets/js/db4f3bbd.f25781b8.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[598],{11470:(e,o,t)=>{t.d(o,{A:()=>x});var n=t(96540),l=t(18215),s=t(23104),r=t(56347),c=t(205),a=t(57485),i=t(31682),p=t(70679);function h(e){return n.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,n.isValidElement)(e)&&function(e){const{props:o}=e;return!!o&&"object"==typeof o&&"value"in o}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function u(e){const{values:o,children:t}=e;return(0,n.useMemo)(()=>{const e=o??function(e){return h(e).map(({props:{value:e,label:o,attributes:t,default:n}})=>({value:e,label:o,attributes:t,default:n}))}(t);return function(e){const o=(0,i.XI)(e,(e,o)=>e.value===o.value);if(o.length>0)throw new Error(`Docusaurus error: Duplicate values "${o.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[o,t])}function d({value:e,tabValues:o}){return o.some(o=>o.value===e)}function f({queryString:e=!1,groupId:o}){const t=(0,r.W6)(),l=function({queryString:e=!1,groupId:o}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!o)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return o??null}({queryString:e,groupId:o});return[(0,a.aZ)(l),(0,n.useCallback)(e=>{if(!l)return;const o=new URLSearchParams(t.location.search);o.set(l,e),t.replace({...t.location,search:o.toString()})},[l,t])]}function m(e){const{defaultValue:o,queryString:t=!1,groupId:l}=e,s=u(e),[r,a]=(0,n.useState)(()=>function({defaultValue:e,tabValues:o}){if(0===o.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!d({value:e,tabValues:o}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${o.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const t=o.find(e=>e.default)??o[0];if(!t)throw new Error("Unexpected error: 0 tabValues");return t.value}({defaultValue:o,tabValues:s})),[i,h]=f({queryString:t,groupId:l}),[m,y]=function({groupId:e}){const o=function(e){return e?`docusaurus.tab.${e}`:null}(e),[t,l]=(0,p.Dv)(o);return[t,(0,n.useCallback)(e=>{o&&l.set(e)},[o,l])]}({groupId:l}),g=(()=>{const e=i??m;return d({value:e,tabValues:s})?e:null})();(0,c.A)(()=>{g&&a(g)},[g]);return{selectedValue:r,selectValue:(0,n.useCallback)(e=>{if(!d({value:e,tabValues:s}))throw new Error(`Can't select invalid tab value=${e}`);a(e),h(e),y(e)},[h,y,s]),tabValues:s}}var y=t(92303);const g={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var F=t(74848);function b({className:e,block:o,selectedValue:t,selectValue:n,tabValues:r}){const c=[],{blockElementScrollPositionUntilNextRender:a}=(0,s.a_)(),i=e=>{const o=e.currentTarget,l=c.indexOf(o),s=r[l].value;s!==t&&(a(o),n(s))},p=e=>{let o=null;switch(e.key){case"Enter":i(e);break;case"ArrowRight":{const t=c.indexOf(e.currentTarget)+1;o=c[t]??c[0];break}case"ArrowLeft":{const t=c.indexOf(e.currentTarget)-1;o=c[t]??c[c.length-1];break}}o?.focus()};return(0,F.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,l.A)("tabs",{"tabs--block":o},e),children:r.map(({value:e,label:o,attributes:n})=>(0,F.jsx)("li",{role:"tab",tabIndex:t===e?0:-1,"aria-selected":t===e,ref:e=>{c.push(e)},onKeyDown:p,onClick:i,...n,className:(0,l.A)("tabs__item",g.tabItem,n?.className,{"tabs__item--active":t===e}),children:o??e},e))})}function w({lazy:e,children:o,selectedValue:t}){const s=(Array.isArray(o)?o:[o]).filter(Boolean);if(e){const e=s.find(e=>e.props.value===t);return e?(0,n.cloneElement)(e,{className:(0,l.A)("margin-top--md",e.props.className)}):null}return(0,F.jsx)("div",{className:"margin-top--md",children:s.map((e,o)=>(0,n.cloneElement)(e,{key:o,hidden:e.props.value!==t}))})}function v(e){const o=m(e);return(0,F.jsxs)("div",{className:(0,l.A)("tabs-container",g.tabList),children:[(0,F.jsx)(b,{...o,...e}),(0,F.jsx)(w,{...o,...e})]})}function x(e){const o=(0,y.A)();return(0,F.jsx)(v,{...e,children:h(e.children)},String(o))}},19365:(e,o,t)=>{t.d(o,{A:()=>r});t(96540);var n=t(18215);const l={tabItem:"tabItem_Ymn6"};var s=t(74848);function r({children:e,hidden:o,className:t}){return(0,s.jsx)("div",{role:"tabpanel",className:(0,n.A)(l.tabItem,t),hidden:o,children:e})}},28453:(e,o,t)=>{t.d(o,{R:()=>r,x:()=>c});var n=t(96540);const l={},s=n.createContext(l);function r(e){const o=n.useContext(s);return n.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function c(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:r(e.components),n.createElement(s.Provider,{value:o},e.children)}},74598:(e,o,t)=>{t.r(o),t.d(o,{CH:()=>u,assets:()=>h,chCodeConfig:()=>d,contentTitle:()=>p,default:()=>y,frontMatter:()=>i,metadata:()=>n,toc:()=>f});const n=JSON.parse('{"id":"Deployment/deployment-kubernetes-prod","title":"Deploy the Langflow production environment on Kubernetes","description":"The Langflow Runtime chart is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently.","source":"@site/docs/Deployment/deployment-kubernetes-prod.mdx","sourceDirName":"Deployment","slug":"/deployment-kubernetes-prod","permalink":"/deployment-kubernetes-prod","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Deploy the Langflow production environment on Kubernetes","slug":"/deployment-kubernetes-prod"},"sidebar":"docs","previous":{"title":"Deploy in development","permalink":"/deployment-kubernetes-dev"},"next":{"title":"Google Cloud Platform","permalink":"/deployment-gcp"}}');var l=t(74848),s=t(28453),r=t(24754),c=t(11470),a=t(19365);const i={title:"Deploy the Langflow production environment on Kubernetes",slug:"/deployment-kubernetes-prod"},p=void 0,h={},u={annotations:r.hk,Code:r.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},f=[{value:"Prerequisites",id:"prerequisites",level:3},{value:"Install the Langflow runtime Helm chart",id:"install-the-langflow-runtime-helm-chart",level:3},{value:"Access the Langflow runtime",id:"access-the-langflow-runtime",level:3},{value:"Configure secrets",id:"configure-secrets",level:3},{value:"Configure the log level",id:"configure-the-log-level",level:3},{value:"Configure scaling",id:"configure-scaling",level:3}];function m(e){const o={a:"a",admonition:"admonition",code:"code",h3:"h3",li:"li",ol:"ol",p:"p",ul:"ul",...(0,s.R)(),...e.components};return u||g("CH",!1),u.Code||g("CH.Code",!0),(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,l.jsxs)(o.p,{children:["The ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime",children:"Langflow Runtime"})," chart is tailored for deploying applications in a production environment. It is focused on stability, performance, isolation, and security to ensure that applications run reliably and efficiently."]}),"\n",(0,l.jsxs)(o.admonition,{type:"important",children:[(0,l.jsxs)(o.p,{children:["By default, the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml#L46",children:"Langflow runtime Helm chart"})," enables ",(0,l.jsx)(o.code,{children:"readOnlyRootFilesystem: true"})," as a security best practice. This setting prevents modifications to the container's root filesystem at runtime, which is a recommended security measure in production environments."]}),(0,l.jsxs)(o.p,{children:["Disabling ",(0,l.jsx)(o.code,{children:"readOnlyRootFilesystem"})," reduces the security of your deployment. Only disable this setting if you understand the security implications and have implemented other security measures."]}),(0,l.jsxs)(o.p,{children:["For more information, see the ",(0,l.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/configure-pod-container/security-context/",children:"Kubernetes documentation"}),"."]})]}),"\n",(0,l.jsx)(o.h3,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,l.jsxs)(o.ul,{children:["\n",(0,l.jsxs)(o.li,{children:["A ",(0,l.jsx)(o.a,{href:"https://kubernetes.io/docs/setup/",children:"Kubernetes"})," server"]}),"\n",(0,l.jsx)(o.li,{children:(0,l.jsx)(o.a,{href:"https://kubernetes.io/docs/tasks/tools/#kubectl",children:"kubectl"})}),"\n",(0,l.jsx)(o.li,{children:(0,l.jsx)(o.a,{href:"https://helm.sh/docs/intro/install/",children:"Helm"})}),"\n"]}),"\n",(0,l.jsx)(o.h3,{id:"install-the-langflow-runtime-helm-chart",children:"Install the Langflow runtime Helm chart"}),"\n",(0,l.jsxs)(o.ol,{children:["\n",(0,l.jsx)(o.li,{children:"Add the repository to Helm."}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo add langflow https://langflow-ai.github.io/langflow-helm-charts",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"repo update",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.ol,{start:"2",children:["\n",(0,l.jsxs)(o.li,{children:["Install the Langflow app with the default options in the ",(0,l.jsx)(o.code,{children:"langflow"})," namespace."]}),"\n"]}),"\n",(0,l.jsxs)(o.p,{children:["If you have a created a ",(0,l.jsx)(o.a,{href:"/deployment-docker#package-your-flow-as-a-docker-image",children:"custom image with packaged flows"}),", you can deploy Langflow by overriding the default ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:"values.yaml"})," file with the ",(0,l.jsx)(o.code,{children:"--set"})," flag."]}),"\n",(0,l.jsxs)(o.ul,{children:["\n",(0,l.jsx)(o.li,{children:"Use a custom image with bundled flows:"}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install my-langflow-app langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"--create-namespace --set ",props:{style:{color:"#79C0FF"}}},{content:"image.repository=myuser/langflow-hello-world ",props:{style:{color:"#A5D6FF"}}},{content:"--set ",props:{style:{color:"#79C0FF"}}},{content:"image.tag=",props:{style:{color:"#A5D6FF"}}},{content:"1.0.0",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.ul,{children:["\n",(0,l.jsxs)(o.li,{children:["Alternatively, install the chart and download the flows from a URL with the ",(0,l.jsx)(o.code,{children:"--set"})," flag:"]}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install my-langflow-app-with-flow langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --create-namespace \\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:"'downloadFlows.flows[0].url=https://raw.githubusercontent.com/langflow-ai/langflow/dev/tests/data/basic_example.json'",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.admonition,{type:"important",children:[(0,l.jsx)(o.p,{children:"You may need to escape the square brackets in this command if you are using a shell that requires it:"}),(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"install my-langflow-app-with-flow langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --create-namespace \\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:"'downloadFlows.flows\\[0\\].url=https://raw.githubusercontent.com/langflow-ai/langflow/dev/tests/data/basic_example.json'",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]})]}),"\n",(0,l.jsxs)(o.ol,{start:"3",children:["\n",(0,l.jsx)(o.li,{children:"Check the status of the pods."}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get pods ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsx)(o.h3,{id:"access-the-langflow-runtime",children:"Access the Langflow runtime"}),"\n",(0,l.jsxs)(o.ol,{children:["\n",(0,l.jsx)(o.li,{children:"Get your service name."}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get svc ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.p,{children:["The service name is your release name followed by ",(0,l.jsx)(o.code,{children:"-langflow-runtime"}),". For example, if you used ",(0,l.jsx)(o.code,{children:"helm install my-langflow-app-with-flow"})," the service name is ",(0,l.jsx)(o.code,{children:"my-langflow-app-with-flow-langflow-runtime"}),"."]}),"\n",(0,l.jsxs)(o.ol,{start:"2",children:["\n",(0,l.jsx)(o.li,{children:"Enable port forwarding to access Langflow from your local machine:"}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"port-forward ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow svc/my-langflow-app-with-flow-langflow-runtime 7860:",props:{style:{color:"#A5D6FF"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.ol,{start:"3",children:["\n",(0,l.jsxs)(o.li,{children:["Confirm you can access the API at ",(0,l.jsx)(o.code,{children:"http://localhost:7860/api/v1/flows/"})," and view a list of flows."]}),"\n"]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-v ",props:{style:{color:"#79C0FF"}}},{content:"http://localhost:7860/api/v1/flows/",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsxs)(o.ol,{start:"4",children:["\n",(0,l.jsx)(o.li,{children:"Execute the packaged flow."}),"\n"]}),"\n",(0,l.jsx)(o.p,{children:"The following command gets the first flow ID from the flows list and runs the flow."}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"# Get flow ID",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"id",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"$(",props:{style:{color:"#A5D6FF"}}},{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-s",props:{style:{color:"#79C0FF"}}},{content:' "http://localhost:7860/api/v1/flows/" ',props:{style:{color:"#A5D6FF"}}},{content:"| ",props:{style:{color:"#FF7B72"}}},{content:"jq ",props:{style:{color:"#FFA657"}}},{content:"-r",props:{style:{color:"#79C0FF"}}},{content:" '.[0].id')",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"# Run flow",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:"curl ",props:{style:{color:"#FFA657"}}},{content:"-X ",props:{style:{color:"#79C0FF"}}},{content:"POST ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:' "http://localhost:7860/api/v1/run/',props:{style:{color:"#A5D6FF"}}},{content:"$id",props:{style:{color:"#C9D1D9"}}},{content:'?stream=false" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -H ",props:{style:{color:"#79C0FF"}}},{content:"'Content-Type: application/json' ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" -d ",props:{style:{color:"#79C0FF"}}},{content:"'{",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_value": "Hello!",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "output_type": "chat",',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:' "input_type": "chat"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" }'",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n",(0,l.jsx)(o.h3,{id:"configure-secrets",children:"Configure secrets"}),"\n",(0,l.jsxs)(o.p,{children:["To inject secrets and Langflow global variables, use the ",(0,l.jsx)(o.code,{children:"secrets"})," and ",(0,l.jsx)(o.code,{children:"env"})," sections in the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:"values.yaml"})," file."]}),"\n",(0,l.jsxs)(o.p,{children:["For example, the ",(0,l.jsx)(o.a,{href:"https://raw.githubusercontent.com/langflow-ai/langflow-helm-charts/refs/heads/main/examples/flows/basic-prompting-hello-world.json",children:"example flow JSON"})," uses a global variable that is a secret. When you export the flow as JSON, it's recommended to not include the secret."]}),"\n",(0,l.jsx)(o.p,{children:"Instead, when importing the flow in the Langflow runtime, you can set the global variable in one of the following ways:"}),"\n",(0,l.jsxs)(c.A,{children:[(0,l.jsxs)(a.A,{value:"values",label:"values.yaml",children:[(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai_key_var",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" valueFrom",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" secretKeyRef",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai-key",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" key",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai-key",props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),(0,l.jsx)(o.p,{children:"Or directly in the values file (not recommended for secret values):"}),(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"openai_key_var",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"sk-...."',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]})]}),(0,l.jsxs)(a.A,{value:"helm",label:"Helm commands",children:[(0,l.jsxs)(o.ol,{children:["\n",(0,l.jsx)(o.li,{children:"Create the secret:"}),"\n"]}),(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"create secret generic openai-credentials ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --namespace ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --from-literal=OPENAI_API_KEY=sk...",props:{style:{color:"#79C0FF"}}}]}],lang:"shell"},annotations:[]}]}),(0,l.jsxs)(o.ol,{start:"2",children:["\n",(0,l.jsx)(o.li,{children:"Verify the secret exists. The result is encrypted."}),"\n"]}),(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"kubectl ",props:{style:{color:"#FFA657"}}},{content:"get secrets ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow openai-credentials",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),(0,l.jsxs)(o.ol,{start:"3",children:["\n",(0,l.jsx)(o.li,{children:"Upgrade the Helm release to use the secret."}),"\n"]}),(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"helm ",props:{style:{color:"#FFA657"}}},{content:"upgrade my-langflow-app-image langflow/langflow-runtime ",props:{style:{color:"#A5D6FF"}}},{content:"-n ",props:{style:{color:"#79C0FF"}}},{content:"langflow ",props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --reuse-values \\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].name=OPENAI_API_KEY" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].valueFrom.secretKeyRef.name=openai-credentials" ',props:{style:{color:"#A5D6FF"}}},{content:"\\",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" --set ",props:{style:{color:"#79C0FF"}}},{content:'"extraEnv[0].valueFrom.secretKeyRef.key=OPENAI_API_KEY"',props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]})]})]}),"\n",(0,l.jsx)(o.h3,{id:"configure-the-log-level",children:"Configure the log level"}),"\n",(0,l.jsxs)(o.p,{children:["Set the log level and other Langflow configurations in the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:"values.yaml"})," file."]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_LOG_LEVEL",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"INFO"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,l.jsx)(o.h3,{id:"configure-scaling",children:"Configure scaling"}),"\n",(0,l.jsxs)(o.p,{children:["To scale the number of replicas for the Langflow appplication, change the ",(0,l.jsx)(o.code,{children:"replicaCount"})," value in the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:"values.yaml"})," file."]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"replicaCount",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"3",props:{style:{color:"#79C0FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,l.jsxs)(o.p,{children:["To scale the application vertically by increasing the resources for the pods, change the ",(0,l.jsx)(o.code,{children:"resources"})," values in the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts/blob/main/charts/langflow-runtime/values.yaml",children:"values.yaml"})," file."]}),"\n",(0,l.jsx)(u.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"resources",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" requests",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" memory",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"2Gi"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" cpu",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"1000m"',props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]}),"\n",(0,l.jsxs)(o.p,{children:["For more information about deploying Langflow on AWS EKS, Google GKE, or Azure AKS, see the ",(0,l.jsx)(o.a,{href:"https://github.com/langflow-ai/langflow-helm-charts",children:"Langflow Helm Charts repository"}),"."]})]})}function y(e={}){const{wrapper:o}={...(0,s.R)(),...e.components};return o?(0,l.jsx)(o,{...e,children:(0,l.jsx)(m,{...e})}):m(e)}function g(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/e6c6a4d2.7d1513d4.js b/assets/js/e6c6a4d2.109611fc.js similarity index 56% rename from assets/js/e6c6a4d2.7d1513d4.js rename to assets/js/e6c6a4d2.109611fc.js index 285ce5a4c9..b2a9ebeb80 100644 --- a/assets/js/e6c6a4d2.7d1513d4.js +++ b/assets/js/e6c6a4d2.109611fc.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8504],{28453:(e,t,n)=>{n.d(t,{R:()=>a,x:()=>l});var s=n(96540);const i={},o=s.createContext(i);function a(e){const t=s.useContext(o);return s.useMemo(function(){return"function"==typeof e?e(t):{...t,...e}},[t,e])}function l(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:a(e.components),s.createElement(o.Provider,{value:t},e.children)}},94910:(e,t,n)=>{n.r(t),n.d(t,{contentTitle:()=>l,default:()=>d,frontMatter:()=>a,metadata:()=>s,toc:()=>r});const s=JSON.parse('{"type":"api","id":"experimental-run-flow","title":"Experimental Run Flow","description":"","slug":"/experimental-run-flow","frontMatter":{},"api":{"tags":["Base"],"description":"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability.\\n\\nThis endpoint supports running flows with caching to enhance performance and efficiency.\\n\\n### Parameters:\\n- `flow_id` (str): The unique identifier of the flow to be executed.\\n- `inputs` (List[InputValueRequest], optional): A list of inputs specifying the input values and components\\n for the flow. Each input can target specific components and provide custom values.\\n- `outputs` (List[str], optional): A list of output names to retrieve from the executed flow.\\n If not provided, all outputs are returned.\\n- `tweaks` (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\\n The tweaks can be used to modify the flow\'s parameters and components.\\n Tweaks can be overridden by the input values.\\n- `stream` (bool, optional): Specifies whether the results should be streamed. Defaults to False.\\n- `session_id` (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\\n execution.\\n- `api_key_user` (User): The user associated with the current API key. Automatically resolved from the API key.\\n\\n### Returns:\\nA `RunResponse` object containing the selected outputs (or all if not specified) of the executed flow\\nand the session ID.\\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input.\\n\\n### Raises:\\nHTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\\nflow execution.\\n\\n### Example usage:\\n```json\\nPOST /run/flow_id\\nx-api-key: YOUR_API_KEY\\nPayload:\\n{\\n \\"inputs\\": [\\n {\\"components\\": [\\"component1\\"], \\"input_value\\": \\"value1\\"},\\n {\\"components\\": [\\"component3\\"], \\"input_value\\": \\"value2\\"}\\n ],\\n \\"outputs\\": [\\"Component Name\\", \\"component_id\\"],\\n \\"tweaks\\": {\\"parameter_name\\": \\"value\\", \\"Component Name\\": {\\"parameter_name\\": \\"value\\"}, \\"component_id\\": {\\"parameter_name\\": \\"value\\"}}\\n \\"stream\\": false\\n}\\n```\\n\\nThis endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\\ncatering to diverse application requirements.","operationId":"experimental_run_flow_api_v1_run_advanced__flow_id__post","security":[{"API key query":[]},{"API key header":[]}],"parameters":[{"name":"flow_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Flow Id"}}],"requestBody":{"content":{"application/json":{"schema":{"properties":{"inputs":{"anyOf":[{"items":{"properties":{"components":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Components","default":[]},"input_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Input Value"},"session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session"},"type":{"anyOf":[{"type":"string","enum":["chat","text","any"]},{"type":"null"}],"title":"Type","description":"Defines on which components the input value should be applied. \'any\' applies to all input components.","default":"any"}},"additionalProperties":false,"type":"object","title":"InputValueRequest","examples":[{"components":["components_id","Component Name"],"input_value":"input_value","session":"session_id"},{"components":["Component Name"],"input_value":"input_value"},{"input_value":"input_value"},{"components":["Component Name"],"input_value":"input_value","session":"session_id"},{"input_value":"input_value","session":"session_id"},{"input_value":"input_value","type":"chat"},{"input_value":"{\\"key\\": \\"value\\"}","type":"json"}]},"type":"array"},{"type":"null"}],"title":"Inputs"},"outputs":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Outputs"},"tweaks":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"object","title":"Tweaks","description":"A dictionary of tweaks to adjust the flow\'s execution. Allows customizing flow behavior dynamically. All tweaks are overridden by the input values.","examples":[{"Component Name":{"parameter_name":"value"},"component_id":{"parameter_name":"value"},"parameter_name":"value"}]},{"type":"null"}]},"stream":{"type":"boolean","title":"Stream","default":false},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","title":"Body_experimental_run_flow_api_v1_run_advanced__flow_id__post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"properties":{"outputs":{"anyOf":[{"items":{"properties":{"inputs":{"type":"object","title":"Inputs"},"outputs":{"items":{"anyOf":[{"properties":{"results":{"anyOf":[{},{"type":"null"}],"title":"Results"},"artifacts":{"anyOf":[{},{"type":"null"}],"title":"Artifacts"},"outputs":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Outputs"},"logs":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Logs"},"messages":{"anyOf":[{"items":{"properties":{"message":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"array"}],"title":"Message"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender","default":"Machine"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name","default":"AI"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"stream_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stream Url"},"component_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Id"},"files":{"items":{"properties":{"path":{"type":"string","title":"Path"},"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"}},"type":"object","required":["path","name","type"],"title":"File","description":"File schema."},"type":"array","title":"Files","default":[]},"type":{"type":"string","title":"Type"}},"type":"object","required":["message","type"],"title":"ChatOutputResponse","description":"Chat output response schema."},"type":"array"},{"type":"null"}],"title":"Messages"},"timedelta":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Timedelta"},"duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Duration"},"component_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Display Name"},"component_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Id"},"used_frozen_result":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Used Frozen Result","default":false}},"type":"object","title":"ResultData"},{"type":"null"}]},"type":"array","title":"Outputs"}},"type":"object","title":"RunOutputs"},"type":"array"},{"type":"null"}],"title":"Outputs","default":[]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","title":"RunResponse","description":"Run response schema."}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"}}}}},"method":"post","path":"/api/v1/run/advanced/{flow_id}","securitySchemes":{"OAuth2PasswordBearer":{"type":"oauth2","flows":{"password":{"scopes":{},"tokenUrl":"api/v1/login"}}},"API key query":{"type":"apiKey","in":"query","name":"x-api-key"},"API key header":{"type":"apiKey","in":"header","name":"x-api-key"}},"jsonRequestBodyExample":{"stream":false},"info":{"title":"Langflow","version":"1.5.0.post1"},"postman":{"name":"Experimental Run Flow","description":{"content":"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability.\\n\\nThis endpoint supports running flows with caching to enhance performance and efficiency.\\n\\n### Parameters:\\n- `flow_id` (str): The unique identifier of the flow to be executed.\\n- `inputs` (List[InputValueRequest], optional): A list of inputs specifying the input values and components\\n for the flow. Each input can target specific components and provide custom values.\\n- `outputs` (List[str], optional): A list of output names to retrieve from the executed flow.\\n If not provided, all outputs are returned.\\n- `tweaks` (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\\n The tweaks can be used to modify the flow\'s parameters and components.\\n Tweaks can be overridden by the input values.\\n- `stream` (bool, optional): Specifies whether the results should be streamed. Defaults to False.\\n- `session_id` (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\\n execution.\\n- `api_key_user` (User): The user associated with the current API key. Automatically resolved from the API key.\\n\\n### Returns:\\nA `RunResponse` object containing the selected outputs (or all if not specified) of the executed flow\\nand the session ID.\\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input.\\n\\n### Raises:\\nHTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\\nflow execution.\\n\\n### Example usage:\\n```json\\nPOST /run/flow_id\\nx-api-key: YOUR_API_KEY\\nPayload:\\n{\\n \\"inputs\\": [\\n {\\"components\\": [\\"component1\\"], \\"input_value\\": \\"value1\\"},\\n {\\"components\\": [\\"component3\\"], \\"input_value\\": \\"value2\\"}\\n ],\\n \\"outputs\\": [\\"Component Name\\", \\"component_id\\"],\\n \\"tweaks\\": {\\"parameter_name\\": \\"value\\", \\"Component Name\\": {\\"parameter_name\\": \\"value\\"}, \\"component_id\\": {\\"parameter_name\\": \\"value\\"}}\\n \\"stream\\": false\\n}\\n```\\n\\nThis endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\\ncatering to diverse application requirements.","type":"text/plain"},"url":{"path":["api","v1","run","advanced",":flow_id"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"flow_id"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"{\\n \\"inputs\\": [\\n {\\n \\"components\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"input_value\\": \\"\\",\\n \\"session\\": \\"\\",\\n \\"type\\": \\"\\"\\n },\\n {\\n \\"components\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"input_value\\": \\"\\",\\n \\"session\\": \\"\\",\\n \\"type\\": \\"\\"\\n }\\n ],\\n \\"outputs\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"tweaks\\": {\\n \\"ipsum_07\\": \\"\\",\\n \\"elit641\\": \\"\\"\\n },\\n \\"stream\\": false,\\n \\"session_id\\": \\"\\"\\n}","options":{"raw":{"language":"json"}}},"auth":{"type":"apikey","apikey":[{"type":"any","value":"x-api-key","key":"key"},{"type":"any","value":"{{apiKey}}","key":"value"},{"type":"any","value":"query","key":"in"}]}}},"source":"@site/openapi.json","sourceDirName":".","permalink":"/api/experimental-run-flow","previous":{"title":"Webhook Run Flow","permalink":"/api/webhook-run-flow"},"next":{"title":"Process","permalink":"/api/process"}}');var i=n(74848),o=n(28453);const a={},l="Experimental Run Flow",r=[{value:"Parameters:",id:"parameters",level:3},{value:"Returns:",id:"returns",level:3},{value:"Raises:",id:"raises",level:3},{value:"Example usage:",id:"example-usage",level:3}];function p(e){const t={code:"code",h1:"h1",h3:"h3",header:"header",li:"li",p:"p",pre:"pre",ul:"ul",...(0,o.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t.header,{children:(0,i.jsx)(t.h1,{id:"experimental-run-flow",children:"Experimental Run Flow"})}),"\n",(0,i.jsx)(t.p,{children:"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability."}),"\n",(0,i.jsx)(t.p,{children:"This endpoint supports running flows with caching to enhance performance and efficiency."}),"\n",(0,i.jsx)(t.h3,{id:"parameters",children:"Parameters:"}),"\n",(0,i.jsxs)(t.ul,{children:["\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"flow_id"})," (str): The unique identifier of the flow to be executed."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"inputs"})," (List[InputValueRequest], optional): A list of inputs specifying the input values and components\nfor the flow. Each input can target specific components and provide custom values."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"outputs"})," (List[str], optional): A list of output names to retrieve from the executed flow.\nIf not provided, all outputs are returned."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"tweaks"})," (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\nThe tweaks can be used to modify the flow's parameters and components.\nTweaks can be overridden by the input values."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"stream"})," (bool, optional): Specifies whether the results should be streamed. Defaults to False."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"session_id"})," (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\nexecution."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"api_key_user"})," (User): The user associated with the current API key. Automatically resolved from the API key."]}),"\n"]}),"\n",(0,i.jsx)(t.h3,{id:"returns",children:"Returns:"}),"\n",(0,i.jsxs)(t.p,{children:["A ",(0,i.jsx)(t.code,{children:"RunResponse"})," object containing the selected outputs (or all if not specified) of the executed flow\nand the session ID.\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input."]}),"\n",(0,i.jsx)(t.h3,{id:"raises",children:"Raises:"}),"\n",(0,i.jsx)(t.p,{children:"HTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\nflow execution."}),"\n",(0,i.jsx)(t.h3,{id:"example-usage",children:"Example usage:"}),"\n",(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:"language-json",children:'POST /run/flow_id\nx-api-key: YOUR_API_KEY\nPayload:\n{\n "inputs": [\n {"components": ["component1"], "input_value": "value1"},\n {"components": ["component3"], "input_value": "value2"}\n ],\n "outputs": ["Component Name", "component_id"],\n "tweaks": {"parameter_name": "value", "Component Name": {"parameter_name": "value"}, "component_id": {"parameter_name": "value"}}\n "stream": false\n}\n'})}),"\n",(0,i.jsx)(t.p,{children:"This endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\ncatering to diverse application requirements."}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsx)("th",{style:{textAlign:"left"},children:"Path Parameters"})})}),(0,i.jsx)("tbody",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"flow_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" uuid"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-required)"},children:" REQUIRED"})]})})})]}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Request Body "}),(0,i.jsx)("div",{})]})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"inputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Inputs"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Outputs"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"tweaks"}),(0,i.jsx)("span",{style:{opacity:"0.6"}})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"stream"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Stream"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"session_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Session Id"})]})})]})]}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsx)("th",{style:{textAlign:"left"},children:"Responses"})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsxs)("div",{style:{display:"flex"},children:[(0,i.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,i.jsx)("code",{children:"200"})}),(0,i.jsx)("div",{children:(0,i.jsx)(t.p,{children:"Successful Response"})})]}),(0,i.jsx)("div",{children:(0,i.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Schema "}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("div",{})]})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"session_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Session Id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"})]})})]})]})})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsxs)("div",{style:{display:"flex"},children:[(0,i.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,i.jsx)("code",{children:"422"})}),(0,i.jsx)("div",{children:(0,i.jsx)(t.p,{children:"Validation Error"})})]}),(0,i.jsx)("div",{children:(0,i.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Schema "}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("div",{})]})})}),(0,i.jsx)("tbody",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"detail"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" object[]"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"loc"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" undefined[]"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"msg"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Message"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"type"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Error Type"})]})})]})})]})})})]})})]})})]})]})]})}function d(e={}){const{wrapper:t}={...(0,o.R)(),...e.components};return t?(0,i.jsx)(t,{...e,children:(0,i.jsx)(p,{...e})}):p(e)}}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8504],{28453:(e,t,n)=>{n.d(t,{R:()=>a,x:()=>l});var s=n(96540);const i={},o=s.createContext(i);function a(e){const t=s.useContext(o);return s.useMemo(function(){return"function"==typeof e?e(t):{...t,...e}},[t,e])}function l(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:a(e.components),s.createElement(o.Provider,{value:t},e.children)}},94910:(e,t,n)=>{n.r(t),n.d(t,{contentTitle:()=>l,default:()=>d,frontMatter:()=>a,metadata:()=>s,toc:()=>r});const s=JSON.parse('{"type":"api","id":"experimental-run-flow","title":"Experimental Run Flow","description":"","slug":"/experimental-run-flow","frontMatter":{},"api":{"tags":["Base"],"description":"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability.\\n\\nThis endpoint supports running flows with caching to enhance performance and efficiency.\\n\\n### Parameters:\\n- `flow_id` (str): The unique identifier of the flow to be executed.\\n- `inputs` (List[InputValueRequest], optional): A list of inputs specifying the input values and components\\n for the flow. Each input can target specific components and provide custom values.\\n- `outputs` (List[str], optional): A list of output names to retrieve from the executed flow.\\n If not provided, all outputs are returned.\\n- `tweaks` (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\\n The tweaks can be used to modify the flow\'s parameters and components.\\n Tweaks can be overridden by the input values.\\n- `stream` (bool, optional): Specifies whether the results should be streamed. Defaults to False.\\n- `session_id` (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\\n execution.\\n- `api_key_user` (User): The user associated with the current API key. Automatically resolved from the API key.\\n\\n### Returns:\\nA `RunResponse` object containing the selected outputs (or all if not specified) of the executed flow\\nand the session ID.\\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input.\\n\\n### Raises:\\nHTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\\nflow execution.\\n\\n### Example usage:\\n```json\\nPOST /run/flow_id\\nx-api-key: YOUR_API_KEY\\nPayload:\\n{\\n \\"inputs\\": [\\n {\\"components\\": [\\"component1\\"], \\"input_value\\": \\"value1\\"},\\n {\\"components\\": [\\"component3\\"], \\"input_value\\": \\"value2\\"}\\n ],\\n \\"outputs\\": [\\"Component Name\\", \\"component_id\\"],\\n \\"tweaks\\": {\\"parameter_name\\": \\"value\\", \\"Component Name\\": {\\"parameter_name\\": \\"value\\"}, \\"component_id\\": {\\"parameter_name\\": \\"value\\"}}\\n \\"stream\\": false\\n}\\n```\\n\\nThis endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\\ncatering to diverse application requirements.","operationId":"experimental_run_flow_api_v1_run_advanced__flow_id__post","security":[{"API key query":[]},{"API key header":[]}],"parameters":[{"name":"flow_id","in":"path","required":true,"schema":{"type":"string","format":"uuid","title":"Flow Id"}}],"requestBody":{"content":{"application/json":{"schema":{"properties":{"inputs":{"anyOf":[{"items":{"properties":{"components":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Components","default":[]},"input_value":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Input Value"},"session":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session"},"type":{"anyOf":[{"type":"string","enum":["chat","text","any"]},{"type":"null"}],"title":"Type","description":"Defines on which components the input value should be applied. \'any\' applies to all input components.","default":"any"}},"additionalProperties":false,"type":"object","title":"InputValueRequest","examples":[{"components":["components_id","Component Name"],"input_value":"input_value","session":"session_id"},{"components":["Component Name"],"input_value":"input_value"},{"input_value":"input_value"},{"components":["Component Name"],"input_value":"input_value","session":"session_id"},{"input_value":"input_value","session":"session_id"},{"input_value":"input_value","type":"chat"},{"input_value":"{\\"key\\": \\"value\\"}","type":"json"}]},"type":"array"},{"type":"null"}],"title":"Inputs"},"outputs":{"anyOf":[{"items":{"type":"string"},"type":"array"},{"type":"null"}],"title":"Outputs"},"tweaks":{"anyOf":[{"additionalProperties":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"object","title":"Tweaks","description":"A dictionary of tweaks to adjust the flow\'s execution. Allows customizing flow behavior dynamically. All tweaks are overridden by the input values.","examples":[{"Component Name":{"parameter_name":"value"},"component_id":{"parameter_name":"value"},"parameter_name":"value"}]},{"type":"null"}]},"stream":{"type":"boolean","title":"Stream","default":false},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","title":"Body_experimental_run_flow_api_v1_run_advanced__flow_id__post"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"properties":{"outputs":{"anyOf":[{"items":{"properties":{"inputs":{"type":"object","title":"Inputs"},"outputs":{"items":{"anyOf":[{"properties":{"results":{"anyOf":[{},{"type":"null"}],"title":"Results"},"artifacts":{"anyOf":[{},{"type":"null"}],"title":"Artifacts"},"outputs":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Outputs"},"logs":{"anyOf":[{"type":"object"},{"type":"null"}],"title":"Logs"},"messages":{"anyOf":[{"items":{"properties":{"message":{"anyOf":[{"type":"string"},{"items":{"anyOf":[{"type":"string"},{"type":"object"}]},"type":"array"}],"title":"Message"},"sender":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender","default":"Machine"},"sender_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Sender Name","default":"AI"},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"},"stream_url":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Stream Url"},"component_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Id"},"files":{"items":{"properties":{"path":{"type":"string","title":"Path"},"name":{"type":"string","title":"Name"},"type":{"type":"string","title":"Type"}},"type":"object","required":["path","name","type"],"title":"File","description":"File schema."},"type":"array","title":"Files","default":[]},"type":{"type":"string","title":"Type"}},"type":"object","required":["message","type"],"title":"ChatOutputResponse","description":"Chat output response schema."},"type":"array"},{"type":"null"}],"title":"Messages"},"timedelta":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Timedelta"},"duration":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Duration"},"component_display_name":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Display Name"},"component_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Component Id"},"used_frozen_result":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Used Frozen Result","default":false}},"type":"object","title":"ResultData"},{"type":"null"}]},"type":"array","title":"Outputs"}},"type":"object","title":"RunOutputs"},"type":"array"},{"type":"null"}],"title":"Outputs","default":[]},"session_id":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Session Id"}},"type":"object","title":"RunResponse","description":"Run response schema."}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"properties":{"detail":{"items":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"}}}}},"method":"post","path":"/api/v1/run/advanced/{flow_id}","securitySchemes":{"OAuth2PasswordBearer":{"type":"oauth2","flows":{"password":{"scopes":{},"tokenUrl":"api/v1/login"}}},"API key query":{"type":"apiKey","in":"query","name":"x-api-key"},"API key header":{"type":"apiKey","in":"header","name":"x-api-key"}},"jsonRequestBodyExample":{"stream":false},"info":{"title":"Langflow","version":"1.5.0.post1"},"postman":{"name":"Experimental Run Flow","description":{"content":"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability.\\n\\nThis endpoint supports running flows with caching to enhance performance and efficiency.\\n\\n### Parameters:\\n- `flow_id` (str): The unique identifier of the flow to be executed.\\n- `inputs` (List[InputValueRequest], optional): A list of inputs specifying the input values and components\\n for the flow. Each input can target specific components and provide custom values.\\n- `outputs` (List[str], optional): A list of output names to retrieve from the executed flow.\\n If not provided, all outputs are returned.\\n- `tweaks` (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\\n The tweaks can be used to modify the flow\'s parameters and components.\\n Tweaks can be overridden by the input values.\\n- `stream` (bool, optional): Specifies whether the results should be streamed. Defaults to False.\\n- `session_id` (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\\n execution.\\n- `api_key_user` (User): The user associated with the current API key. Automatically resolved from the API key.\\n\\n### Returns:\\nA `RunResponse` object containing the selected outputs (or all if not specified) of the executed flow\\nand the session ID.\\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input.\\n\\n### Raises:\\nHTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\\nflow execution.\\n\\n### Example usage:\\n```json\\nPOST /run/flow_id\\nx-api-key: YOUR_API_KEY\\nPayload:\\n{\\n \\"inputs\\": [\\n {\\"components\\": [\\"component1\\"], \\"input_value\\": \\"value1\\"},\\n {\\"components\\": [\\"component3\\"], \\"input_value\\": \\"value2\\"}\\n ],\\n \\"outputs\\": [\\"Component Name\\", \\"component_id\\"],\\n \\"tweaks\\": {\\"parameter_name\\": \\"value\\", \\"Component Name\\": {\\"parameter_name\\": \\"value\\"}, \\"component_id\\": {\\"parameter_name\\": \\"value\\"}}\\n \\"stream\\": false\\n}\\n```\\n\\nThis endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\\ncatering to diverse application requirements.","type":"text/plain"},"url":{"path":["api","v1","run","advanced",":flow_id"],"host":["{{baseUrl}}"],"query":[],"variable":[{"disabled":false,"description":{"content":"(Required) ","type":"text/plain"},"type":"any","value":"","key":"flow_id"}]},"header":[{"key":"Content-Type","value":"application/json"},{"key":"Accept","value":"application/json"}],"method":"POST","body":{"mode":"raw","raw":"{\\n \\"inputs\\": [\\n {\\n \\"components\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"input_value\\": \\"\\",\\n \\"session\\": \\"\\",\\n \\"type\\": \\"\\"\\n },\\n {\\n \\"components\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"input_value\\": \\"\\",\\n \\"session\\": \\"\\",\\n \\"type\\": \\"\\"\\n }\\n ],\\n \\"outputs\\": [\\n \\"\\",\\n \\"\\"\\n ],\\n \\"tweaks\\": {\\n \\"ex20b\\": \\"\\"\\n },\\n \\"stream\\": false,\\n \\"session_id\\": \\"\\"\\n}","options":{"raw":{"language":"json"}}},"auth":{"type":"apikey","apikey":[{"type":"any","value":"x-api-key","key":"key"},{"type":"any","value":"{{apiKey}}","key":"value"},{"type":"any","value":"query","key":"in"}]}}},"source":"@site/openapi.json","sourceDirName":".","permalink":"/api/experimental-run-flow","previous":{"title":"Webhook Run Flow","permalink":"/api/webhook-run-flow"},"next":{"title":"Process","permalink":"/api/process"}}');var i=n(74848),o=n(28453);const a={},l="Experimental Run Flow",r=[{value:"Parameters:",id:"parameters",level:3},{value:"Returns:",id:"returns",level:3},{value:"Raises:",id:"raises",level:3},{value:"Example usage:",id:"example-usage",level:3}];function p(e){const t={code:"code",h1:"h1",h3:"h3",header:"header",li:"li",p:"p",pre:"pre",ul:"ul",...(0,o.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t.header,{children:(0,i.jsx)(t.h1,{id:"experimental-run-flow",children:"Experimental Run Flow"})}),"\n",(0,i.jsx)(t.p,{children:"Executes a specified flow by ID with optional input values, output selection, tweaks, and streaming capability."}),"\n",(0,i.jsx)(t.p,{children:"This endpoint supports running flows with caching to enhance performance and efficiency."}),"\n",(0,i.jsx)(t.h3,{id:"parameters",children:"Parameters:"}),"\n",(0,i.jsxs)(t.ul,{children:["\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"flow_id"})," (str): The unique identifier of the flow to be executed."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"inputs"})," (List[InputValueRequest], optional): A list of inputs specifying the input values and components\nfor the flow. Each input can target specific components and provide custom values."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"outputs"})," (List[str], optional): A list of output names to retrieve from the executed flow.\nIf not provided, all outputs are returned."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"tweaks"})," (Optional[Tweaks], optional): A dictionary of tweaks to customize the flow execution.\nThe tweaks can be used to modify the flow's parameters and components.\nTweaks can be overridden by the input values."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"stream"})," (bool, optional): Specifies whether the results should be streamed. Defaults to False."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"session_id"})," (Union[None, str], optional): An optional session ID to utilize existing session data for the flow\nexecution."]}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.code,{children:"api_key_user"})," (User): The user associated with the current API key. Automatically resolved from the API key."]}),"\n"]}),"\n",(0,i.jsx)(t.h3,{id:"returns",children:"Returns:"}),"\n",(0,i.jsxs)(t.p,{children:["A ",(0,i.jsx)(t.code,{children:"RunResponse"})," object containing the selected outputs (or all if not specified) of the executed flow\nand the session ID.\nThe structure of the response accommodates multiple inputs, providing a nested list of outputs for each input."]}),"\n",(0,i.jsx)(t.h3,{id:"raises",children:"Raises:"}),"\n",(0,i.jsx)(t.p,{children:"HTTPException: Indicates issues with finding the specified flow, invalid input formats, or internal errors during\nflow execution."}),"\n",(0,i.jsx)(t.h3,{id:"example-usage",children:"Example usage:"}),"\n",(0,i.jsx)(t.pre,{children:(0,i.jsx)(t.code,{className:"language-json",children:'POST /run/flow_id\nx-api-key: YOUR_API_KEY\nPayload:\n{\n "inputs": [\n {"components": ["component1"], "input_value": "value1"},\n {"components": ["component3"], "input_value": "value2"}\n ],\n "outputs": ["Component Name", "component_id"],\n "tweaks": {"parameter_name": "value", "Component Name": {"parameter_name": "value"}, "component_id": {"parameter_name": "value"}}\n "stream": false\n}\n'})}),"\n",(0,i.jsx)(t.p,{children:"This endpoint facilitates complex flow executions with customized inputs, outputs, and configurations,\ncatering to diverse application requirements."}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsx)("th",{style:{textAlign:"left"},children:"Path Parameters"})})}),(0,i.jsx)("tbody",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"flow_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" uuid"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-required)"},children:" REQUIRED"})]})})})]}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Request Body "}),(0,i.jsx)("div",{})]})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"inputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Inputs"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Outputs"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"tweaks"}),(0,i.jsx)("span",{style:{opacity:"0.6"}})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"stream"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Stream"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"session_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Session Id"})]})})]})]}),"\n",(0,i.jsxs)("table",{style:{display:"table",width:"100%"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsx)("th",{style:{textAlign:"left"},children:"Responses"})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsxs)("div",{style:{display:"flex"},children:[(0,i.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,i.jsx)("code",{children:"200"})}),(0,i.jsx)("div",{children:(0,i.jsx)(t.p,{children:"Successful Response"})})]}),(0,i.jsx)("div",{children:(0,i.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Schema "}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("div",{})]})})}),(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Outputs"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"session_id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Session Id"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"})]})})]})]})})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsxs)("div",{style:{display:"flex"},children:[(0,i.jsx)("div",{style:{marginRight:"var(--ifm-table-cell-padding)"},children:(0,i.jsx)("code",{children:"422"})}),(0,i.jsx)("div",{children:(0,i.jsx)(t.p,{children:"Validation Error"})})]}),(0,i.jsx)("div",{children:(0,i.jsxs)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:[(0,i.jsx)("thead",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("th",{style:{textAlign:"left"},children:[(0,i.jsx)("span",{children:"Schema "}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("div",{})]})})}),(0,i.jsx)("tbody",{children:(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"detail"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" object[]"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" \u2014 "}),(0,i.jsx)("strong",{style:{fontSize:"var(--ifm-code-font-size)",color:"var(--openapi-optional)"},children:" OPTIONAL"}),(0,i.jsx)("table",{style:{display:"table",width:"100%",marginTop:"var(--ifm-table-cell-padding)",marginBottom:"0px"},children:(0,i.jsxs)("tbody",{children:[(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"loc"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" undefined[]"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"msg"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Message"})]})}),(0,i.jsx)("tr",{children:(0,i.jsxs)("td",{children:[(0,i.jsx)("code",{children:"type"}),(0,i.jsx)("span",{style:{opacity:"0.6"},children:" Error Type"})]})})]})})]})})})]})})]})})]})]})]})}function d(e={}){const{wrapper:t}={...(0,o.R)(),...e.components};return t?(0,i.jsx)(t,{...e,children:(0,i.jsx)(p,{...e})}):p(e)}}}]); \ No newline at end of file diff --git a/assets/js/f0eeb72e.13f39c9c.js b/assets/js/f0eeb72e.13f39c9c.js new file mode 100644 index 0000000000..716444cb96 --- /dev/null +++ b/assets/js/f0eeb72e.13f39c9c.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9897],{11470:(e,o,n)=>{n.d(o,{A:()=>w});var t=n(96540),s=n(18215),r=n(23104),l=n(56347),a=n(205),i=n(57485),c=n(31682),d=n(70679);function p(e){return t.Children.toArray(e).filter(e=>"\n"!==e).map(e=>{if(!e||(0,t.isValidElement)(e)&&function(e){const{props:o}=e;return!!o&&"object"==typeof o&&"value"in o}(e))return e;throw new Error(`Docusaurus error: Bad child <${"string"==typeof e.type?e.type:e.type.name}>: all children of the component should be , and every should have a unique "value" prop.`)})?.filter(Boolean)??[]}function u(e){const{values:o,children:n}=e;return(0,t.useMemo)(()=>{const e=o??function(e){return p(e).map(({props:{value:e,label:o,attributes:n,default:t}})=>({value:e,label:o,attributes:n,default:t}))}(n);return function(e){const o=(0,c.XI)(e,(e,o)=>e.value===o.value);if(o.length>0)throw new Error(`Docusaurus error: Duplicate values "${o.map(e=>e.value).join(", ")}" found in . Every value needs to be unique.`)}(e),e},[o,n])}function h({value:e,tabValues:o}){return o.some(o=>o.value===e)}function g({queryString:e=!1,groupId:o}){const n=(0,l.W6)(),s=function({queryString:e=!1,groupId:o}){if("string"==typeof e)return e;if(!1===e)return null;if(!0===e&&!o)throw new Error('Docusaurus error: The component groupId prop is required if queryString=true, because this value is used as the search param name. You can also provide an explicit value such as queryString="my-search-param".');return o??null}({queryString:e,groupId:o});return[(0,i.aZ)(s),(0,t.useCallback)(e=>{if(!s)return;const o=new URLSearchParams(n.location.search);o.set(s,e),n.replace({...n.location,search:o.toString()})},[s,n])]}function f(e){const{defaultValue:o,queryString:n=!1,groupId:s}=e,r=u(e),[l,i]=(0,t.useState)(()=>function({defaultValue:e,tabValues:o}){if(0===o.length)throw new Error("Docusaurus error: the component requires at least one children component");if(e){if(!h({value:e,tabValues:o}))throw new Error(`Docusaurus error: The has a defaultValue "${e}" but none of its children has the corresponding value. Available values are: ${o.map(e=>e.value).join(", ")}. If you intend to show no default tab, use defaultValue={null} instead.`);return e}const n=o.find(e=>e.default)??o[0];if(!n)throw new Error("Unexpected error: 0 tabValues");return n.value}({defaultValue:o,tabValues:r})),[c,p]=g({queryString:n,groupId:s}),[f,m]=function({groupId:e}){const o=function(e){return e?`docusaurus.tab.${e}`:null}(e),[n,s]=(0,d.Dv)(o);return[n,(0,t.useCallback)(e=>{o&&s.set(e)},[o,s])]}({groupId:s}),y=(()=>{const e=c??f;return h({value:e,tabValues:r})?e:null})();(0,a.A)(()=>{y&&i(y)},[y]);return{selectedValue:l,selectValue:(0,t.useCallback)(e=>{if(!h({value:e,tabValues:r}))throw new Error(`Can't select invalid tab value=${e}`);i(e),p(e),m(e)},[p,m,r]),tabValues:r}}var m=n(92303);const y={tabList:"tabList__CuJ",tabItem:"tabItem_LNqP"};var x=n(74848);function b({className:e,block:o,selectedValue:n,selectValue:t,tabValues:l}){const a=[],{blockElementScrollPositionUntilNextRender:i}=(0,r.a_)(),c=e=>{const o=e.currentTarget,s=a.indexOf(o),r=l[s].value;r!==n&&(i(o),t(r))},d=e=>{let o=null;switch(e.key){case"Enter":c(e);break;case"ArrowRight":{const n=a.indexOf(e.currentTarget)+1;o=a[n]??a[0];break}case"ArrowLeft":{const n=a.indexOf(e.currentTarget)-1;o=a[n]??a[a.length-1];break}}o?.focus()};return(0,x.jsx)("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,s.A)("tabs",{"tabs--block":o},e),children:l.map(({value:e,label:o,attributes:t})=>(0,x.jsx)("li",{role:"tab",tabIndex:n===e?0:-1,"aria-selected":n===e,ref:e=>{a.push(e)},onKeyDown:d,onClick:c,...t,className:(0,s.A)("tabs__item",y.tabItem,t?.className,{"tabs__item--active":n===e}),children:o??e},e))})}function j({lazy:e,children:o,selectedValue:n}){const r=(Array.isArray(o)?o:[o]).filter(Boolean);if(e){const e=r.find(e=>e.props.value===n);return e?(0,t.cloneElement)(e,{className:(0,s.A)("margin-top--md",e.props.className)}):null}return(0,x.jsx)("div",{className:"margin-top--md",children:r.map((e,o)=>(0,t.cloneElement)(e,{key:o,hidden:e.props.value!==n}))})}function v(e){const o=f(e);return(0,x.jsxs)("div",{className:(0,s.A)("tabs-container",y.tabList),children:[(0,x.jsx)(b,{...o,...e}),(0,x.jsx)(j,{...o,...e})]})}function w(e){const o=(0,m.A)();return(0,x.jsx)(v,{...e,children:p(e.children)},String(o))}},19365:(e,o,n)=>{n.d(o,{A:()=>l});n(96540);var t=n(18215);const s={tabItem:"tabItem_Ymn6"};var r=n(74848);function l({children:e,hidden:o,className:n}){return(0,r.jsx)("div",{role:"tabpanel",className:(0,t.A)(s.tabItem,n),hidden:o,children:e})}},28453:(e,o,n)=>{n.d(o,{R:()=>l,x:()=>a});var t=n(96540);const s={},r=t.createContext(s);function l(e){const o=t.useContext(r);return t.useMemo(function(){return"function"==typeof e?e(o):{...o,...e}},[o,e])}function a(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:l(e.components),t.createElement(r.Provider,{value:o},e.children)}},61227:(e,o,n)=>{n.r(o),n.d(o,{CH:()=>u,assets:()=>p,chCodeConfig:()=>h,contentTitle:()=>d,default:()=>m,frontMatter:()=>c,metadata:()=>t,toc:()=>g});const t=JSON.parse('{"id":"Develop/enterprise-database-guide","title":"Langflow database guide for enterprise DBAs","description":"The Langflow database stores data that is essential for more Langflow operations, including startup, flow execution, user interactions, and administrative tasks.","source":"@site/docs/Develop/enterprise-database-guide.mdx","sourceDirName":"Develop","slug":"/enterprise-database-guide","permalink":"/enterprise-database-guide","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Langflow database guide for enterprise DBAs","slug":"/enterprise-database-guide"},"sidebar":"docs","previous":{"title":"Configure an external PostgreSQL database","permalink":"/configuration-custom-database"},"next":{"title":"Logs","permalink":"/logging"}}');var s=n(74848),r=n(28453),l=n(24754),a=n(11470),i=n(19365);const c={title:"Langflow database guide for enterprise DBAs",slug:"/enterprise-database-guide"},d=void 0,p={},u={annotations:l.hk,Code:l.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Configure Langflow with PostgreSQL",id:"configure-langflow-with-postgresql",level:2},{value:"High Availability for PostgreSQL",id:"high-availability-for-postgresql",level:3},{value:"Impact of database failure",id:"impact-of-database-failure",level:2},{value:"Database monitoring",id:"database-monitoring",level:2},{value:"See also",id:"see-also",level:2}];function f(e){const o={a:"a",admonition:"admonition",code:"code",h2:"h2",h3:"h3",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return u||y("CH",!1),u.Code||y("CH.Code",!0),(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)("style",{dangerouslySetInnerHTML:{__html:'[data-ch-theme="github-dark"] { --ch-t-colorScheme: dark;--ch-t-foreground: #c9d1d9;--ch-t-background: #0d1117;--ch-t-lighter-inlineBackground: #0d1117e6;--ch-t-editor-background: #0d1117;--ch-t-editor-foreground: #c9d1d9;--ch-t-editor-lineHighlightBackground: #6e76811a;--ch-t-editor-rangeHighlightBackground: #ffffff0b;--ch-t-editor-infoForeground: #3794FF;--ch-t-editor-selectionBackground: #264F78;--ch-t-focusBorder: #1f6feb;--ch-t-tab-activeBackground: #0d1117;--ch-t-tab-activeForeground: #c9d1d9;--ch-t-tab-inactiveBackground: #010409;--ch-t-tab-inactiveForeground: #8b949e;--ch-t-tab-border: #30363d;--ch-t-tab-activeBorder: #0d1117;--ch-t-editorGroup-border: #30363d;--ch-t-editorGroupHeader-tabsBackground: #010409;--ch-t-editorLineNumber-foreground: #6e7681;--ch-t-input-background: #0d1117;--ch-t-input-foreground: #c9d1d9;--ch-t-input-border: #30363d;--ch-t-icon-foreground: #8b949e;--ch-t-sideBar-background: #010409;--ch-t-sideBar-foreground: #c9d1d9;--ch-t-sideBar-border: #30363d;--ch-t-list-activeSelectionBackground: #6e768166;--ch-t-list-activeSelectionForeground: #c9d1d9;--ch-t-list-hoverBackground: #6e76811a;--ch-t-list-hoverForeground: #c9d1d9; }'}}),"\n","\n",(0,s.jsxs)(o.p,{children:["The Langflow database stores data that is essential for more Langflow operations, including startup, flow execution, user interactions, and administrative tasks.\nThe database supports both frontend (visual editor) and backend (API) operations, making its availability critical to Langflow's stability and functionality.\nFor details about the database schema, see ",(0,s.jsx)(o.a,{href:"/memory",children:"Memory management options"}),"."]}),"\n",(0,s.jsx)(o.p,{children:"This guide is designed for enterprise database administrators (DBAs) and operators responsible for deploying and managing Langflow in production environments.\nIt explains how to configure Langflow to use PostgreSQL, including high availability (HA) and active-active configurations, as well as best practices for monitoring, maintenance, and security."}),"\n",(0,s.jsx)(o.h2,{id:"configure-langflow-with-postgresql",children:"Configure Langflow with PostgreSQL"}),"\n",(0,s.jsx)(o.p,{children:"Langflow's default database is SQLite.\nHowever, PostgreSQL is recommended for production deployments due to its scalability, performance, and robustness."}),"\n",(0,s.jsxs)(o.p,{children:["The following steps explain how to configure Langflow to use PostgreSQL for a standalone or containerized deployment.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"}),"."]}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Set up PostgreSQL:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsx)(o.li,{children:"Deploy a PostgreSQL instance (version 12 or higher recommended) using a local server, Docker, or a managed cloud service."}),"\n",(0,s.jsx)(o.li,{children:"Create a database for Langflow."}),"\n",(0,s.jsx)(o.li,{children:"Create a PostgreSQL user with appropriate, minimal permissions to manage and write to the database, such as CREATE, SELECT, INSERT, UPDATE, DELETE on your Langflow tables."}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Obtain the connection string in the format ",(0,s.jsx)(o.code,{children:"postgresql://user:password@host:port/dbname"}),", such as",(0,s.jsx)(o.code,{children:"postgresql://langflow:securepassword@postgres:5432/langflow"}),"."]}),"\n",(0,s.jsxs)(o.p,{children:["For High Availability, use the virtual IP or proxy hostname instead of the direct database host.\nFor more information, see ",(0,s.jsx)(o.a,{href:"#high-availability-for-postgresql",children:"High Availability for PostgreSQL"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Configure Langflow with the ",(0,s.jsx)(o.code,{children:".env"})," or ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," files."]}),"\n",(0,s.jsxs)(a.A,{groupId:"environment",children:[(0,s.jsxs)(i.A,{value:".env",label:".env",default:!0,children:[(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Create a ",(0,s.jsx)(o.code,{children:".env"})," file in the ",(0,s.jsx)(o.code,{children:"langflow"})," directory:"]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"touch ",props:{style:{color:"#FFA657"}}},{content:".env",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsxs)(o.p,{children:["Add the connection string to the ",(0,s.jsx)(o.code,{children:".env"})," file:"]}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'LANGFLOW_DATABASE_URL="postgresql://langflow:securepassword@postgres:5432/langflow"',props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n"]}),(0,s.jsxs)(o.p,{children:["For more environment variables, see the ",(0,s.jsx)(o.code,{children:".env.example"})," file in the Langflow repository."]})]}),(0,s.jsxs)(i.A,{value:"docker-compose.yml",label:"docker-compose.yml",children:[(0,s.jsxs)(o.p,{children:["Use the sample ",(0,s.jsx)(o.code,{children:"docker-compose.yml"})," from the Langflow Repository.\nYou can use the default values or customize them as needed."]}),(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"version",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"'3'",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"services",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" langflow",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"7860:7860"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL=postgresql://langflow:langflow@postgres:5432/langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"postgres:16",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:'"5432:5432"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" environment",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_USER=langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_PASSWORD=langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"POSTGRES_DB=langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-postgres:/var/lib/postgresql/data",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"volumes",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-postgres",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]}],lang:"yaml"},annotations:[]}]})]})]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Start Langflow with your PostgreSQL connection:"}),"\n",(0,s.jsxs)(a.A,{groupId:"environment",children:[(0,s.jsx)(i.A,{value:".env",label:".env",default:!0,children:(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"uv ",props:{style:{color:"#FFA657"}}},{content:"run langflow run ",props:{style:{color:"#A5D6FF"}}},{content:"--env-file ",props:{style:{color:"#79C0FF"}}},{content:".env",props:{style:{color:"#A5D6FF"}}}]}],lang:"shell"},annotations:[]}]})}),(0,s.jsx)(i.A,{value:"docker-compose.yml",label:"docker-compose.yml",children:(0,s.jsxs)(o.p,{children:["Navigate to the directory containing ",(0,s.jsx)(o.code,{children:"docker-compose.yml"}),", and then run ",(0,s.jsx)(o.code,{children:"docker-compose up"}),"."]})})]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Optional: Run migrations."}),"\n",(0,s.jsx)(o.p,{children:"Langflow, through SQLAlchemy and Alembic, uses migrations to manage its database schema.\nAvoid manual schema changes to prevent conflicts with Langflow's built-in schema management."}),"\n",(0,s.jsx)(o.p,{children:"When you first connect to PostgreSQL, Langflow automatically runs migrations to create the necessary tables."}),"\n",(0,s.jsxs)(o.p,{children:["To manually run migrations, run ",(0,s.jsx)(o.code,{children:"langflow migration"})," to preview the changes, and then run ",(0,s.jsx)(o.code,{children:"langflow migration --fix"})," to apply the changes."]}),"\n",(0,s.jsx)(o.admonition,{type:"danger",children:(0,s.jsxs)(o.p,{children:["Migrations are a destructive operation that can delete data.\nAlways run ",(0,s.jsx)(o.code,{children:"langflow migration"})," first to preview changes before applying them with ",(0,s.jsx)(o.code,{children:"--fix"}),".\nFor more information, see ",(0,s.jsx)(o.a,{href:"/configuration-cli",children:"Langflow CLI"}),"."]})}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"To verify the configuration, create any flow using the Langflow visual editor or API, and then query your database to confirm the tables and activity are recorded there. The content of the flow doesn't matter; you only need to confirm that the flow is stored in your PostgreSQL database.\nYou can query the database in two ways:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Query the database container:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"docker exec -it psql -U langflow -d langflow",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Use SQL:"}),"\n",(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"SELECT * FROM pg_stat_activity WHERE datname = 'langflow';",props:{}}]}],lang:"text"},annotations:[]}]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(o.h3,{id:"high-availability-for-postgresql",children:"High Availability for PostgreSQL"}),"\n",(0,s.jsx)(o.p,{children:"To further improve performance, reliability, and scalability, use a High Availability (HA) or Active-Active HA PostgreSQL configuration.\nThis is recommended for production deployments to minimize downtime and ensure continuous operations if your database server fails, especially when multiple Langflow instances rely on the same database."}),"\n",(0,s.jsxs)(a.A,{children:[(0,s.jsx)(i.A,{value:"HA",label:"High Availability (HA)",default:!0,children:(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Set up streaming replication:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Configure one primary database for writes."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Configure one or more replicas for reads and failover."}),"\n",(0,s.jsx)(o.p,{children:"Select either synchronous or asynchronous replication based on your latency and consistency requirements."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Implement automatic failover using one of the following options:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Use an HA orchestrator, distributed configuration store, and traffic router, such as ",(0,s.jsx)(o.a,{href:"https://patroni.readthedocs.io/en/latest/",children:"Patroni"}),", etcd or ",(0,s.jsx)(o.a,{href:"https://developer.hashicorp.com/consul",children:"Consul"}),", and ",(0,s.jsx)(o.a,{href:"https://www.haproxy.org/",children:"HAProxy"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Use ",(0,s.jsx)(o.a,{href:"https://www.pgpool.net/docs/46/en/html/index.html",children:"Pgpool-II"})," alone or add supporting services for more robust HA support."]}),"\n",(0,s.jsx)(o.li,{children:"Use managed services that provide built-in HA with automatic failover, such as AWS RDS or Google Cloud SQL."}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Update your PostgreSQL connection string to point to the HA setup.\nIf you have a multi-instance deployment, make sure all of your Langflow instances connect to the same HA PostgreSQL database."}),"\n",(0,s.jsx)(o.p,{children:"The connection string you use depends on your HA configuration and services."}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Use a virtual IP or DNS name that resolves to the current primary database, such as ",(0,s.jsx)(o.code,{children:"postgresql://langflow:securepassword@db-proxy:5432/langflow?sslmode=require"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Use the provided endpoint for a managed service, such as ",(0,s.jsx)(o.code,{children:"langflow.cluster-xyz.us-east-1.rds.amazonaws.com"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Optional: Implement load balancing for read-heavy workloads:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["Use a connection pooler like ",(0,s.jsx)(o.a,{href:"https://www.pgbouncer.org/",children:"PgBouncer"})," to distribute read queries across replicas."]}),"\n",(0,s.jsx)(o.li,{children:"Configure Langflow to use a single connection string pointing to the primary PostgreSQL database or proxy."}),"\n"]}),"\n"]}),"\n"]})}),(0,s.jsxs)(i.A,{value:"AA",label:"Active-Active HA",children:[(0,s.jsx)(o.p,{children:"To implement Active-Active HA, you must deploy multiple Langflow instances, use load balancing to distribute traffic across the instances, and ensure all instances connect to the same HA PostgreSQL database:"}),(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Deploy multiple Langflow instances using Kubernetes or Docker Swarm."}),"\n",(0,s.jsxs)(o.p,{children:["You must configure your instances to use a shared PostgreSQL database.\nFor more information, see ",(0,s.jsx)(o.a,{href:"/deployment-prod-best-practices",children:"Best practices for Langflow on Kubernetes"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Set up streaming replication:"}),"\n",(0,s.jsxs)(o.ol,{children:["\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Configure one primary database for writes."}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Configure one or more replicas for reads and failover."}),"\n",(0,s.jsx)(o.p,{children:"Select either synchronous or asynchronous replication based on your latency and consistency requirements."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Implement automatic failover using one of the following options:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Use an HA orchestrator, distributed configuration store, and traffic router, such as ",(0,s.jsx)(o.a,{href:"https://patroni.readthedocs.io/en/latest/",children:"Patroni"}),", etcd or ",(0,s.jsx)(o.a,{href:"https://developer.hashicorp.com/consul",children:"Consul"}),", and ",(0,s.jsx)(o.a,{href:"https://www.haproxy.org/",children:"HAProxy"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Use ",(0,s.jsx)(o.a,{href:"https://www.pgpool.net/docs/46/en/html/index.html",children:"Pgpool-II"})," alone or add supporting services for more robust HA support."]}),"\n",(0,s.jsx)(o.li,{children:"Use managed services that provide built-in HA with automatic failover, such as AWS RDS or Google Cloud SQL."}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Update your PostgreSQL connection string to point to the HA setup.\nMake sure all of your Langflow instances connect to the same HA PostgreSQL database."}),"\n",(0,s.jsx)(o.p,{children:"The connection string you use depends on your HA configuration and services:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:["Use a virtual IP or DNS name that resolves to the current primary database, such as ",(0,s.jsx)(o.code,{children:"postgresql://langflow:securepassword@db-proxy:5432/langflow?sslmode=require"}),"."]}),"\n",(0,s.jsxs)(o.li,{children:["Use the provided endpoint for a managed service, such as ",(0,s.jsx)(o.code,{children:"langflow.cluster-xyz.us-east-1.rds.amazonaws.com"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(o.li,{children:["\n",(0,s.jsx)(o.p,{children:"Use a load balancer to distribute requests across your instances."}),"\n"]}),"\n"]}),(0,s.jsxs)(o.p,{children:["The following example configuration is for a production deployment that has three ",(0,s.jsx)(o.code,{children:"langflow-runtime"})," replicas, uses the Kubernetes load balancer service to distribute traffic to healthy pods, and uses the HA PostgreSQL database connection string."]}),(0,s.jsx)(u.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"apiVersion",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"apps/v1",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"kind",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"Deployment",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"metadata",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"spec",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" replicas",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"3",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" selector",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" matchLabels",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" app",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" template",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" metadata",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" labels",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" app",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" spec",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" containers",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" image",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflowai/langflow:latest",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"containerPort",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" env",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"LANGFLOW_DATABASE_URL",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" value",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:'"postgresql://langflow:securepassword@db-proxy:5432/langflow?sslmode=require"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"---",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:"apiVersion",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"v1",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"kind",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"Service",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"metadata",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"spec",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" selector",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" app",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"langflow-runtime",props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" ports",props:{style:{color:"#7EE787"}}},{content:":",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" - ",props:{style:{color:"#C9D1D9"}}},{content:"port",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"80",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" targetPort",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"7860",props:{style:{color:"#79C0FF"}}}]},{tokens:[{content:" type",props:{style:{color:"#7EE787"}}},{content:": ",props:{style:{color:"#C9D1D9"}}},{content:"LoadBalancer",props:{style:{color:"#A5D6FF"}}}]}],lang:"yaml"},annotations:[]}]})]})]}),"\n",(0,s.jsxs)(o.p,{children:["After implementing HA or Active-Active HA, monitor failover events and ensure replicas are in sync.\nLangflow, through ",(0,s.jsx)(o.a,{href:"https://docs.sqlalchemy.org/en/20/",children:"SQLAlchemy"}),", supports reconnection attempts, ensures recovery after failover, and reduces disruption once the database is back online."]}),"\n",(0,s.jsx)(o.p,{children:"Although PostgreSQL handles concurrent connections well, you must still monitor for contention, deadlocks, or other performance degradation during high load."}),"\n",(0,s.jsx)(o.h2,{id:"impact-of-database-failure",children:"Impact of database failure"}),"\n",(0,s.jsx)(o.p,{children:"If the PostgreSQL database becomes unavailable, the following Langflow functions will fail:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Flow Retrieval"}),": Cannot load new or existing flows from the database."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Flow Saving"}),": Unable to save new flows or updates to existing flows."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"User Authentication"}),": Login and user management functions fail."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Project Collection Access"}),": Cannot access or share community/custom project collections."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Configuration Retrieval"}),": Unable to load application settings."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Configuration Updates"}),": Changes to settings cannot be saved."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Execution Log Access"}),": Cannot retrieve historical flow execution logs."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Log Writing"}),": New execution or system activity logs cannot be recorded."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"Multi-User Collaboration"}),": Sharing flows or projects across users fails."]}),"\n",(0,s.jsxs)(o.li,{children:[(0,s.jsx)(o.strong,{children:"API Flow Loading"}),": API requests to load new flows (non-cached) fail."]}),"\n"]}),"\n",(0,s.jsx)(o.p,{children:"Flows already loaded in memory may continue to function with cached configurations.\nHowever, any operation requiring database access fails until the database is restored.\nFor example, a cached flow might run, but it won't record logs or message history to the database."}),"\n",(0,s.jsxs)(o.p,{children:["To minimize the possibility and impact of database failure, use ",(0,s.jsx)(o.a,{href:"#high-availability-for-postgresql",children:"HA configurations"})," and record backups regularly.\nFor example, you can use ",(0,s.jsx)(o.code,{children:"pg_dump"})," to create logical backups or set up continuous archiving with write-ahead logs (WAL) for point-in-time recovery.\nTest restoration procedures regularly to ensure your team understands how to execute them in a disaster recovery scenario."]}),"\n",(0,s.jsx)(o.h2,{id:"database-monitoring",children:"Database monitoring"}),"\n",(0,s.jsx)(o.p,{children:"Monitor your PostgreSQL database to ensure optimal performance and reliability:"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:"Use tools like pgAdmin, Prometheus with PostgreSQL exporter, or cloud-based monitoring for PostgreSQL."}),"\n",(0,s.jsx)(o.li,{children:"Track performance metrics such as CPU, memory, and disk I/O usage."}),"\n",(0,s.jsxs)(o.li,{children:["Monitor replica health, availability, lag, and synchronization.\nFor example, use ",(0,s.jsx)(o.code,{children:"pg_stat_activity"})," to monitor connection counts and contention."]}),"\n",(0,s.jsx)(o.li,{children:"Set up alerts and notifications for high latency, failover events, or replication issues."}),"\n",(0,s.jsxs)(o.li,{children:["Enable PostgreSQL logging, such as ",(0,s.jsx)(o.code,{children:"log_connections"})," and ",(0,s.jsx)(o.code,{children:"log_statements"}),", to track access and changes."]}),"\n"]}),"\n",(0,s.jsx)(o.h2,{id:"see-also",children:"See also"}),"\n",(0,s.jsxs)(o.ul,{children:["\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/configuration-custom-database",children:"Configure an external PostgreSQL database"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-architecture",children:"Langflow architecture on Kubernetes"})}),"\n",(0,s.jsx)(o.li,{children:(0,s.jsx)(o.a,{href:"/deployment-kubernetes-prod",children:"Deploy the Langflow production environment on Kubernetes"})}),"\n"]})]})}function m(e={}){const{wrapper:o}={...(0,r.R)(),...e.components};return o?(0,s.jsx)(o,{...e,children:(0,s.jsx)(f,{...e})}):f(e)}function y(e,o){throw new Error("Expected "+(o?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}}}]); \ No newline at end of file diff --git a/assets/js/main.926a9998.js b/assets/js/main.926a9998.js deleted file mode 100644 index cd2d02fb26..0000000000 --- a/assets/js/main.926a9998.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! For license information please see main.926a9998.js.LICENSE.txt */ -(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8792],{205:(e,t,n)=>{"use strict";n.d(t,{A:()=>o});var r=n(96540);const o=n(38193).A.canUseDOM?r.useLayoutEffect:r.useEffect},641:(e,t,n)=>{"use strict";n.r(t)},1093:e=>{"use strict";var t=Object.prototype.toString;e.exports=function(e){var n=t.call(e),r="[object Arguments]"===n;return r||(r="[object Array]"!==n&&null!==e&&"object"==typeof e&&"number"==typeof e.length&&e.length>=0&&"[object Function]"===t.call(e.callee)),r}},1189:(e,t,n)=>{"use strict";var r=Array.prototype.slice,o=n(1093),a=Object.keys,i=a?function(e){return a(e)}:n(28875),s=Object.keys;i.shim=function(){if(Object.keys){var e=function(){var e=Object.keys(arguments);return e&&e.length===arguments.length}(1,2);e||(Object.keys=function(e){return o(e)?s(r.call(e)):s(e)})}else Object.keys=i;return Object.keys||i},e.exports=i},2694:(e,t,n)=>{"use strict";var r=n(6925);function o(){}function a(){}a.resetWarningCache=o,e.exports=function(){function e(e,t,n,o,a,i){if(i!==r){var s=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw s.name="Invariant Violation",s}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:a,resetWarningCache:o};return n.PropTypes=n,n}},2833:e=>{e.exports=function(e,t,n,r){var o=n?n.call(r,e,t):void 0;if(void 0!==o)return!!o;if(e===t)return!0;if("object"!=typeof e||!e||"object"!=typeof t||!t)return!1;var a=Object.keys(e),i=Object.keys(t);if(a.length!==i.length)return!1;for(var s=Object.prototype.hasOwnProperty.bind(t),l=0;l{"use strict";n.d(t,{C:()=>r});const r="default"},3918:(e,t,n)=>{"use strict";var r=n(65606);function o(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function a(e){for(var t=1;te.length)&&(n=e.length),e.substring(n-t.length,n)===t}var w="",x="",k="",S="",_={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"};function E(e){var t=Object.keys(e),n=Object.create(Object.getPrototypeOf(e));return t.forEach(function(t){n[t]=e[t]}),Object.defineProperty(n,"message",{value:e.message}),n}function j(e){return b(e,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function O(e,t,n){var o="",a="",i=0,s="",l=!1,c=j(e),u=c.split("\n"),d=j(t).split("\n"),p=0,f="";if("strictEqual"===n&&"object"===g(e)&&"object"===g(t)&&null!==e&&null!==t&&(n="strictEqualObject"),1===u.length&&1===d.length&&u[0]!==d[0]){var m=u[0].length+d[0].length;if(m<=10){if(!("object"===g(e)&&null!==e||"object"===g(t)&&null!==t||0===e&&0===t))return"".concat(_[n],"\n\n")+"".concat(u[0]," !== ").concat(d[0],"\n")}else if("strictEqualObject"!==n){if(m<(r.stderr&&r.stderr.isTTY?r.stderr.columns:80)){for(;u[0][p]===d[0][p];)p++;p>2&&(f="\n ".concat(function(e,t){if(t=Math.floor(t),0==e.length||0==t)return"";var n=e.length*t;for(t=Math.floor(Math.log(t)/Math.log(2));t;)e+=e,t--;return e+e.substring(0,n-e.length)}(" ",p),"^"),p=0)}}}for(var h=u[u.length-1],b=d[d.length-1];h===b&&(p++<2?s="\n ".concat(h).concat(s):o=h,u.pop(),d.pop(),0!==u.length&&0!==d.length);)h=u[u.length-1],b=d[d.length-1];var y=Math.max(u.length,d.length);if(0===y){var E=c.split("\n");if(E.length>30)for(E[26]="".concat(w,"...").concat(S);E.length>27;)E.pop();return"".concat(_.notIdentical,"\n\n").concat(E.join("\n"),"\n")}p>3&&(s="\n".concat(w,"...").concat(S).concat(s),l=!0),""!==o&&(s="\n ".concat(o).concat(s),o="");var O=0,A=_[n]+"\n".concat(x,"+ actual").concat(S," ").concat(k,"- expected").concat(S),C=" ".concat(w,"...").concat(S," Lines skipped");for(p=0;p1&&p>2&&(P>4?(a+="\n".concat(w,"...").concat(S),l=!0):P>3&&(a+="\n ".concat(d[p-2]),O++),a+="\n ".concat(d[p-1]),O++),i=p,o+="\n".concat(k,"-").concat(S," ").concat(d[p]),O++;else if(d.length1&&p>2&&(P>4?(a+="\n".concat(w,"...").concat(S),l=!0):P>3&&(a+="\n ".concat(u[p-2]),O++),a+="\n ".concat(u[p-1]),O++),i=p,a+="\n".concat(x,"+").concat(S," ").concat(u[p]),O++;else{var T=d[p],I=u[p],R=I!==T&&(!v(I,",")||I.slice(0,-1)!==T);R&&v(T,",")&&T.slice(0,-1)===I&&(R=!1,I+=","),R?(P>1&&p>2&&(P>4?(a+="\n".concat(w,"...").concat(S),l=!0):P>3&&(a+="\n ".concat(u[p-2]),O++),a+="\n ".concat(u[p-1]),O++),i=p,a+="\n".concat(x,"+").concat(S," ").concat(I),o+="\n".concat(k,"-").concat(S," ").concat(T),O+=2):(a+=o,o="",1!==P&&0!==p||(a+="\n ".concat(I),O++))}if(O>20&&p30)for(f[26]="".concat(w,"...").concat(S);f.length>27;)f.pop();t=1===f.length?p.call(this,"".concat(d," ").concat(f[0])):p.call(this,"".concat(d,"\n\n").concat(f.join("\n"),"\n"))}else{var m=j(i),h="",b=_[o];"notDeepEqual"===o||"notEqual"===o?(m="".concat(_[o],"\n\n").concat(m)).length>1024&&(m="".concat(m.slice(0,1021),"...")):(h="".concat(j(s)),m.length>512&&(m="".concat(m.slice(0,509),"...")),h.length>512&&(h="".concat(h.slice(0,509),"...")),"deepEqual"===o||"equal"===o?m="".concat(b,"\n\n").concat(m,"\n\nshould equal\n\n"):h=" ".concat(o," ").concat(h)),t=p.call(this,"".concat(m).concat(h))}return Error.stackTraceLimit=l,t.generatedMessage=!n,Object.defineProperty(u(t),"name",{value:"AssertionError [ERR_ASSERTION]",enumerable:!1,writable:!0,configurable:!0}),t.code="ERR_ASSERTION",t.actual=i,t.expected=s,t.operator=o,Error.captureStackTrace&&Error.captureStackTrace(u(t),a),t.stack,t.name="AssertionError",c(t)}return i=v,(l=[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:t,value:function(e,t){return b(this,a(a({},t),{},{customInspect:!1,depth:0}))}}])&&s(i.prototype,l),d&&s(i,d),Object.defineProperty(i,"prototype",{writable:!1}),v}(d(Error),b.custom);e.exports=A},4146:(e,t,n)=>{"use strict";var r=n(44363),o={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},a={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},i={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},s={};function l(e){return r.isMemo(e)?i:s[e.$$typeof]||o}s[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},s[r.Memo]=i;var c=Object.defineProperty,u=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,p=Object.getOwnPropertyDescriptor,f=Object.getPrototypeOf,m=Object.prototype;e.exports=function e(t,n,r){if("string"!=typeof n){if(m){var o=f(n);o&&o!==m&&e(t,o,r)}var i=u(n);d&&(i=i.concat(d(n)));for(var s=l(t),h=l(n),g=0;g{"use strict";n.d(t,{A:()=>r});const r={title:"Langflow Documentation",tagline:"Langflow is a low-code app builder for RAG and multi-agent AI applications.",favicon:"img/favicon.ico",url:"https://docs.langflow.org",baseUrl:"/",onBrokenLinks:"throw",onBrokenMarkdownLinks:"warn",onBrokenAnchors:"warn",organizationName:"langflow-ai",projectName:"langflow",trailingSlash:!1,staticDirectories:["static"],i18n:{defaultLocale:"en",locales:["en"],path:"i18n",localeConfigs:{}},headTags:[{tagName:"link",attributes:{rel:"stylesheet",href:"https://fonts.googleapis.com/css2?family=Sora:wght@550;600&display=swap"}},{tagName:"script",attributes:{},innerHTML:'!function(){window.semaphore=window.semaphore||[],window.ketch=function(){window.semaphore.push(arguments)};var e=document.createElement("script");e.type="text/javascript",e.src="https://global.ketchcdn.com/web/v3/config/datastax/langflow_org_web/boot.js",e.defer=e.async=!0,document.getElementsByTagName("head")[0].appendChild(e)}();'},{tagName:"script",attributes:{defer:"true"},innerHTML:"\n ;(function () {\n const onKetchConsentGtagTrack = (consent) => {\n if (window.gtag &&\n consent.purposes &&\n 'analytics' in consent.purposes &&\n 'targeted_advertising' in consent.purposes\n ) {\n const analyticsString = consent.purposes.analytics === true ? 'granted' : 'denied'\n const targetedAdsString = consent.purposes.targeted_advertising === true ? 'granted' : 'denied'\n const gtagObject = {\n analytics_storage: analyticsString,\n ad_personalization: targetedAdsString,\n ad_storage: targetedAdsString,\n ad_user_data: targetedAdsString,\n }\n window.gtag('consent', 'update', gtagObject)\n }\n }\n if (window.ketch) {\n window.ketch('on', 'consent', onKetchConsentGtagTrack)\n }\n })()\n "}],presets:[["docusaurus-preset-openapi",{api:{path:"openapi.json",routeBasePath:"/api"},docs:{routeBasePath:"/",sidebarPath:"/home/runner/work/langflow/langflow/docs/sidebars.js",sidebarCollapsed:!0,beforeDefaultRemarkPlugins:[[null,{theme:"github-dark",showCopyButton:!0,lineNumbers:!0}]]},sitemap:{lastmod:"datetime",changefreq:null,priority:null,ignorePatterns:["/preferences"]},gtag:{trackingID:"G-SLQFLQ3KPT"},blog:!1,theme:{customCss:["/home/runner/work/langflow/langflow/docs/node_modules/@code-hike/mdx/dist/index.css","/home/runner/work/langflow/langflow/docs/css/custom.css","/home/runner/work/langflow/langflow/docs/css/docu-notion-styles.css","/home/runner/work/langflow/langflow/docs/css/gifplayer.css"]}}]],plugins:[["docusaurus-node-polyfills",{excludeAliases:["console"]}],"docusaurus-plugin-image-zoom",["./src/plugins/segment",{segmentPublicWriteKey:"60AfGDrVxy8nAGJngo3fCYWG4LvhMAlG",allowedInDev:!0}],["./src/plugins/scroll-tracking",{segmentPublicWriteKey:"60AfGDrVxy8nAGJngo3fCYWG4LvhMAlG",allowedInDev:!0,selectors:[{selector:"h1, h2, h3, h4, h5, h6",eventName:"Docs.langflow.org - Heading Viewed",properties:{element_type:"heading"}},{selector:".ch-codeblock",eventName:"Docs.langflow.org - Codeblock Viewed",properties:{element_type:"code",language:"helper:codeLanguage"}}]}],["@docusaurus/plugin-client-redirects",{redirects:[{to:"/",from:["/whats-new-a-new-chapter-langflow","/\ud83d\udc4b Welcome-to-Langflow","/getting-started-welcome-to-langflow","/guides-new-to-llms"]},{to:"/get-started-installation",from:["/getting-started-installation","/getting-started-common-installation-issues"]},{to:"/get-started-quickstart",from:"/getting-started-quickstart"},{to:"concepts-overview",from:["/workspace-overview","/365085a8-a90a-43f9-a779-f8769ec7eca1","/My-Collection","/workspace","/settings-project-general-settings"]},{to:"/concepts-components",from:["/components","/components-overview"]},{to:"/configuration-global-variables",from:"/settings-global-variables"},{to:"/concepts-playground",from:["/workspace-playground","/workspace-logs","/guides-chat-memory"]},{to:"/data-types",from:["/guides-data-message","/configuration-objects"]},{to:"/concepts-flows",from:["/travel-planning-agent","/starter-projects-travel-planning-agent","/tutorials-travel-planning-agent","/starter-projects-dynamic-agent/","/simple-agent","/math-agent","/starter-projects-simple-agent","/starter-projects-math-agent","/tutorials-math-agent","/sequential-agent","/starter-projects-sequential-agent","/tutorials-sequential-agent","/memory-chatbot","/starter-projects-memory-chatbot","/tutorials-memory-chatbot","/financial-report-parser","/document-qa","/starter-projects-document-qa","/tutorials-document-qa","/blog-writer","/starter-projects-blog-writer","/tutorials-blog-writer","/basic-prompting","/starter-projects-basic-prompting","/vector-store-rag","/starter-projects-vector-store-rag"]},{to:"/components-vector-stores",from:"/components-rag"},{to:"/api-keys-and-authentication",from:["/configuration-api-keys","/configuration-authentication","/configuration-security-best-practices","/Configuration/configuration-security-best-practices"]},{to:"/environment-variables",from:["/configuration-auto-saving","/Configuration/configuration-auto-saving","/configuration-backend-only","/Configuration/configuration-backend-only"]},{to:"/concepts-publish",from:["/concepts-api","/workspace-api"]},{to:"/components-custom-components",from:"/components/custom"},{to:"/components-bundle-components",from:"/components-loaders"},{to:"/mcp-server",from:"/integrations-mcp"},{to:"/integrations-nvidia-g-assist",from:"/integrations-nvidia-system-assist"},{to:"/deployment-kubernetes-dev",from:"/deployment-kubernetes"},{to:"/contributing-github-issues",from:"/contributing-github-discussions"},{to:"/agents",from:"/agents-tool-calling-agent-component"},{to:"/concepts-publish",from:"/embedded-chat-widget"},{to:"/bundles-google",from:"/integrations-setup-google-oauth-langflow"},{to:"/bundles-vertexai",from:"/integrations-setup-google-cloud-vertex-ai-langflow"},{to:"/develop-application",from:"/develop-overview"},{to:"/data-types",from:"/concepts-objects"}]}],null],themeConfig:{navbar:{hideOnScroll:!0,logo:{alt:"Langflow",src:"img/lf-docs-light.svg",srcDark:"img/lf-docs-dark.svg"},items:[{position:"right",href:"https://github.com/langflow-ai/langflow",className:"header-github-link",target:"_blank",rel:null,"data-event":"Docs.langflow.org - Social Clicked","data-platform":"github"},{position:"right",href:"https://twitter.com/langflow_ai",className:"header-twitter-link",target:"_blank",rel:null,"data-event":"Docs.langflow.org - Social Clicked","data-platform":"x"},{position:"right",href:"https://discord.gg/EqksyE2EX9",className:"header-discord-link",target:"_blank",rel:null,"data-event":"Docs.langflow.org - Social Clicked","data-platform":"discord"}]},colorMode:{defaultMode:"light",disableSwitch:!1,respectPrefersColorScheme:!0},prism:{theme:{plain:{color:"#393A34",backgroundColor:"#f6f8fa"},styles:[{types:["comment","prolog","doctype","cdata"],style:{color:"#999988",fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}},{types:["string","attr-value"],style:{color:"#e3116c"}},{types:["punctuation","operator"],style:{color:"#393A34"}},{types:["entity","url","symbol","number","boolean","variable","constant","property","regex","inserted"],style:{color:"#36acaa"}},{types:["atrule","keyword","attr-name","selector"],style:{color:"#00a4db"}},{types:["function","deleted","tag"],style:{color:"#d73a49"}},{types:["function-variable"],style:{color:"#6f42c1"}},{types:["tag","selector","keyword"],style:{color:"#00009f"}}]},darkTheme:{plain:{color:"#F8F8F2",backgroundColor:"#282A36"},styles:[{types:["prolog","constant","builtin"],style:{color:"rgb(189, 147, 249)"}},{types:["inserted","function"],style:{color:"rgb(80, 250, 123)"}},{types:["deleted"],style:{color:"rgb(255, 85, 85)"}},{types:["changed"],style:{color:"rgb(255, 184, 108)"}},{types:["punctuation","symbol"],style:{color:"rgb(248, 248, 242)"}},{types:["string","char","tag","selector"],style:{color:"rgb(255, 121, 198)"}},{types:["keyword","variable"],style:{color:"rgb(189, 147, 249)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(98, 114, 164)"}},{types:["attr-name"],style:{color:"rgb(241, 250, 140)"}}]},additionalLanguages:[],magicComments:[{className:"theme-code-block-highlighted-line",line:"highlight-next-line",block:{start:"highlight-start",end:"highlight-end"}}]},zoom:{selector:".markdown :not(a) > img:not(.no-zoom)",background:{light:"rgba(240, 240, 240, 0.9)"},config:{}},docs:{sidebar:{hideable:!1,autoCollapseCategories:!1},versionPersistence:"localStorage"},footer:{logo:{alt:"Langflow",src:"img/lf-docs-light.svg",srcDark:"img/lf-docs-dark.svg",width:160,height:40},links:[{title:null,items:[{html:''}]}],style:"light"},algolia:{appId:"UZK6BDPCVY",apiKey:"adbd7686dceb1cd510d5ce20d04bf74c",indexName:"langflow",contextualSearch:!0,searchParameters:{},searchPagePath:"search"},blog:{sidebar:{groupByYear:!0}},metadata:[],tableOfContents:{minHeadingLevel:2,maxHeadingLevel:3}},baseUrlIssueBanner:!0,future:{v4:{removeLegacyPostBuildHeadAttribute:!1,useCssCascadeLayers:!1},experimental_faster:{swcJsLoader:!1,swcJsMinimizer:!1,swcHtmlMinimizer:!1,lightningCssMinimizer:!1,mdxCrossCompilerCache:!1,rspackBundler:!1,rspackPersistentCache:!1,ssgWorkerThreads:!1},experimental_storage:{type:"localStorage",namespace:!1},experimental_router:"browser"},onDuplicateRoutes:"warn",customFields:{},themes:[],scripts:[],stylesheets:[],clientModules:[],titleDelimiter:"|",noIndex:!1,markdown:{format:"mdx",mermaid:!1,mdx1Compat:{comments:!0,admonitions:!0,headingIds:!0},anchors:{maintainCase:!1}}}},5260:(e,t,n)=>{"use strict";n.d(t,{A:()=>a});n(96540);var r=n(80545),o=n(74848);function a(e){return(0,o.jsx)(r.mg,{...e})}},5338:(e,t,n)=>{"use strict";var r=n(40961);t.createRoot=r.createRoot,t.hydrateRoot=r.hydrateRoot},5556:(e,t,n)=>{e.exports=n(2694)()},5947:function(e,t,n){var r,o;r=function(){var e,t,n={version:"0.2.0"},r=n.settings={minimum:.08,easing:"ease",positionUsing:"",speed:200,trickle:!0,trickleRate:.02,trickleSpeed:800,showSpinner:!0,barSelector:'[role="bar"]',spinnerSelector:'[role="spinner"]',parent:"body",template:'
'};function o(e,t,n){return en?n:e}function a(e){return 100*(-1+e)}function i(e,t,n){var o;return(o="translate3d"===r.positionUsing?{transform:"translate3d("+a(e)+"%,0,0)"}:"translate"===r.positionUsing?{transform:"translate("+a(e)+"%,0)"}:{"margin-left":a(e)+"%"}).transition="all "+t+"ms "+n,o}n.configure=function(e){var t,n;for(t in e)void 0!==(n=e[t])&&e.hasOwnProperty(t)&&(r[t]=n);return this},n.status=null,n.set=function(e){var t=n.isStarted();e=o(e,r.minimum,1),n.status=1===e?null:e;var a=n.render(!t),c=a.querySelector(r.barSelector),u=r.speed,d=r.easing;return a.offsetWidth,s(function(t){""===r.positionUsing&&(r.positionUsing=n.getPositioningCSS()),l(c,i(e,u,d)),1===e?(l(a,{transition:"none",opacity:1}),a.offsetWidth,setTimeout(function(){l(a,{transition:"all "+u+"ms linear",opacity:0}),setTimeout(function(){n.remove(),t()},u)},u)):setTimeout(t,u)}),this},n.isStarted=function(){return"number"==typeof n.status},n.start=function(){n.status||n.set(0);var e=function(){setTimeout(function(){n.status&&(n.trickle(),e())},r.trickleSpeed)};return r.trickle&&e(),this},n.done=function(e){return e||n.status?n.inc(.3+.5*Math.random()).set(1):this},n.inc=function(e){var t=n.status;return t?("number"!=typeof e&&(e=(1-t)*o(Math.random()*t,.1,.95)),t=o(t+e,0,.994),n.set(t)):n.start()},n.trickle=function(){return n.inc(Math.random()*r.trickleRate)},e=0,t=0,n.promise=function(r){return r&&"resolved"!==r.state()?(0===t&&n.start(),e++,t++,r.always(function(){0===--t?(e=0,n.done()):n.set((e-t)/e)}),this):this},n.render=function(e){if(n.isRendered())return document.getElementById("nprogress");u(document.documentElement,"nprogress-busy");var t=document.createElement("div");t.id="nprogress",t.innerHTML=r.template;var o,i=t.querySelector(r.barSelector),s=e?"-100":a(n.status||0),c=document.querySelector(r.parent);return l(i,{transition:"all 0 linear",transform:"translate3d("+s+"%,0,0)"}),r.showSpinner||(o=t.querySelector(r.spinnerSelector))&&f(o),c!=document.body&&u(c,"nprogress-custom-parent"),c.appendChild(t),t},n.remove=function(){d(document.documentElement,"nprogress-busy"),d(document.querySelector(r.parent),"nprogress-custom-parent");var e=document.getElementById("nprogress");e&&f(e)},n.isRendered=function(){return!!document.getElementById("nprogress")},n.getPositioningCSS=function(){var e=document.body.style,t="WebkitTransform"in e?"Webkit":"MozTransform"in e?"Moz":"msTransform"in e?"ms":"OTransform"in e?"O":"";return t+"Perspective"in e?"translate3d":t+"Transform"in e?"translate":"margin"};var s=function(){var e=[];function t(){var n=e.shift();n&&n(t)}return function(n){e.push(n),1==e.length&&t()}}(),l=function(){var e=["Webkit","O","Moz","ms"],t={};function n(e){return e.replace(/^-ms-/,"ms-").replace(/-([\da-z])/gi,function(e,t){return t.toUpperCase()})}function r(t){var n=document.body.style;if(t in n)return t;for(var r,o=e.length,a=t.charAt(0).toUpperCase()+t.slice(1);o--;)if((r=e[o]+a)in n)return r;return t}function o(e){return e=n(e),t[e]||(t[e]=r(e))}function a(e,t,n){t=o(t),e.style[t]=n}return function(e,t){var n,r,o=arguments;if(2==o.length)for(n in t)void 0!==(r=t[n])&&t.hasOwnProperty(n)&&a(e,n,r);else a(e,o[1],o[2])}}();function c(e,t){return("string"==typeof e?e:p(e)).indexOf(" "+t+" ")>=0}function u(e,t){var n=p(e),r=n+t;c(n,t)||(e.className=r.substring(1))}function d(e,t){var n,r=p(e);c(e,t)&&(n=r.replace(" "+t+" "," "),e.className=n.substring(1,n.length-1))}function p(e){return(" "+(e.className||"")+" ").replace(/\s+/gi," ")}function f(e){e&&e.parentNode&&e.parentNode.removeChild(e)}return n},void 0===(o="function"==typeof r?r.call(t,n,t,e):r)||(e.exports=o)},6125:(e,t,n)=>{"use strict";n.d(t,{o:()=>a,x:()=>i});var r=n(96540),o=n(74848);const a=r.createContext(!1);function i({children:e}){const[t,n]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{n(!0)},[]),(0,o.jsx)(a.Provider,{value:t,children:e})}},6188:e=>{"use strict";e.exports=Math.max},6342:(e,t,n)=>{"use strict";n.d(t,{p:()=>o});var r=n(44586);function o(){return(0,r.A)().siteConfig.themeConfig}},6549:e=>{"use strict";e.exports=Object.getOwnPropertyDescriptor},6925:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},6969:e=>{e.exports&&(e.exports={core:{meta:{path:"components/prism-core.js",option:"mandatory"},core:"Core"},themes:{meta:{path:"themes/{id}.css",link:"index.html?theme={id}",exclusive:!0},prism:{title:"Default",option:"default"},"prism-dark":"Dark","prism-funky":"Funky","prism-okaidia":{title:"Okaidia",owner:"ocodia"},"prism-twilight":{title:"Twilight",owner:"remybach"},"prism-coy":{title:"Coy",owner:"tshedor"},"prism-solarizedlight":{title:"Solarized Light",owner:"hectormatos2011 "},"prism-tomorrow":{title:"Tomorrow Night",owner:"Rosey"}},languages:{meta:{path:"components/prism-{id}",noCSS:!0,examplesPath:"examples/prism-{id}",addCheckAll:!0},markup:{title:"Markup",alias:["html","xml","svg","mathml","ssml","atom","rss"],aliasTitles:{html:"HTML",xml:"XML",svg:"SVG",mathml:"MathML",ssml:"SSML",atom:"Atom",rss:"RSS"},option:"default"},css:{title:"CSS",option:"default",modify:"markup"},clike:{title:"C-like",option:"default"},javascript:{title:"JavaScript",require:"clike",modify:"markup",optional:"regex",alias:"js",option:"default"},abap:{title:"ABAP",owner:"dellagustin"},abnf:{title:"ABNF",owner:"RunDevelopment"},actionscript:{title:"ActionScript",require:"javascript",modify:"markup",owner:"Golmote"},ada:{title:"Ada",owner:"Lucretia"},agda:{title:"Agda",owner:"xy-ren"},al:{title:"AL",owner:"RunDevelopment"},antlr4:{title:"ANTLR4",alias:"g4",owner:"RunDevelopment"},apacheconf:{title:"Apache Configuration",owner:"GuiTeK"},apex:{title:"Apex",require:["clike","sql"],owner:"RunDevelopment"},apl:{title:"APL",owner:"ngn"},applescript:{title:"AppleScript",owner:"Golmote"},aql:{title:"AQL",owner:"RunDevelopment"},arduino:{title:"Arduino",require:"cpp",alias:"ino",owner:"dkern"},arff:{title:"ARFF",owner:"Golmote"},armasm:{title:"ARM Assembly",alias:"arm-asm",owner:"RunDevelopment"},arturo:{title:"Arturo",alias:"art",optional:["bash","css","javascript","markup","markdown","sql"],owner:"drkameleon"},asciidoc:{alias:"adoc",title:"AsciiDoc",owner:"Golmote"},aspnet:{title:"ASP.NET (C#)",require:["markup","csharp"],owner:"nauzilus"},asm6502:{title:"6502 Assembly",owner:"kzurawel"},asmatmel:{title:"Atmel AVR Assembly",owner:"cerkit"},autohotkey:{title:"AutoHotkey",owner:"aviaryan"},autoit:{title:"AutoIt",owner:"Golmote"},avisynth:{title:"AviSynth",alias:"avs",owner:"Zinfidel"},"avro-idl":{title:"Avro IDL",alias:"avdl",owner:"RunDevelopment"},awk:{title:"AWK",alias:"gawk",aliasTitles:{gawk:"GAWK"},owner:"RunDevelopment"},bash:{title:"Bash",alias:["sh","shell"],aliasTitles:{sh:"Shell",shell:"Shell"},owner:"zeitgeist87"},basic:{title:"BASIC",owner:"Golmote"},batch:{title:"Batch",owner:"Golmote"},bbcode:{title:"BBcode",alias:"shortcode",aliasTitles:{shortcode:"Shortcode"},owner:"RunDevelopment"},bbj:{title:"BBj",owner:"hyyan"},bicep:{title:"Bicep",owner:"johnnyreilly"},birb:{title:"Birb",require:"clike",owner:"Calamity210"},bison:{title:"Bison",require:"c",owner:"Golmote"},bnf:{title:"BNF",alias:"rbnf",aliasTitles:{rbnf:"RBNF"},owner:"RunDevelopment"},bqn:{title:"BQN",owner:"yewscion"},brainfuck:{title:"Brainfuck",owner:"Golmote"},brightscript:{title:"BrightScript",owner:"RunDevelopment"},bro:{title:"Bro",owner:"wayward710"},bsl:{title:"BSL (1C:Enterprise)",alias:"oscript",aliasTitles:{oscript:"OneScript"},owner:"Diversus23"},c:{title:"C",require:"clike",owner:"zeitgeist87"},csharp:{title:"C#",require:"clike",alias:["cs","dotnet"],owner:"mvalipour"},cpp:{title:"C++",require:"c",owner:"zeitgeist87"},cfscript:{title:"CFScript",require:"clike",alias:"cfc",owner:"mjclemente"},chaiscript:{title:"ChaiScript",require:["clike","cpp"],owner:"RunDevelopment"},cil:{title:"CIL",owner:"sbrl"},cilkc:{title:"Cilk/C",require:"c",alias:"cilk-c",owner:"OpenCilk"},cilkcpp:{title:"Cilk/C++",require:"cpp",alias:["cilk-cpp","cilk"],owner:"OpenCilk"},clojure:{title:"Clojure",owner:"troglotit"},cmake:{title:"CMake",owner:"mjrogozinski"},cobol:{title:"COBOL",owner:"RunDevelopment"},coffeescript:{title:"CoffeeScript",require:"javascript",alias:"coffee",owner:"R-osey"},concurnas:{title:"Concurnas",alias:"conc",owner:"jasontatton"},csp:{title:"Content-Security-Policy",owner:"ScottHelme"},cooklang:{title:"Cooklang",owner:"ahue"},coq:{title:"Coq",owner:"RunDevelopment"},crystal:{title:"Crystal",require:"ruby",owner:"MakeNowJust"},"css-extras":{title:"CSS Extras",require:"css",modify:"css",owner:"milesj"},csv:{title:"CSV",owner:"RunDevelopment"},cue:{title:"CUE",owner:"RunDevelopment"},cypher:{title:"Cypher",owner:"RunDevelopment"},d:{title:"D",require:"clike",owner:"Golmote"},dart:{title:"Dart",require:"clike",owner:"Golmote"},dataweave:{title:"DataWeave",owner:"machaval"},dax:{title:"DAX",owner:"peterbud"},dhall:{title:"Dhall",owner:"RunDevelopment"},diff:{title:"Diff",owner:"uranusjr"},django:{title:"Django/Jinja2",require:"markup-templating",alias:"jinja2",owner:"romanvm"},"dns-zone-file":{title:"DNS zone file",owner:"RunDevelopment",alias:"dns-zone"},docker:{title:"Docker",alias:"dockerfile",owner:"JustinBeckwith"},dot:{title:"DOT (Graphviz)",alias:"gv",optional:"markup",owner:"RunDevelopment"},ebnf:{title:"EBNF",owner:"RunDevelopment"},editorconfig:{title:"EditorConfig",owner:"osipxd"},eiffel:{title:"Eiffel",owner:"Conaclos"},ejs:{title:"EJS",require:["javascript","markup-templating"],owner:"RunDevelopment",alias:"eta",aliasTitles:{eta:"Eta"}},elixir:{title:"Elixir",owner:"Golmote"},elm:{title:"Elm",owner:"zwilias"},etlua:{title:"Embedded Lua templating",require:["lua","markup-templating"],owner:"RunDevelopment"},erb:{title:"ERB",require:["ruby","markup-templating"],owner:"Golmote"},erlang:{title:"Erlang",owner:"Golmote"},"excel-formula":{title:"Excel Formula",alias:["xlsx","xls"],owner:"RunDevelopment"},fsharp:{title:"F#",require:"clike",owner:"simonreynolds7"},factor:{title:"Factor",owner:"catb0t"},false:{title:"False",owner:"edukisto"},"firestore-security-rules":{title:"Firestore security rules",require:"clike",owner:"RunDevelopment"},flow:{title:"Flow",require:"javascript",owner:"Golmote"},fortran:{title:"Fortran",owner:"Golmote"},ftl:{title:"FreeMarker Template Language",require:"markup-templating",owner:"RunDevelopment"},gml:{title:"GameMaker Language",alias:"gamemakerlanguage",require:"clike",owner:"LiarOnce"},gap:{title:"GAP (CAS)",owner:"RunDevelopment"},gcode:{title:"G-code",owner:"RunDevelopment"},gdscript:{title:"GDScript",owner:"RunDevelopment"},gedcom:{title:"GEDCOM",owner:"Golmote"},gettext:{title:"gettext",alias:"po",owner:"RunDevelopment"},gherkin:{title:"Gherkin",owner:"hason"},git:{title:"Git",owner:"lgiraudel"},glsl:{title:"GLSL",require:"c",owner:"Golmote"},gn:{title:"GN",alias:"gni",owner:"RunDevelopment"},"linker-script":{title:"GNU Linker Script",alias:"ld",owner:"RunDevelopment"},go:{title:"Go",require:"clike",owner:"arnehormann"},"go-module":{title:"Go module",alias:"go-mod",owner:"RunDevelopment"},gradle:{title:"Gradle",require:"clike",owner:"zeabdelkhalek-badido18"},graphql:{title:"GraphQL",optional:"markdown",owner:"Golmote"},groovy:{title:"Groovy",require:"clike",owner:"robfletcher"},haml:{title:"Haml",require:"ruby",optional:["css","css-extras","coffeescript","erb","javascript","less","markdown","scss","textile"],owner:"Golmote"},handlebars:{title:"Handlebars",require:"markup-templating",alias:["hbs","mustache"],aliasTitles:{mustache:"Mustache"},owner:"Golmote"},haskell:{title:"Haskell",alias:"hs",owner:"bholst"},haxe:{title:"Haxe",require:"clike",optional:"regex",owner:"Golmote"},hcl:{title:"HCL",owner:"outsideris"},hlsl:{title:"HLSL",require:"c",owner:"RunDevelopment"},hoon:{title:"Hoon",owner:"matildepark"},http:{title:"HTTP",optional:["csp","css","hpkp","hsts","javascript","json","markup","uri"],owner:"danielgtaylor"},hpkp:{title:"HTTP Public-Key-Pins",owner:"ScottHelme"},hsts:{title:"HTTP Strict-Transport-Security",owner:"ScottHelme"},ichigojam:{title:"IchigoJam",owner:"BlueCocoa"},icon:{title:"Icon",owner:"Golmote"},"icu-message-format":{title:"ICU Message Format",owner:"RunDevelopment"},idris:{title:"Idris",alias:"idr",owner:"KeenS",require:"haskell"},ignore:{title:".ignore",owner:"osipxd",alias:["gitignore","hgignore","npmignore"],aliasTitles:{gitignore:".gitignore",hgignore:".hgignore",npmignore:".npmignore"}},inform7:{title:"Inform 7",owner:"Golmote"},ini:{title:"Ini",owner:"aviaryan"},io:{title:"Io",owner:"AlesTsurko"},j:{title:"J",owner:"Golmote"},java:{title:"Java",require:"clike",owner:"sherblot"},javadoc:{title:"JavaDoc",require:["markup","java","javadoclike"],modify:"java",optional:"scala",owner:"RunDevelopment"},javadoclike:{title:"JavaDoc-like",modify:["java","javascript","php"],owner:"RunDevelopment"},javastacktrace:{title:"Java stack trace",owner:"RunDevelopment"},jexl:{title:"Jexl",owner:"czosel"},jolie:{title:"Jolie",require:"clike",owner:"thesave"},jq:{title:"JQ",owner:"RunDevelopment"},jsdoc:{title:"JSDoc",require:["javascript","javadoclike","typescript"],modify:"javascript",optional:["actionscript","coffeescript"],owner:"RunDevelopment"},"js-extras":{title:"JS Extras",require:"javascript",modify:"javascript",optional:["actionscript","coffeescript","flow","n4js","typescript"],owner:"RunDevelopment"},json:{title:"JSON",alias:"webmanifest",aliasTitles:{webmanifest:"Web App Manifest"},owner:"CupOfTea696"},json5:{title:"JSON5",require:"json",owner:"RunDevelopment"},jsonp:{title:"JSONP",require:"json",owner:"RunDevelopment"},jsstacktrace:{title:"JS stack trace",owner:"sbrl"},"js-templates":{title:"JS Templates",require:"javascript",modify:"javascript",optional:["css","css-extras","graphql","markdown","markup","sql"],owner:"RunDevelopment"},julia:{title:"Julia",owner:"cdagnino"},keepalived:{title:"Keepalived Configure",owner:"dev-itsheng"},keyman:{title:"Keyman",owner:"mcdurdin"},kotlin:{title:"Kotlin",alias:["kt","kts"],aliasTitles:{kts:"Kotlin Script"},require:"clike",owner:"Golmote"},kumir:{title:"KuMir (\u041a\u0443\u041c\u0438\u0440)",alias:"kum",owner:"edukisto"},kusto:{title:"Kusto",owner:"RunDevelopment"},latex:{title:"LaTeX",alias:["tex","context"],aliasTitles:{tex:"TeX",context:"ConTeXt"},owner:"japborst"},latte:{title:"Latte",require:["clike","markup-templating","php"],owner:"nette"},less:{title:"Less",require:"css",optional:"css-extras",owner:"Golmote"},lilypond:{title:"LilyPond",require:"scheme",alias:"ly",owner:"RunDevelopment"},liquid:{title:"Liquid",require:"markup-templating",owner:"cinhtau"},lisp:{title:"Lisp",alias:["emacs","elisp","emacs-lisp"],owner:"JuanCaicedo"},livescript:{title:"LiveScript",owner:"Golmote"},llvm:{title:"LLVM IR",owner:"porglezomp"},log:{title:"Log file",optional:"javastacktrace",owner:"RunDevelopment"},lolcode:{title:"LOLCODE",owner:"Golmote"},lua:{title:"Lua",owner:"Golmote"},magma:{title:"Magma (CAS)",owner:"RunDevelopment"},makefile:{title:"Makefile",owner:"Golmote"},markdown:{title:"Markdown",require:"markup",optional:"yaml",alias:"md",owner:"Golmote"},"markup-templating":{title:"Markup templating",require:"markup",owner:"Golmote"},mata:{title:"Mata",owner:"RunDevelopment"},matlab:{title:"MATLAB",owner:"Golmote"},maxscript:{title:"MAXScript",owner:"RunDevelopment"},mel:{title:"MEL",owner:"Golmote"},mermaid:{title:"Mermaid",owner:"RunDevelopment"},metafont:{title:"METAFONT",owner:"LaeriExNihilo"},mizar:{title:"Mizar",owner:"Golmote"},mongodb:{title:"MongoDB",owner:"airs0urce",require:"javascript"},monkey:{title:"Monkey",owner:"Golmote"},moonscript:{title:"MoonScript",alias:"moon",owner:"RunDevelopment"},n1ql:{title:"N1QL",owner:"TMWilds"},n4js:{title:"N4JS",require:"javascript",optional:"jsdoc",alias:"n4jsd",owner:"bsmith-n4"},"nand2tetris-hdl":{title:"Nand To Tetris HDL",owner:"stephanmax"},naniscript:{title:"Naninovel Script",owner:"Elringus",alias:"nani"},nasm:{title:"NASM",owner:"rbmj"},neon:{title:"NEON",owner:"nette"},nevod:{title:"Nevod",owner:"nezaboodka"},nginx:{title:"nginx",owner:"volado"},nim:{title:"Nim",owner:"Golmote"},nix:{title:"Nix",owner:"Golmote"},nsis:{title:"NSIS",owner:"idleberg"},objectivec:{title:"Objective-C",require:"c",alias:"objc",owner:"uranusjr"},ocaml:{title:"OCaml",owner:"Golmote"},odin:{title:"Odin",owner:"edukisto"},opencl:{title:"OpenCL",require:"c",modify:["c","cpp"],owner:"Milania1"},openqasm:{title:"OpenQasm",alias:"qasm",owner:"RunDevelopment"},oz:{title:"Oz",owner:"Golmote"},parigp:{title:"PARI/GP",owner:"Golmote"},parser:{title:"Parser",require:"markup",owner:"Golmote"},pascal:{title:"Pascal",alias:"objectpascal",aliasTitles:{objectpascal:"Object Pascal"},owner:"Golmote"},pascaligo:{title:"Pascaligo",owner:"DefinitelyNotAGoat"},psl:{title:"PATROL Scripting Language",owner:"bertysentry"},pcaxis:{title:"PC-Axis",alias:"px",owner:"RunDevelopment"},peoplecode:{title:"PeopleCode",alias:"pcode",owner:"RunDevelopment"},perl:{title:"Perl",owner:"Golmote"},php:{title:"PHP",require:"markup-templating",owner:"milesj"},phpdoc:{title:"PHPDoc",require:["php","javadoclike"],modify:"php",owner:"RunDevelopment"},"php-extras":{title:"PHP Extras",require:"php",modify:"php",owner:"milesj"},"plant-uml":{title:"PlantUML",alias:"plantuml",owner:"RunDevelopment"},plsql:{title:"PL/SQL",require:"sql",owner:"Golmote"},powerquery:{title:"PowerQuery",alias:["pq","mscript"],owner:"peterbud"},powershell:{title:"PowerShell",owner:"nauzilus"},processing:{title:"Processing",require:"clike",owner:"Golmote"},prolog:{title:"Prolog",owner:"Golmote"},promql:{title:"PromQL",owner:"arendjr"},properties:{title:".properties",owner:"Golmote"},protobuf:{title:"Protocol Buffers",require:"clike",owner:"just-boris"},pug:{title:"Pug",require:["markup","javascript"],optional:["coffeescript","ejs","handlebars","less","livescript","markdown","scss","stylus","twig"],owner:"Golmote"},puppet:{title:"Puppet",owner:"Golmote"},pure:{title:"Pure",optional:["c","cpp","fortran"],owner:"Golmote"},purebasic:{title:"PureBasic",require:"clike",alias:"pbfasm",owner:"HeX0R101"},purescript:{title:"PureScript",require:"haskell",alias:"purs",owner:"sriharshachilakapati"},python:{title:"Python",alias:"py",owner:"multipetros"},qsharp:{title:"Q#",require:"clike",alias:"qs",owner:"fedonman"},q:{title:"Q (kdb+ database)",owner:"Golmote"},qml:{title:"QML",require:"javascript",owner:"RunDevelopment"},qore:{title:"Qore",require:"clike",owner:"temnroegg"},r:{title:"R",owner:"Golmote"},racket:{title:"Racket",require:"scheme",alias:"rkt",owner:"RunDevelopment"},cshtml:{title:"Razor C#",alias:"razor",require:["markup","csharp"],optional:["css","css-extras","javascript","js-extras"],owner:"RunDevelopment"},jsx:{title:"React JSX",require:["markup","javascript"],optional:["jsdoc","js-extras","js-templates"],owner:"vkbansal"},tsx:{title:"React TSX",require:["jsx","typescript"]},reason:{title:"Reason",require:"clike",owner:"Golmote"},regex:{title:"Regex",owner:"RunDevelopment"},rego:{title:"Rego",owner:"JordanSh"},renpy:{title:"Ren'py",alias:"rpy",owner:"HyuchiaDiego"},rescript:{title:"ReScript",alias:"res",owner:"vmarcosp"},rest:{title:"reST (reStructuredText)",owner:"Golmote"},rip:{title:"Rip",owner:"ravinggenius"},roboconf:{title:"Roboconf",owner:"Golmote"},robotframework:{title:"Robot Framework",alias:"robot",owner:"RunDevelopment"},ruby:{title:"Ruby",require:"clike",alias:"rb",owner:"samflores"},rust:{title:"Rust",owner:"Golmote"},sas:{title:"SAS",optional:["groovy","lua","sql"],owner:"Golmote"},sass:{title:"Sass (Sass)",require:"css",optional:"css-extras",owner:"Golmote"},scss:{title:"Sass (SCSS)",require:"css",optional:"css-extras",owner:"MoOx"},scala:{title:"Scala",require:"java",owner:"jozic"},scheme:{title:"Scheme",owner:"bacchus123"},"shell-session":{title:"Shell session",require:"bash",alias:["sh-session","shellsession"],owner:"RunDevelopment"},smali:{title:"Smali",owner:"RunDevelopment"},smalltalk:{title:"Smalltalk",owner:"Golmote"},smarty:{title:"Smarty",require:"markup-templating",optional:"php",owner:"Golmote"},sml:{title:"SML",alias:"smlnj",aliasTitles:{smlnj:"SML/NJ"},owner:"RunDevelopment"},solidity:{title:"Solidity (Ethereum)",alias:"sol",require:"clike",owner:"glachaud"},"solution-file":{title:"Solution file",alias:"sln",owner:"RunDevelopment"},soy:{title:"Soy (Closure Template)",require:"markup-templating",owner:"Golmote"},sparql:{title:"SPARQL",require:"turtle",owner:"Triply-Dev",alias:"rq"},"splunk-spl":{title:"Splunk SPL",owner:"RunDevelopment"},sqf:{title:"SQF: Status Quo Function (Arma 3)",require:"clike",owner:"RunDevelopment"},sql:{title:"SQL",owner:"multipetros"},squirrel:{title:"Squirrel",require:"clike",owner:"RunDevelopment"},stan:{title:"Stan",owner:"RunDevelopment"},stata:{title:"Stata Ado",require:["mata","java","python"],owner:"RunDevelopment"},iecst:{title:"Structured Text (IEC 61131-3)",owner:"serhioromano"},stylus:{title:"Stylus",owner:"vkbansal"},supercollider:{title:"SuperCollider",alias:"sclang",owner:"RunDevelopment"},swift:{title:"Swift",owner:"chrischares"},systemd:{title:"Systemd configuration file",owner:"RunDevelopment"},"t4-templating":{title:"T4 templating",owner:"RunDevelopment"},"t4-cs":{title:"T4 Text Templates (C#)",require:["t4-templating","csharp"],alias:"t4",owner:"RunDevelopment"},"t4-vb":{title:"T4 Text Templates (VB)",require:["t4-templating","vbnet"],owner:"RunDevelopment"},tap:{title:"TAP",owner:"isaacs",require:"yaml"},tcl:{title:"Tcl",owner:"PeterChaplin"},tt2:{title:"Template Toolkit 2",require:["clike","markup-templating"],owner:"gflohr"},textile:{title:"Textile",require:"markup",optional:"css",owner:"Golmote"},toml:{title:"TOML",owner:"RunDevelopment"},tremor:{title:"Tremor",alias:["trickle","troy"],owner:"darach",aliasTitles:{trickle:"trickle",troy:"troy"}},turtle:{title:"Turtle",alias:"trig",aliasTitles:{trig:"TriG"},owner:"jakubklimek"},twig:{title:"Twig",require:"markup-templating",owner:"brandonkelly"},typescript:{title:"TypeScript",require:"javascript",optional:"js-templates",alias:"ts",owner:"vkbansal"},typoscript:{title:"TypoScript",alias:"tsconfig",aliasTitles:{tsconfig:"TSConfig"},owner:"dkern"},unrealscript:{title:"UnrealScript",alias:["uscript","uc"],owner:"RunDevelopment"},uorazor:{title:"UO Razor Script",owner:"jaseowns"},uri:{title:"URI",alias:"url",aliasTitles:{url:"URL"},owner:"RunDevelopment"},v:{title:"V",require:"clike",owner:"taggon"},vala:{title:"Vala",require:"clike",optional:"regex",owner:"TemplarVolk"},vbnet:{title:"VB.Net",require:"basic",owner:"Bigsby"},velocity:{title:"Velocity",require:"markup",owner:"Golmote"},verilog:{title:"Verilog",owner:"a-rey"},vhdl:{title:"VHDL",owner:"a-rey"},vim:{title:"vim",owner:"westonganger"},"visual-basic":{title:"Visual Basic",alias:["vb","vba"],aliasTitles:{vba:"VBA"},owner:"Golmote"},warpscript:{title:"WarpScript",owner:"RunDevelopment"},wasm:{title:"WebAssembly",owner:"Golmote"},"web-idl":{title:"Web IDL",alias:"webidl",owner:"RunDevelopment"},wgsl:{title:"WGSL",owner:"Dr4gonthree"},wiki:{title:"Wiki markup",require:"markup",owner:"Golmote"},wolfram:{title:"Wolfram language",alias:["mathematica","nb","wl"],aliasTitles:{mathematica:"Mathematica",nb:"Mathematica Notebook"},owner:"msollami"},wren:{title:"Wren",owner:"clsource"},xeora:{title:"Xeora",require:"markup",alias:"xeoracube",aliasTitles:{xeoracube:"XeoraCube"},owner:"freakmaxi"},"xml-doc":{title:"XML doc (.net)",require:"markup",modify:["csharp","fsharp","vbnet"],owner:"RunDevelopment"},xojo:{title:"Xojo (REALbasic)",owner:"Golmote"},xquery:{title:"XQuery",require:"markup",owner:"Golmote"},yaml:{title:"YAML",alias:"yml",owner:"hason"},yang:{title:"YANG",owner:"RunDevelopment"},zig:{title:"Zig",owner:"RunDevelopment"}},plugins:{meta:{path:"plugins/{id}/prism-{id}",link:"plugins/{id}/"},"line-highlight":{title:"Line Highlight",description:"Highlights specific lines and/or line ranges."},"line-numbers":{title:"Line Numbers",description:"Line number at the beginning of code lines.",owner:"kuba-kubula"},"show-invisibles":{title:"Show Invisibles",description:"Show hidden characters such as tabs and line breaks.",optional:["autolinker","data-uri-highlight"]},autolinker:{title:"Autolinker",description:"Converts URLs and emails in code to clickable links. Parses Markdown links in comments."},wpd:{title:"WebPlatform Docs",description:'Makes tokens link to WebPlatform.org documentation. The links open in a new tab.'},"custom-class":{title:"Custom Class",description:"This plugin allows you to prefix Prism's default classes (.comment can become .namespace--comment) or replace them with your defined ones (like .editor__comment). You can even add new classes.",owner:"dvkndn",noCSS:!0},"file-highlight":{title:"File Highlight",description:"Fetch external files and highlight them with Prism. Used on the Prism website itself.",noCSS:!0},"show-language":{title:"Show Language",description:"Display the highlighted language in code blocks (inline code does not show the label).",owner:"nauzilus",noCSS:!0,require:"toolbar"},"jsonp-highlight":{title:"JSONP Highlight",description:"Fetch content with JSONP and highlight some interesting content (e.g. GitHub/Gists or Bitbucket API).",noCSS:!0,owner:"nauzilus"},"highlight-keywords":{title:"Highlight Keywords",description:"Adds special CSS classes for each keyword for fine-grained highlighting.",owner:"vkbansal",noCSS:!0},"remove-initial-line-feed":{title:"Remove initial line feed",description:"Removes the initial line feed in code blocks.",owner:"Golmote",noCSS:!0},"inline-color":{title:"Inline color",description:"Adds a small inline preview for colors in style sheets.",require:"css-extras",owner:"RunDevelopment"},previewers:{title:"Previewers",description:"Previewers for angles, colors, gradients, easing and time.",require:"css-extras",owner:"Golmote"},autoloader:{title:"Autoloader",description:"Automatically loads the needed languages to highlight the code blocks.",owner:"Golmote",noCSS:!0},"keep-markup":{title:"Keep Markup",description:"Prevents custom markup from being dropped out during highlighting.",owner:"Golmote",optional:"normalize-whitespace",noCSS:!0},"command-line":{title:"Command Line",description:"Display a command line with a prompt and, optionally, the output/response from the commands.",owner:"chriswells0"},"unescaped-markup":{title:"Unescaped Markup",description:"Write markup without having to escape anything."},"normalize-whitespace":{title:"Normalize Whitespace",description:"Supports multiple operations to normalize whitespace in code blocks.",owner:"zeitgeist87",optional:"unescaped-markup",noCSS:!0},"data-uri-highlight":{title:"Data-URI Highlight",description:"Highlights data-URI contents.",owner:"Golmote",noCSS:!0},toolbar:{title:"Toolbar",description:"Attach a toolbar for plugins to easily register buttons on the top of a code block.",owner:"mAAdhaTTah"},"copy-to-clipboard":{title:"Copy to Clipboard Button",description:"Add a button that copies the code block to the clipboard when clicked.",owner:"mAAdhaTTah",require:"toolbar",noCSS:!0},"download-button":{title:"Download Button",description:"A button in the toolbar of a code block adding a convenient way to download a code file.",owner:"Golmote",require:"toolbar",noCSS:!0},"match-braces":{title:"Match braces",description:"Highlights matching braces.",owner:"RunDevelopment"},"diff-highlight":{title:"Diff Highlight",description:"Highlights the code inside diff blocks.",owner:"RunDevelopment",require:"diff"},"filter-highlight-all":{title:"Filter highlightAll",description:"Filters the elements the highlightAll and highlightAllUnder methods actually highlight.",owner:"RunDevelopment",noCSS:!0},treeview:{title:"Treeview",description:"A language with special styles to highlight file system tree structures.",owner:"Golmote"}}})},7176:(e,t,n)=>{"use strict";var r,o=n(73126),a=n(75795);try{r=[].__proto__===Array.prototype}catch(c){if(!c||"object"!=typeof c||!("code"in c)||"ERR_PROTO_ACCESS"!==c.code)throw c}var i=!!r&&a&&a(Object.prototype,"__proto__"),s=Object,l=s.getPrototypeOf;e.exports=i&&"function"==typeof i.get?o([i.get]):"function"==typeof l&&function(e){return l(null==e?e:s(e))}},7463:(e,t,n)=>{"use strict";var r=n(96763);function o(e,t){var n=e.length;e.push(t);e:for(;0>>1,o=e[r];if(!(0>>1;rs(l,n))cs(u,l)?(e[r]=u,e[c]=n,r=c):(e[r]=l,e[i]=n,r=i);else{if(!(cs(u,n)))break e;e[r]=u,e[c]=n,r=c}}}return t}function s(e,t){var n=e.sortIndex-t.sortIndex;return 0!==n?n:e.id-t.id}if("object"==typeof performance&&"function"==typeof performance.now){var l=performance;t.unstable_now=function(){return l.now()}}else{var c=Date,u=c.now();t.unstable_now=function(){return c.now()-u}}var d=[],p=[],f=1,m=null,h=3,g=!1,b=!1,y=!1,v="function"==typeof setTimeout?setTimeout:null,w="function"==typeof clearTimeout?clearTimeout:null,x="undefined"!=typeof setImmediate?setImmediate:null;function k(e){for(var t=a(p);null!==t;){if(null===t.callback)i(p);else{if(!(t.startTime<=e))break;i(p),t.sortIndex=t.expirationTime,o(d,t)}t=a(p)}}function S(e){if(y=!1,k(e),!b)if(null!==a(d))b=!0,D(_);else{var t=a(p);null!==t&&L(S,t.startTime-e)}}function _(e,n){b=!1,y&&(y=!1,w(A),A=-1),g=!0;var r=h;try{for(k(n),m=a(d);null!==m&&(!(m.expirationTime>n)||e&&!T());){var o=m.callback;if("function"==typeof o){m.callback=null,h=m.priorityLevel;var s=o(m.expirationTime<=n);n=t.unstable_now(),"function"==typeof s?m.callback=s:m===a(d)&&i(d),k(n)}else i(d);m=a(d)}if(null!==m)var l=!0;else{var c=a(p);null!==c&&L(S,c.startTime-n),l=!1}return l}finally{m=null,h=r,g=!1}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var E,j=!1,O=null,A=-1,C=5,P=-1;function T(){return!(t.unstable_now()-Pe||125i?(e.sortIndex=r,o(p,e),null===a(d)&&e===a(p)&&(y?(w(A),A=-1):y=!0,L(S,r-i))):(e.sortIndex=s,o(d,e),b||g||(b=!0,D(_))),e},t.unstable_shouldYield=T,t.unstable_wrapCallback=function(e){var t=h;return function(){var n=h;h=t;try{return e.apply(this,arguments)}finally{h=n}}}},8505:(e,t,n)=>{var r=n(64634);e.exports=h,e.exports.parse=a,e.exports.compile=function(e,t){return c(a(e,t),t)},e.exports.tokensToFunction=c,e.exports.tokensToRegExp=m;var o=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function a(e,t){for(var n,r=[],a=0,s=0,l="",c=t&&t.delimiter||"/";null!=(n=o.exec(e));){var u=n[0],p=n[1],f=n.index;if(l+=e.slice(s,f),s=f+u.length,p)l+=p[1];else{var m=e[s],h=n[2],g=n[3],b=n[4],y=n[5],v=n[6],w=n[7];l&&(r.push(l),l="");var x=null!=h&&null!=m&&m!==h,k="+"===v||"*"===v,S="?"===v||"*"===v,_=h||c,E=b||y,j=h||("string"==typeof r[r.length-1]?r[r.length-1]:"");r.push({name:g||a++,prefix:h||"",delimiter:_,optional:S,repeat:k,partial:x,asterisk:!!w,pattern:E?d(E):w?".*":i(_,j)})}}return s-1?"[^"+u(e)+"]+?":u(t)+"|(?:(?!"+u(t)+")[^"+u(e)+"])+?"}function s(e){return encodeURI(e).replace(/[\/?#]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}function l(e){return encodeURI(e).replace(/[?#]/g,function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()})}function c(e,t){for(var n=new Array(e.length),o=0;o{var r=n(96763);const o=n(6969),a=n(98380),i=new Set;function s(e){void 0===e?e=Object.keys(o.languages).filter(e=>"meta"!=e):Array.isArray(e)||(e=[e]);const t=[...i,...Object.keys(Prism.languages)];a(o,e,t).load(e=>{if(!(e in o.languages))return void(s.silent||r.warn("Language does not exist: "+e));const t="./prism-"+e;delete n.c[n(63157).resolve(t)],delete Prism.languages[e],n(63157)(t),i.add(e)})}s.silent=!1,e.exports=s},9394:(e,t,n)=>{"use strict";var r=n(89211);e.exports=function(){return"function"==typeof Object.is?Object.is:r}},9957:(e,t,n)=>{"use strict";var r=Function.prototype.call,o=Object.prototype.hasOwnProperty,a=n(66743);e.exports=a.call(r,o)},10076:e=>{"use strict";e.exports=Function.prototype.call},10119:(e,t,n)=>{"use strict";n.r(t)},10487:(e,t,n)=>{"use strict";var r=n(96897),o=n(30655),a=n(73126),i=n(12205);e.exports=function(e){var t=a(arguments),n=e.length-(arguments.length-1);return r(t,1+(n>0?n:0),!0)},o?o(e.exports,"apply",{value:i}):e.exports.apply=i},11002:e=>{"use strict";e.exports=Function.prototype.apply},11514:(e,t,n)=>{"use strict";var r=n(38403);e.exports=function(){return Object.assign?function(){if(!Object.assign)return!1;for(var e="abcdefghijklmnopqrst",t=e.split(""),n={},r=0;r{"use strict";n.d(t,{A:()=>a});var r=!0,o="Invariant failed";function a(e,t){if(!e){if(r)throw new Error(o);var n="function"==typeof t?t():t,a=n?"".concat(o,": ").concat(n):o;throw new Error(a)}}},11818:(e,t,n)=>{"use strict";n.r(t)},12205:(e,t,n)=>{"use strict";var r=n(66743),o=n(11002),a=n(13144);e.exports=function(){return a(r,o,arguments)}},12838:(e,t,n)=>{"use strict";n.d(t,{A:()=>qt});var r=n(96540),o=n(18215),a=n(67489),i=n(45500),s=n(56347),l=n(21312),c=n(75062),u=n(74848);const d="__docusaurus_skipToContent_fallback";function p(e){e.setAttribute("tabindex","-1"),e.focus(),e.removeAttribute("tabindex")}function f(){const e=(0,r.useRef)(null),{action:t}=(0,s.W6)(),n=(0,r.useCallback)(e=>{e.preventDefault();const t=document.querySelector("main:first-of-type")??document.getElementById(d);t&&p(t)},[]);return(0,c.$)(({location:n})=>{e.current&&!n.hash&&"PUSH"===t&&p(e.current)}),{containerRef:e,onClick:n}}const m=(0,l.T)({id:"theme.common.skipToMainContent",description:"The skip to content label used for accessibility, allowing to rapidly navigate to main content with keyboard tab/enter navigation",message:"Skip to main content"});function h(e){const t=e.children??m,{containerRef:n,onClick:r}=f();return(0,u.jsx)("div",{ref:n,role:"region","aria-label":m,children:(0,u.jsx)("a",{...e,href:`#${d}`,onClick:r,children:t})})}var g=n(17559),b=n(14090);const y={skipToContent:"skipToContent_fXgn"};function v(){return(0,u.jsx)(h,{className:y.skipToContent})}var w=n(6342),x=n(65041);function k({width:e=21,height:t=21,color:n="currentColor",strokeWidth:r=1.2,className:o,...a}){return(0,u.jsx)("svg",{viewBox:"0 0 15 15",width:e,height:t,...a,children:(0,u.jsx)("g",{stroke:n,strokeWidth:r,children:(0,u.jsx)("path",{d:"M.75.75l13.5 13.5M14.25.75L.75 14.25"})})})}const S={closeButton:"closeButton_CVFx"};function _(e){return(0,u.jsx)("button",{type:"button","aria-label":(0,l.T)({id:"theme.AnnouncementBar.closeButtonAriaLabel",message:"Close",description:"The ARIA label for close button of announcement bar"}),...e,className:(0,o.A)("clean-btn close",S.closeButton,e.className),children:(0,u.jsx)(k,{width:14,height:14,strokeWidth:3.1})})}const E={content:"content_knG7"};function j(e){const{announcementBar:t}=(0,w.p)(),{content:n}=t;return(0,u.jsx)("div",{...e,className:(0,o.A)(E.content,e.className),dangerouslySetInnerHTML:{__html:n}})}const O={announcementBar:"announcementBar_mb4j",announcementBarPlaceholder:"announcementBarPlaceholder_vyr4",announcementBarClose:"announcementBarClose_gvF7",announcementBarContent:"announcementBarContent_xLdY"};function A(){const{announcementBar:e}=(0,w.p)(),{isActive:t,close:n}=(0,x.M)();if(!t)return null;const{backgroundColor:r,textColor:a,isCloseable:i}=e;return(0,u.jsxs)("div",{className:(0,o.A)(g.G.announcementBar.container,O.announcementBar),style:{backgroundColor:r,color:a},role:"banner",children:[i&&(0,u.jsx)("div",{className:O.announcementBarPlaceholder}),(0,u.jsx)(j,{className:O.announcementBarContent}),i&&(0,u.jsx)(_,{onClick:n,className:O.announcementBarClose})]})}var C=n(22069),P=n(23104);var T=n(89532),I=n(75600);const R=r.createContext(null);function N({children:e}){const t=function(){const e=(0,C.M)(),t=(0,I.YL)(),[n,o]=(0,r.useState)(!1),a=null!==t.component,i=(0,T.ZC)(a);return(0,r.useEffect)(()=>{a&&!i&&o(!0)},[a,i]),(0,r.useEffect)(()=>{a?e.shown||o(!0):o(!1)},[e.shown,a]),(0,r.useMemo)(()=>[n,o],[n])}();return(0,u.jsx)(R.Provider,{value:t,children:e})}function D(e){if(e.component){const t=e.component;return(0,u.jsx)(t,{...e.props})}}function L(){const e=(0,r.useContext)(R);if(!e)throw new T.dV("NavbarSecondaryMenuDisplayProvider");const[t,n]=e,o=(0,r.useCallback)(()=>n(!1),[n]),a=(0,I.YL)();return(0,r.useMemo)(()=>({shown:t,hide:o,content:D(a)}),[o,a,t])}function M(e){return parseInt(r.version.split(".")[0],10)<19?{inert:e?"":void 0}:{inert:e}}function F({children:e,inert:t}){return(0,u.jsx)("div",{className:(0,o.A)(g.G.layout.navbar.mobileSidebar.panel,"navbar-sidebar__item menu"),...M(t),children:e})}function z({header:e,primaryMenu:t,secondaryMenu:n}){const{shown:r}=L();return(0,u.jsxs)("div",{className:(0,o.A)(g.G.layout.navbar.mobileSidebar.container,"navbar-sidebar"),children:[e,(0,u.jsxs)("div",{className:(0,o.A)("navbar-sidebar__items",{"navbar-sidebar__items--show-secondary":r}),children:[(0,u.jsx)(F,{inert:r,children:t}),(0,u.jsx)(F,{inert:!r,children:n})]})]})}var B=n(95293),U=n(92303);function q(e){return(0,u.jsx)("svg",{viewBox:"0 0 24 24",width:24,height:24,...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"})})}function $(e){return(0,u.jsx)("svg",{viewBox:"0 0 24 24",width:24,height:24,...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"})})}function H(e){return(0,u.jsx)("svg",{viewBox:"0 0 24 24",width:24,height:24,...e,children:(0,u.jsx)("path",{fill:"currentColor",d:"m12 21c4.971 0 9-4.029 9-9s-4.029-9-9-9-9 4.029-9 9 4.029 9 9 9zm4.95-13.95c1.313 1.313 2.05 3.093 2.05 4.95s-0.738 3.637-2.05 4.95c-1.313 1.313-3.093 2.05-4.95 2.05v-14c1.857 0 3.637 0.737 4.95 2.05z"})})}const G="toggle_vylO",V="toggleButton_gllP",W="toggleIcon_g3eP",K="systemToggleIcon_QzmC",Q="lightToggleIcon_pyhR",Y="darkToggleIcon_wfgR",J="toggleButtonDisabled_aARS";function Z(e){switch(e){case null:return(0,l.T)({message:"system mode",id:"theme.colorToggle.ariaLabel.mode.system",description:"The name for the system color mode"});case"light":return(0,l.T)({message:"light mode",id:"theme.colorToggle.ariaLabel.mode.light",description:"The name for the light color mode"});case"dark":return(0,l.T)({message:"dark mode",id:"theme.colorToggle.ariaLabel.mode.dark",description:"The name for the dark color mode"});default:throw new Error(`unexpected color mode ${e}`)}}function X(e){return(0,l.T)({message:"Switch between dark and light mode (currently {mode})",id:"theme.colorToggle.ariaLabel",description:"The ARIA label for the color mode toggle"},{mode:Z(e)})}function ee(){return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(q,{"aria-hidden":!0,className:(0,o.A)(W,Q)}),(0,u.jsx)($,{"aria-hidden":!0,className:(0,o.A)(W,Y)}),(0,u.jsx)(H,{"aria-hidden":!0,className:(0,o.A)(W,K)})]})}function te({className:e,buttonClassName:t,respectPrefersColorScheme:n,value:r,onChange:a}){const i=(0,U.A)();return(0,u.jsx)("div",{className:(0,o.A)(G,e),children:(0,u.jsx)("button",{className:(0,o.A)("clean-btn",V,!i&&J,t),type:"button",onClick:()=>a(function(e,t){if(!t)return"dark"===e?"light":"dark";switch(e){case null:return"light";case"light":return"dark";case"dark":return null;default:throw new Error(`unexpected color mode ${e}`)}}(r,n)),disabled:!i,title:Z(r),"aria-label":X(r),children:(0,u.jsx)(ee,{})})})}const ne=r.memo(te),re={darkNavbarColorModeToggle:"darkNavbarColorModeToggle_X3D1"};function oe({className:e}){const t=(0,w.p)().navbar.style,{disableSwitch:n,respectPrefersColorScheme:r}=(0,w.p)().colorMode,{colorModeChoice:o,setColorMode:a}=(0,B.G)();return n?null:(0,u.jsx)(ne,{className:e,buttonClassName:"dark"===t?re.darkNavbarColorModeToggle:void 0,respectPrefersColorScheme:r,value:o,onChange:a})}var ae=n(23465);function ie(){return(0,u.jsx)(ae.A,{className:"navbar__brand",imageClassName:"navbar__logo",titleClassName:"navbar__title text--truncate"})}function se(){const e=(0,C.M)();return(0,u.jsx)("button",{type:"button","aria-label":(0,l.T)({id:"theme.docs.sidebar.closeSidebarButtonAriaLabel",message:"Close navigation bar",description:"The ARIA label for close button of mobile sidebar"}),className:"clean-btn navbar-sidebar__close",onClick:()=>e.toggle(),children:(0,u.jsx)(k,{color:"var(--ifm-color-emphasis-600)"})})}function le(){return(0,u.jsxs)("div",{className:"navbar-sidebar__brand",children:[(0,u.jsx)(ie,{}),(0,u.jsx)(oe,{className:"margin-right--md"}),(0,u.jsx)(se,{})]})}var ce=n(28774),ue=n(86025),de=n(16654),pe=n(91252),fe=n(43186);function me({activeBasePath:e,activeBaseRegex:t,to:n,href:r,label:o,html:a,isDropdownLink:i,prependBaseUrlToHref:s,...l}){const c=(0,ue.Ay)(n),d=(0,ue.Ay)(e),p=(0,ue.Ay)(r,{forcePrependBaseUrl:!0}),f=o&&r&&!(0,de.A)(r),m=a?{dangerouslySetInnerHTML:{__html:a}}:{children:(0,u.jsxs)(u.Fragment,{children:[o,f&&(0,u.jsx)(fe.A,{...i&&{width:12,height:12}})]})};return r?(0,u.jsx)(ce.A,{href:s?p:r,...l,...m}):(0,u.jsx)(ce.A,{to:c,isNavLink:!0,...(e||t)&&{isActive:(e,n)=>t?(0,pe.G)(t,n.pathname):n.pathname.startsWith(d)},...l,...m})}function he({className:e,isDropdownItem:t,...n}){return(0,u.jsx)("li",{className:"menu__list-item",children:(0,u.jsx)(me,{className:(0,o.A)("menu__link",e),...n})})}function ge({className:e,isDropdownItem:t=!1,...n}){const r=(0,u.jsx)(me,{className:(0,o.A)(t?"dropdown__link":"navbar__item navbar__link",e),isDropdownLink:t,...n});return t?(0,u.jsx)("li",{children:r}):r}function be({mobile:e=!1,position:t,...n}){const r=e?he:ge;return(0,u.jsx)(r,{...n,activeClassName:n.activeClassName??(e?"menu__link--active":"navbar__link--active")})}var ye=n(41422),ve=n(99169),we=n(44586);const xe="dropdownNavbarItemMobile_J0Sd";function ke(e,t){return e.some(e=>function(e,t){return!!(0,ve.ys)(e.to,t)||!!(0,pe.G)(e.activeBaseRegex,t)||!(!e.activeBasePath||!t.startsWith(e.activeBasePath))}(e,t))}function Se({collapsed:e,onClick:t}){return(0,u.jsx)("button",{"aria-label":e?(0,l.T)({id:"theme.navbar.mobileDropdown.collapseButton.expandAriaLabel",message:"Expand the dropdown",description:"The ARIA label of the button to expand the mobile dropdown navbar item"}):(0,l.T)({id:"theme.navbar.mobileDropdown.collapseButton.collapseAriaLabel",message:"Collapse the dropdown",description:"The ARIA label of the button to collapse the mobile dropdown navbar item"}),"aria-expanded":!e,type:"button",className:"clean-btn menu__caret",onClick:t})}function _e({items:e,className:t,position:n,onClick:a,...i}){const l=function(){const{siteConfig:{baseUrl:e}}=(0,we.A)(),{pathname:t}=(0,s.zy)();return t.replace(e,"/")}(),c=(0,ve.ys)(i.to,l),d=ke(e,l),{collapsed:p,toggleCollapsed:f}=function({active:e}){const{collapsed:t,toggleCollapsed:n,setCollapsed:o}=(0,ye.u)({initialState:()=>!e});return(0,r.useEffect)(()=>{e&&o(!1)},[e,o]),{collapsed:t,toggleCollapsed:n}}({active:c||d}),m=i.to?void 0:"#";return(0,u.jsxs)("li",{className:(0,o.A)("menu__list-item",{"menu__list-item--collapsed":p}),children:[(0,u.jsxs)("div",{className:(0,o.A)("menu__list-item-collapsible",{"menu__list-item-collapsible--active":c}),children:[(0,u.jsx)(me,{role:"button",className:(0,o.A)(xe,"menu__link menu__link--sublist",t),href:m,...i,onClick:e=>{"#"===m&&e.preventDefault(),f()},children:i.children??i.label}),(0,u.jsx)(Se,{collapsed:p,onClick:e=>{e.preventDefault(),f()}})]}),(0,u.jsx)(ye.N,{lazy:!0,as:"ul",className:"menu__list",collapsed:p,children:e.map((e,t)=>(0,r.createElement)(Xe,{mobile:!0,isDropdownItem:!0,onClick:a,activeClassName:"menu__link--active",...e,key:t}))})]})}function Ee({items:e,position:t,className:n,onClick:a,...i}){const s=(0,r.useRef)(null),[l,c]=(0,r.useState)(!1);return(0,r.useEffect)(()=>{const e=e=>{s.current&&!s.current.contains(e.target)&&c(!1)};return document.addEventListener("mousedown",e),document.addEventListener("touchstart",e),document.addEventListener("focusin",e),()=>{document.removeEventListener("mousedown",e),document.removeEventListener("touchstart",e),document.removeEventListener("focusin",e)}},[s]),(0,u.jsxs)("div",{ref:s,className:(0,o.A)("navbar__item","dropdown","dropdown--hoverable",{"dropdown--right":"right"===t,"dropdown--show":l}),children:[(0,u.jsx)(me,{"aria-haspopup":"true","aria-expanded":l,role:"button",href:i.to?void 0:"#",className:(0,o.A)("navbar__link",n),...i,onClick:i.to?void 0:e=>e.preventDefault(),onKeyDown:e=>{"Enter"===e.key&&(e.preventDefault(),c(!l))},children:i.children??i.label}),(0,u.jsx)("ul",{className:"dropdown__menu",children:e.map((e,t)=>(0,r.createElement)(Xe,{isDropdownItem:!0,activeClassName:"dropdown__link--active",...e,key:t}))})]})}function je({mobile:e=!1,...t}){const n=e?_e:Ee;return(0,u.jsx)(n,{...t})}var Oe=n(32131);function Ae({width:e=20,height:t=20,...n}){return(0,u.jsx)("svg",{viewBox:"0 0 24 24",width:e,height:t,"aria-hidden":!0,...n,children:(0,u.jsx)("path",{fill:"currentColor",d:"M12.87 15.07l-2.54-2.51.03-.03c1.74-1.94 2.98-4.17 3.71-6.53H17V4h-7V2H8v2H1v1.99h11.17C11.5 7.92 10.44 9.75 9 11.35 8.07 10.32 7.3 9.19 6.69 8h-2c.73 1.63 1.73 3.17 2.98 4.56l-5.09 5.02L4 19l5-5 3.11 3.11.76-2.04zM18.5 10h-2L12 22h2l1.12-3h4.75L21 22h2l-4.5-12zm-2.62 7l1.62-4.33L19.12 17h-3.24z"})})}const Ce="iconLanguage_nlXk";var Pe=n(40961),Te=n(55600),Ie=n(5260),Re=n(24255),Ne=n(51062),De=n(2967),Le=n(82565);function Me(){return[`language:${(0,we.A)().i18n.currentLocale}`,function(){const e=(0,Le.v)();return[De.C,...e]}().map(e=>`docusaurus_tag:${e}`)]}const Fe={button:{buttonText:(0,l.T)({id:"theme.SearchBar.label",message:"Search",description:"The ARIA label and placeholder for search button"}),buttonAriaLabel:(0,l.T)({id:"theme.SearchBar.label",message:"Search",description:"The ARIA label and placeholder for search button"})},modal:{searchBox:{resetButtonTitle:(0,l.T)({id:"theme.SearchModal.searchBox.resetButtonTitle",message:"Clear the query",description:"The label and ARIA label for search box reset button"}),resetButtonAriaLabel:(0,l.T)({id:"theme.SearchModal.searchBox.resetButtonTitle",message:"Clear the query",description:"The label and ARIA label for search box reset button"}),cancelButtonText:(0,l.T)({id:"theme.SearchModal.searchBox.cancelButtonText",message:"Cancel",description:"The label and ARIA label for search box cancel button"}),cancelButtonAriaLabel:(0,l.T)({id:"theme.SearchModal.searchBox.cancelButtonText",message:"Cancel",description:"The label and ARIA label for search box cancel button"})},startScreen:{recentSearchesTitle:(0,l.T)({id:"theme.SearchModal.startScreen.recentSearchesTitle",message:"Recent",description:"The title for recent searches"}),noRecentSearchesText:(0,l.T)({id:"theme.SearchModal.startScreen.noRecentSearchesText",message:"No recent searches",description:"The text when no recent searches"}),saveRecentSearchButtonTitle:(0,l.T)({id:"theme.SearchModal.startScreen.saveRecentSearchButtonTitle",message:"Save this search",description:"The label for save recent search button"}),removeRecentSearchButtonTitle:(0,l.T)({id:"theme.SearchModal.startScreen.removeRecentSearchButtonTitle",message:"Remove this search from history",description:"The label for remove recent search button"}),favoriteSearchesTitle:(0,l.T)({id:"theme.SearchModal.startScreen.favoriteSearchesTitle",message:"Favorite",description:"The title for favorite searches"}),removeFavoriteSearchButtonTitle:(0,l.T)({id:"theme.SearchModal.startScreen.removeFavoriteSearchButtonTitle",message:"Remove this search from favorites",description:"The label for remove favorite search button"})},errorScreen:{titleText:(0,l.T)({id:"theme.SearchModal.errorScreen.titleText",message:"Unable to fetch results",description:"The title for error screen of search modal"}),helpText:(0,l.T)({id:"theme.SearchModal.errorScreen.helpText",message:"You might want to check your network connection.",description:"The help text for error screen of search modal"})},footer:{selectText:(0,l.T)({id:"theme.SearchModal.footer.selectText",message:"to select",description:"The explanatory text of the action for the enter key"}),selectKeyAriaLabel:(0,l.T)({id:"theme.SearchModal.footer.selectKeyAriaLabel",message:"Enter key",description:"The ARIA label for the Enter key button that makes the selection"}),navigateText:(0,l.T)({id:"theme.SearchModal.footer.navigateText",message:"to navigate",description:"The explanatory text of the action for the Arrow up and Arrow down key"}),navigateUpKeyAriaLabel:(0,l.T)({id:"theme.SearchModal.footer.navigateUpKeyAriaLabel",message:"Arrow up",description:"The ARIA label for the Arrow up key button that makes the navigation"}),navigateDownKeyAriaLabel:(0,l.T)({id:"theme.SearchModal.footer.navigateDownKeyAriaLabel",message:"Arrow down",description:"The ARIA label for the Arrow down key button that makes the navigation"}),closeText:(0,l.T)({id:"theme.SearchModal.footer.closeText",message:"to close",description:"The explanatory text of the action for Escape key"}),closeKeyAriaLabel:(0,l.T)({id:"theme.SearchModal.footer.closeKeyAriaLabel",message:"Escape key",description:"The ARIA label for the Escape key button that close the modal"}),searchByText:(0,l.T)({id:"theme.SearchModal.footer.searchByText",message:"Search by",description:"The text explain that the search is making by Algolia"})},noResultsScreen:{noResultsText:(0,l.T)({id:"theme.SearchModal.noResultsScreen.noResultsText",message:"No results for",description:"The text explains that there are no results for the following search"}),suggestedQueryText:(0,l.T)({id:"theme.SearchModal.noResultsScreen.suggestedQueryText",message:"Try searching for",description:"The text for the suggested query when no results are found for the following search"}),reportMissingResultsText:(0,l.T)({id:"theme.SearchModal.noResultsScreen.reportMissingResultsText",message:"Believe this query should return results?",description:"The text for the question where the user thinks there are missing results"}),reportMissingResultsLinkText:(0,l.T)({id:"theme.SearchModal.noResultsScreen.reportMissingResultsLinkText",message:"Let us know.",description:"The text for the link to report missing results"})}},placeholder:(0,l.T)({id:"theme.SearchModal.placeholder",message:"Search docs",description:"The placeholder of the input of the DocSearch pop-up modal"})};let ze=null;function Be(){return ze?Promise.resolve():Promise.all([n.e(8158).then(n.bind(n,48158)),Promise.all([n.e(1869),n.e(8913)]).then(n.bind(n,58913)),Promise.all([n.e(1869),n.e(416)]).then(n.bind(n,90416))]).then(([{DocSearchModal:e}])=>{ze=e})}function Ue({hit:e,children:t}){return(0,u.jsx)(ce.A,{to:e.url,children:t})}function qe({state:e,onClose:t}){const n=(0,Re.w)();return(0,u.jsx)(ce.A,{to:n(e.query),onClick:t,children:(0,u.jsx)(l.A,{id:"theme.SearchBar.seeAll",values:{count:e.context.nbHits},children:"See all {count} results"})})}function $e({externalUrlRegex:e,...t}){const n=function({externalUrlRegex:e}){const t=(0,s.W6)(),[n]=(0,r.useState)(()=>({navigate(n){(0,pe.G)(e,n.itemUrl)?window.location.href=n.itemUrl:t.push(n.itemUrl)}}));return n}({externalUrlRegex:e}),o=function({contextualSearch:e,...t}){const n=Me(),r=t.searchParameters?.facetFilters??[],o=e?function(e,t){const n=e=>"string"==typeof e?[e]:e;return[...n(e),...n(t)]}(n,r):r;return{...t.searchParameters,facetFilters:o}}({...t}),a=function(e){const t=(0,Ne.C)(),[n]=(0,r.useState)(()=>n=>e.transformItems?e.transformItems(n):n.map(e=>({...e,url:t(e.url)})));return n}(t),i=function(){const{siteMetadata:{docusaurusVersion:e}}=(0,we.A)();return(0,r.useCallback)(t=>(t.addAlgoliaAgent("docusaurus",e),t),[e])}(),l=(0,r.useRef)(null),c=(0,r.useRef)(null),[d,p]=(0,r.useState)(!1),[f,m]=(0,r.useState)(void 0),h=(0,r.useCallback)(()=>{if(!l.current){const e=document.createElement("div");l.current=e,document.body.insertBefore(e,document.body.firstChild)}},[]),g=(0,r.useCallback)(()=>{h(),Be().then(()=>p(!0))},[h]),b=(0,r.useCallback)(()=>{p(!1),c.current?.focus(),m(void 0)},[]),y=(0,r.useCallback)(e=>{"f"===e.key&&(e.metaKey||e.ctrlKey)||(e.preventDefault(),m(e.key),g())},[g]),v=function({closeModal:e}){return(0,r.useMemo)(()=>({state:t})=>(0,u.jsx)(qe,{state:t,onClose:e}),[e])}({closeModal:b});return(0,Te.E8)({isOpen:d,onOpen:g,onClose:b,onInput:y,searchButtonRef:c}),(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(Ie.A,{children:(0,u.jsx)("link",{rel:"preconnect",href:`https://${t.appId}-dsn.algolia.net`,crossOrigin:"anonymous"})}),(0,u.jsx)(Te.Bc,{onTouchStart:Be,onFocus:Be,onMouseOver:Be,onClick:g,ref:c,translations:t.translations?.button??Fe.button}),d&&ze&&l.current&&(0,Pe.createPortal)((0,u.jsx)(ze,{onClose:b,initialScrollY:window.scrollY,initialQuery:f,navigator:n,transformItems:a,hitComponent:Ue,transformSearchClient:i,...t.searchPagePath&&{resultsFooterComponent:v},placeholder:Fe.placeholder,...t,translations:t.translations?.modal??Fe.modal,searchParameters:o}),l.current)]})}function He(){const{siteConfig:e}=(0,we.A)();return(0,u.jsx)($e,{...e.themeConfig.algolia})}const Ge={navbarSearchContainer:"navbarSearchContainer_Bca1"};function Ve({children:e,className:t}){return(0,u.jsx)("div",{className:(0,o.A)(t,Ge.navbarSearchContainer),children:e})}var We=n(44070),Ke=n(26972);var Qe=n(53886);function Ye({docsPluginId:e,configs:t}){return function(e,t){if(t){const n=new Map(e.map(e=>[e.name,e])),r=(t,r)=>{const o=n.get(t);if(!o)throw new Error(`No docs version exist for name '${t}', please verify your 'docsVersionDropdown' navbar item versions config.\nAvailable version names:\n- ${e.map(e=>`${e.name}`).join("\n- ")}`);return{version:o,label:r?.label??o.label}};return Array.isArray(t)?t.map(e=>r(e,void 0)):Object.entries(t).map(([e,t])=>r(e,t))}return e.map(e=>({version:e,label:e.label}))}((0,We.jh)(e),t)}function Je(e,t){return t.alternateDocVersions[e.name]??function(e){return e.docs.find(t=>t.id===e.mainDocId)}(e)}const Ze={default:be,localeDropdown:function({mobile:e,dropdownItemsBefore:t,dropdownItemsAfter:n,queryString:r="",...o}){const{i18n:{currentLocale:a,locales:i,localeConfigs:c}}=(0,we.A)(),d=(0,Oe.o)(),{search:p,hash:f}=(0,s.zy)(),m=[...t,...i.map(t=>{const n=`${`pathname://${d.createUrl({locale:t,fullyQualified:!1})}`}${p}${f}${r}`;return{label:c[t].label,lang:c[t].htmlLang,to:n,target:"_self",autoAddBaseUrl:!1,className:t===a?e?"menu__link--active":"dropdown__link--active":""}}),...n],h=e?(0,l.T)({message:"Languages",id:"theme.navbar.mobileLanguageDropdown.label",description:"The label for the mobile language switcher dropdown"}):c[a].label;return(0,u.jsx)(je,{...o,mobile:e,label:(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(Ae,{className:Ce}),h]}),items:m})},search:function({mobile:e,className:t}){return e?null:(0,u.jsx)(Ve,{className:t,children:(0,u.jsx)(He,{})})},dropdown:je,html:function({value:e,className:t,mobile:n=!1,isDropdownItem:r=!1}){const a=r?"li":"div";return(0,u.jsx)(a,{className:(0,o.A)({navbar__item:!n&&!r,"menu__list-item":n},t),dangerouslySetInnerHTML:{__html:e}})},doc:function({docId:e,label:t,docsPluginId:n,...r}){const{activeDoc:o}=(0,We.zK)(n),a=(0,Ke.QB)(e,n),i=o?.path===a?.path;return null===a||a.unlisted&&!i?null:(0,u.jsx)(be,{exact:!0,...r,isActive:()=>i||!!o?.sidebar&&o.sidebar===a.sidebar,label:t??a.id,to:a.path})},docSidebar:function({sidebarId:e,label:t,docsPluginId:n,...r}){const{activeDoc:o}=(0,We.zK)(n),a=(0,Ke.fW)(e,n).link;if(!a)throw new Error(`DocSidebarNavbarItem: Sidebar with ID "${e}" doesn't have anything to be linked to.`);return(0,u.jsx)(be,{exact:!0,...r,isActive:()=>o?.sidebar===e,label:t??a.label,to:a.path})},docsVersion:function({label:e,to:t,docsPluginId:n,...r}){const o=(0,Ke.Vd)(n)[0],a=e??o.label,i=t??(e=>e.docs.find(t=>t.id===e.mainDocId))(o).path;return(0,u.jsx)(be,{...r,label:a,to:i})},docsVersionDropdown:function({mobile:e,docsPluginId:t,dropdownActiveClassDisabled:n,dropdownItemsBefore:r,dropdownItemsAfter:o,versions:a,...i}){const{search:c,hash:d}=(0,s.zy)(),p=(0,We.zK)(t),{savePreferredVersionName:f}=(0,Qe.g1)(t),m=Ye({docsPluginId:t,configs:a}),h=function({docsPluginId:e,versionItems:t}){return(0,Ke.Vd)(e).map(e=>t.find(t=>t.version===e)).filter(e=>void 0!==e)[0]??t[0]}({docsPluginId:t,versionItems:m}),g=[...r,...m.map(function({version:e,label:t}){return{label:t,to:`${Je(e,p).path}${c}${d}`,isActive:()=>e===p.activeVersion,onClick:()=>f(e.name)}}),...o],b=e&&g.length>1?(0,l.T)({id:"theme.navbar.mobileVersionsDropdown.label",message:"Versions",description:"The label for the navbar versions dropdown on mobile view"}):h.label,y=e&&g.length>1?void 0:Je(h.version,p).path;return g.length<=1?(0,u.jsx)(be,{...i,mobile:e,label:b,to:y,isActive:n?()=>!1:void 0}):(0,u.jsx)(je,{...i,mobile:e,label:b,to:y,items:g,isActive:n?()=>!1:void 0})}};function Xe({type:e,...t}){const n=function(e,t){return e&&"default"!==e?e:"items"in t?"dropdown":"default"}(e,t),r=Ze[n];if(!r)throw new Error(`No NavbarItem component found for type "${e}".`);return(0,u.jsx)(r,{...t})}function et(){const e=(0,C.M)(),t=(0,w.p)().navbar.items;return(0,u.jsx)("ul",{className:"menu__list",children:t.map((t,n)=>(0,r.createElement)(Xe,{mobile:!0,...t,onClick:()=>e.toggle(),key:n}))})}function tt(e){return(0,u.jsx)("button",{...e,type:"button",className:"clean-btn navbar-sidebar__back",children:(0,u.jsx)(l.A,{id:"theme.navbar.mobileSidebarSecondaryMenu.backButtonLabel",description:"The label of the back button to return to main menu, inside the mobile navbar sidebar secondary menu (notably used to display the docs sidebar)",children:"\u2190 Back to main menu"})})}function nt(){const e=0===(0,w.p)().navbar.items.length,t=L();return(0,u.jsxs)(u.Fragment,{children:[!e&&(0,u.jsx)(tt,{onClick:()=>t.hide()}),t.content]})}function rt(){const e=(0,C.M)();return function(e=!0){(0,r.useEffect)(()=>(document.body.style.overflow=e?"hidden":"visible",()=>{document.body.style.overflow="visible"}),[e])}(e.shown),e.shouldRender?(0,u.jsx)(z,{header:(0,u.jsx)(le,{}),primaryMenu:(0,u.jsx)(et,{}),secondaryMenu:(0,u.jsx)(nt,{})}):null}const ot={navbarHideable:"navbarHideable_m1mJ",navbarHidden:"navbarHidden_jGov"};function at(e){return(0,u.jsx)("div",{role:"presentation",...e,className:(0,o.A)("navbar-sidebar__backdrop",e.className)})}function it({children:e}){const{navbar:{hideOnScroll:t,style:n}}=(0,w.p)(),a=(0,C.M)(),{navbarRef:i,isNavbarVisible:s}=function(e){const[t,n]=(0,r.useState)(e),o=(0,r.useRef)(!1),a=(0,r.useRef)(0),i=(0,r.useCallback)(e=>{null!==e&&(a.current=e.getBoundingClientRect().height)},[]);return(0,P.Mq)(({scrollY:t},r)=>{if(!e)return;if(t=i?n(!1):t+l{if(!e)return;const r=t.location.hash;if(r?document.getElementById(r.substring(1)):void 0)return o.current=!0,void n(!1);n(!0)}),{navbarRef:i,isNavbarVisible:t}}(t);return(0,u.jsxs)("nav",{ref:i,"aria-label":(0,l.T)({id:"theme.NavBar.navAriaLabel",message:"Main",description:"The ARIA label for the main navigation"}),className:(0,o.A)(g.G.layout.navbar.container,"navbar","navbar--fixed-top",t&&[ot.navbarHideable,!s&&ot.navbarHidden],{"navbar--dark":"dark"===n,"navbar--primary":"primary"===n,"navbar-sidebar--show":a.shown}),children:[e,(0,u.jsx)(at,{onClick:a.toggle}),(0,u.jsx)(rt,{})]})}var st=n(70440);const lt={errorBoundaryError:"errorBoundaryError_a6uf",errorBoundaryFallback:"errorBoundaryFallback_VBag"};function ct(e){return(0,u.jsx)("button",{type:"button",...e,children:(0,u.jsx)(l.A,{id:"theme.ErrorPageContent.tryAgain",description:"The label of the button to try again rendering when the React error boundary captures an error",children:"Try again"})})}function ut({error:e}){const t=(0,st.rA)(e).map(e=>e.message).join("\n\nCause:\n");return(0,u.jsx)("p",{className:lt.errorBoundaryError,children:t})}class dt extends r.Component{componentDidCatch(e,t){throw this.props.onError(e,t)}render(){return this.props.children}}const pt="right";function ft({width:e=30,height:t=30,className:n,...r}){return(0,u.jsx)("svg",{className:n,width:e,height:t,viewBox:"0 0 30 30","aria-hidden":"true",...r,children:(0,u.jsx)("path",{stroke:"currentColor",strokeLinecap:"round",strokeMiterlimit:"10",strokeWidth:"2",d:"M4 7h22M4 15h22M4 23h22"})})}function mt(){const{toggle:e,shown:t}=(0,C.M)();return(0,u.jsx)("button",{onClick:e,"aria-label":(0,l.T)({id:"theme.docs.sidebar.toggleSidebarButtonAriaLabel",message:"Toggle navigation bar",description:"The ARIA label for hamburger menu button of mobile navigation"}),"aria-expanded":t,className:"navbar__toggle clean-btn",type:"button",children:(0,u.jsx)(ft,{})})}const ht={colorModeToggle:"colorModeToggle_DEke"};function gt({items:e}){return(0,u.jsx)(u.Fragment,{children:e.map((e,t)=>(0,u.jsx)(dt,{onError:t=>new Error(`A theme navbar item failed to render.\nPlease double-check the following navbar item (themeConfig.navbar.items) of your Docusaurus config:\n${JSON.stringify(e,null,2)}`,{cause:t}),children:(0,u.jsx)(Xe,{...e})},t))})}function bt({left:e,right:t}){return(0,u.jsxs)("div",{className:"navbar__inner",children:[(0,u.jsx)("div",{className:(0,o.A)(g.G.layout.navbar.containerLeft,"navbar__items"),children:e}),(0,u.jsx)("div",{className:(0,o.A)(g.G.layout.navbar.containerRight,"navbar__items navbar__items--right"),children:t})]})}function yt(){const e=(0,C.M)(),t=(0,w.p)().navbar.items,[n,r]=function(e){function t(e){return"left"===(e.position??pt)}return[e.filter(t),e.filter(e=>!t(e))]}(t),o=t.find(e=>"search"===e.type);return(0,u.jsx)(bt,{left:(0,u.jsxs)(u.Fragment,{children:[!e.disabled&&(0,u.jsx)(mt,{}),(0,u.jsx)(ie,{}),(0,u.jsx)(gt,{items:n})]}),right:(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(gt,{items:r}),(0,u.jsx)(oe,{className:ht.colorModeToggle}),!o&&(0,u.jsx)(Ve,{children:(0,u.jsx)(He,{})})]})})}function vt(){return(0,u.jsx)(it,{children:(0,u.jsx)(yt,{})})}function wt({item:e}){const{to:t,href:n,label:r,prependBaseUrlToHref:a,className:i,...s}=e,l=(0,ue.Ay)(t),c=(0,ue.Ay)(n,{forcePrependBaseUrl:!0});return(0,u.jsxs)(ce.A,{className:(0,o.A)("footer__link-item",i),...n?{href:a?c:n}:{to:l},...s,children:[r,n&&!(0,de.A)(n)&&(0,u.jsx)(fe.A,{})]})}function xt({item:e}){return e.html?(0,u.jsx)("li",{className:(0,o.A)("footer__item",e.className),dangerouslySetInnerHTML:{__html:e.html}}):(0,u.jsx)("li",{className:"footer__item",children:(0,u.jsx)(wt,{item:e})},e.href??e.to)}function kt({column:e}){return(0,u.jsxs)("div",{className:(0,o.A)(g.G.layout.footer.column,"col footer__col",e.className),children:[(0,u.jsx)("div",{className:"footer__title",children:e.title}),(0,u.jsx)("ul",{className:"footer__items clean-list",children:e.items.map((e,t)=>(0,u.jsx)(xt,{item:e},t))})]})}function St({columns:e}){return(0,u.jsx)("div",{className:"row footer__links",children:e.map((e,t)=>(0,u.jsx)(kt,{column:e},t))})}function _t(){return(0,u.jsx)("span",{className:"footer__link-separator",children:"\xb7"})}function Et({item:e}){return e.html?(0,u.jsx)("span",{className:(0,o.A)("footer__link-item",e.className),dangerouslySetInnerHTML:{__html:e.html}}):(0,u.jsx)(wt,{item:e})}function jt({links:e}){return(0,u.jsx)("div",{className:"footer__links text--center",children:(0,u.jsx)("div",{className:"footer__links",children:e.map((t,n)=>(0,u.jsxs)(r.Fragment,{children:[(0,u.jsx)(Et,{item:t}),e.length!==n+1&&(0,u.jsx)(_t,{})]},n))})})}function Ot({links:e}){return function(e){return"title"in e[0]}(e)?(0,u.jsx)(St,{columns:e}):(0,u.jsx)(jt,{links:e})}var At=n(21122);const Ct="footerLogoLink_BH7S";function Pt({logo:e}){const{withBaseUrl:t}=(0,ue.hH)(),n={light:t(e.src),dark:t(e.srcDark??e.src)};return(0,u.jsx)(At.A,{className:(0,o.A)("footer__logo",e.className),alt:e.alt,sources:n,width:e.width,height:e.height,style:e.style})}function Tt({logo:e}){return e.href?(0,u.jsx)(ce.A,{href:e.href,className:Ct,target:e.target,children:(0,u.jsx)(Pt,{logo:e})}):(0,u.jsx)(Pt,{logo:e})}function It({copyright:e}){return(0,u.jsx)("div",{className:"footer__copyright",dangerouslySetInnerHTML:{__html:e}})}function Rt({style:e,links:t,logo:n,copyright:r}){return(0,u.jsx)("footer",{className:(0,o.A)(g.G.layout.footer.container,"footer",{"footer--dark":"dark"===e}),children:(0,u.jsxs)("div",{className:"container container-fluid",children:[t,(n||r)&&(0,u.jsxs)("div",{className:"footer__bottom text--center",children:[n&&(0,u.jsx)("div",{className:"margin-bottom--sm",children:n}),r]})]})})}function Nt(){const{footer:e}=(0,w.p)();if(!e)return null;const{copyright:t,links:n,logo:r,style:o}=e;return(0,u.jsx)(Rt,{style:o,links:n&&n.length>0&&(0,u.jsx)(Ot,{links:n}),logo:r&&(0,u.jsx)(Tt,{logo:r}),copyright:t&&(0,u.jsx)(It,{copyright:t})})}const Dt=r.memo(Nt);function Lt(e){const[t,n]=(0,r.useState)(!1),o=r.useRef(null);(0,Te.E8)({isOpen:!1,onOpen:()=>{o.current?.click()}});const a=(0,u.jsxs)("div",{ref:o,onClick:()=>{document.querySelector(".DocSearch-Button")?.click()},onMouseEnter:()=>n(!0),onMouseLeave:()=>n(!1),style:{position:"fixed",right:"20px",bottom:"20px",zIndex:100,display:"flex",alignItems:"center",gap:"10px",cursor:"pointer"},children:[t&&(0,u.jsx)("div",{style:{backgroundColor:"#f6f6f6",padding:"8px 16px",borderRadius:"20px",color:"#000",fontSize:"14px",boxShadow:"0 2px 4px rgba(0,0,0,0.1)"},children:"Hi, how can I help you?"}),(0,u.jsx)("div",{style:{backgroundColor:"#f6f6f6",borderRadius:"50%",width:"48px",height:"48px",display:"flex",alignItems:"center",justifyContent:"center",boxShadow:"0 2px 4px rgba(0,0,0,0.1)"},children:(0,u.jsx)("img",{src:"/img/langflow-icon-black-transparent.svg",style:{width:"40px"},alt:"Search"})})]});return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(Dt,{...e}),a]})}const Mt=(0,T.fM)([B.a,x.o,P.Tv,Qe.VQ,i.Jx,function({children:e}){return(0,u.jsx)(I.y_,{children:(0,u.jsx)(C.e,{children:(0,u.jsx)(N,{children:e})})})}]);function Ft({children:e}){return(0,u.jsx)(Mt,{children:e})}var zt=n(51107);function Bt({error:e,tryAgain:t}){return(0,u.jsx)("main",{className:"container margin-vert--xl",children:(0,u.jsx)("div",{className:"row",children:(0,u.jsxs)("div",{className:"col col--6 col--offset-3",children:[(0,u.jsx)(zt.A,{as:"h1",className:"hero__title",children:(0,u.jsx)(l.A,{id:"theme.ErrorPageContent.title",description:"The title of the fallback page when the page crashed",children:"This page crashed."})}),(0,u.jsx)("div",{className:"margin-vert--lg",children:(0,u.jsx)(ct,{onClick:t,className:"button button--primary shadow--lw"})}),(0,u.jsx)("hr",{}),(0,u.jsx)("div",{className:"margin-vert--md",children:(0,u.jsx)(ut,{error:e})})]})})})}const Ut={mainWrapper:"mainWrapper_z2l0"};function qt(e){const{children:t,noFooter:n,wrapperClassName:r,title:s,description:l}=e;return(0,b.J)(),(0,u.jsxs)(Ft,{children:[(0,u.jsx)(i.be,{title:s,description:l}),(0,u.jsx)(v,{}),(0,u.jsx)(A,{}),(0,u.jsx)(vt,{}),(0,u.jsx)("div",{id:d,className:(0,o.A)(g.G.layout.main.container,g.G.wrapper.main,Ut.mainWrapper,r),children:(0,u.jsx)(a.A,{fallback:e=>(0,u.jsx)(Bt,{...e}),children:t})}),!n&&(0,u.jsx)(Lt,{})]})}},12983:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.addTrailingSlash=o,t.default=function(e,t){const{trailingSlash:n,baseUrl:r}=t;if(e.startsWith("#"))return e;if(void 0===n)return e;const[i]=e.split(/[#?]/),s="/"===i||i===r?i:(l=i,c=n,c?o(l):a(l));var l,c;return e.replace(i,s)},t.addLeadingSlash=function(e){return(0,r.addPrefix)(e,"/")},t.removeTrailingSlash=a;const r=n(42566);function o(e){return e.endsWith("/")?e:`${e}/`}function a(e){return(0,r.removeSuffix)(e,"/")}},13003:e=>{"use strict";e.exports=function(e){return e!=e}},13144:(e,t,n)=>{"use strict";var r=n(66743),o=n(11002),a=n(10076),i=n(47119);e.exports=i||r.call(a,o)},14035:(e,t,n)=>{"use strict";var r,o=n(36556),a=n(49092)(),i=n(9957),s=n(75795);if(a){var l=o("RegExp.prototype.exec"),c={},u=function(){throw c},d={toString:u,valueOf:u};"symbol"==typeof Symbol.toPrimitive&&(d[Symbol.toPrimitive]=u),r=function(e){if(!e||"object"!=typeof e)return!1;var t=s(e,"lastIndex");if(!(t&&i(t,"value")))return!1;try{l(e,d)}catch(n){return n===c}}}else{var p=o("Object.prototype.toString");r=function(e){return!(!e||"object"!=typeof e&&"function"!=typeof e)&&"[object RegExp]"===p(e)}}e.exports=r},14090:(e,t,n)=>{"use strict";n.d(t,{w:()=>o,J:()=>a});var r=n(96540);const o="navigation-with-keyboard";function a(){(0,r.useEffect)(()=>{function e(e){"keydown"===e.type&&"Tab"===e.key&&document.body.classList.add(o),"mousedown"===e.type&&document.body.classList.remove(o)}return document.addEventListener("keydown",e),document.addEventListener("mousedown",e),()=>{document.body.classList.remove(o),document.removeEventListener("keydown",e),document.removeEventListener("mousedown",e)}},[])}},14563:(e,t,n)=>{"use strict";n.d(t,{AL:()=>u,s$:()=>d});var r=n(96540),o=n(44586),a=n(36803),i=n(89532),s=n(74848);const l=({title:e,siteTitle:t,titleDelimiter:n})=>{const r=e?.trim();return r&&r!==t?`${r} ${n} ${t}`:t},c=(0,r.createContext)(null);function u({formatter:e,children:t}){return(0,s.jsx)(c.Provider,{value:e,children:t})}function d(){const e=function(){const e=(0,r.useContext)(c);if(null===e)throw new i.dV("TitleFormatterProvider");return e}(),{siteConfig:t}=(0,o.A)(),{title:n,titleDelimiter:s}=t,{plugin:u}=(0,a.A)();return{format:t=>e({title:t,siteTitle:n,titleDelimiter:s,plugin:u,defaultFormatter:l})}}},14875:(e,t,n)=>{"use strict";n.r(t),n.d(t,{onRouteDidUpdate:()=>d});var r=n(38193),o=n(96763);let a=!1;const i={codeLanguage:e=>{const t=e.querySelector("[data-ch-lang]")||e.closest("[data-ch-lang]");if(t){const e=t.getAttribute("data-ch-lang");if(e&&"text"!==e)return e}const n=e.closest(".theme-code-block")||e.parentElement?.closest('[class*="code"]')||e.parentElement;if(n){const e=n.querySelector('li[role="tab"][aria-selected="true"]');if(e){const t=e.textContent?.trim();if(t&&"text"!==t.toLowerCase())return t.toLowerCase()}}if(n){const e=n.querySelector('li[role="tab"]');if(e){const t=e.textContent?.trim();if(t&&"text"!==t.toLowerCase())return t.toLowerCase()}}return null}},s={selectors:[{selector:"h1, h2, h3, h4, h5, h6",eventName:"Scroll - Heading Viewed",properties:{element_type:"heading"}}]};function l(e,t={}){const n={};return Object.keys(t).forEach(r=>{const a=t[r];if("function"==typeof a)try{const t=a(e);null!=t&&(n[r]=t)}catch(s){o.warn(`Scroll tracking: Error executing function for property "${r}":`,s)}else if("string"==typeof a&&a.startsWith("helper:")){const t=a.replace("helper:","");if(i[t])try{const o=i[t](e);null!=o&&(n[r]=o)}catch(s){o.warn(`Scroll tracking: Error executing helper "${t}" for property "${r}":`,s)}else o.warn(`Scroll tracking: Unknown helper function "${t}"`)}else n[r]=a}),n.page_path=window.location.pathname,n.page_url=window.location.href,n.scroll_depth=function(){const e=window.pageYOffset||document.documentElement.scrollTop,t=Math.max(document.body.scrollHeight,document.body.offsetHeight,document.documentElement.clientHeight,document.documentElement.scrollHeight,document.documentElement.offsetHeight)-window.innerHeight;return t<=0?100:Math.min(100,Math.round(e/t*100))}(),e.tagName&&(n.tag_name=e.tagName.toLowerCase()),e.id&&(n.element_id=e.id),e.className&&(n.element_class=e.className),e.tagName&&e.tagName.match(/^H[1-6]$/)&&(n.heading_level=e.tagName.toLowerCase(),n.heading_text=e.textContent?.trim().substring(0,200),n.text=e.textContent?.trim().substring(0,200)),n}function c(e={}){if(!r.A.canUseDOM||a)return;const t=window.__SCROLL_TRACKING_CONFIG__||{},n=function(e){if(!window.IntersectionObserver)return void o.warn("IntersectionObserver not supported, element tracking disabled");const t=new IntersectionObserver(t=>{t.forEach(t=>{if(t.isIntersecting){const n=e.selectors.find(e=>t.target.matches(e.selector));if(n){const e=window.innerWidth<=768,r=t.target.matches(".ch-codeblock");setTimeout(()=>{const e=l(t.target,n.properties||{});window.analytics&&"function"==typeof window.analytics.track&&window.analytics.track(n.eventName,e)},e&&r?100:0)}}})},{threshold:.1,rootMargin:"0px"}),n=e=>{document.querySelectorAll(e.selector).forEach(e=>{e._scrollTrackingObserved||(t.observe(e),e._scrollTrackingObserved=!0)})};if(e.selectors.forEach(n),setTimeout(()=>{e.selectors.forEach(n)},1e3),window.MutationObserver){const n=new MutationObserver(n=>{n.forEach(n=>{n.addedNodes.forEach(n=>{n.nodeType===Node.ELEMENT_NODE&&e.selectors.forEach(e=>{n.matches&&n.matches(e.selector)&&(n._scrollTrackingObserved||(t.observe(n),n._scrollTrackingObserved=!0)),(n.querySelectorAll?n.querySelectorAll(e.selector):[]).forEach(e=>{e._scrollTrackingObserved||(t.observe(e),e._scrollTrackingObserved=!0)})})})})});n.observe(document.body,{childList:!0,subtree:!0}),t._mutationObserver=n}return t}({...s,...t,...e});a=!0,window._scrollTrackingObserver=n}function u(){window._scrollTrackingObserver&&(window._scrollTrackingObserver._mutationObserver&&window._scrollTrackingObserver._mutationObserver.disconnect(),window._scrollTrackingObserver.disconnect(),window._scrollTrackingObserver=null),document.querySelectorAll("[data-scroll-tracked]").forEach(e=>{delete e._scrollTrackingObserved,e.removeAttribute("data-scroll-tracked")}),a=!1}if(r.A.canUseDOM){const e=()=>{setTimeout(()=>{c()},250)};"loading"===document.readyState?document.addEventListener("DOMContentLoaded",e):"interactive"===document.readyState?setTimeout(e,100):e(),window.addEventListener("popstate",()=>{u(),setTimeout(()=>c(),100)})}function d({location:e,previousLocation:t}){r.A.canUseDOM&&t&&e.pathname!==t.pathname&&(u(),setTimeout(()=>c(),100))}},15066:(e,t,n)=>{"use strict";function r(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var a=e.length;for(t=0;to});const o=function(){for(var e,t,n=0,o="",a=arguments.length;n{"use strict";var n=Symbol.for("react.element"),r=Symbol.for("react.portal"),o=Symbol.for("react.fragment"),a=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),f=Symbol.iterator;var m={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},h=Object.assign,g={};function b(e,t,n){this.props=e,this.context=t,this.refs=g,this.updater=n||m}function y(){}function v(e,t,n){this.props=e,this.context=t,this.refs=g,this.updater=n||m}b.prototype.isReactComponent={},b.prototype.setState=function(e,t){if("object"!=typeof e&&"function"!=typeof e&&null!=e)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")},b.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},y.prototype=b.prototype;var w=v.prototype=new y;w.constructor=v,h(w,b.prototype),w.isPureReactComponent=!0;var x=Array.isArray,k=Object.prototype.hasOwnProperty,S={current:null},_={key:!0,ref:!0,__self:!0,__source:!0};function E(e,t,r){var o,a={},i=null,s=null;if(null!=t)for(o in void 0!==t.ref&&(s=t.ref),void 0!==t.key&&(i=""+t.key),t)k.call(t,o)&&!_.hasOwnProperty(o)&&(a[o]=t[o]);var l=arguments.length-2;if(1===l)a.children=r;else if(1{"use strict";function r(e){return/^(?:\w*:|\/\/)/.test(e)}function o(e){return void 0!==e&&!r(e)}n.d(t,{A:()=>o,z:()=>r})},17065:(e,t,n)=>{"use strict";n.d(t,{W:()=>r});const r="default"},17559:(e,t,n)=>{"use strict";n.d(t,{G:()=>r});const r={page:{blogListPage:"blog-list-page",blogPostPage:"blog-post-page",blogTagsListPage:"blog-tags-list-page",blogTagPostListPage:"blog-tags-post-list-page",blogAuthorsListPage:"blog-authors-list-page",blogAuthorsPostsPage:"blog-authors-posts-page",docsDocPage:"docs-doc-page",docsTagsListPage:"docs-tags-list-page",docsTagDocListPage:"docs-tags-doc-list-page",mdxPage:"mdx-page"},wrapper:{main:"main-wrapper",blogPages:"blog-wrapper",docsPages:"docs-wrapper",mdxPages:"mdx-wrapper"},common:{editThisPage:"theme-edit-this-page",lastUpdated:"theme-last-updated",backToTopButton:"theme-back-to-top-button",codeBlock:"theme-code-block",admonition:"theme-admonition",unlistedBanner:"theme-unlisted-banner",draftBanner:"theme-draft-banner",admonitionType:e=>`theme-admonition-${e}`},announcementBar:{container:"theme-announcement-bar"},layout:{navbar:{container:"theme-layout-navbar",containerLeft:"theme-layout-navbar-left",containerRight:"theme-layout-navbar-right",mobileSidebar:{container:"theme-layout-navbar-sidebar",panel:"theme-layout-navbar-sidebar-panel"}},main:{container:"theme-layout-main"},footer:{container:"theme-layout-footer",column:"theme-layout-footer-column"}},docs:{docVersionBanner:"theme-doc-version-banner",docVersionBadge:"theme-doc-version-badge",docBreadcrumbs:"theme-doc-breadcrumbs",docMarkdown:"theme-doc-markdown",docTocMobile:"theme-doc-toc-mobile",docTocDesktop:"theme-doc-toc-desktop",docFooter:"theme-doc-footer",docFooterTagsRow:"theme-doc-footer-tags-row",docFooterEditMetaRow:"theme-doc-footer-edit-meta-row",docSidebarContainer:"theme-doc-sidebar-container",docSidebarMenu:"theme-doc-sidebar-menu",docSidebarItemCategory:"theme-doc-sidebar-item-category",docSidebarItemLink:"theme-doc-sidebar-item-link",docSidebarItemCategoryLevel:e=>`theme-doc-sidebar-item-category-level-${e}`,docSidebarItemLinkLevel:e=>`theme-doc-sidebar-item-link-level-${e}`},blog:{blogFooterTagsRow:"theme-blog-footer-tags-row",blogFooterEditMetaRow:"theme-blog-footer-edit-meta-row"},pages:{pageFooterEditMetaRow:"theme-pages-footer-edit-meta-row"}}},18215:(e,t,n)=>{"use strict";function r(e){var t,n,o="";if("string"==typeof e||"number"==typeof e)o+=e;else if("object"==typeof e)if(Array.isArray(e)){var a=e.length;for(t=0;to});const o=function(){for(var e,t,n=0,o="",a=arguments.length;n{var r={"./":8722};function o(e){var t=a(e);return n(t)}function a(e){if(!n.o(r,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return r[e]}o.keys=function(){return Object.keys(r)},o.resolve=a,e.exports=o,o.id=18692},19700:()=>{!function(e){function t(e,t){return"___"+e.toUpperCase()+t+"___"}Object.defineProperties(e.languages["markup-templating"]={},{buildPlaceholders:{value:function(n,r,o,a){if(n.language===r){var i=n.tokenStack=[];n.code=n.code.replace(o,function(e){if("function"==typeof a&&!a(e))return e;for(var o,s=i.length;-1!==n.code.indexOf(o=t(r,s));)++s;return i[s]=e,o}),n.grammar=e.languages.markup}}},tokenizePlaceholders:{value:function(n,r){if(n.language===r&&n.tokenStack){n.grammar=e.languages[r];var o=0,a=Object.keys(n.tokenStack);!function i(s){for(var l=0;l=a.length);l++){var c=s[l];if("string"==typeof c||c.content&&"string"==typeof c.content){var u=a[o],d=n.tokenStack[u],p="string"==typeof c?c:c.content,f=t(r,u),m=p.indexOf(f);if(m>-1){++o;var h=p.substring(0,m),g=new e.Token(r,e.tokenize(d,n.grammar),"language-"+r,d),b=p.substring(m+f.length),y=[];h&&y.push.apply(y,i([h])),y.push(g),b&&y.push.apply(y,i([b])),"string"==typeof c?s.splice.apply(s,[l,1].concat(y)):c.content=y}}else c.content&&i(c.content)}return s}(n.tokens)}}}})}(Prism)},20311:e=>{"use strict";e.exports=function(e,t,n,r,o,a,i,s){if(!e){var l;if(void 0===t)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,o,a,i,s],u=0;(l=new Error(t.replace(/%s/g,function(){return c[u++]}))).name="Invariant Violation"}throw l.framesToPop=1,l}}},21020:(e,t,n)=>{"use strict";var r=n(96540),o=Symbol.for("react.element"),a=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,l={key:!0,ref:!0,__self:!0,__source:!0};function c(e,t,n){var r,a={},c=null,u=null;for(r in void 0!==n&&(c=""+n),void 0!==t.key&&(c=""+t.key),void 0!==t.ref&&(u=t.ref),t)i.call(t,r)&&!l.hasOwnProperty(r)&&(a[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===a[r]&&(a[r]=t[r]);return{$$typeof:o,type:e,key:c,ref:u,props:a,_owner:s.current}}t.Fragment=a,t.jsx=c,t.jsxs=c},21122:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});var r=n(96540),o=n(15066),a=n(92303),i=n(95293);const s={themedComponent:"themedComponent_mlkZ","themedComponent--light":"themedComponent--light_NVdE","themedComponent--dark":"themedComponent--dark_xIcU"};var l=n(74848);function c({className:e,children:t}){const n=(0,a.A)(),{colorMode:c}=(0,i.G)();return(0,l.jsx)(l.Fragment,{children:(n?"dark"===c?["dark"]:["light"]:["light","dark"]).map(n=>{const a=t({theme:n,className:(0,o.A)(e,s.themedComponent,s[`themedComponent--${n}`])});return(0,l.jsx)(r.Fragment,{children:a},n)})})}function u(e){const{sources:t,className:n,alt:r,...o}=e;return(0,l.jsx)(c,{className:n,children:({theme:e,className:n})=>(0,l.jsx)("img",{src:t[e],alt:r,className:n,...o})})}},21312:(e,t,n)=>{"use strict";n.d(t,{A:()=>u,T:()=>c});var r=n(96540),o=n(74848);function a(e,t){const n=e.split(/(\{\w+\})/).map((e,n)=>{if(n%2==1){const n=t?.[e.slice(1,-1)];if(void 0!==n)return n}return e});return n.some(e=>(0,r.isValidElement)(e))?n.map((e,t)=>(0,r.isValidElement)(e)?r.cloneElement(e,{key:t}):e).filter(e=>""!==e):n.join("")}var i=n(22654),s=n(96763);function l({id:e,message:t}){if(void 0===e&&void 0===t)throw new Error("Docusaurus translation declarations must have at least a translation id or a default translation message");return i[e??t]??t??e}function c({message:e,id:t},n){return a(l({message:e,id:t}),n)}function u({children:e,id:t,values:n}){if(e&&"string"!=typeof e)throw s.warn("Illegal children",e),new Error("The Docusaurus component only accept simple string values");const r=l({message:e,id:t});return(0,o.jsx)(o.Fragment,{children:a(r,n)})}},21798:(e,t,n)=>{"use strict";n.r(t)},22067:(e,t,n)=>{"use strict";var r=n(96540),o=n(5338),a=n(80545),i=n(54625),s=n(4784),l=n(38193);const c=[n(31911),n(10119),n(26134),n(76294),n(641),n(21798),n(68665),n(11818),n(73796),n(29492),n(88135),n(14875)];var u=n(35947),d=n(56347),p=n(22831),f=n(74848);function m({children:e}){return(0,f.jsx)(f.Fragment,{children:e})}var h=n(14563);const g=e=>e.defaultFormatter(e);function b({children:e}){return(0,f.jsx)(h.AL,{formatter:g,children:e})}function y({children:e}){return(0,f.jsx)(b,{children:e})}var v=n(5260),w=n(44586),x=n(86025),k=n(6342),S=n(45500),_=n(32131),E=n(14090),j=n(2967),O=n(70440),A=n(41463);function C(){const{i18n:{currentLocale:e,defaultLocale:t,localeConfigs:n}}=(0,w.A)(),r=(0,_.o)(),o=n[e].htmlLang,a=e=>e.replace("-","_");return(0,f.jsxs)(v.A,{children:[Object.entries(n).map(([e,{htmlLang:t}])=>(0,f.jsx)("link",{rel:"alternate",href:r.createUrl({locale:e,fullyQualified:!0}),hrefLang:t},e)),(0,f.jsx)("link",{rel:"alternate",href:r.createUrl({locale:t,fullyQualified:!0}),hrefLang:"x-default"}),(0,f.jsx)("meta",{property:"og:locale",content:a(o)}),Object.values(n).filter(e=>o!==e.htmlLang).map(e=>(0,f.jsx)("meta",{property:"og:locale:alternate",content:a(e.htmlLang)},`meta-og-${e.htmlLang}`))]})}function P({permalink:e}){const{siteConfig:{url:t}}=(0,w.A)(),n=function(){const{siteConfig:{url:e,baseUrl:t,trailingSlash:n}}=(0,w.A)(),{pathname:r}=(0,d.zy)();return e+(0,O.Ks)((0,x.Ay)(r),{trailingSlash:n,baseUrl:t})}(),r=e?`${t}${e}`:n;return(0,f.jsxs)(v.A,{children:[(0,f.jsx)("meta",{property:"og:url",content:r}),(0,f.jsx)("link",{rel:"canonical",href:r})]})}function T(){const{i18n:{currentLocale:e}}=(0,w.A)(),{metadata:t,image:n}=(0,k.p)();return(0,f.jsxs)(f.Fragment,{children:[(0,f.jsxs)(v.A,{children:[(0,f.jsx)("meta",{name:"twitter:card",content:"summary_large_image"}),(0,f.jsx)("body",{className:E.w})]}),n&&(0,f.jsx)(S.be,{image:n}),(0,f.jsx)(P,{}),(0,f.jsx)(C,{}),(0,f.jsx)(A.A,{tag:j.C,locale:e}),(0,f.jsx)(v.A,{children:t.map((e,t)=>(0,f.jsx)("meta",{...e},t))})]})}const I=new Map;var R=n(6125),N=n(26988),D=n(205);function L(e,...t){const n=c.map(n=>{const r=n.default?.[e]??n[e];return r?.(...t)});return()=>n.forEach(e=>e?.())}const M=function({children:e,location:t,previousLocation:n}){return(0,D.A)(()=>{n!==t&&(!function({location:e,previousLocation:t}){if(!t)return;const n=e.pathname===t.pathname,r=e.hash===t.hash,o=e.search===t.search;if(n&&r&&!o)return;const{hash:a}=e;if(a){const e=decodeURIComponent(a.substring(1)),t=document.getElementById(e);t?.scrollIntoView()}else window.scrollTo(0,0)}({location:t,previousLocation:n}),L("onRouteDidUpdate",{previousLocation:n,location:t}))},[n,t]),e};function F(e){const t=Array.from(new Set([e,decodeURI(e)])).map(e=>(0,p.u)(u.A,e)).flat();return Promise.all(t.map(e=>e.route.component.preload?.()))}var z=n(96763);class B extends r.Component{previousLocation;routeUpdateCleanupCb;constructor(e){super(e),this.previousLocation=null,this.routeUpdateCleanupCb=l.A.canUseDOM?L("onRouteUpdate",{previousLocation:null,location:this.props.location}):()=>{},this.state={nextRouteHasLoaded:!0}}shouldComponentUpdate(e,t){if(e.location===this.props.location)return t.nextRouteHasLoaded;const n=e.location;return this.previousLocation=this.props.location,this.setState({nextRouteHasLoaded:!1}),this.routeUpdateCleanupCb=L("onRouteUpdate",{previousLocation:this.previousLocation,location:n}),F(n.pathname).then(()=>{this.routeUpdateCleanupCb(),this.setState({nextRouteHasLoaded:!0})}).catch(e=>{z.warn(e),window.location.reload()}),!1}render(){const{children:e,location:t}=this.props;return(0,f.jsx)(M,{previousLocation:this.previousLocation,location:t,children:(0,f.jsx)(d.qh,{location:t,render:()=>e})})}}const U=B,q="__docusaurus-base-url-issue-banner-suggestion-container";function $(e){return`\ndocument.addEventListener('DOMContentLoaded', function maybeInsertBanner() {\n var shouldInsert = typeof window['docusaurus'] === 'undefined';\n shouldInsert && insertBanner();\n});\n\nfunction insertBanner() {\n var bannerContainer = document.createElement('div');\n bannerContainer.id = '__docusaurus-base-url-issue-banner-container';\n var bannerHtml = ${JSON.stringify(function(e){return`\n
\n

Your Docusaurus site did not load properly.

\n

A very common reason is a wrong site baseUrl configuration.

\n

Current configured baseUrl = ${e} ${"/"===e?" (default value)":""}

\n

We suggest trying baseUrl =

\n
\n`}(e)).replace(/!0===e.exact))return I.set(e.pathname,e.pathname),e;const t=e.pathname.trim().replace(/(?:\/index)?\.html$/,"")||"/";return I.set(e.pathname,t),{...e,pathname:t}}((0,d.zy)());return(0,f.jsx)(U,{location:e,children:Y})}function Z(){return(0,f.jsx)(W.A,{children:(0,f.jsx)(N.l,{children:(0,f.jsxs)(R.x,{children:[(0,f.jsx)(m,{children:(0,f.jsxs)(y,{children:[(0,f.jsx)(V,{}),(0,f.jsx)(T,{}),(0,f.jsx)(G,{}),(0,f.jsx)(J,{})]})}),(0,f.jsx)(Q,{})]})})})}var X=n(84054);const ee=function(e){try{return document.createElement("link").relList.supports(e)}catch{return!1}}("prefetch")?function(e){return new Promise((t,n)=>{if("undefined"==typeof document)return void n();const r=document.createElement("link");r.setAttribute("rel","prefetch"),r.setAttribute("href",e),r.onload=()=>t(),r.onerror=()=>n();const o=document.getElementsByTagName("head")[0]??document.getElementsByName("script")[0]?.parentNode;o?.appendChild(r)})}:function(e){return new Promise((t,n)=>{const r=new XMLHttpRequest;r.open("GET",e,!0),r.withCredentials=!0,r.onload=()=>{200===r.status?t():n()},r.send(null)})};var te=n(86921);const ne=new Set,re=new Set,oe=()=>navigator.connection?.effectiveType.includes("2g")||navigator.connection?.saveData,ae={prefetch:e=>{if(!(e=>!oe()&&!re.has(e)&&!ne.has(e))(e))return!1;ne.add(e);const t=(0,p.u)(u.A,e).flatMap(e=>{return t=e.route.path,Object.entries(X).filter(([e])=>e.replace(/-[^-]+$/,"")===t).flatMap(([,e])=>Object.values((0,te.A)(e)));var t});return Promise.all(t.map(e=>{const t=n.gca(e);return t&&!t.includes("undefined")?ee(t).catch(()=>{}):Promise.resolve()}))},preload:e=>!!(e=>!oe()&&!re.has(e))(e)&&(re.add(e),F(e))},ie=Object.freeze(ae);var se=n(96763);function le({children:e}){return"hash"===s.A.future.experimental_router?(0,f.jsx)(i.I9,{children:e}):(0,f.jsx)(i.Kd,{children:e})}const ce=Boolean(!0);if(l.A.canUseDOM){window.docusaurus=ie;const e=document.getElementById("__docusaurus"),t=(0,f.jsx)(a.vd,{children:(0,f.jsx)(le,{children:(0,f.jsx)(Z,{})})}),n=(e,t)=>{se.error("Docusaurus React Root onRecoverableError:",e,t)},i=()=>{if(window.docusaurusRoot)window.docusaurusRoot.render(t);else if(ce)window.docusaurusRoot=o.hydrateRoot(e,t,{onRecoverableError:n});else{const r=o.createRoot(e,{onRecoverableError:n});r.render(t),window.docusaurusRoot=r}};F(window.location.pathname).then(()=>{(0,r.startTransition)(i)})}},22069:(e,t,n)=>{"use strict";n.d(t,{M:()=>m,e:()=>f});var r=n(96540),o=n(75600),a=n(24581),i=n(57485),s=n(6342),l=n(89532),c=n(74848);const u=r.createContext(void 0);function d(){const e=function(){const e=(0,o.YL)(),{items:t}=(0,s.p)().navbar;return 0===t.length&&!e.component}(),t=(0,a.l)(),n=!e&&"mobile"===t,[i,l]=(0,r.useState)(!1),c=(0,r.useCallback)(()=>{l(e=>!e)},[]);return(0,r.useEffect)(()=>{"desktop"===t&&l(!1)},[t]),(0,r.useMemo)(()=>({disabled:e,shouldRender:n,toggle:c,shown:i}),[e,n,c,i])}function p({handler:e}){return(0,i.$Z)(e),null}function f({children:e}){const t=d();return(0,c.jsxs)(c.Fragment,{children:[t.shown&&(0,c.jsx)(p,{handler:()=>(t.toggle(),!1)}),(0,c.jsx)(u.Provider,{value:t,children:e})]})}function m(){const e=r.useContext(u);if(void 0===e)throw new l.dV("NavbarMobileSidebarProvider");return e}},22551:(e,t,n)=>{"use strict";var r=n(96763),o=n(96540),a=n(69982);function i(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n