diff --git a/404.html b/404.html index b912dc757f..ff9fcab1ce 100644 --- a/404.html +++ b/404.html @@ -22,8 +22,8 @@ - - + + diff --git a/agents-overview.html b/agents-overview.html index e68b7b88cf..4e2e80c5d2 100644 --- a/agents-overview.html +++ b/agents-overview.html @@ -22,8 +22,8 @@ - - + + diff --git a/agents-tool-calling-agent-component.html b/agents-tool-calling-agent-component.html index de5063c1c0..516f75a295 100644 --- a/agents-tool-calling-agent-component.html +++ b/agents-tool-calling-agent-component.html @@ -22,8 +22,8 @@ - - + + @@ -81,7 +81,7 @@ Point API Request to an online rules document, tell your agent
  • You need to learn a new software language quickly. Point API Request to some docs, tell your agent You are a knowledgeable software developer who uses the tools at your disposal, and start learning.
  • -

    See what problems you can solve with this flow. As your problem becomes more specialized, add a tool. For example, the math agent project adds a Python REPL component to solve math problems that are too challenging for the calculator.

    +

    See what problems you can solve with this flow. As your problem becomes more specialized, add more tools. For example, add a Python REPL component to solve math problems that are too challenging for the calculator.

    Edit a tool's metadata

    To edit a tool's metadata, click the Edit Tools button in the tool to modify its name or description metadata. These fields help connected agents understand how to use the tool, without having to modify the agent's prompt instructions.

    For example, the URL component has three tools available when Tool Mode is enabled.

    diff --git a/api-reference-api-examples.html b/api-reference-api-examples.html index 08af3fbe87..0f56479154 100644 --- a/api-reference-api-examples.html +++ b/api-reference-api-examples.html @@ -22,8 +22,8 @@ - - + + diff --git a/api.html b/api.html index fd885520bb..911227eea7 100644 --- a/api.html +++ b/api.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/add-user.html b/api/add-user.html index f2c1631f1e..1879672930 100644 --- a/api/add-user.html +++ b/api/add-user.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/auto-login.html b/api/auto-login.html index a39b89491a..7a03d647b5 100644 --- a/api/auto-login.html +++ b/api/auto-login.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/build-flow.html b/api/build-flow.html index 5fcf29f71a..9bc2b8d176 100644 --- a/api/build-flow.html +++ b/api/build-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/build-vertex-stream.html b/api/build-vertex-stream.html index 9fdee3c917..9c626f4d94 100644 --- a/api/build-vertex-stream.html +++ b/api/build-vertex-stream.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/build-vertex.html b/api/build-vertex.html index e7d57620f5..9006a0e0d4 100644 --- a/api/build-vertex.html +++ b/api/build-vertex.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/cancel-build.html b/api/cancel-build.html index 32b405b412..5d5f9c746a 100644 --- a/api/cancel-build.html +++ b/api/cancel-build.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/check-if-store-has-api-key.html b/api/check-if-store-has-api-key.html index e375eb7791..0b652db12b 100644 --- a/api/check-if-store-has-api-key.html +++ b/api/check-if-store-has-api-key.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/check-if-store-is-enabled.html b/api/check-if-store-is-enabled.html index 67828ac6de..0005418989 100644 --- a/api/check-if-store-is-enabled.html +++ b/api/check-if-store-is-enabled.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-api-key-route.html b/api/create-api-key-route.html index 1bd4e1141d..1f6ec672b8 100644 --- a/api/create-api-key-route.html +++ b/api/create-api-key-route.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-flow.html b/api/create-flow.html index 8d21a493b6..0231ef0b82 100644 --- a/api/create-flow.html +++ b/api/create-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-flows.html b/api/create-flows.html index b71be73006..3047dbbf8e 100644 --- a/api/create-flows.html +++ b/api/create-flows.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-folder.html b/api/create-folder.html index 17ec315c9d..8c15cd83f0 100644 --- a/api/create-folder.html +++ b/api/create-folder.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-upload-file.html b/api/create-upload-file.html index a377c6b005..5e8e36f417 100644 --- a/api/create-upload-file.html +++ b/api/create-upload-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/create-variable.html b/api/create-variable.html index 3f20ba97b6..97dd283c43 100644 --- a/api/create-variable.html +++ b/api/create-variable.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/custom-component-update.html b/api/custom-component-update.html index 2a8dd859ad..83d5f46f07 100644 --- a/api/custom-component-update.html +++ b/api/custom-component-update.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/custom-component.html b/api/custom-component.html index d0356566da..454edb280f 100644 --- a/api/custom-component.html +++ b/api/custom-component.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-all-files.html b/api/delete-all-files.html index adc4e4b9d8..6e5a0d9673 100644 --- a/api/delete-all-files.html +++ b/api/delete-all-files.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-api-key-route.html b/api/delete-api-key-route.html index f1ec09daf2..4f65217865 100644 --- a/api/delete-api-key-route.html +++ b/api/delete-api-key-route.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-file-1.html b/api/delete-file-1.html index d57839249d..bcf7e7250b 100644 --- a/api/delete-file-1.html +++ b/api/delete-file-1.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-file.html b/api/delete-file.html index f919723003..e0fc0103a0 100644 --- a/api/delete-file.html +++ b/api/delete-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-flow.html b/api/delete-flow.html index 58ebf7aec6..bd9547ad37 100644 --- a/api/delete-flow.html +++ b/api/delete-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-folder.html b/api/delete-folder.html index 89a17ba385..237a39aadd 100644 --- a/api/delete-folder.html +++ b/api/delete-folder.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-messages-session.html b/api/delete-messages-session.html index d34cd150c5..c798c3a23d 100644 --- a/api/delete-messages-session.html +++ b/api/delete-messages-session.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-messages.html b/api/delete-messages.html index b6f9be7173..93ff724319 100644 --- a/api/delete-messages.html +++ b/api/delete-messages.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-multiple-flows.html b/api/delete-multiple-flows.html index 1f4b28fc76..263e706a4b 100644 --- a/api/delete-multiple-flows.html +++ b/api/delete-multiple-flows.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-user.html b/api/delete-user.html index 535af6cbbd..dddbd6ff05 100644 --- a/api/delete-user.html +++ b/api/delete-user.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-variable.html b/api/delete-variable.html index 0aab21c3e7..2c308a60fc 100644 --- a/api/delete-variable.html +++ b/api/delete-variable.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/delete-vertex-builds.html b/api/delete-vertex-builds.html index 057ece6a0e..5352f2638d 100644 --- a/api/delete-vertex-builds.html +++ b/api/delete-vertex-builds.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-component.html b/api/download-component.html index 70d01b3c8e..18eff76a27 100644 --- a/api/download-component.html +++ b/api/download-component.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-file-1.html b/api/download-file-1.html index 2bf9cb25d9..5ec4ee8ff4 100644 --- a/api/download-file-1.html +++ b/api/download-file-1.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-file-2.html b/api/download-file-2.html index c9c5fdb1da..9e6da984f3 100644 --- a/api/download-file-2.html +++ b/api/download-file-2.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-file.html b/api/download-file.html index c219b54d45..e37ab384ca 100644 --- a/api/download-file.html +++ b/api/download-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-image.html b/api/download-image.html index 82c880b699..a1f88d9d41 100644 --- a/api/download-image.html +++ b/api/download-image.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-multiple-file.html b/api/download-multiple-file.html index 1427a1f85a..5e4227406f 100644 --- a/api/download-multiple-file.html +++ b/api/download-multiple-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/download-profile-picture.html b/api/download-profile-picture.html index e7d8e86cc3..a298ebd8aa 100644 --- a/api/download-profile-picture.html +++ b/api/download-profile-picture.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/edit-file-name.html b/api/edit-file-name.html index 99334601c8..8e6085b7fa 100644 --- a/api/edit-file-name.html +++ b/api/edit-file-name.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/experimental-run-flow.html b/api/experimental-run-flow.html index bf856897de..cf91bc1058 100644 --- a/api/experimental-run-flow.html +++ b/api/experimental-run-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-all.html b/api/get-all.html index 95d56909ba..71ed501a13 100644 --- a/api/get-all.html +++ b/api/get-all.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-api-keys-route.html b/api/get-api-keys-route.html index e89a7ab8d6..f9055400cf 100644 --- a/api/get-api-keys-route.html +++ b/api/get-api-keys-route.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-build-events.html b/api/get-build-events.html index 4fdfd0481f..79dd8d9ef7 100644 --- a/api/get-build-events.html +++ b/api/get-build-events.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-components.html b/api/get-components.html index 706b3f20c7..622d38c044 100644 --- a/api/get-components.html +++ b/api/get-components.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-config.html b/api/get-config.html index 7eed979c0b..da369832e8 100644 --- a/api/get-config.html +++ b/api/get-config.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-list-of-components-liked-by-user.html b/api/get-list-of-components-liked-by-user.html index a22735ba08..440e46f0f9 100644 --- a/api/get-list-of-components-liked-by-user.html +++ b/api/get-list-of-components-liked-by-user.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-messages.html b/api/get-messages.html index a7c6fc5da6..3b5771775c 100644 --- a/api/get-messages.html +++ b/api/get-messages.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-starter-projects.html b/api/get-starter-projects.html index 4ba2f2f6a1..41724bab6a 100644 --- a/api/get-starter-projects.html +++ b/api/get-starter-projects.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-tags.html b/api/get-tags.html index 32d7fa18c0..8ac9e42404 100644 --- a/api/get-tags.html +++ b/api/get-tags.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-task-status.html b/api/get-task-status.html index 7553619e76..14f189bf9c 100644 --- a/api/get-task-status.html +++ b/api/get-task-status.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-transactions.html b/api/get-transactions.html index 018f19eee9..7a0d3173ac 100644 --- a/api/get-transactions.html +++ b/api/get-transactions.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-version.html b/api/get-version.html index edcfe60548..0714f66a5b 100644 --- a/api/get-version.html +++ b/api/get-version.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/get-vertex-builds.html b/api/get-vertex-builds.html index fd33ebea16..05918a0cee 100644 --- a/api/get-vertex-builds.html +++ b/api/get-vertex-builds.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/handle-messages.html b/api/handle-messages.html index 05c64e0502..5c9e2b5fd4 100644 --- a/api/handle-messages.html +++ b/api/handle-messages.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/handle-sse.html b/api/handle-sse.html index 00fc5e4df4..809d9ddfe0 100644 --- a/api/handle-sse.html +++ b/api/handle-sse.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/health-check.html b/api/health-check.html index d2d1657503..1779696032 100644 --- a/api/health-check.html +++ b/api/health-check.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/health.html b/api/health.html index 7b36073ad7..695b4e0c49 100644 --- a/api/health.html +++ b/api/health.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/like-component.html b/api/like-component.html index 3622d56171..8e82a22818 100644 --- a/api/like-component.html +++ b/api/like-component.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/list-files-1.html b/api/list-files-1.html index b5fa600408..64c624fa72 100644 --- a/api/list-files-1.html +++ b/api/list-files-1.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/list-files.html b/api/list-files.html index 9037bf0de6..6ab1f43813 100644 --- a/api/list-files.html +++ b/api/list-files.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/list-profile-pictures.html b/api/list-profile-pictures.html index 0ff250ffc9..818bea3a65 100644 --- a/api/list-profile-pictures.html +++ b/api/list-profile-pictures.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/login-to-get-access-token.html b/api/login-to-get-access-token.html index 4f2d4eb2ce..ca6856d527 100644 --- a/api/login-to-get-access-token.html +++ b/api/login-to-get-access-token.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/logout.html b/api/logout.html index 0f9b764e01..542aef3063 100644 --- a/api/logout.html +++ b/api/logout.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/logs.html b/api/logs.html index e878d4b6bb..f5517deb39 100644 --- a/api/logs.html +++ b/api/logs.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/patch-user.html b/api/patch-user.html index 627bd99848..6afee237f8 100644 --- a/api/patch-user.html +++ b/api/patch-user.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/post-validate-code.html b/api/post-validate-code.html index c7e122272e..b7346adfd1 100644 --- a/api/post-validate-code.html +++ b/api/post-validate-code.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/post-validate-prompt.html b/api/post-validate-prompt.html index 63a43e33f0..7f91791bdc 100644 --- a/api/post-validate-prompt.html +++ b/api/post-validate-prompt.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/process-1.html b/api/process-1.html index e729c025d4..20b0c6809d 100644 --- a/api/process-1.html +++ b/api/process-1.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/process.html b/api/process.html index 300353c8db..1bfecdece4 100644 --- a/api/process.html +++ b/api/process.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-all-users.html b/api/read-all-users.html index f24697984a..66c08dd5b3 100644 --- a/api/read-all-users.html +++ b/api/read-all-users.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-basic-examples.html b/api/read-basic-examples.html index 82dbc70461..dadfb35303 100644 --- a/api/read-basic-examples.html +++ b/api/read-basic-examples.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-current-user.html b/api/read-current-user.html index 31b749d487..87c2061f7b 100644 --- a/api/read-current-user.html +++ b/api/read-current-user.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-flow.html b/api/read-flow.html index 269801c718..19f95990d0 100644 --- a/api/read-flow.html +++ b/api/read-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-flows.html b/api/read-flows.html index 91550c4ec7..c1e3025b96 100644 --- a/api/read-flows.html +++ b/api/read-flows.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-folder.html b/api/read-folder.html index fb5d5d93ca..ed79f4640d 100644 --- a/api/read-folder.html +++ b/api/read-folder.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-folders.html b/api/read-folders.html index 713c75ee4c..0e9e9b0118 100644 --- a/api/read-folders.html +++ b/api/read-folders.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/read-variables.html b/api/read-variables.html index c09734af91..0f57abcdfb 100644 --- a/api/read-variables.html +++ b/api/read-variables.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/refresh-token.html b/api/refresh-token.html index 0e316fff79..771cd84011 100644 --- a/api/refresh-token.html +++ b/api/refresh-token.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/reset-password.html b/api/reset-password.html index 12e25ce71a..e63beb7b8a 100644 --- a/api/reset-password.html +++ b/api/reset-password.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/retrieve-vertices-order.html b/api/retrieve-vertices-order.html index 7f2d86adc1..4c0f3001d9 100644 --- a/api/retrieve-vertices-order.html +++ b/api/retrieve-vertices-order.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/save-store-api-key.html b/api/save-store-api-key.html index 9b2e650b6e..a593db7965 100644 --- a/api/save-store-api-key.html +++ b/api/save-store-api-key.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/share-component.html b/api/share-component.html index a574378e1a..b0cba190bf 100644 --- a/api/share-component.html +++ b/api/share-component.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/simplified-run-flow.html b/api/simplified-run-flow.html index d677a9b2d3..38b3fbad07 100644 --- a/api/simplified-run-flow.html +++ b/api/simplified-run-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/stream-logs.html b/api/stream-logs.html index b137e095ce..8690425804 100644 --- a/api/stream-logs.html +++ b/api/stream-logs.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-flow.html b/api/update-flow.html index 0268ffb816..fe99ceaef1 100644 --- a/api/update-flow.html +++ b/api/update-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-folder.html b/api/update-folder.html index ca5ebc1358..6d92ab7e9d 100644 --- a/api/update-folder.html +++ b/api/update-folder.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-message.html b/api/update-message.html index ec2826b951..74e1fa1994 100644 --- a/api/update-message.html +++ b/api/update-message.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-session-id.html b/api/update-session-id.html index fe3452f926..9d3e525e66 100644 --- a/api/update-session-id.html +++ b/api/update-session-id.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-shared-component.html b/api/update-shared-component.html index 5d3e7a6e33..db4cbe75ae 100644 --- a/api/update-shared-component.html +++ b/api/update-shared-component.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/update-variable.html b/api/update-variable.html index 313532e453..cb896a216e 100644 --- a/api/update-variable.html +++ b/api/update-variable.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/upload-file-1.html b/api/upload-file-1.html index 3a958ccf24..81b5ecc1e9 100644 --- a/api/upload-file-1.html +++ b/api/upload-file-1.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/upload-file-2.html b/api/upload-file-2.html index 5c530354d3..783b5619d5 100644 --- a/api/upload-file-2.html +++ b/api/upload-file-2.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/upload-file.html b/api/upload-file.html index 004a21da1e..8ec113d696 100644 --- a/api/upload-file.html +++ b/api/upload-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/upload-user-file.html b/api/upload-user-file.html index a1bea413b1..60753ea6a3 100644 --- a/api/upload-user-file.html +++ b/api/upload-user-file.html @@ -22,8 +22,8 @@ - - + + diff --git a/api/webhook-run-flow.html b/api/webhook-run-flow.html index 4647bdff3b..efa3bc0207 100644 --- a/api/webhook-run-flow.html +++ b/api/webhook-run-flow.html @@ -22,8 +22,8 @@ - - + + diff --git a/assets/images/quickstart-add-document-ingestion-5f9756b0a4b7e232b1507e12f335b15e.png b/assets/images/quickstart-add-document-ingestion-5f9756b0a4b7e232b1507e12f335b15e.png deleted file mode 100644 index 9bda4458d1..0000000000 Binary files a/assets/images/quickstart-add-document-ingestion-5f9756b0a4b7e232b1507e12f335b15e.png and /dev/null differ diff --git a/assets/images/quickstart-add-document-ingestion-6c34bac012400e3d35f6cebdd350ecf7.png b/assets/images/quickstart-add-document-ingestion-6c34bac012400e3d35f6cebdd350ecf7.png new file mode 100644 index 0000000000..b30cd8be8c Binary files /dev/null and b/assets/images/quickstart-add-document-ingestion-6c34bac012400e3d35f6cebdd350ecf7.png differ diff --git a/assets/images/starter-flow-blog-writer-05ef4634a1c68dba46a1144f98116700.png b/assets/images/starter-flow-blog-writer-05ef4634a1c68dba46a1144f98116700.png deleted file mode 100644 index ef2efba8c3..0000000000 Binary files a/assets/images/starter-flow-blog-writer-05ef4634a1c68dba46a1144f98116700.png and /dev/null differ diff --git a/assets/images/starter-flow-blog-writer-410606fc158b41f5c719c5801801befb.png b/assets/images/starter-flow-blog-writer-410606fc158b41f5c719c5801801befb.png new file mode 100644 index 0000000000..792601f255 Binary files /dev/null and b/assets/images/starter-flow-blog-writer-410606fc158b41f5c719c5801801befb.png differ diff --git a/assets/images/starter-flow-document-qa-766402aed4a9fbcc4f68a064f30fc6a1.png b/assets/images/starter-flow-document-qa-766402aed4a9fbcc4f68a064f30fc6a1.png new file mode 100644 index 0000000000..5f60bda26c Binary files /dev/null and b/assets/images/starter-flow-document-qa-766402aed4a9fbcc4f68a064f30fc6a1.png differ diff --git a/assets/images/starter-flow-document-qa-79583cca9932646d9e3c7630692c26d0.png b/assets/images/starter-flow-document-qa-79583cca9932646d9e3c7630692c26d0.png deleted file mode 100644 index 6768579c2e..0000000000 Binary files a/assets/images/starter-flow-document-qa-79583cca9932646d9e3c7630692c26d0.png and /dev/null differ diff --git a/assets/images/starter-flow-simple-agent-repl-6c6df85ce6d01bfafebe3e4247cefc83.png b/assets/images/starter-flow-simple-agent-repl-6c6df85ce6d01bfafebe3e4247cefc83.png deleted file mode 100644 index e6799c12d1..0000000000 Binary files a/assets/images/starter-flow-simple-agent-repl-6c6df85ce6d01bfafebe3e4247cefc83.png and /dev/null differ diff --git a/assets/images/starter-flow-unstructured-qa-4260fdd42821cf2cbd056661b96be655.png b/assets/images/starter-flow-unstructured-qa-4260fdd42821cf2cbd056661b96be655.png new file mode 100644 index 0000000000..59af21d059 Binary files /dev/null and b/assets/images/starter-flow-unstructured-qa-4260fdd42821cf2cbd056661b96be655.png differ diff --git a/assets/images/starter-flow-unstructured-qa-c029fa3529d7098a59549e3dfc1517a8.png b/assets/images/starter-flow-unstructured-qa-c029fa3529d7098a59549e3dfc1517a8.png deleted file mode 100644 index 631038cdf9..0000000000 Binary files a/assets/images/starter-flow-unstructured-qa-c029fa3529d7098a59549e3dfc1517a8.png and /dev/null differ diff --git a/assets/images/starter-flow-vector-rag-53aa6c362abccc7e01e69c80d6194315.png b/assets/images/starter-flow-vector-rag-53aa6c362abccc7e01e69c80d6194315.png new file mode 100644 index 0000000000..5c15e26c2e Binary files /dev/null and b/assets/images/starter-flow-vector-rag-53aa6c362abccc7e01e69c80d6194315.png differ diff --git a/assets/images/starter-flow-vector-rag-d83743e5e049082b9c7a37aaa7b930e9.png b/assets/images/starter-flow-vector-rag-d83743e5e049082b9c7a37aaa7b930e9.png deleted file mode 100644 index d7830a641a..0000000000 Binary files a/assets/images/starter-flow-vector-rag-d83743e5e049082b9c7a37aaa7b930e9.png and /dev/null differ diff --git a/assets/images/url-component-0ced1fa00ee3b97582421254b6d5be78.png b/assets/images/url-component-0ced1fa00ee3b97582421254b6d5be78.png deleted file mode 100644 index a0e9733cca..0000000000 Binary files a/assets/images/url-component-0ced1fa00ee3b97582421254b6d5be78.png and /dev/null differ diff --git a/assets/images/url-component-fb712df73581345c0f344013ce6ff2fd.png b/assets/images/url-component-fb712df73581345c0f344013ce6ff2fd.png new file mode 100644 index 0000000000..cde4838cb0 Binary files /dev/null and b/assets/images/url-component-fb712df73581345c0f344013ce6ff2fd.png differ diff --git a/assets/images/vector-store-retrieval-3d2d30b0bfef46783987efd758fc5497.png b/assets/images/vector-store-retrieval-3d2d30b0bfef46783987efd758fc5497.png new file mode 100644 index 0000000000..dabfce5410 Binary files /dev/null and b/assets/images/vector-store-retrieval-3d2d30b0bfef46783987efd758fc5497.png differ diff --git a/assets/images/vector-store-retrieval-452b8316c734a28f85fcddf9ff7a32e4.png b/assets/images/vector-store-retrieval-452b8316c734a28f85fcddf9ff7a32e4.png deleted file mode 100644 index 132ba25a0c..0000000000 Binary files a/assets/images/vector-store-retrieval-452b8316c734a28f85fcddf9ff7a32e4.png and /dev/null differ diff --git a/assets/js/22dd74f7.271965fe.js b/assets/js/22dd74f7.271965fe.js new file mode 100644 index 0000000000..937ffc16f4 --- /dev/null +++ b/assets/js/22dd74f7.271965fe.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":"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}],"collapsed":true,"collapsible":true},{"type":"category","label":"Starter projects","items":[{"type":"link","label":"Basic prompting","href":"/starter-projects-basic-prompting","docId":"Starter-Projects/starter-projects-basic-prompting","unlisted":false},{"type":"link","label":"Vector store RAG","href":"/starter-projects-vector-store-rag","docId":"Starter-Projects/starter-projects-vector-store-rag","unlisted":false},{"type":"link","label":"Simple agent","href":"/starter-projects-simple-agent","docId":"Starter-Projects/starter-projects-simple-agent","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Sample flows","items":[{"type":"link","label":"Blog writer","href":"/blog-writer","docId":"Sample-Flows/blog-writer","unlisted":false},{"type":"link","label":"Document QA","href":"/document-qa","docId":"Sample-Flows/document-qa","unlisted":false},{"type":"link","label":"Memory chatbot","href":"/memory-chatbot","docId":"Sample-Flows/memory-chatbot","unlisted":false},{"type":"link","label":"Sequential tasks agent","href":"/sequential-agent","docId":"Sample-Flows/sequential-agent","unlisted":false},{"type":"link","label":"Travel planning agent","href":"/travel-planning-agent","docId":"Sample-Flows/travel-planning-agent","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Concepts","items":[{"type":"link","label":"Langflow overview","href":"/concepts-overview","docId":"Concepts/concepts-overview","unlisted":false},{"type":"link","label":"Playground","href":"/concepts-playground","docId":"Concepts/concepts-playground","unlisted":false},{"type":"link","label":"Components","href":"/concepts-components","docId":"Concepts/concepts-components","unlisted":false},{"type":"link","label":"Flows","href":"/concepts-flows","docId":"Concepts/concepts-flows","unlisted":false},{"type":"link","label":"Langflow objects","href":"/concepts-objects","docId":"Concepts/concepts-objects","unlisted":false},{"type":"link","label":"Publish flows","href":"/concepts-publish","docId":"Concepts/concepts-publish","unlisted":false},{"type":"link","label":"Manage files","href":"/concepts-file-management","docId":"Concepts/concepts-file-management","unlisted":false},{"type":"link","label":"Voice mode","href":"/concepts-voice-mode","docId":"Concepts/concepts-voice-mode","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Components","items":[{"type":"link","label":"Agents","href":"/components-agents","docId":"Components/components-agents","unlisted":false},{"type":"link","label":"Bundles","href":"/components-bundle-components","docId":"Components/components-bundles","unlisted":false},{"type":"link","label":"Create custom Python components","href":"/components-custom-components","docId":"Components/components-custom-components","unlisted":false},{"type":"link","label":"Data","href":"/components-data","docId":"Components/components-data","unlisted":false},{"type":"link","label":"Embeddings","href":"/components-embedding-models","docId":"Components/components-embedding-models","unlisted":false},{"type":"link","label":"Helpers","href":"/components-helpers","docId":"Components/components-helpers","unlisted":false},{"type":"link","label":"Inputs and outputs","href":"/components-io","docId":"Components/components-io","unlisted":false},{"type":"link","label":"Loaders","href":"/components-loaders","docId":"Components/components-loaders","unlisted":false},{"type":"link","label":"Logic","href":"/components-logic","docId":"Components/components-logic","unlisted":false},{"type":"link","label":"Memories","href":"/components-memories","docId":"Components/components-memories","unlisted":false},{"type":"link","label":"Models","href":"/components-models","docId":"Components/components-models","unlisted":false},{"type":"link","label":"Processing","href":"/components-processing","docId":"Components/components-processing","unlisted":false},{"type":"link","label":"Prompts","href":"/components-prompts","docId":"Components/components-prompts","unlisted":false},{"type":"link","label":"Tools","href":"/components-tools","docId":"Components/components-tools","unlisted":false},{"type":"link","label":"Vector stores","href":"/components-vector-stores","docId":"Components/components-vector-stores","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Agents","items":[{"type":"link","label":"Agents overview","href":"/agents-overview","docId":"Agents/agents-overview","unlisted":false},{"type":"link","label":"Create a problem-solving agent","href":"/agents-tool-calling-agent-component","docId":"Agents/agent-tool-calling-agent-component","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Configuration","items":[{"type":"link","label":"API keys","href":"/configuration-api-keys","docId":"Configuration/configuration-api-keys","unlisted":false},{"type":"link","label":"Authentication","href":"/configuration-authentication","docId":"Configuration/configuration-authentication","unlisted":false},{"type":"link","label":"Auto-saving","href":"/configuration-auto-save","docId":"Configuration/configuration-auto-saving","unlisted":false},{"type":"link","label":"Run Langflow in backend-only mode","href":"/configuration-backend-only","docId":"Configuration/configuration-backend-only","unlisted":false},{"type":"link","label":"Langflow CLI","href":"/configuration-cli","docId":"Configuration/configuration-cli","unlisted":false},{"type":"link","label":"Configure an external PostgreSQL database","href":"/configuration-custom-database","docId":"Configuration/configuration-custom-database","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":"link","label":"Security best practices","href":"/configuration-security-best-practices","docId":"Configuration/configuration-security-best-practices","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Develop","items":[{"type":"link","label":"About developing and configuring Langflow applications","href":"/develop-overview","docId":"Develop/develop-overview","unlisted":false},{"type":"link","label":"Develop an application in Langflow","href":"/develop-application","docId":"Develop/develop-application","unlisted":false},{"type":"link","label":"Install custom dependencies","href":"/install-custom-dependencies","docId":"Develop/install-custom-dependencies","unlisted":false},{"type":"link","label":"Memory management options","href":"/memory","docId":"Develop/memory","unlisted":false},{"type":"link","label":"Use session ID to manage communication between components","href":"/session-id","docId":"Develop/session-id","unlisted":false},{"type":"link","label":"Logging options in Langflow","href":"/logging","docId":"Develop/logging","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Deployment","items":[{"type":"link","label":"Deployment overview","href":"/deployment-overview","docId":"Deployment/deployment-overview","unlisted":false},{"type":"link","label":"Docker","href":"/deployment-docker","docId":"Deployment/deployment-docker","unlisted":false},{"type":"link","label":"Kubernetes","href":"/deployment-kubernetes","docId":"Deployment/deployment-kubernetes","unlisted":false},{"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},{"type":"category","label":"API reference","items":[{"type":"link","label":"API documentation","href":"/api"},{"type":"link","label":"API examples","href":"/api-reference-api-examples","docId":"API-Reference/api-reference-api-examples","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Integrations","items":[{"type":"category","label":"MCP (Model Context Protocol)","items":[{"type":"link","label":"Integrate Langflow with MCP","href":"/integrations-mcp","docId":"Integrations/MCP/integrations-mcp","unlisted":false},{"type":"link","label":"Connect an Astra DB MCP server to Langflow","href":"/mcp-component-astra","docId":"Integrations/MCP/mcp-component-astra","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Apify","href":"/integrations-apify","docId":"Integrations/Apify/integrations-apify","unlisted":false},{"type":"link","label":"Arize","href":"/integrations-arize","docId":"Integrations/Arize/integrations-arize","unlisted":false},{"type":"link","label":"AssemblyAI","href":"/integrations-assemblyai","docId":"Integrations/integrations-assemblyai","unlisted":false},{"type":"link","label":"Composio","href":"/integrations-composio","docId":"Integrations/Composio/integrations-composio","unlisted":false},{"type":"category","label":"Google","items":[{"type":"link","label":"Integrate Google OAuth with Langflow","href":"/integrations-setup-google-oauth-langflow","docId":"Integrations/Google/integrations-setup-google-oauth-langflow","unlisted":false},{"type":"link","label":"Integrate Google Cloud Vertex AI with Langflow","href":"/integrations-setup-google-cloud-vertex-ai-langflow","docId":"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow","unlisted":false}],"collapsed":true,"collapsible":true},{"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},{"type":"category","label":"Notion","items":[{"type":"link","label":"Setup","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":"category","label":"NVIDIA","items":[{"type":"link","label":"Integrate NVIDIA Ingest with Langflow","href":"/integrations-nvidia-ingest","docId":"Integrations/Nvidia/integrations-nvidia-ingest","unlisted":false},{"type":"link","label":"Integrate NVIDIA NIMs with Langflow","href":"/integrations-nvidia-ingest-wsl2","docId":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contributing","items":[{"type":"link","label":"Join the Langflow community","href":"/contributing-community","docId":"Contributing/contributing-community","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":"Ask for help on the Discussions board","href":"/contributing-github-discussions","docId":"Contributing/contributing-github-discussion-board","unlisted":false},{"type":"link","label":"Request an enhancement or report a bug","href":"/contributing-github-issues","docId":"Contributing/contributing-github-issues","unlisted":false},{"type":"link","label":"Contribute to Langflow","href":"/contributing-how-to-contribute","docId":"Contributing/contributing-how-to-contribute","unlisted":false},{"type":"link","label":"Telemetry","href":"/contributing-telemetry","docId":"Contributing/contributing-telemetry","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Changelog","items":[{"type":"link","label":"Changelog","href":"https://github.com/langflow-ai/langflow/releases/latest"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Support","items":[{"type":"link","label":"Luna for Langflow","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 Use Langflow in the cloud\\n Sign up for DataStax Langflow\\n
    \\n
    \\n "}]},"docs":{"Agents/agent-tool-calling-agent-component":{"id":"Agents/agent-tool-calling-agent-component","title":"Create a problem-solving agent","description":"Developing agents in Langchain is complex.","sidebar":"docs"},"Agents/agents-overview":{"id":"Agents/agents-overview","title":"Agents overview","description":"Agents are AI systems that use LLMs as a brain to analyze problems and select external tools.","sidebar":"docs"},"API-Reference/api-reference-api-examples":{"id":"API-Reference/api-reference-api-examples","title":"API examples","description":"This page provides examples and practices for managing Langflow using the Langflow API.","sidebar":"docs"},"Components/components-agents":{"id":"Components/components-agents","title":"Agents","description":"Agent components define the behavior and capabilities of AI agents in your flow.","sidebar":"docs"},"Components/components-bundles":{"id":"Components/components-bundles","title":"Bundles","description":"Bundles are third-party components grouped by provider.","sidebar":"docs"},"Components/components-custom-components":{"id":"Components/components-custom-components","title":"Create custom Python components","description":"Custom components are created within Langflow and extend the platform\'s functionality with custom, reusable Python code.","sidebar":"docs"},"Components/components-data":{"id":"Components/components-data","title":"Data","description":"Data components load data from a source into your flow.","sidebar":"docs"},"Components/components-embedding-models":{"id":"Components/components-embedding-models","title":"Embeddings","description":"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context.","sidebar":"docs"},"Components/components-helpers":{"id":"Components/components-helpers","title":"Helpers","description":"Helper components provide utility functions to help manage data, tasks, and other components in your flow.","sidebar":"docs"},"Components/components-io":{"id":"Components/components-io","title":"Inputs and outputs","description":"Input and output components define where data enters and exits your flow.","sidebar":"docs"},"Components/components-loaders":{"id":"Components/components-loaders","title":"Loaders","description":"As of Langflow 1.1, loader components are now found in the Components menu under Bundles.","sidebar":"docs"},"Components/components-logic":{"id":"Components/components-logic","title":"Logic","description":"Logic components provide functionalities for routing, conditional processing, and flow management.","sidebar":"docs"},"Components/components-memories":{"id":"Components/components-memories","title":"Memories","description":"Memory components store and retrieve chat messages by session_id.","sidebar":"docs"},"Components/components-models":{"id":"Components/components-models","title":"Models","description":"Model components generate text using large language models.","sidebar":"docs"},"Components/components-processing":{"id":"Components/components-processing","title":"Processing","description":"Processing components process and transform data within a flow.","sidebar":"docs"},"Components/components-prompts":{"id":"Components/components-prompts","title":"Prompts","description":"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables.","sidebar":"docs"},"Components/components-tools":{"id":"Components/components-tools","title":"Tools","description":"Tools are typically connected to agent components at the Tools port. Agents use LLMs as a reasoning engine to decide which of the connected tool components to use to solve a problem.","sidebar":"docs"},"Components/components-vector-stores":{"id":"Components/components-vector-stores","title":"Vector stores","description":"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation.","sidebar":"docs"},"Concepts/concepts-components":{"id":"Concepts/concepts-components","title":"Components","description":"A\xa0component\xa0is a single building block within a flow with inputs, outputs, functions, and parameters that define its functionality. A single component is like a class within a larger application.","sidebar":"docs"},"Concepts/concepts-file-management":{"id":"Concepts/concepts-file-management","title":"Manage files","description":"Upload, store, and manage files in Langflow\'s File management system.","sidebar":"docs"},"Concepts/concepts-flows":{"id":"Concepts/concepts-flows","title":"Flows","description":"Flows in Langflow are fully serializable and can be saved and loaded from the file system. In this guide, we\'ll explore how to import and export flows.","sidebar":"docs"},"Concepts/concepts-objects":{"id":"Concepts/concepts-objects","title":"Langflow objects","description":"In Langflow, objects are Pydantic models that serve as structured, functional representations of data.","sidebar":"docs"},"Concepts/concepts-overview":{"id":"Concepts/concepts-overview","title":"Langflow overview","description":"This page explores the fundamental building blocks of Langflow, beginning with the question, \\"What is a flow?\\"","sidebar":"docs"},"Concepts/concepts-playground":{"id":"Concepts/concepts-playground","title":"Playground","description":"The\xa0Playground\xa0is a dynamic interface designed for real-time interaction with LLMs, allowing users to chat, access memories, and monitor inputs and outputs. Here, users can directly prototype their models, making adjustments and observing different outcomes.","sidebar":"docs"},"Concepts/concepts-publish":{"id":"Concepts/concepts-publish","title":"Publish flows","description":"Langflow provides several ways to publish and integrate your flows into external applications. Whether you want to expose your flow via API endpoints, embed it as a chat widget in your website, or share it as a public playground, this guide covers the options available for making your flows accessible to users.","sidebar":"docs"},"Concepts/concepts-voice-mode":{"id":"Concepts/concepts-voice-mode","title":"Voice mode","description":"The Langflow Playground supports voice mode for interacting with your applications through a microphone.","sidebar":"docs"},"Configuration/configuration-api-keys":{"id":"Configuration/configuration-api-keys","title":"API keys","description":"Langflow provides an API key functionality that allows users to access their individual components and flows without traditional login authentication.","sidebar":"docs"},"Configuration/configuration-authentication":{"id":"Configuration/configuration-authentication","title":"Authentication","description":"This guide covers Langflow\'s authentication system and API key management, including how to secure your deployment and manage access to flows and components.","sidebar":"docs"},"Configuration/configuration-auto-saving":{"id":"Configuration/configuration-auto-saving","title":"Auto-saving","description":"Langflow supports both manual and auto-saving functionality.","sidebar":"docs"},"Configuration/configuration-backend-only":{"id":"Configuration/configuration-backend-only","title":"Run Langflow in backend-only mode","description":"Langflow can run in --backend-only mode to expose a Langflow app as an API endpoint, without running the frontend UI.","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 projects.","sidebar":"docs"},"Configuration/configuration-security-best-practices":{"id":"Configuration/configuration-security-best-practices","title":"Security best practices","description":"This guide outlines security best practices for deploying and managing Langflow.","sidebar":"docs"},"Configuration/environment-variables":{"id":"Configuration/environment-variables","title":"Environment variables","description":"Langflow lets you configure a number of settings using environment variables.","sidebar":"docs"},"Contributing/contributing-community":{"id":"Contributing/contributing-community","title":"Join the Langflow community","description":"Join the Langflow Discord server","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\xa0CustomComponent\xa0class.","sidebar":"docs"},"Contributing/contributing-github-discussion-board":{"id":"Contributing/contributing-github-discussion-board","title":"Ask for help on the Discussions board","description":"If you\'re looking for help with your code, consider posting a question on the Langflow\xa0GitHub Discussions board. The Langflow team cannot provide individual support via email. The team also believes that help is much more valuable if it\'s\xa0shared publicly, so that more people can benefit from it.","sidebar":"docs"},"Contributing/contributing-github-issues":{"id":"Contributing/contributing-github-issues","title":"Request an enhancement or report a bug","description":"The\xa0Issues page in the Langflow repo is kept up to date with bugs, improvements, and feature requests. Labels are used to help with sorting and discovery of issues of interest. For an overview of the system Langflow uses to tag issues and pull requests, see the Langflow repo\'s labels page.","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 essential usage statistics to enhance functionality and the user experience. This data helps us identify popular features and areas that need improvement, and ensures development efforts align with what you need.","sidebar":"docs"},"Deployment/deployment-docker":{"id":"Deployment/deployment-docker","title":"Deploy Langflow on Docker","description":"This guide demonstrates deploying Langflow with Docker and Docker Compose.","sidebar":"docs"},"Deployment/deployment-gcp":{"id":"Deployment/deployment-gcp","title":"Deploy Langflow on Google Cloud Platform","description":"This guide demonstrates deploying Langflow on Google Cloud Platform.","sidebar":"docs"},"Deployment/deployment-hugging-face-spaces":{"id":"Deployment/deployment-hugging-face-spaces","title":"Deploy Langflow on HuggingFace Spaces","description":"This guide explains how to deploy Langflow on HuggingFace Spaces.","sidebar":"docs"},"Deployment/deployment-kubernetes":{"id":"Deployment/deployment-kubernetes","title":"Deploy Langflow on Kubernetes","description":"This guide demonstrates deploying Langflow on a Kubernetes cluster.","sidebar":"docs"},"Deployment/deployment-overview":{"id":"Deployment/deployment-overview","title":"Langflow deployment overview","description":"You have a flow, and want to share it with the world in a production environment.","sidebar":"docs"},"Deployment/deployment-railway":{"id":"Deployment/deployment-railway","title":"Deploy Langflow on Railway","description":"This guide explains how to deploy Langflow on Railway, a cloud infrastructure platform that provides auto-deploy, managed databases, and automatic scaling.","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/develop-application":{"id":"Develop/develop-application","title":"Develop an application in Langflow","description":"Follow this guide to learn how to build an application using Langflow.","sidebar":"docs"},"Develop/develop-overview":{"id":"Develop/develop-overview","title":"About developing and configuring Langflow applications","description":"The following pages provide information about how to develop and configure Langflow applications.","sidebar":"docs"},"Develop/install-custom-dependencies":{"id":"Develop/install-custom-dependencies","title":"Install custom dependencies","description":"To install custom dependencies in your Langflow environment, add them with your package manager.","sidebar":"docs"},"Develop/logging":{"id":"Develop/logging","title":"Logging options in Langflow","description":"Langflow uses the loguru library for logging.","sidebar":"docs"},"Develop/memory":{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval.","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"},"Get-Started/get-started-installation":{"id":"Get-Started/get-started-installation","title":"Install Langflow","description":"You can deploy Langflow either locally or as a hosted service with Datastax Langflow.","sidebar":"docs"},"Get-Started/get-started-quickstart":{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get to know Langflow by building an OpenAI-powered chatbot application. After you\'ve constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data.","sidebar":"docs"},"Get-Started/welcome-to-langflow":{"id":"Get-Started/welcome-to-langflow","title":"Welcome to Langflow","description":"Langflow is a new, visual framework for building multi-agent and RAG applications. It is open-source, Python-powered, fully customizable, and LLM and vector store agnostic.","sidebar":"docs"},"Integrations/Apify/integrations-apify":{"id":"Integrations/Apify/integrations-apify","title":"Apify","description":"Apify is a web scraping and data extraction platform. It provides an Actor Store with more than 3,000 ready-made cloud tools called Actors.","sidebar":"docs"},"Integrations/Arize/integrations-arize":{"id":"Integrations/Arize/integrations-arize","title":"Integrate Arize with Langflow","description":"Arize is a tool built on OpenTelemetry and OpenInference for monitoring and optimizing LLM applications.","sidebar":"docs"},"Integrations/Composio/integrations-composio":{"id":"Integrations/Composio/integrations-composio","title":"Integrate Composio with Langflow","description":"Langflow integrates with Composio as a toolset for your Agent component.","sidebar":"docs"},"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow":{"id":"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow","title":"Integrate Google Cloud Vertex AI with Langflow","description":"A comprehensive guide on creating a Google OAuth app, obtaining tokens, and integrating them with Langflow\'s Google components.","sidebar":"docs"},"Integrations/Google/integrations-setup-google-oauth-langflow":{"id":"Integrations/Google/integrations-setup-google-oauth-langflow","title":"Integrate Google OAuth with Langflow","description":"A comprehensive guide on creating a Google OAuth app, obtaining tokens, and integrating them with Langflow\'s Google components.","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 observability and analytics platform specifically designed for language models and AI applications.","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, just add your LangChain API key as a Langflow environment variable and you are good to go!","sidebar":"docs"},"Integrations/integrations-langwatch":{"id":"Integrations/integrations-langwatch","title":"LangWatch","description":"938674091aac4d9d9aa4aa6eb5c215b4}","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/integrations-mcp":{"id":"Integrations/MCP/integrations-mcp","title":"Integrate Langflow with MCP","description":"Langflow integrates with the Model Context Protocol (MCP). This allows you to use your Langflow flows as tools in client applications that support the MCP, or extend Langflow with the MCP server component to access MCP servers.","sidebar":"docs"},"Integrations/MCP/mcp-component-astra":{"id":"Integrations/MCP/mcp-component-astra","title":"Connect an Astra DB MCP server to Langflow","description":"Use the MCP server component to connect Langflow to a Datastax Astra DB MCP server.","sidebar":"docs"},"Integrations/Notion/integrations-notion":{"id":"Integrations/Notion/integrations-notion","title":"Setup","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-ingest":{"id":"Integrations/Nvidia/integrations-nvidia-ingest","title":"Integrate NVIDIA Ingest with Langflow","description":"The NVIDIA Ingest 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"},"Sample-Flows/blog-writer":{"id":"Sample-Flows/blog-writer","title":"Blog writer","description":"Build a Blog Writer flow for a one-shot application using OpenAI.","sidebar":"docs"},"Sample-Flows/document-qa":{"id":"Sample-Flows/document-qa","title":"Document QA","description":"Build a question-and-answer chatbot with a document loaded from local memory.","sidebar":"docs"},"Sample-Flows/memory-chatbot":{"id":"Sample-Flows/memory-chatbot","title":"Memory chatbot","description":"This flow extends the basic prompting flow with a Chat memory component that stores up to 100 previous chat messages and uses them to provide context for the current conversation.","sidebar":"docs"},"Sample-Flows/sequential-agent":{"id":"Sample-Flows/sequential-agent","title":"Sequential tasks agent","description":"Build a Sequential Tasks Agent flow for a multi-agent application using multiple Agent components.","sidebar":"docs"},"Sample-Flows/travel-planning-agent":{"id":"Sample-Flows/travel-planning-agent","title":"Travel planning agent","description":"Build a Travel Planning Agent flow for an agentic application using the multiple Tool-calling agents.","sidebar":"docs"},"Starter-Projects/starter-projects-basic-prompting":{"id":"Starter-Projects/starter-projects-basic-prompting","title":"Basic prompting","description":"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks.","sidebar":"docs"},"Starter-Projects/starter-projects-simple-agent":{"id":"Starter-Projects/starter-projects-simple-agent","title":"Simple agent","description":"Build a Simple Agent flow for an agentic application using the Tool-calling agent component.","sidebar":"docs"},"Starter-Projects/starter-projects-vector-store-rag":{"id":"Starter-Projects/starter-projects-vector-store-rag","title":"Vector store RAG","description":"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it.","sidebar":"docs"},"Support/luna-for-langflow":{"id":"Support/luna-for-langflow","title":"Luna for Langflow","description":"With Luna for Langflow support, you can develop and deploy Langflow applications with confidence.","sidebar":"docs"}}}}')}}]); \ No newline at end of file diff --git a/assets/js/22dd74f7.950378dd.js b/assets/js/22dd74f7.950378dd.js deleted file mode 100644 index de71a3c5ad..0000000000 --- a/assets/js/22dd74f7.950378dd.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":"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}],"collapsed":true,"collapsible":true},{"type":"category","label":"Starter projects","items":[{"type":"link","label":"Basic prompting","href":"/starter-projects-basic-prompting","docId":"Starter-Projects/starter-projects-basic-prompting","unlisted":false},{"type":"link","label":"Vector store RAG","href":"/starter-projects-vector-store-rag","docId":"Starter-Projects/starter-projects-vector-store-rag","unlisted":false},{"type":"link","label":"Simple agent","href":"/starter-projects-simple-agent","docId":"Starter-Projects/starter-projects-simple-agent","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Sample flows","items":[{"type":"link","label":"Blog writer","href":"/blog-writer","docId":"Sample-Flows/blog-writer","unlisted":false},{"type":"link","label":"Document QA","href":"/document-qa","docId":"Sample-Flows/document-qa","unlisted":false},{"type":"link","label":"Memory chatbot","href":"/memory-chatbot","docId":"Sample-Flows/memory-chatbot","unlisted":false},{"type":"link","label":"Math agent","href":"/math-agent","docId":"Sample-Flows/math-agent","unlisted":false},{"type":"link","label":"Sequential tasks agent","href":"/sequential-agent","docId":"Sample-Flows/sequential-agent","unlisted":false},{"type":"link","label":"Travel planning agent","href":"/travel-planning-agent","docId":"Sample-Flows/travel-planning-agent","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Concepts","items":[{"type":"link","label":"Langflow overview","href":"/concepts-overview","docId":"Concepts/concepts-overview","unlisted":false},{"type":"link","label":"Playground","href":"/concepts-playground","docId":"Concepts/concepts-playground","unlisted":false},{"type":"link","label":"Components","href":"/concepts-components","docId":"Concepts/concepts-components","unlisted":false},{"type":"link","label":"Flows","href":"/concepts-flows","docId":"Concepts/concepts-flows","unlisted":false},{"type":"link","label":"Langflow objects","href":"/concepts-objects","docId":"Concepts/concepts-objects","unlisted":false},{"type":"link","label":"Publish flows","href":"/concepts-publish","docId":"Concepts/concepts-publish","unlisted":false},{"type":"link","label":"Manage files","href":"/concepts-file-management","docId":"Concepts/concepts-file-management","unlisted":false},{"type":"link","label":"Voice mode","href":"/concepts-voice-mode","docId":"Concepts/concepts-voice-mode","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Components","items":[{"type":"link","label":"Agents","href":"/components-agents","docId":"Components/components-agents","unlisted":false},{"type":"link","label":"Bundles","href":"/components-bundle-components","docId":"Components/components-bundles","unlisted":false},{"type":"link","label":"Create custom Python components","href":"/components-custom-components","docId":"Components/components-custom-components","unlisted":false},{"type":"link","label":"Data","href":"/components-data","docId":"Components/components-data","unlisted":false},{"type":"link","label":"Embeddings","href":"/components-embedding-models","docId":"Components/components-embedding-models","unlisted":false},{"type":"link","label":"Helpers","href":"/components-helpers","docId":"Components/components-helpers","unlisted":false},{"type":"link","label":"Inputs and outputs","href":"/components-io","docId":"Components/components-io","unlisted":false},{"type":"link","label":"Loaders","href":"/components-loaders","docId":"Components/components-loaders","unlisted":false},{"type":"link","label":"Logic","href":"/components-logic","docId":"Components/components-logic","unlisted":false},{"type":"link","label":"Memories","href":"/components-memories","docId":"Components/components-memories","unlisted":false},{"type":"link","label":"Models","href":"/components-models","docId":"Components/components-models","unlisted":false},{"type":"link","label":"Processing","href":"/components-processing","docId":"Components/components-processing","unlisted":false},{"type":"link","label":"Prompts","href":"/components-prompts","docId":"Components/components-prompts","unlisted":false},{"type":"link","label":"Tools","href":"/components-tools","docId":"Components/components-tools","unlisted":false},{"type":"link","label":"Vector stores","href":"/components-vector-stores","docId":"Components/components-vector-stores","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Agents","items":[{"type":"link","label":"Agents overview","href":"/agents-overview","docId":"Agents/agents-overview","unlisted":false},{"type":"link","label":"Create a problem-solving agent","href":"/agents-tool-calling-agent-component","docId":"Agents/agent-tool-calling-agent-component","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Configuration","items":[{"type":"link","label":"API keys","href":"/configuration-api-keys","docId":"Configuration/configuration-api-keys","unlisted":false},{"type":"link","label":"Authentication","href":"/configuration-authentication","docId":"Configuration/configuration-authentication","unlisted":false},{"type":"link","label":"Auto-saving","href":"/configuration-auto-save","docId":"Configuration/configuration-auto-saving","unlisted":false},{"type":"link","label":"Run Langflow in backend-only mode","href":"/configuration-backend-only","docId":"Configuration/configuration-backend-only","unlisted":false},{"type":"link","label":"Langflow CLI","href":"/configuration-cli","docId":"Configuration/configuration-cli","unlisted":false},{"type":"link","label":"Configure an external PostgreSQL database","href":"/configuration-custom-database","docId":"Configuration/configuration-custom-database","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":"link","label":"Security best practices","href":"/configuration-security-best-practices","docId":"Configuration/configuration-security-best-practices","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Develop","items":[{"type":"link","label":"About developing and configuring Langflow applications","href":"/develop-overview","docId":"Develop/develop-overview","unlisted":false},{"type":"link","label":"Develop an application in Langflow","href":"/develop-application","docId":"Develop/develop-application","unlisted":false},{"type":"link","label":"Install custom dependencies","href":"/install-custom-dependencies","docId":"Develop/install-custom-dependencies","unlisted":false},{"type":"link","label":"Memory management options","href":"/memory","docId":"Develop/memory","unlisted":false},{"type":"link","label":"Use session ID to manage communication between components","href":"/session-id","docId":"Develop/session-id","unlisted":false},{"type":"link","label":"Logging options in Langflow","href":"/logging","docId":"Develop/logging","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Deployment","items":[{"type":"link","label":"Deployment overview","href":"/deployment-overview","docId":"Deployment/deployment-overview","unlisted":false},{"type":"link","label":"Docker","href":"/deployment-docker","docId":"Deployment/deployment-docker","unlisted":false},{"type":"link","label":"Kubernetes","href":"/deployment-kubernetes","docId":"Deployment/deployment-kubernetes","unlisted":false},{"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},{"type":"category","label":"API reference","items":[{"type":"link","label":"API documentation","href":"/api"},{"type":"link","label":"API examples","href":"/api-reference-api-examples","docId":"API-Reference/api-reference-api-examples","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Integrations","items":[{"type":"category","label":"MCP (Model Context Protocol)","items":[{"type":"link","label":"Integrate Langflow with MCP","href":"/integrations-mcp","docId":"Integrations/MCP/integrations-mcp","unlisted":false},{"type":"link","label":"Connect an Astra DB MCP server to Langflow","href":"/mcp-component-astra","docId":"Integrations/MCP/mcp-component-astra","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"link","label":"Apify","href":"/integrations-apify","docId":"Integrations/Apify/integrations-apify","unlisted":false},{"type":"link","label":"Arize","href":"/integrations-arize","docId":"Integrations/Arize/integrations-arize","unlisted":false},{"type":"link","label":"AssemblyAI","href":"/integrations-assemblyai","docId":"Integrations/integrations-assemblyai","unlisted":false},{"type":"link","label":"Composio","href":"/integrations-composio","docId":"Integrations/Composio/integrations-composio","unlisted":false},{"type":"category","label":"Google","items":[{"type":"link","label":"Integrate Google OAuth with Langflow","href":"/integrations-setup-google-oauth-langflow","docId":"Integrations/Google/integrations-setup-google-oauth-langflow","unlisted":false},{"type":"link","label":"Integrate Google Cloud Vertex AI with Langflow","href":"/integrations-setup-google-cloud-vertex-ai-langflow","docId":"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow","unlisted":false}],"collapsed":true,"collapsible":true},{"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},{"type":"category","label":"Notion","items":[{"type":"link","label":"Setup","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":"category","label":"NVIDIA","items":[{"type":"link","label":"Integrate NVIDIA Ingest with Langflow","href":"/integrations-nvidia-ingest","docId":"Integrations/Nvidia/integrations-nvidia-ingest","unlisted":false},{"type":"link","label":"Integrate NVIDIA NIMs with Langflow","href":"/integrations-nvidia-ingest-wsl2","docId":"Integrations/Nvidia/integrations-nvidia-nim-wsl2","unlisted":false}],"collapsed":true,"collapsible":true}],"collapsed":true,"collapsible":true},{"type":"category","label":"Contributing","items":[{"type":"link","label":"Join the Langflow community","href":"/contributing-community","docId":"Contributing/contributing-community","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":"Ask for help on the Discussions board","href":"/contributing-github-discussions","docId":"Contributing/contributing-github-discussion-board","unlisted":false},{"type":"link","label":"Request an enhancement or report a bug","href":"/contributing-github-issues","docId":"Contributing/contributing-github-issues","unlisted":false},{"type":"link","label":"Contribute to Langflow","href":"/contributing-how-to-contribute","docId":"Contributing/contributing-how-to-contribute","unlisted":false},{"type":"link","label":"Telemetry","href":"/contributing-telemetry","docId":"Contributing/contributing-telemetry","unlisted":false}],"collapsed":true,"collapsible":true},{"type":"category","label":"Changelog","items":[{"type":"link","label":"Changelog","href":"https://github.com/langflow-ai/langflow/releases/latest"}],"collapsed":true,"collapsible":true},{"type":"category","label":"Support","items":[{"type":"link","label":"Luna for Langflow","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 Use Langflow in the cloud\\n Sign up for DataStax Langflow\\n
    \\n
    \\n "}]},"docs":{"Agents/agent-tool-calling-agent-component":{"id":"Agents/agent-tool-calling-agent-component","title":"Create a problem-solving agent","description":"Developing agents in Langchain is complex.","sidebar":"docs"},"Agents/agents-overview":{"id":"Agents/agents-overview","title":"Agents overview","description":"Agents are AI systems that use LLMs as a brain to analyze problems and select external tools.","sidebar":"docs"},"API-Reference/api-reference-api-examples":{"id":"API-Reference/api-reference-api-examples","title":"API examples","description":"This page provides examples and practices for managing Langflow using the Langflow API.","sidebar":"docs"},"Components/components-agents":{"id":"Components/components-agents","title":"Agents","description":"Agent components define the behavior and capabilities of AI agents in your flow.","sidebar":"docs"},"Components/components-bundles":{"id":"Components/components-bundles","title":"Bundles","description":"Bundles are third-party components grouped by provider.","sidebar":"docs"},"Components/components-custom-components":{"id":"Components/components-custom-components","title":"Create custom Python components","description":"Custom components are created within Langflow and extend the platform\'s functionality with custom, reusable Python code.","sidebar":"docs"},"Components/components-data":{"id":"Components/components-data","title":"Data","description":"Data components load data from a source into your flow.","sidebar":"docs"},"Components/components-embedding-models":{"id":"Components/components-embedding-models","title":"Embeddings","description":"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context.","sidebar":"docs"},"Components/components-helpers":{"id":"Components/components-helpers","title":"Helpers","description":"Helper components provide utility functions to help manage data, tasks, and other components in your flow.","sidebar":"docs"},"Components/components-io":{"id":"Components/components-io","title":"Inputs and outputs","description":"Input and output components define where data enters and exits your flow.","sidebar":"docs"},"Components/components-loaders":{"id":"Components/components-loaders","title":"Loaders","description":"As of Langflow 1.1, loader components are now found in the Components menu under Bundles.","sidebar":"docs"},"Components/components-logic":{"id":"Components/components-logic","title":"Logic","description":"Logic components provide functionalities for routing, conditional processing, and flow management.","sidebar":"docs"},"Components/components-memories":{"id":"Components/components-memories","title":"Memories","description":"Memory components store and retrieve chat messages by session_id.","sidebar":"docs"},"Components/components-models":{"id":"Components/components-models","title":"Models","description":"Model components generate text using large language models.","sidebar":"docs"},"Components/components-processing":{"id":"Components/components-processing","title":"Processing","description":"Processing components process and transform data within a flow.","sidebar":"docs"},"Components/components-prompts":{"id":"Components/components-prompts","title":"Prompts","description":"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables.","sidebar":"docs"},"Components/components-tools":{"id":"Components/components-tools","title":"Tools","description":"Tools are typically connected to agent components at the Tools port. Agents use LLMs as a reasoning engine to decide which of the connected tool components to use to solve a problem.","sidebar":"docs"},"Components/components-vector-stores":{"id":"Components/components-vector-stores","title":"Vector stores","description":"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation.","sidebar":"docs"},"Concepts/concepts-components":{"id":"Concepts/concepts-components","title":"Components","description":"A\xa0component\xa0is a single building block within a flow with inputs, outputs, functions, and parameters that define its functionality. A single component is like a class within a larger application.","sidebar":"docs"},"Concepts/concepts-file-management":{"id":"Concepts/concepts-file-management","title":"Manage files","description":"Upload, store, and manage files in Langflow\'s File management system.","sidebar":"docs"},"Concepts/concepts-flows":{"id":"Concepts/concepts-flows","title":"Flows","description":"Flows in Langflow are fully serializable and can be saved and loaded from the file system. In this guide, we\'ll explore how to import and export flows.","sidebar":"docs"},"Concepts/concepts-objects":{"id":"Concepts/concepts-objects","title":"Langflow objects","description":"In Langflow, objects are Pydantic models that serve as structured, functional representations of data.","sidebar":"docs"},"Concepts/concepts-overview":{"id":"Concepts/concepts-overview","title":"Langflow overview","description":"This page explores the fundamental building blocks of Langflow, beginning with the question, \\"What is a flow?\\"","sidebar":"docs"},"Concepts/concepts-playground":{"id":"Concepts/concepts-playground","title":"Playground","description":"The\xa0Playground\xa0is a dynamic interface designed for real-time interaction with LLMs, allowing users to chat, access memories, and monitor inputs and outputs. Here, users can directly prototype their models, making adjustments and observing different outcomes.","sidebar":"docs"},"Concepts/concepts-publish":{"id":"Concepts/concepts-publish","title":"Publish flows","description":"Langflow provides several ways to publish and integrate your flows into external applications. Whether you want to expose your flow via API endpoints, embed it as a chat widget in your website, or share it as a public playground, this guide covers the options available for making your flows accessible to users.","sidebar":"docs"},"Concepts/concepts-voice-mode":{"id":"Concepts/concepts-voice-mode","title":"Voice mode","description":"The Langflow Playground supports voice mode for interacting with your applications through a microphone.","sidebar":"docs"},"Configuration/configuration-api-keys":{"id":"Configuration/configuration-api-keys","title":"API keys","description":"Langflow provides an API key functionality that allows users to access their individual components and flows without traditional login authentication.","sidebar":"docs"},"Configuration/configuration-authentication":{"id":"Configuration/configuration-authentication","title":"Authentication","description":"This guide covers Langflow\'s authentication system and API key management, including how to secure your deployment and manage access to flows and components.","sidebar":"docs"},"Configuration/configuration-auto-saving":{"id":"Configuration/configuration-auto-saving","title":"Auto-saving","description":"Langflow supports both manual and auto-saving functionality.","sidebar":"docs"},"Configuration/configuration-backend-only":{"id":"Configuration/configuration-backend-only","title":"Run Langflow in backend-only mode","description":"Langflow can run in --backend-only mode to expose a Langflow app as an API endpoint, without running the frontend UI.","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 projects.","sidebar":"docs"},"Configuration/configuration-security-best-practices":{"id":"Configuration/configuration-security-best-practices","title":"Security best practices","description":"This guide outlines security best practices for deploying and managing Langflow.","sidebar":"docs"},"Configuration/environment-variables":{"id":"Configuration/environment-variables","title":"Environment variables","description":"Langflow lets you configure a number of settings using environment variables.","sidebar":"docs"},"Contributing/contributing-community":{"id":"Contributing/contributing-community","title":"Join the Langflow community","description":"Join the Langflow Discord server","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\xa0CustomComponent\xa0class.","sidebar":"docs"},"Contributing/contributing-github-discussion-board":{"id":"Contributing/contributing-github-discussion-board","title":"Ask for help on the Discussions board","description":"If you\'re looking for help with your code, consider posting a question on the Langflow\xa0GitHub Discussions board. The Langflow team cannot provide individual support via email. The team also believes that help is much more valuable if it\'s\xa0shared publicly, so that more people can benefit from it.","sidebar":"docs"},"Contributing/contributing-github-issues":{"id":"Contributing/contributing-github-issues","title":"Request an enhancement or report a bug","description":"The\xa0Issues page in the Langflow repo is kept up to date with bugs, improvements, and feature requests. Labels are used to help with sorting and discovery of issues of interest. For an overview of the system Langflow uses to tag issues and pull requests, see the Langflow repo\'s labels page.","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 essential usage statistics to enhance functionality and the user experience. This data helps us identify popular features and areas that need improvement, and ensures development efforts align with what you need.","sidebar":"docs"},"Deployment/deployment-docker":{"id":"Deployment/deployment-docker","title":"Deploy Langflow on Docker","description":"This guide demonstrates deploying Langflow with Docker and Docker Compose.","sidebar":"docs"},"Deployment/deployment-gcp":{"id":"Deployment/deployment-gcp","title":"Deploy Langflow on Google Cloud Platform","description":"This guide demonstrates deploying Langflow on Google Cloud Platform.","sidebar":"docs"},"Deployment/deployment-hugging-face-spaces":{"id":"Deployment/deployment-hugging-face-spaces","title":"Deploy Langflow on HuggingFace Spaces","description":"This guide explains how to deploy Langflow on HuggingFace Spaces.","sidebar":"docs"},"Deployment/deployment-kubernetes":{"id":"Deployment/deployment-kubernetes","title":"Deploy Langflow on Kubernetes","description":"This guide demonstrates deploying Langflow on a Kubernetes cluster.","sidebar":"docs"},"Deployment/deployment-overview":{"id":"Deployment/deployment-overview","title":"Langflow deployment overview","description":"You have a flow, and want to share it with the world in a production environment.","sidebar":"docs"},"Deployment/deployment-railway":{"id":"Deployment/deployment-railway","title":"Deploy Langflow on Railway","description":"This guide explains how to deploy Langflow on Railway, a cloud infrastructure platform that provides auto-deploy, managed databases, and automatic scaling.","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/develop-application":{"id":"Develop/develop-application","title":"Develop an application in Langflow","description":"Follow this guide to learn how to build an application using Langflow.","sidebar":"docs"},"Develop/develop-overview":{"id":"Develop/develop-overview","title":"About developing and configuring Langflow applications","description":"The following pages provide information about how to develop and configure Langflow applications.","sidebar":"docs"},"Develop/install-custom-dependencies":{"id":"Develop/install-custom-dependencies","title":"Install custom dependencies","description":"To install custom dependencies in your Langflow environment, add them with your package manager.","sidebar":"docs"},"Develop/logging":{"id":"Develop/logging","title":"Logging options in Langflow","description":"Langflow uses the loguru library for logging.","sidebar":"docs"},"Develop/memory":{"id":"Develop/memory","title":"Memory management options","description":"Langflow provides flexible memory management options for storage and retrieval.","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"},"Get-Started/get-started-installation":{"id":"Get-Started/get-started-installation","title":"Install Langflow","description":"You can deploy Langflow either locally or as a hosted service with Datastax Langflow.","sidebar":"docs"},"Get-Started/get-started-quickstart":{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get to know Langflow by building an OpenAI-powered chatbot application. After you\'ve constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data.","sidebar":"docs"},"Get-Started/welcome-to-langflow":{"id":"Get-Started/welcome-to-langflow","title":"Welcome to Langflow","description":"Langflow is a new, visual framework for building multi-agent and RAG applications. It is open-source, Python-powered, fully customizable, and LLM and vector store agnostic.","sidebar":"docs"},"Integrations/Apify/integrations-apify":{"id":"Integrations/Apify/integrations-apify","title":"Apify","description":"Apify is a web scraping and data extraction platform. It provides an Actor Store with more than 3,000 ready-made cloud tools called Actors.","sidebar":"docs"},"Integrations/Arize/integrations-arize":{"id":"Integrations/Arize/integrations-arize","title":"Integrate Arize with Langflow","description":"Arize is a tool built on OpenTelemetry and OpenInference for monitoring and optimizing LLM applications.","sidebar":"docs"},"Integrations/Composio/integrations-composio":{"id":"Integrations/Composio/integrations-composio","title":"Integrate Composio with Langflow","description":"Langflow integrates with Composio as a toolset for your Agent component.","sidebar":"docs"},"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow":{"id":"Integrations/Google/integrations-setup-google-cloud-vertex-ai-langflow","title":"Integrate Google Cloud Vertex AI with Langflow","description":"A comprehensive guide on creating a Google OAuth app, obtaining tokens, and integrating them with Langflow\'s Google components.","sidebar":"docs"},"Integrations/Google/integrations-setup-google-oauth-langflow":{"id":"Integrations/Google/integrations-setup-google-oauth-langflow","title":"Integrate Google OAuth with Langflow","description":"A comprehensive guide on creating a Google OAuth app, obtaining tokens, and integrating them with Langflow\'s Google components.","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 observability and analytics platform specifically designed for language models and AI applications.","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, just add your LangChain API key as a Langflow environment variable and you are good to go!","sidebar":"docs"},"Integrations/integrations-langwatch":{"id":"Integrations/integrations-langwatch","title":"LangWatch","description":"938674091aac4d9d9aa4aa6eb5c215b4}","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/integrations-mcp":{"id":"Integrations/MCP/integrations-mcp","title":"Integrate Langflow with MCP","description":"Langflow integrates with the Model Context Protocol (MCP). This allows you to use your Langflow flows as tools in client applications that support the MCP, or extend Langflow with the MCP server component to access MCP servers.","sidebar":"docs"},"Integrations/MCP/mcp-component-astra":{"id":"Integrations/MCP/mcp-component-astra","title":"Connect an Astra DB MCP server to Langflow","description":"Use the MCP server component to connect Langflow to a Datastax Astra DB MCP server.","sidebar":"docs"},"Integrations/Notion/integrations-notion":{"id":"Integrations/Notion/integrations-notion","title":"Setup","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-ingest":{"id":"Integrations/Nvidia/integrations-nvidia-ingest","title":"Integrate NVIDIA Ingest with Langflow","description":"The NVIDIA Ingest 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"},"Sample-Flows/blog-writer":{"id":"Sample-Flows/blog-writer","title":"Blog writer","description":"Build a Blog Writer flow for a one-shot application using OpenAI.","sidebar":"docs"},"Sample-Flows/document-qa":{"id":"Sample-Flows/document-qa","title":"Document QA","description":"Build a question-and-answer chatbot with a document loaded from local memory.","sidebar":"docs"},"Sample-Flows/math-agent":{"id":"Sample-Flows/math-agent","title":"Math agent","description":"Build a Math Agent flow for an agentic application using the Tool-calling agent component.","sidebar":"docs"},"Sample-Flows/memory-chatbot":{"id":"Sample-Flows/memory-chatbot","title":"Memory chatbot","description":"This flow extends the basic prompting flow with a Chat memory component that stores up to 100 previous chat messages and uses them to provide context for the current conversation.","sidebar":"docs"},"Sample-Flows/sequential-agent":{"id":"Sample-Flows/sequential-agent","title":"Sequential tasks agent","description":"Build a Sequential Tasks Agent flow for a multi-agent application using multiple Agent components.","sidebar":"docs"},"Sample-Flows/travel-planning-agent":{"id":"Sample-Flows/travel-planning-agent","title":"Travel planning agent","description":"Build a Travel Planning Agent flow for an agentic application using the multiple Tool-calling agents.","sidebar":"docs"},"Starter-Projects/starter-projects-basic-prompting":{"id":"Starter-Projects/starter-projects-basic-prompting","title":"Basic prompting","description":"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks.","sidebar":"docs"},"Starter-Projects/starter-projects-simple-agent":{"id":"Starter-Projects/starter-projects-simple-agent","title":"Simple agent","description":"Build a Simple Agent flow for an agentic application using the Tool-calling agent component.","sidebar":"docs"},"Starter-Projects/starter-projects-vector-store-rag":{"id":"Starter-Projects/starter-projects-vector-store-rag","title":"Vector store RAG","description":"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it.","sidebar":"docs"},"Support/luna-for-langflow":{"id":"Support/luna-for-langflow","title":"Luna for Langflow","description":"With Luna for Langflow support, you can develop and deploy Langflow applications with confidence.","sidebar":"docs"}}}}')}}]); \ No newline at end of file diff --git a/assets/js/25bf2d67.d39ee16a.js b/assets/js/25bf2d67.d39ee16a.js new file mode 100644 index 0000000000..299956c0f6 --- /dev/null +++ b/assets/js/25bf2d67.d39ee16a.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8031],{2215:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>d,chCodeConfig:()=>p,contentTitle:()=>l,default:()=>m,frontMatter:()=>a,metadata:()=>r,toc:()=>g});const r=JSON.parse('{"id":"Starter-Projects/starter-projects-basic-prompting","title":"Basic prompting","description":"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks.","source":"@site/docs/Starter-Projects/starter-projects-basic-prompting.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-basic-prompting","permalink":"/starter-projects-basic-prompting","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Basic prompting","slug":"/starter-projects-basic-prompting"},"sidebar":"docs","previous":{"title":"Quickstart","permalink":"/get-started-quickstart"},"next":{"title":"Vector store RAG","permalink":"/starter-projects-vector-store-rag"}}');var o=n(74848),i=n(28453),s=n(24754),c=n(84443);const a={title:"Basic prompting",slug:"/starter-projects-basic-prompting"},l=void 0,d={},h={annotations:s.hk,Code:s.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the basic prompting flow",id:"create-the-basic-prompting-flow",level:2},{value:"Run the basic prompting flow",id:"run-the-basic-prompting-flow",level:2},{value:"Modify the prompt for a different result",id:"modify-the-prompt-for-a-different-result",level:2}];function u(e){const t={a:"a",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return h||f("CH",!1),h.Code||f("CH.Code",!0),(0,o.jsxs)(o.Fragment,{children:[(0,o.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,o.jsx)(t.p,{children:"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks."}),"\n",(0,o.jsx)(t.p,{children:"By submitting natural language requests in a prompt to an LLM, you can obtain answers, generate text, and solve problems."}),"\n",(0,o.jsx)(t.p,{children:"This article demonstrates how to use Langflow's prompt tools to issue basic prompts to an LLM, and how various prompting strategies can affect your outcomes."}),"\n",(0,o.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,o.jsxs)(t.ul,{children:["\n",(0,o.jsx)(t.li,{children:(0,o.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,o.jsx)(t.li,{children:(0,o.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"create-the-basic-prompting-flow",children:"Create the basic prompting flow"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["From the Langflow dashboard, click\xa0",(0,o.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n"]}),"\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["Select\xa0",(0,o.jsx)(t.strong,{children:"Basic Prompting"}),"."]}),"\n"]}),"\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["The\xa0",(0,o.jsx)(t.strong,{children:"Basic Prompting"}),"\xa0flow is created."]}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(t.p,{children:(0,o.jsx)(t.img,{src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,o.jsxs)(t.p,{children:["This flow allows you to chat with the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI model"}),"\xa0component.\nThe model will respond according to the prompt constructed in the\xa0",(0,o.jsx)(t.strong,{children:"Prompt"}),"\xa0component."]}),"\n",(0,o.jsxs)(t.ol,{start:"4",children:["\n",(0,o.jsxs)(t.li,{children:["To examine the ",(0,o.jsx)(t.strong,{children:"Template"}),", in the ",(0,o.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,o.jsx)(t.strong,{children:"Template"})," field."]}),"\n"]}),"\n",(0,o.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,o.jsxs)(t.ol,{start:"5",children:["\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["To create an environment variable for the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI"}),"\xa0component, in the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI API Key"}),"\xa0field, click the\xa0",(0,o.jsx)(c.A,{name:"Globe","aria-label":"Globe icon"})," ",(0,o.jsx)(t.strong,{children:"Globe"}),"\xa0button, and then click\xa0",(0,o.jsx)(t.strong,{children:"Add New Variable"}),"."]}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["In the\xa0",(0,o.jsx)(t.strong,{children:"Variable Name"}),"\xa0field, enter\xa0",(0,o.jsx)(t.code,{children:"openai_api_key"}),"."]}),"\n",(0,o.jsxs)(t.li,{children:["In the\xa0",(0,o.jsx)(t.strong,{children:"Value"}),"\xa0field, paste your OpenAI API Key (",(0,o.jsx)(t.code,{children:"sk-..."}),")."]}),"\n",(0,o.jsxs)(t.li,{children:["Click\xa0",(0,o.jsx)(t.strong,{children:"Save Variable"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"run-the-basic-prompting-flow",children:"Run the basic prompting flow"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["Click the\xa0",(0,o.jsx)(t.strong,{children:"Playground"}),"\xa0button."]}),"\n",(0,o.jsx)(t.li,{children:"Type a message and press Enter. The bot should respond in a markedly piratical manner!"}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"modify-the-prompt-for-a-different-result",children:"Modify the prompt for a different result"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["To modify your prompt results, in the\xa0",(0,o.jsx)(t.strong,{children:"Prompt"}),"\xa0component, click the\xa0",(0,o.jsx)(t.strong,{children:"Template"}),"\xa0field. The\xa0",(0,o.jsx)(t.strong,{children:"Edit Prompt"}),"\xa0window opens."]}),"\n",(0,o.jsxs)(t.li,{children:["Change\xa0the existing prompt\xa0to a different character, perhaps\xa0",(0,o.jsx)(t.code,{children:"Answer the user as if you were Hermione Granger."})]}),"\n",(0,o.jsx)(t.li,{children:"Run the workflow again and notice how the prompt changes the model's response."}),"\n"]})]})}function m(e={}){const{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,o.jsx)(t,{...e,children:(0,o.jsx)(u,{...e})}):u(e)}function f(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},84443:(e,t,n)=>{n.d(t,{A:()=>i});n(96540);var r=n(64058),o=n(74848);function i(e){let{name:t,...n}=e;const i=r[t];return i?(0,o.jsx)(i,{...n}):null}},90567:(e,t,n)=>{n.d(t,{A:()=>r});const r=n.p+"assets/images/starter-flow-basic-prompting-09331815d7282bd6a3feedf84838ba20.png"}}]); \ No newline at end of file diff --git a/assets/js/25bf2d67.d87ef78d.js b/assets/js/25bf2d67.d87ef78d.js deleted file mode 100644 index 9bfeb8e0ed..0000000000 --- a/assets/js/25bf2d67.d87ef78d.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8031],{2215:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>l,chCodeConfig:()=>p,contentTitle:()=>d,default:()=>m,frontMatter:()=>a,metadata:()=>r,toc:()=>g});const r=JSON.parse('{"id":"Starter-Projects/starter-projects-basic-prompting","title":"Basic prompting","description":"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks.","source":"@site/docs/Starter-Projects/starter-projects-basic-prompting.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-basic-prompting","permalink":"/starter-projects-basic-prompting","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Basic prompting","slug":"/starter-projects-basic-prompting"},"sidebar":"docs","previous":{"title":"Quickstart","permalink":"/get-started-quickstart"},"next":{"title":"Vector store RAG","permalink":"/starter-projects-vector-store-rag"}}');var o=n(74848),i=n(28453),s=n(24754),c=n(84443);const a={title:"Basic prompting",slug:"/starter-projects-basic-prompting"},d=void 0,l={},h={annotations:s.hk,Code:s.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the basic prompting flow",id:"create-the-basic-prompting-flow",level:2},{value:"Run the basic prompting flow",id:"run-the-basic-prompting-flow",level:2},{value:"Modify the prompt for a different result",id:"modify-the-prompt-for-a-different-result",level:2}];function u(e){const t={a:"a",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return h||f("CH",!1),h.Code||f("CH.Code",!0),(0,o.jsxs)(o.Fragment,{children:[(0,o.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,o.jsx)(t.p,{children:"Prompts serve as the inputs to a large language model (LLM), acting as the interface between human instructions and computational tasks."}),"\n",(0,o.jsx)(t.p,{children:"By submitting natural language requests in a prompt to an LLM, you can obtain answers, generate text, and solve problems."}),"\n",(0,o.jsx)(t.p,{children:"This article demonstrates how to use Langflow's prompt tools to issue basic prompts to an LLM, and how various prompting strategies can affect your outcomes."}),"\n",(0,o.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,o.jsxs)(t.ul,{children:["\n",(0,o.jsx)(t.li,{children:(0,o.jsx)(t.a,{href:"/get-started-installation",children:"Langflow installed and running"})}),"\n",(0,o.jsx)(t.li,{children:(0,o.jsx)(t.a,{href:"https://platform.openai.com/",children:"OpenAI API key created"})}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"create-the-basic-prompting-flow",children:"Create the basic prompting flow"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["From the Langflow dashboard, click\xa0",(0,o.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n"]}),"\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["Select\xa0",(0,o.jsx)(t.strong,{children:"Basic Prompting"}),"."]}),"\n"]}),"\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["The\xa0",(0,o.jsx)(t.strong,{children:"Basic Prompting"}),"\xa0flow is created."]}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(t.p,{children:(0,o.jsx)(t.img,{src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,o.jsxs)(t.p,{children:["This flow allows you to chat with the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI model"}),"\xa0component.\nThe model will respond according to the prompt constructed in the\xa0",(0,o.jsx)(t.strong,{children:"Prompt"}),"\xa0component."]}),"\n",(0,o.jsxs)(t.ol,{start:"4",children:["\n",(0,o.jsxs)(t.li,{children:["To examine the ",(0,o.jsx)(t.strong,{children:"Template"}),", in the ",(0,o.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,o.jsx)(t.strong,{children:"Template"})," field."]}),"\n"]}),"\n",(0,o.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,o.jsxs)(t.ol,{start:"5",children:["\n",(0,o.jsxs)(t.li,{children:["\n",(0,o.jsxs)(t.p,{children:["To create an environment variable for the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI"}),"\xa0component, in the\xa0",(0,o.jsx)(t.strong,{children:"OpenAI API Key"}),"\xa0field, click the\xa0",(0,o.jsx)(c.A,{name:"Globe","aria-label":"Globe icon"})," ",(0,o.jsx)(t.strong,{children:"Globe"}),"\xa0button, and then click\xa0",(0,o.jsx)(t.strong,{children:"Add New Variable"}),"."]}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["In the\xa0",(0,o.jsx)(t.strong,{children:"Variable Name"}),"\xa0field, enter\xa0",(0,o.jsx)(t.code,{children:"openai_api_key"}),"."]}),"\n",(0,o.jsxs)(t.li,{children:["In the\xa0",(0,o.jsx)(t.strong,{children:"Value"}),"\xa0field, paste your OpenAI API Key (",(0,o.jsx)(t.code,{children:"sk-..."}),")."]}),"\n",(0,o.jsxs)(t.li,{children:["Click\xa0",(0,o.jsx)(t.strong,{children:"Save Variable"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"run-the-basic-prompting-flow",children:"Run the basic prompting flow"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["Click the\xa0",(0,o.jsx)(t.strong,{children:"Playground"}),"\xa0button."]}),"\n",(0,o.jsx)(t.li,{children:"Type a message and press Enter. The bot should respond in a markedly piratical manner!"}),"\n"]}),"\n",(0,o.jsx)(t.h2,{id:"modify-the-prompt-for-a-different-result",children:"Modify the prompt for a different result"}),"\n",(0,o.jsxs)(t.ol,{children:["\n",(0,o.jsxs)(t.li,{children:["To modify your prompt results, in the\xa0",(0,o.jsx)(t.strong,{children:"Prompt"}),"\xa0component, click the\xa0",(0,o.jsx)(t.strong,{children:"Template"}),"\xa0field. The\xa0",(0,o.jsx)(t.strong,{children:"Edit Prompt"}),"\xa0window opens."]}),"\n",(0,o.jsxs)(t.li,{children:["Change\xa0the existing prompt\xa0to a different character, perhaps\xa0",(0,o.jsx)(t.code,{children:"Answer the user as if you were Hermione Granger."})]}),"\n",(0,o.jsx)(t.li,{children:"Run the workflow again and notice how the prompt changes the model's response."}),"\n"]})]})}function m(e={}){const{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,o.jsx)(t,{...e,children:(0,o.jsx)(u,{...e})}):u(e)}function f(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},84443:(e,t,n)=>{n.d(t,{A:()=>i});n(96540);var r=n(64058),o=n(74848);function i(e){let{name:t,...n}=e;const i=r[t];return i?(0,o.jsx)(i,{...n}):null}},90567:(e,t,n)=>{n.d(t,{A:()=>r});const r=n.p+"assets/images/starter-flow-basic-prompting-09331815d7282bd6a3feedf84838ba20.png"}}]); \ No newline at end of file diff --git a/assets/js/2ab0d4f5.0775d1de.js b/assets/js/2ab0d4f5.0775d1de.js new file mode 100644 index 0000000000..a5728afab1 --- /dev/null +++ b/assets/js/2ab0d4f5.0775d1de.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.2.0"},"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 \\"sint__\\": \\"\\"\\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.19c8b852.js b/assets/js/2ab0d4f5.19c8b852.js deleted file mode 100644 index 1712ead11b..0000000000 --- a/assets/js/2ab0d4f5.19c8b852.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.2.0"},"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 \\"in_4a\\": \\"\\",\\n \\"aliquip__\\": \\"\\",\\n \\"Excepteur8\\": \\"\\"\\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/3f19c00a.076e5cc7.js b/assets/js/3f19c00a.076e5cc7.js new file mode 100644 index 0000000000..45240b9199 --- /dev/null +++ b/assets/js/3f19c00a.076e5cc7.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[6066],{36003:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>c,chCodeConfig:()=>d,contentTitle:()=>l,default:()=>p,frontMatter:()=>i,metadata:()=>o,toc:()=>u});const o=JSON.parse('{"id":"Sample-Flows/sequential-agent","title":"Sequential tasks agent","description":"Build a Sequential Tasks Agent flow for a multi-agent application using multiple Agent components.","source":"@site/docs/Sample-Flows/sequential-agent.md","sourceDirName":"Sample-Flows","slug":"/sequential-agent","permalink":"/sequential-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Sequential tasks agent","slug":"/sequential-agent"},"sidebar":"docs","previous":{"title":"Memory chatbot","permalink":"/memory-chatbot"},"next":{"title":"Travel planning agent","permalink":"/travel-planning-agent"}}');var s=n(74848),r=n(28453),a=n(24754);const i={title:"Sequential tasks agent",slug:"/sequential-agent"},l=void 0,c={},h={annotations:a.hk,Code:a.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and create a new flow",id:"open-langflow-and-create-a-new-flow",level:2},{value:"Run the Sequential Tasks Agent flow",id:"run-the-sequential-tasks-agent-flow",level:2},{value:"Next steps",id:"next-steps",level:2}];function g(e){const t={a:"a",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return h||m("CH",!1),h.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",(0,s.jsxs)(t.p,{children:["Build a ",(0,s.jsx)(t.strong,{children:"Sequential Tasks Agent"})," flow for a multi-agent application using multiple ",(0,s.jsx)(t.strong,{children:"Agent"})," components."]}),"\n",(0,s.jsxs)(t.p,{children:["Each agent has an LLM model and a unique set of tools at its disposal, with ",(0,s.jsx)(t.strong,{children:"Prompt"})," components connected to the ",(0,s.jsx)(t.strong,{children:"Agent Instructions"})," fields to control the agent's behavior. For example, the ",(0,s.jsx)(t.strong,{children:"Researcher Agent"})," has a ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," component connected as a tool. The ",(0,s.jsx)(t.strong,{children:"Prompt"})," instructs the agent how to answer your query, format the response, and pass the query and research results on to the next agent in the flow."]}),"\n",(0,s.jsx)(t.p,{children:"Each successive agent in the flow builds on the work of the previous agent, creating a chain of reasoning for solving complex problems."}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://www.tavily.com/",children:"A Tavily AI API key"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"open-langflow-and-create-a-new-flow",children:"Open Langflow and create a new flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Sequential Tasks Agent"}),".\nThis opens a starter template with the necessary components to run the flow."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Starter flow for Sequential Tasks Agent",src:n(97807).A+"",width:"2908",height:"1106"})}),"\n",(0,s.jsx)(t.p,{children:"The Sequential Tasks Agent flow consists of these components:"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Agent"})," components use the connected LLM to analyze the user's input and select among the connected tools to complete the tasks."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Prompt"})," component combines the user input with a user-defined prompt."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"YFinance"})," tool component provides access to financial data from Yahoo Finance."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," tool component performs AI-powered web searches."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Calculator"})," tool component performs mathematical calculations."]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"run-the-sequential-tasks-agent-flow",children:"Run the Sequential Tasks Agent flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Add your OpenAI API key to the ",(0,s.jsx)(t.strong,{children:"Agent"})," components."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your Tavily API key to the ",(0,s.jsx)(t.strong,{children:"Tavily"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session with the template's default question."]}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Should I invest in Tesla (TSLA) stock right now?",props:{}}]},{tokens:[{content:"Please analyze the company's current position, market trends,",props:{}}]},{tokens:[{content:"financial health, and provide a clear investment recommendation.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.p,{children:"This question provides clear instructions to the agents about how to proceed and what question to answer."}),"\n",(0,s.jsxs)(t.ol,{start:"4",children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Playground"}),", inspect the answers to see how the agents use the ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," tool to research the query, the ",(0,s.jsx)(t.strong,{children:"YFinance"})," tool to analyze the stock data, and the ",(0,s.jsx)(t.strong,{children:"Calculator"})," to determine if the stock is a wise investment."]}),"\n",(0,s.jsx)(t.li,{children:"Ask similar questions to see how the agents use the tools to answer your queries."}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"next-steps",children:"Next steps"}),"\n",(0,s.jsxs)(t.p,{children:["To create your own multi-agent flow, see ",(0,s.jsx)(t.a,{href:"/agents-tool-calling-agent-component",children:"Create a problem solving agent"}),"."]})]})}function p(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(g,{...e})}):g(e)}function m(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},97807:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-sequential-agent-ccd15bee6bedbe3a33c81a12c10d6475.png"}}]); \ No newline at end of file diff --git a/assets/js/3f19c00a.63b4c50c.js b/assets/js/3f19c00a.63b4c50c.js deleted file mode 100644 index dc25214ab2..0000000000 --- a/assets/js/3f19c00a.63b4c50c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[6066],{36003:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>c,chCodeConfig:()=>d,contentTitle:()=>l,default:()=>p,frontMatter:()=>i,metadata:()=>o,toc:()=>u});const o=JSON.parse('{"id":"Sample-Flows/sequential-agent","title":"Sequential tasks agent","description":"Build a Sequential Tasks Agent flow for a multi-agent application using multiple Agent components.","source":"@site/docs/Sample-Flows/sequential-agent.md","sourceDirName":"Sample-Flows","slug":"/sequential-agent","permalink":"/sequential-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Sequential tasks agent","slug":"/sequential-agent"},"sidebar":"docs","previous":{"title":"Math agent","permalink":"/math-agent"},"next":{"title":"Travel planning agent","permalink":"/travel-planning-agent"}}');var s=n(74848),r=n(28453),a=n(24754);const i={title:"Sequential tasks agent",slug:"/sequential-agent"},l=void 0,c={},h={annotations:a.hk,Code:a.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and create a new flow",id:"open-langflow-and-create-a-new-flow",level:2},{value:"Run the Sequential Tasks Agent flow",id:"run-the-sequential-tasks-agent-flow",level:2},{value:"Next steps",id:"next-steps",level:2}];function g(e){const t={a:"a",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return h||m("CH",!1),h.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",(0,s.jsxs)(t.p,{children:["Build a ",(0,s.jsx)(t.strong,{children:"Sequential Tasks Agent"})," flow for a multi-agent application using multiple ",(0,s.jsx)(t.strong,{children:"Agent"})," components."]}),"\n",(0,s.jsxs)(t.p,{children:["Each agent has an LLM model and a unique set of tools at its disposal, with ",(0,s.jsx)(t.strong,{children:"Prompt"})," components connected to the ",(0,s.jsx)(t.strong,{children:"Agent Instructions"})," fields to control the agent's behavior. For example, the ",(0,s.jsx)(t.strong,{children:"Researcher Agent"})," has a ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," component connected as a tool. The ",(0,s.jsx)(t.strong,{children:"Prompt"})," instructs the agent how to answer your query, format the response, and pass the query and research results on to the next agent in the flow."]}),"\n",(0,s.jsx)(t.p,{children:"Each successive agent in the flow builds on the work of the previous agent, creating a chain of reasoning for solving complex problems."}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://www.tavily.com/",children:"A Tavily AI API key"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"open-langflow-and-create-a-new-flow",children:"Open Langflow and create a new flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Sequential Tasks Agent"}),".\nThis opens a starter template with the necessary components to run the flow."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Starter flow for Sequential Tasks Agent",src:n(97807).A+"",width:"2908",height:"1106"})}),"\n",(0,s.jsx)(t.p,{children:"The Sequential Tasks Agent flow consists of these components:"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Agent"})," components use the connected LLM to analyze the user's input and select among the connected tools to complete the tasks."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Prompt"})," component combines the user input with a user-defined prompt."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"YFinance"})," tool component provides access to financial data from Yahoo Finance."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," tool component performs AI-powered web searches."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Calculator"})," tool component performs mathematical calculations."]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"run-the-sequential-tasks-agent-flow",children:"Run the Sequential Tasks Agent flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Add your OpenAI API key to the ",(0,s.jsx)(t.strong,{children:"Agent"})," components."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your Tavily API key to the ",(0,s.jsx)(t.strong,{children:"Tavily"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session with the template's default question."]}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Should I invest in Tesla (TSLA) stock right now?",props:{}}]},{tokens:[{content:"Please analyze the company's current position, market trends,",props:{}}]},{tokens:[{content:"financial health, and provide a clear investment recommendation.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.p,{children:"This question provides clear instructions to the agents about how to proceed and what question to answer."}),"\n",(0,s.jsxs)(t.ol,{start:"4",children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Playground"}),", inspect the answers to see how the agents use the ",(0,s.jsx)(t.strong,{children:"Tavily AI Search"})," tool to research the query, the ",(0,s.jsx)(t.strong,{children:"YFinance"})," tool to analyze the stock data, and the ",(0,s.jsx)(t.strong,{children:"Calculator"})," to determine if the stock is a wise investment."]}),"\n",(0,s.jsx)(t.li,{children:"Ask similar questions to see how the agents use the tools to answer your queries."}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"next-steps",children:"Next steps"}),"\n",(0,s.jsxs)(t.p,{children:["To create your own multi-agent flow, see ",(0,s.jsx)(t.a,{href:"/agents-tool-calling-agent-component",children:"Create a problem solving agent"}),"."]})]})}function p(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(g,{...e})}):g(e)}function m(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},97807:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-sequential-agent-ccd15bee6bedbe3a33c81a12c10d6475.png"}}]); \ No newline at end of file diff --git a/assets/js/647965d5.facb2096.js b/assets/js/647965d5.efa89a5e.js similarity index 97% rename from assets/js/647965d5.facb2096.js rename to assets/js/647965d5.efa89a5e.js index 95b5ac9466..087cf36c42 100644 --- a/assets/js/647965d5.facb2096.js +++ b/assets/js/647965d5.efa89a5e.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1227],{31832:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>c,chCodeConfig:()=>l,contentTitle:()=>a,default:()=>m,frontMatter:()=>d,metadata:()=>o,toc:()=>p});const o=JSON.parse('{"id":"Components/components-prompts","title":"Prompts","description":"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables.","source":"@site/docs/Components/components-prompts.md","sourceDirName":"Components","slug":"/components-prompts","permalink":"/components-prompts","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Prompts","slug":"/components-prompts"},"sidebar":"docs","previous":{"title":"Processing","permalink":"/components-processing"},"next":{"title":"Tools","permalink":"/components-tools"}}');var r=n(74848),s=n(28453),i=n(24754);const d={title:"Prompts",slug:"/components-prompts"},a="Prompt components in Langflow",c={},h={annotations:i.hk,Code:i.Cy},l={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Use a prompt component in a flow",id:"use-a-prompt-component-in-a-flow",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Langchain Hub Prompt Template",id:"langchain-hub-prompt-template",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3}];function u(e){const t={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.R)(),...e.components};return h||x("CH",!1),h.Code||x("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)(t.header,{children:(0,r.jsx)(t.h1,{id:"prompt-components-in-langflow",children:"Prompt components in Langflow"})}),"\n",(0,r.jsx)(t.p,{children:"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables."}),"\n",(0,r.jsx)(t.p,{children:"Prompt components create prompt templates with custom fields and dynamic variables for providing your model structured, repeatable prompts."}),"\n",(0,r.jsx)(t.p,{children:"Prompts are a combination of natural language and variables created with curly braces."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-prompt-component-in-a-flow",children:"Use a prompt component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["An example of modifying a prompt can be found in the ",(0,r.jsx)(t.a,{href:"/get-started-quickstart#run-the-chatbot-with-retrieved-context",children:"Quickstart"}),", where a basic chatbot flow is extended to include a full vector RAG pipeline."]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{src:n(69645).A+"",width:"2848",height:"1324"})}),"\n",(0,r.jsxs)(t.p,{children:["The default prompt in the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component is ",(0,r.jsx)(t.code,{children:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh."})]}),"\n",(0,r.jsx)(t.p,{children:"This prompt creates a \"personality\" for your LLM's chat interactions, but it doesn't include variables that you may find useful when templating prompts."}),"\n",(0,r.jsxs)(t.p,{children:["To modify the prompt template, in the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,r.jsx)(t.strong,{children:"Template"})," field. For example, the ",(0,r.jsx)(t.code,{children:"{context}"})," variable gives the LLM model access to embedded vector data to return better answers."]}),"\n",(0,r.jsx)(h.Code,{codeConfig:l,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Given the context",props:{}}]},{tokens:[{content:"{context}",props:{}}]},{tokens:[{content:"Answer the question",props:{}}]},{tokens:[{content:"{user_question}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["When variables are added to a prompt template, new fields are automatically created in the component. These fields can be connected to receive text input from other components to automate prompting, or to output instructions to other components. An example of prompts controlling agents behavior is available in the ",(0,r.jsx)(t.a,{href:"/sequential-agent",children:"sequential tasks agent starter flow"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"template"}),(0,r.jsx)(t.td,{children:"Template"}),(0,r.jsx)(t.td,{children:"Create a prompt template with dynamic variables."})]})})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"prompt"}),(0,r.jsx)(t.td,{children:"Prompt Message"}),(0,r.jsxs)(t.td,{children:["The built prompt message returned by the ",(0,r.jsx)(t.code,{children:"build_prompt"})," method."]})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"langchain-hub-prompt-template",children:"Langchain Hub Prompt Template"}),"\n",(0,r.jsxs)(t.p,{children:["This component fetches prompts from the ",(0,r.jsx)(t.a,{href:"https://docs.smith.langchain.com/old/category/prompt-hub",children:"Langchain Hub"}),"."]}),"\n",(0,r.jsxs)(t.p,{children:['When a prompt is loaded, the component generates input fields for custom variables. For example, the default prompt "efriis/my-first-prompt" generates fields for ',(0,r.jsx)(t.code,{children:"profession"})," and ",(0,r.jsx)(t.code,{children:"question"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"langchain_api_key"}),(0,r.jsx)(t.td,{children:"Your LangChain API Key"}),(0,r.jsx)(t.td,{children:"The LangChain API Key to use."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"langchain_hub_prompt"}),(0,r.jsx)(t.td,{children:"LangChain Hub Prompt"}),(0,r.jsx)(t.td,{children:"The LangChain Hub prompt to use."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"prompt"}),(0,r.jsx)(t.td,{children:"Build Prompt"}),(0,r.jsxs)(t.td,{children:["The built prompt message returned by the ",(0,r.jsx)(t.code,{children:"build_prompt"})," method."]})]})})]})]})}function m(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(u,{...e})}):u(e)}function x(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},69645:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-add-document-ingestion-5f9756b0a4b7e232b1507e12f335b15e.png"}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1227],{31832:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>c,chCodeConfig:()=>l,contentTitle:()=>a,default:()=>m,frontMatter:()=>d,metadata:()=>o,toc:()=>p});const o=JSON.parse('{"id":"Components/components-prompts","title":"Prompts","description":"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables.","source":"@site/docs/Components/components-prompts.md","sourceDirName":"Components","slug":"/components-prompts","permalink":"/components-prompts","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Prompts","slug":"/components-prompts"},"sidebar":"docs","previous":{"title":"Processing","permalink":"/components-processing"},"next":{"title":"Tools","permalink":"/components-tools"}}');var r=n(74848),s=n(28453),i=n(24754);const d={title:"Prompts",slug:"/components-prompts"},a="Prompt components in Langflow",c={},h={annotations:i.hk,Code:i.Cy},l={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Use a prompt component in a flow",id:"use-a-prompt-component-in-a-flow",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Langchain Hub Prompt Template",id:"langchain-hub-prompt-template",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3}];function u(e){const t={a:"a",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.R)(),...e.components};return h||x("CH",!1),h.Code||x("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)(t.header,{children:(0,r.jsx)(t.h1,{id:"prompt-components-in-langflow",children:"Prompt components in Langflow"})}),"\n",(0,r.jsx)(t.p,{children:"A prompt is a structured input to a language model that instructs the model how to handle user inputs and variables."}),"\n",(0,r.jsx)(t.p,{children:"Prompt components create prompt templates with custom fields and dynamic variables for providing your model structured, repeatable prompts."}),"\n",(0,r.jsx)(t.p,{children:"Prompts are a combination of natural language and variables created with curly braces."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-prompt-component-in-a-flow",children:"Use a prompt component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["An example of modifying a prompt can be found in the ",(0,r.jsx)(t.a,{href:"/get-started-quickstart#run-the-chatbot-with-retrieved-context",children:"Quickstart"}),", where a basic chatbot flow is extended to include a full vector RAG pipeline."]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{src:n(69645).A+"",width:"2868",height:"1566"})}),"\n",(0,r.jsxs)(t.p,{children:["The default prompt in the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component is ",(0,r.jsx)(t.code,{children:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh."})]}),"\n",(0,r.jsx)(t.p,{children:"This prompt creates a \"personality\" for your LLM's chat interactions, but it doesn't include variables that you may find useful when templating prompts."}),"\n",(0,r.jsxs)(t.p,{children:["To modify the prompt template, in the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,r.jsx)(t.strong,{children:"Template"})," field. For example, the ",(0,r.jsx)(t.code,{children:"{context}"})," variable gives the LLM model access to embedded vector data to return better answers."]}),"\n",(0,r.jsx)(h.Code,{codeConfig:l,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Given the context",props:{}}]},{tokens:[{content:"{context}",props:{}}]},{tokens:[{content:"Answer the question",props:{}}]},{tokens:[{content:"{user_question}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["When variables are added to a prompt template, new fields are automatically created in the component. These fields can be connected to receive text input from other components to automate prompting, or to output instructions to other components. An example of prompts controlling agents behavior is available in the ",(0,r.jsx)(t.a,{href:"/sequential-agent",children:"sequential tasks agent starter flow"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"template"}),(0,r.jsx)(t.td,{children:"Template"}),(0,r.jsx)(t.td,{children:"Create a prompt template with dynamic variables."})]})})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"prompt"}),(0,r.jsx)(t.td,{children:"Prompt Message"}),(0,r.jsxs)(t.td,{children:["The built prompt message returned by the ",(0,r.jsx)(t.code,{children:"build_prompt"})," method."]})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"langchain-hub-prompt-template",children:"Langchain Hub Prompt Template"}),"\n",(0,r.jsxs)(t.p,{children:["This component fetches prompts from the ",(0,r.jsx)(t.a,{href:"https://docs.smith.langchain.com/old/category/prompt-hub",children:"Langchain Hub"}),"."]}),"\n",(0,r.jsxs)(t.p,{children:['When a prompt is loaded, the component generates input fields for custom variables. For example, the default prompt "efriis/my-first-prompt" generates fields for ',(0,r.jsx)(t.code,{children:"profession"})," and ",(0,r.jsx)(t.code,{children:"question"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"langchain_api_key"}),(0,r.jsx)(t.td,{children:"Your LangChain API Key"}),(0,r.jsx)(t.td,{children:"The LangChain API Key to use."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"langchain_hub_prompt"}),(0,r.jsx)(t.td,{children:"LangChain Hub Prompt"}),(0,r.jsx)(t.td,{children:"The LangChain Hub prompt to use."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"prompt"}),(0,r.jsx)(t.td,{children:"Build Prompt"}),(0,r.jsxs)(t.td,{children:["The built prompt message returned by the ",(0,r.jsx)(t.code,{children:"build_prompt"})," method."]})]})})]})]})}function m(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(u,{...e})}):u(e)}function x(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},69645:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-add-document-ingestion-6c34bac012400e3d35f6cebdd350ecf7.png"}}]); \ No newline at end of file diff --git a/assets/js/7ad92a12.72b0e753.js b/assets/js/7ad92a12.72b0e753.js deleted file mode 100644 index da07ca55bb..0000000000 --- a/assets/js/7ad92a12.72b0e753.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[2008],{25838:(e,n,t)=>{t.d(n,{A:()=>o});const o=t.p+"assets/images/starter-flow-document-qa-79583cca9932646d9e3c7630692c26d0.png"},28453:(e,n,t)=>{t.d(n,{R:()=>c,x:()=>l});var o=t(96540);const s={},r=o.createContext(s);function c(e){const n=o.useContext(r);return o.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(s):e.components||s:c(e.components),o.createElement(r.Provider,{value:n},e.children)}},94753:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>i,contentTitle:()=>l,default:()=>h,frontMatter:()=>c,metadata:()=>o,toc:()=>a});const o=JSON.parse('{"id":"Sample-Flows/document-qa","title":"Document QA","description":"Build a question-and-answer chatbot with a document loaded from local memory.","source":"@site/docs/Sample-Flows/document-qa.md","sourceDirName":"Sample-Flows","slug":"/document-qa","permalink":"/document-qa","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Document QA","slug":"/document-qa"},"sidebar":"docs","previous":{"title":"Blog writer","permalink":"/blog-writer"},"next":{"title":"Memory chatbot","permalink":"/memory-chatbot"}}');var s=t(74848),r=t(28453);const c={title:"Document QA",slug:"/document-qa"},l=void 0,i={},a=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the document QA flow",id:"create-the-document-qa-flow",level:2},{value:"Run the document QA flow",id:"run-the-document-qa-flow",level:3}];function d(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.p,{children:"Build a question-and-answer chatbot with a document loaded from local memory."}),"\n",(0,s.jsx)(n.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/get-started-installation",children:"Langflow installed and running"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://platform.openai.com/",children:"OpenAI API key created"})}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"create-the-document-qa-flow",children:"Create the document QA flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(n.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select\xa0",(0,s.jsx)(n.strong,{children:"Document QA"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Document QA"}),"\xa0flow is created."]}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{src:t(25838).A+"",width:"2890",height:"1038"})}),"\n",(0,s.jsxs)(n.p,{children:["This flow is composed of a chatbot with the\xa0",(0,s.jsx)(n.strong,{children:"Chat Input"}),",\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),",\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),", and\xa0",(0,s.jsx)(n.strong,{children:"Chat Output"}),"\xa0components, but also incorporates a ",(0,s.jsx)(n.strong,{children:"File"})," component, which loads a file from your local machine. ",(0,s.jsx)(n.strong,{children:"Parse Data"})," is used to convert the data from ",(0,s.jsx)(n.strong,{children:"File"})," into the\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),"\xa0component as\xa0",(0,s.jsx)(n.code,{children:"{Document}"}),"."]}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),"\xa0component is instructed to answer questions based on the contents of\xa0",(0,s.jsx)(n.code,{children:"{Document}"}),". This gives the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),"\xa0component context it would not otherwise have access to."]}),"\n",(0,s.jsx)(n.h3,{id:"run-the-document-qa-flow",children:"Run the document QA flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Add your ",(0,s.jsx)(n.strong,{children:"OpenAI API key"})," to the ",(0,s.jsx)(n.strong,{children:"Open AI"})," model component."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["To select a document to load, in the\xa0",(0,s.jsx)(n.strong,{children:"File"}),"\xa0component, click the\xa0",(0,s.jsx)(n.strong,{children:"Select files"}),"\xa0button. Select a local file or a file loaded with ",(0,s.jsx)(n.a,{href:"/concepts-file-management",children:"File management"}),", and then click\xa0",(0,s.jsx)(n.strong,{children:"Select file"}),". The file name appears in the component."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Click the\xa0",(0,s.jsx)(n.strong,{children:"Playground"}),"\xa0button. Enter a question about the loaded document's content. You should receive a contextual response indicating that the AI has read your document."]}),"\n"]}),"\n"]})]})}function h(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/7ad92a12.7ff881a6.js b/assets/js/7ad92a12.7ff881a6.js new file mode 100644 index 0000000000..51a018f78d --- /dev/null +++ b/assets/js/7ad92a12.7ff881a6.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[2008],{25838:(e,n,t)=>{t.d(n,{A:()=>o});const o=t.p+"assets/images/starter-flow-document-qa-766402aed4a9fbcc4f68a064f30fc6a1.png"},28453:(e,n,t)=>{t.d(n,{R:()=>r,x:()=>l});var o=t(96540);const s={},c=o.createContext(s);function r(e){const n=o.useContext(c);return o.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(s):e.components||s:r(e.components),o.createElement(c.Provider,{value:n},e.children)}},94753:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>i,contentTitle:()=>l,default:()=>h,frontMatter:()=>r,metadata:()=>o,toc:()=>a});const o=JSON.parse('{"id":"Sample-Flows/document-qa","title":"Document QA","description":"Build a question-and-answer chatbot with a document loaded from local memory.","source":"@site/docs/Sample-Flows/document-qa.md","sourceDirName":"Sample-Flows","slug":"/document-qa","permalink":"/document-qa","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Document QA","slug":"/document-qa"},"sidebar":"docs","previous":{"title":"Blog writer","permalink":"/blog-writer"},"next":{"title":"Memory chatbot","permalink":"/memory-chatbot"}}');var s=t(74848),c=t(28453);const r={title:"Document QA",slug:"/document-qa"},l=void 0,i={},a=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the document QA flow",id:"create-the-document-qa-flow",level:2},{value:"Run the document QA flow",id:"run-the-document-qa-flow",level:3}];function d(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,c.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.p,{children:"Build a question-and-answer chatbot with a document loaded from local memory."}),"\n",(0,s.jsx)(n.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"create-the-document-qa-flow",children:"Create the document QA flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(n.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select\xa0",(0,s.jsx)(n.strong,{children:"Document QA"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Document QA"}),"\xa0flow is created."]}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{src:t(25838).A+"",width:"2976",height:"1276"})}),"\n",(0,s.jsxs)(n.p,{children:["This flow is composed of a chatbot with the\xa0",(0,s.jsx)(n.strong,{children:"Chat Input"}),",\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),",\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),", and\xa0",(0,s.jsx)(n.strong,{children:"Chat Output"}),"\xa0components, but also incorporates a ",(0,s.jsx)(n.strong,{children:"File"})," component, which loads a file from your local machine. The ",(0,s.jsx)(n.strong,{children:"Parser"})," component converts the data from the ",(0,s.jsx)(n.strong,{children:"File"})," component into the\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),"\xa0component as\xa0",(0,s.jsx)(n.code,{children:"{Document}"}),"."]}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Prompt"}),"\xa0component is instructed to answer questions based on the contents of\xa0",(0,s.jsx)(n.code,{children:"{Document}"}),". This gives the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),"\xa0component context it would not otherwise have access to."]}),"\n",(0,s.jsx)(n.h3,{id:"run-the-document-qa-flow",children:"Run the document QA flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Add your ",(0,s.jsx)(n.strong,{children:"OpenAI API key"})," to the ",(0,s.jsx)(n.strong,{children:"Open AI"})," model component."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["To select a document to load, in the\xa0",(0,s.jsx)(n.strong,{children:"File"}),"\xa0component, click the\xa0",(0,s.jsx)(n.strong,{children:"Select files"}),"\xa0button. Select a local file or a file loaded with ",(0,s.jsx)(n.a,{href:"/concepts-file-management",children:"File management"}),", and then click\xa0",(0,s.jsx)(n.strong,{children:"Select file"}),". The file name appears in the component."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Click the\xa0",(0,s.jsx)(n.strong,{children:"Playground"}),"\xa0button. Enter a question about the loaded document's content. You should receive a contextual response indicating that the AI has read your document."]}),"\n"]}),"\n"]})]})}function h(e={}){const{wrapper:n}={...(0,c.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/8054effa.c6bf3115.js b/assets/js/8054effa.c6bf3115.js new file mode 100644 index 0000000000..d450848c9e --- /dev/null +++ b/assets/js/8054effa.c6bf3115.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1394],{9194:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-component-05bf4384404781510bc02454d867c342.png"},26260:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-as-tool-c3ad685e87943112803cf97992cb17b2.png"},30208:(o,t,e)=>{e.r(t),e.d(t,{CH:()=>p,assets:()=>i,chCodeConfig:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>n,toc:()=>h});const n=JSON.parse('{"id":"Agents/agent-tool-calling-agent-component","title":"Create a problem-solving agent","description":"Developing agents in Langchain is complex.","source":"@site/docs/Agents/agent-tool-calling-agent-component.md","sourceDirName":"Agents","slug":"/agents-tool-calling-agent-component","permalink":"/agents-tool-calling-agent-component","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Create a problem-solving agent","slug":"/agents-tool-calling-agent-component"},"sidebar":"docs","previous":{"title":"Agents overview","permalink":"/agents-overview"},"next":{"title":"API keys","permalink":"/configuration-api-keys"}}');var s=e(74848),l=e(28453),r=e(24754);const c={title:"Create a problem-solving agent",slug:"/agents-tool-calling-agent-component"},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"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create a problem-solving agent with AgentComponent",id:"create-a-problem-solving-agent-with-agentcomponent",level:2},{value:"Solve problems with the agent",id:"solve-problems-with-the-agent",level:2},{value:"Edit a tool's metadata",id:"edit-a-tools-metadata",level:3},{value:"Use an agent as a tool",id:"use-an-agent-as-a-tool",level:2},{value:"Add custom components as tools",id:"components-as-tools",level:2},{value:"Make any component a tool",id:"make-any-component-a-tool",level:2},{value:"Use the Run Flow component as a tool",id:"use-the-run-flow-component-as-a-tool",level:2}];function g(o){const t={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,l.R)(),...o.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",(0,s.jsxs)(t.p,{children:["Developing ",(0,s.jsx)(t.strong,{children:"agents"})," in Langchain is complex."]}),"\n",(0,s.jsxs)(t.p,{children:["The ",(0,s.jsx)(t.code,{children:"AgentComponent"})," is a component for easily creating an AI agent capable of analyzing tasks using tools you provide."]}),"\n",(0,s.jsxs)(t.p,{children:["The component contains all of the elements you'll need for creating an agent. Instead of managing LLM models and providers, pick your model and enter your API key. Instead of connecting a ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, enter instructions in the component's ",(0,s.jsx)(t.strong,{children:"Agent Instruction"})," fields."]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Tool calling agentcomponent",src:e(9194).A+"",width:"864",height:"1728"})}),"\n",(0,s.jsxs)(t.p,{children:["Learn how to build a flow starting with the ",(0,s.jsx)(t.strong,{children:"Tool calling agent"})," component, and see how it can help you solve problems."]}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://www.searchapi.io/",children:"A Search API key"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"create-a-problem-solving-agent-with-agentcomponent",children:"Create a problem-solving agent with AgentComponent"}),"\n",(0,s.jsxs)(t.p,{children:["Create a problem-solving agent in Langflow, starting with the ",(0,s.jsx)(t.strong,{children:"Tool calling agent"}),"."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then click ",(0,s.jsx)(t.strong,{children:"Blank Flow"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Click and drag an ",(0,s.jsx)(t.strong,{children:"Agent"})," component to your workspace.\nThe default settings are acceptable for now, so this guide assumes you're using ",(0,s.jsx)(t.strong,{children:"Open AI"})," for the LLM."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Open AI API Key"})," to the ",(0,s.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["Add ",(0,s.jsx)(t.strong,{children:"Chat input"})," and ",(0,s.jsx)(t.strong,{children:"Chat output"})," components to your flow, and connect them to the tool calling agent."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Chat with agent component",src:e(50811).A+"",width:"2266",height:"1620"})}),"\n",(0,s.jsxs)(t.p,{children:["This basic flow enables you to chat with the agent with the ",(0,s.jsx)(t.strong,{children:"Playground"})," after you've connected some ",(0,s.jsx)(t.strong,{children:"Tools"}),"."]}),"\n",(0,s.jsxs)(t.ol,{start:"5",children:["\n",(0,s.jsxs)(t.li,{children:["Connect the ",(0,s.jsx)(t.strong,{children:"Search API"})," tool component to your agent."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Search API key"})," to the component.\nYour agent can now query the Search API for information."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect a ",(0,s.jsx)(t.strong,{children:"Calculator"})," tool for solving basic math problems."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect an ",(0,s.jsx)(t.strong,{children:"API Request"})," component to the agent.\nThis component is not in the ",(0,s.jsx)(t.strong,{children:"Tools"})," category, but the agent can still use it as a tool by enabling ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),".\n",(0,s.jsx)(t.strong,{children:"Tool Mode"})," makes a component into a tool by adding a ",(0,s.jsx)(t.strong,{children:"Toolset"})," port that can be connected to an agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," port.\nTo enable ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," on the component, click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),".\nThe component's fields change dynamically based on the mode it's in."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Chat with agent component",src:e(77064).A+"",width:"1786",height:"1664"})}),"\n",(0,s.jsx)(t.h2,{id:"solve-problems-with-the-agent",children:"Solve problems with the agent"}),"\n",(0,s.jsx)(t.p,{children:"Your agent now has tools for performing a web search, doing basic math, and performing API requests. You can solve many problems with just these capabilities."}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["Your tabletop game group cancelled, and you're stuck at home.\nPoint ",(0,s.jsx)(t.strong,{children:"API Request"})," to an online rules document, tell your agent ",(0,s.jsx)(t.code,{children:"You are a fun game organizer who uses the tools at your disposal"}),", and play a game."]}),"\n",(0,s.jsxs)(t.li,{children:["You need to learn a new software language quickly.\nPoint ",(0,s.jsx)(t.strong,{children:"API Request"})," to some docs, tell your agent ",(0,s.jsx)(t.code,{children:"You are a knowledgeable software developer who uses the tools at your disposal"}),", and start learning."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"See what problems you can solve with this flow. As your problem becomes more specialized, add more tools. For example, add a Python REPL component to solve math problems that are too challenging for the calculator."}),"\n",(0,s.jsx)(t.h3,{id:"edit-a-tools-metadata",children:"Edit a tool's metadata"}),"\n",(0,s.jsxs)(t.p,{children:["To edit a tool's metadata, click the ",(0,s.jsx)(t.strong,{children:"Edit Tools"})," button in the tool to modify its ",(0,s.jsx)(t.code,{children:"name"})," or ",(0,s.jsx)(t.code,{children:"description"})," metadata. These fields help connected agents understand how to use the tool, without having to modify the agent's prompt instructions."]}),"\n",(0,s.jsxs)(t.p,{children:["For example, the ",(0,s.jsx)(t.a,{href:"/components-data#url",children:"URL"})," component has three tools available when ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," is enabled."]}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Tool Name"}),(0,s.jsx)(t.th,{children:"Description"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-fetch_content"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch and retrieve raw content from a URL, including HTML and other structured data. The full response content is returned."})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-fetch_content_text"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch and extract clean, readable text content from a webpage. Only plain text content is returned."})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-as_dataframe"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch structured data from a URL and convert it into a tabular format. Data is returned in a structured DataFrame table format."})]})]})]}),"\n",(0,s.jsxs)(t.p,{children:["A connected agent will have a clear idea of each tool's capabilities based on the ",(0,s.jsx)(t.code,{children:"name"})," and ",(0,s.jsx)(t.code,{children:"description"})," metadata. If you think the agent is using a tool incorrectly, edit a tool's metadata to help it understand the tool better."]}),"\n",(0,s.jsx)(t.p,{children:"Tool names and descriptions can be edited, but the default tool identifiers cannot be changed. If you want to change the tool identifier, create a custom component."}),"\n",(0,s.jsxs)(t.p,{children:["To see which tools the agent is using and how it's using them, ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"})]}),"\n",(0,s.jsx)(t.h2,{id:"use-an-agent-as-a-tool",children:"Use an agent as a tool"}),"\n",(0,s.jsxs)(t.p,{children:["The agent component itself also supports ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," for creating multi-agent flows."]}),"\n",(0,s.jsx)(t.p,{children:"Add an agent to your problem-solving flow that uses a different OpenAI model for more specialized problem solving."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click and drag an ",(0,s.jsx)(t.strong,{children:"Agent"})," component to your workspace."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Open AI API Key"})," to the ",(0,s.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Model Name"})," field, select ",(0,s.jsx)(t.code,{children:"gpt-4o"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," to use this new agent as a tool."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect the new agent's ",(0,s.jsx)(t.strong,{children:"Toolset"})," port to the previously created agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect ",(0,s.jsx)(t.strong,{children:"Search API"})," and ",(0,s.jsx)(t.strong,{children:"API Request"})," to the new agent.\nThe new agent will use ",(0,s.jsx)(t.code,{children:"gpt-4o"})," for the larger tasks of scraping and searching information that requires large context windows.\nThe problem-solving agent will now use this agent as a tool, with its unique LLM and toolset."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"The tool calling agent as a tool",src:e(26260).A+"",width:"2498",height:"1504"})}),"\n",(0,s.jsxs)(t.ol,{start:"7",children:["\n",(0,s.jsxs)(t.li,{children:["The new agent's metadata can be edited to help the problem-solving agent understand how to use it.\nClick ",(0,s.jsx)(t.strong,{children:"Edit Tools"})," to modify the new agent's ",(0,s.jsx)(t.code,{children:"name"})," or ",(0,s.jsx)(t.code,{children:"description"})," metadata so its usage is clear to the problem-solving agent.\nFor example, the default tool name is ",(0,s.jsx)(t.code,{children:"Agent"}),". Edit the name to ",(0,s.jsx)(t.code,{children:"Agent-gpt-4o"}),", and edit the description to ",(0,s.jsx)(t.code,{children:"Use the gpt-4o model for complex problem solving"}),". The problem-solving agent will understand that this is the ",(0,s.jsx)(t.code,{children:"gpt-4o"})," agent, and will use it for tasks requiring a larger context window."]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"components-as-tools",children:"Add custom components as tools"}),"\n",(0,s.jsx)(t.p,{children:"An agent can use custom components as tools."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["To add a custom component to the problem-solving agent flow, click ",(0,s.jsx)(t.strong,{children:"New Custom Component"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsx)(t.p,{children:"Add custom Python code to the custom component.\nHere's an example text analyzer for sentiment analysis."}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.custom ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" Component",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.io ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" MessageTextInput, Output",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.schema ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" Data",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"import",props:{style:{color:"#FF7B72"}}},{content:" re",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"class ",props:{style:{color:"#FF7B72"}}},{content:"TextAnalyzerComponent",props:{style:{color:"#FFA657"}}},{content:"(",props:{style:{color:"#C9D1D9"}}},{content:"Component",props:{style:{color:"#79C0FF"}}},{content:"):",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"Text Analyzer"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" description ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"Analyzes and transforms input text."',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" documentation: ",props:{style:{color:"#C9D1D9"}}},{content:"str ",props:{style:{color:"#79C0FF"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"http://docs.langflow.org/components/custom"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" icon ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"chart-bar"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" name ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"TextAnalyzerComponent"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" inputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" MessageTextInput(",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"input_text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Input Text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" info",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Enter text to analyze"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Hello, World!"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tool_mode",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"True",props:{style:{color:"#79C0FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" outputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" Output(",props:{style:{color:"#C9D1D9"}}},{content:"display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Analysis Result"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"output"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:"method",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"analyze_text"',props:{style:{color:"#A5D6FF"}}},{content:"),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" def ",props:{style:{color:"#FF7B72"}}},{content:"analyze_text",props:{style:{color:"#D2A8FF"}}},{content:"(self) -> Data:",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" text ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"self",props:{style:{color:"#79C0FF"}}},{content:".input_text",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" # Perform text analysis",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" word_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(text.split())",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" char_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(text)",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" sentence_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(re.findall(",props:{style:{color:"#C9D1D9"}}},{content:"r",props:{style:{color:"#FF7B72"}}},{content:"'",props:{style:{color:"#A5D6FF"}}},{content:"\\w",props:{style:{color:"#79C0FF"}}},{content:"+",props:{style:{color:"#FF7B72"}}},{content:"[.!?]",props:{style:{color:"#79C0FF"}}},{content:"'",props:{style:{color:"#A5D6FF"}}},{content:", text))",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" # Transform text",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" reversed_text ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" text[::",props:{style:{color:"#C9D1D9"}}},{content:"-",props:{style:{color:"#FF7B72"}}},{content:"1",props:{style:{color:"#79C0FF"}}},{content:"]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" uppercase_text ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" text.upper()",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" analysis_result ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" {",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "original_text"',props:{style:{color:"#A5D6FF"}}},{content:": text,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "word_count"',props:{style:{color:"#A5D6FF"}}},{content:": word_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "character_count"',props:{style:{color:"#A5D6FF"}}},{content:": char_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "sentence_count"',props:{style:{color:"#A5D6FF"}}},{content:": sentence_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "reversed_text"',props:{style:{color:"#A5D6FF"}}},{content:": reversed_text,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "uppercase_text"',props:{style:{color:"#A5D6FF"}}},{content:": uppercase_text",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" }",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" data ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" Data(",props:{style:{color:"#C9D1D9"}}},{content:"value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"analysis_result)",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" self",props:{style:{color:"#79C0FF"}}},{content:".status ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" data",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" return",props:{style:{color:"#FF7B72"}}},{content:" data",props:{style:{color:"#C9D1D9"}}}]}],lang:"python"},annotations:[]}]}),"\n",(0,s.jsxs)(t.ol,{start:"3",children:["\n",(0,s.jsxs)(t.li,{children:["To enable the custom component as a tool, click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the tool output to the agent's tools input."}),"\n",(0,s.jsxs)(t.li,{children:["Ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"}),"\nYour response will be similar to the following, and will include your custom component."]}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I have access to several tools that assist me in answering your questions, including:",props:{}}]},{tokens:[{content:"Search API: This allows me to search for recent information or results on the web.",props:{}}]},{tokens:[{content:"HTTP Requests: I can make HTTP requests to various URLs to retrieve data or interact with APIs.",props:{}}]},{tokens:[{content:"Calculator: I can evaluate basic arithmetic expressions.",props:{}}]},{tokens:[{content:"Text Analyzer: I can analyze and transform input text.",props:{}}]},{tokens:[{content:"Current Date and Time: I can retrieve the current date and time in various time zones.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.h2,{id:"make-any-component-a-tool",children:"Make any component a tool"}),"\n",(0,s.jsxs)(t.p,{children:["If the component you want to use as a tool doesn't have a ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," button, add ",(0,s.jsx)(t.code,{children:"tool_mode=True"})," to one of the component's inputs, and connect the new ",(0,s.jsx)(t.strong,{children:"Toolset"})," output to the agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," input."]}),"\n",(0,s.jsxs)(t.p,{children:["Langflow supports ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," for the following data types:"]}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DataInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DataFrameInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"PromptInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"MessageTextInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"MultilineInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DropdownInput"})}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["For example, the ",(0,s.jsx)(t.a,{href:"#components-as-tools",children:"components as tools"})," example above adds ",(0,s.jsx)(t.code,{children:"tool_mode=True"})," to the ",(0,s.jsx)(t.code,{children:"MessageTextInput"})," input so the custom component can be used as a tool."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"inputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" MessageTextInput(",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"input_text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Input Text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" info",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Enter text to analyze"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Hello, World!"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tool_mode",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"True",props:{style:{color:"#79C0FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"]",props:{style:{color:"#C9D1D9"}}}]}],lang:"python"},annotations:[]}]}),"\n",(0,s.jsx)(t.h2,{id:"use-the-run-flow-component-as-a-tool",children:"Use the Run Flow component as a tool"}),"\n",(0,s.jsxs)(t.p,{children:["An agent can use flows that are saved in your workspace as tools with the ",(0,s.jsx)(t.a,{href:"/components-logic#run-flow",children:"Run flow"})," component."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["To add a ",(0,s.jsx)(t.strong,{children:"Run flow"})," component, click and drag a ",(0,s.jsx)(t.strong,{children:"Run flow"})," component to your workspace."]}),"\n",(0,s.jsx)(t.li,{children:"Select the flow you want the agent to use as a tool."}),"\n",(0,s.jsxs)(t.li,{children:["Enable ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," in the component."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the tool output to the agent's tools input."}),"\n",(0,s.jsxs)(t.li,{children:["To enable tool mode, select a ",(0,s.jsx)(t.strong,{children:"Flow"})," in the ",(0,s.jsx)(t.strong,{children:"Run flow"})," component, and then click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"}),"\nYour flow should be visible in the response as a tool."]}),"\n"]})]})}function u(o={}){const{wrapper:t}={...(0,l.R)(),...o.components};return t?(0,s.jsx)(t,{...o,children:(0,s.jsx)(g,{...o})}):g(o)}function y(o,t){throw new Error("Expected "+(t?"component":"object")+" `"+o+"` to be defined: you likely forgot to import, pass, or provide it.")}},50811:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-add-chat-add13631186c9475f8e74bdcb9b0446e.png"},77064:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-add-tools-c6a8fb643df51ff62d1da858d583d15b.png"}}]); \ No newline at end of file diff --git a/assets/js/8054effa.e6e15310.js b/assets/js/8054effa.e6e15310.js deleted file mode 100644 index 1b6e866cab..0000000000 --- a/assets/js/8054effa.e6e15310.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1394],{9194:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-component-05bf4384404781510bc02454d867c342.png"},26260:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-as-tool-c3ad685e87943112803cf97992cb17b2.png"},30208:(o,t,e)=>{e.r(t),e.d(t,{CH:()=>p,assets:()=>i,chCodeConfig:()=>d,contentTitle:()=>a,default:()=>u,frontMatter:()=>c,metadata:()=>n,toc:()=>h});const n=JSON.parse('{"id":"Agents/agent-tool-calling-agent-component","title":"Create a problem-solving agent","description":"Developing agents in Langchain is complex.","source":"@site/docs/Agents/agent-tool-calling-agent-component.md","sourceDirName":"Agents","slug":"/agents-tool-calling-agent-component","permalink":"/agents-tool-calling-agent-component","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Create a problem-solving agent","slug":"/agents-tool-calling-agent-component"},"sidebar":"docs","previous":{"title":"Agents overview","permalink":"/agents-overview"},"next":{"title":"API keys","permalink":"/configuration-api-keys"}}');var s=e(74848),l=e(28453),r=e(24754);const c={title:"Create a problem-solving agent",slug:"/agents-tool-calling-agent-component"},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"},h=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create a problem-solving agent with AgentComponent",id:"create-a-problem-solving-agent-with-agentcomponent",level:2},{value:"Solve problems with the agent",id:"solve-problems-with-the-agent",level:2},{value:"Edit a tool's metadata",id:"edit-a-tools-metadata",level:3},{value:"Use an agent as a tool",id:"use-an-agent-as-a-tool",level:2},{value:"Add custom components as tools",id:"components-as-tools",level:2},{value:"Make any component a tool",id:"make-any-component-a-tool",level:2},{value:"Use the Run Flow component as a tool",id:"use-the-run-flow-component-as-a-tool",level:2}];function g(o){const t={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,l.R)(),...o.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",(0,s.jsxs)(t.p,{children:["Developing ",(0,s.jsx)(t.strong,{children:"agents"})," in Langchain is complex."]}),"\n",(0,s.jsxs)(t.p,{children:["The ",(0,s.jsx)(t.code,{children:"AgentComponent"})," is a component for easily creating an AI agent capable of analyzing tasks using tools you provide."]}),"\n",(0,s.jsxs)(t.p,{children:["The component contains all of the elements you'll need for creating an agent. Instead of managing LLM models and providers, pick your model and enter your API key. Instead of connecting a ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, enter instructions in the component's ",(0,s.jsx)(t.strong,{children:"Agent Instruction"})," fields."]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Tool calling agentcomponent",src:e(9194).A+"",width:"864",height:"1728"})}),"\n",(0,s.jsxs)(t.p,{children:["Learn how to build a flow starting with the ",(0,s.jsx)(t.strong,{children:"Tool calling agent"})," component, and see how it can help you solve problems."]}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://www.searchapi.io/",children:"A Search API key"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"create-a-problem-solving-agent-with-agentcomponent",children:"Create a problem-solving agent with AgentComponent"}),"\n",(0,s.jsxs)(t.p,{children:["Create a problem-solving agent in Langflow, starting with the ",(0,s.jsx)(t.strong,{children:"Tool calling agent"}),"."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then click ",(0,s.jsx)(t.strong,{children:"Blank Flow"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Click and drag an ",(0,s.jsx)(t.strong,{children:"Agent"})," component to your workspace.\nThe default settings are acceptable for now, so this guide assumes you're using ",(0,s.jsx)(t.strong,{children:"Open AI"})," for the LLM."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Open AI API Key"})," to the ",(0,s.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["Add ",(0,s.jsx)(t.strong,{children:"Chat input"})," and ",(0,s.jsx)(t.strong,{children:"Chat output"})," components to your flow, and connect them to the tool calling agent."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Chat with agent component",src:e(50811).A+"",width:"2266",height:"1620"})}),"\n",(0,s.jsxs)(t.p,{children:["This basic flow enables you to chat with the agent with the ",(0,s.jsx)(t.strong,{children:"Playground"})," after you've connected some ",(0,s.jsx)(t.strong,{children:"Tools"}),"."]}),"\n",(0,s.jsxs)(t.ol,{start:"5",children:["\n",(0,s.jsxs)(t.li,{children:["Connect the ",(0,s.jsx)(t.strong,{children:"Search API"})," tool component to your agent."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Search API key"})," to the component.\nYour agent can now query the Search API for information."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect a ",(0,s.jsx)(t.strong,{children:"Calculator"})," tool for solving basic math problems."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect an ",(0,s.jsx)(t.strong,{children:"API Request"})," component to the agent.\nThis component is not in the ",(0,s.jsx)(t.strong,{children:"Tools"})," category, but the agent can still use it as a tool by enabling ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),".\n",(0,s.jsx)(t.strong,{children:"Tool Mode"})," makes a component into a tool by adding a ",(0,s.jsx)(t.strong,{children:"Toolset"})," port that can be connected to an agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," port.\nTo enable ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," on the component, click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),".\nThe component's fields change dynamically based on the mode it's in."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Chat with agent component",src:e(77064).A+"",width:"1786",height:"1664"})}),"\n",(0,s.jsx)(t.h2,{id:"solve-problems-with-the-agent",children:"Solve problems with the agent"}),"\n",(0,s.jsx)(t.p,{children:"Your agent now has tools for performing a web search, doing basic math, and performing API requests. You can solve many problems with just these capabilities."}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["Your tabletop game group cancelled, and you're stuck at home.\nPoint ",(0,s.jsx)(t.strong,{children:"API Request"})," to an online rules document, tell your agent ",(0,s.jsx)(t.code,{children:"You are a fun game organizer who uses the tools at your disposal"}),", and play a game."]}),"\n",(0,s.jsxs)(t.li,{children:["You need to learn a new software language quickly.\nPoint ",(0,s.jsx)(t.strong,{children:"API Request"})," to some docs, tell your agent ",(0,s.jsx)(t.code,{children:"You are a knowledgeable software developer who uses the tools at your disposal"}),", and start learning."]}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["See what problems you can solve with this flow. As your problem becomes more specialized, add a tool. For example, the ",(0,s.jsx)(t.a,{href:"/math-agent",children:"math agent project"})," adds a Python REPL component to solve math problems that are too challenging for the calculator."]}),"\n",(0,s.jsx)(t.h3,{id:"edit-a-tools-metadata",children:"Edit a tool's metadata"}),"\n",(0,s.jsxs)(t.p,{children:["To edit a tool's metadata, click the ",(0,s.jsx)(t.strong,{children:"Edit Tools"})," button in the tool to modify its ",(0,s.jsx)(t.code,{children:"name"})," or ",(0,s.jsx)(t.code,{children:"description"})," metadata. These fields help connected agents understand how to use the tool, without having to modify the agent's prompt instructions."]}),"\n",(0,s.jsxs)(t.p,{children:["For example, the ",(0,s.jsx)(t.a,{href:"/components-data#url",children:"URL"})," component has three tools available when ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," is enabled."]}),"\n",(0,s.jsxs)(t.table,{children:[(0,s.jsx)(t.thead,{children:(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.th,{children:"Tool Name"}),(0,s.jsx)(t.th,{children:"Description"})]})}),(0,s.jsxs)(t.tbody,{children:[(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-fetch_content"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch and retrieve raw content from a URL, including HTML and other structured data. The full response content is returned."})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-fetch_content_text"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch and extract clean, readable text content from a webpage. Only plain text content is returned."})]}),(0,s.jsxs)(t.tr,{children:[(0,s.jsx)(t.td,{children:(0,s.jsx)(t.code,{children:"URL-as_dataframe"})}),(0,s.jsx)(t.td,{children:"Use this tool to fetch structured data from a URL and convert it into a tabular format. Data is returned in a structured DataFrame table format."})]})]})]}),"\n",(0,s.jsxs)(t.p,{children:["A connected agent will have a clear idea of each tool's capabilities based on the ",(0,s.jsx)(t.code,{children:"name"})," and ",(0,s.jsx)(t.code,{children:"description"})," metadata. If you think the agent is using a tool incorrectly, edit a tool's metadata to help it understand the tool better."]}),"\n",(0,s.jsx)(t.p,{children:"Tool names and descriptions can be edited, but the default tool identifiers cannot be changed. If you want to change the tool identifier, create a custom component."}),"\n",(0,s.jsxs)(t.p,{children:["To see which tools the agent is using and how it's using them, ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"})]}),"\n",(0,s.jsx)(t.h2,{id:"use-an-agent-as-a-tool",children:"Use an agent as a tool"}),"\n",(0,s.jsxs)(t.p,{children:["The agent component itself also supports ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," for creating multi-agent flows."]}),"\n",(0,s.jsx)(t.p,{children:"Add an agent to your problem-solving flow that uses a different OpenAI model for more specialized problem solving."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click and drag an ",(0,s.jsx)(t.strong,{children:"Agent"})," component to your workspace."]}),"\n",(0,s.jsxs)(t.li,{children:["Add your ",(0,s.jsx)(t.strong,{children:"Open AI API Key"})," to the ",(0,s.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Model Name"})," field, select ",(0,s.jsx)(t.code,{children:"gpt-4o"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," to use this new agent as a tool."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect the new agent's ",(0,s.jsx)(t.strong,{children:"Toolset"})," port to the previously created agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["Connect ",(0,s.jsx)(t.strong,{children:"Search API"})," and ",(0,s.jsx)(t.strong,{children:"API Request"})," to the new agent.\nThe new agent will use ",(0,s.jsx)(t.code,{children:"gpt-4o"})," for the larger tasks of scraping and searching information that requires large context windows.\nThe problem-solving agent will now use this agent as a tool, with its unique LLM and toolset."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"The tool calling agent as a tool",src:e(26260).A+"",width:"2498",height:"1504"})}),"\n",(0,s.jsxs)(t.ol,{start:"7",children:["\n",(0,s.jsxs)(t.li,{children:["The new agent's metadata can be edited to help the problem-solving agent understand how to use it.\nClick ",(0,s.jsx)(t.strong,{children:"Edit Tools"})," to modify the new agent's ",(0,s.jsx)(t.code,{children:"name"})," or ",(0,s.jsx)(t.code,{children:"description"})," metadata so its usage is clear to the problem-solving agent.\nFor example, the default tool name is ",(0,s.jsx)(t.code,{children:"Agent"}),". Edit the name to ",(0,s.jsx)(t.code,{children:"Agent-gpt-4o"}),", and edit the description to ",(0,s.jsx)(t.code,{children:"Use the gpt-4o model for complex problem solving"}),". The problem-solving agent will understand that this is the ",(0,s.jsx)(t.code,{children:"gpt-4o"})," agent, and will use it for tasks requiring a larger context window."]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"components-as-tools",children:"Add custom components as tools"}),"\n",(0,s.jsx)(t.p,{children:"An agent can use custom components as tools."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["To add a custom component to the problem-solving agent flow, click ",(0,s.jsx)(t.strong,{children:"New Custom Component"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsx)(t.p,{children:"Add custom Python code to the custom component.\nHere's an example text analyzer for sentiment analysis."}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.custom ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" Component",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.io ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" MessageTextInput, Output",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"from",props:{style:{color:"#FF7B72"}}},{content:" langflow.schema ",props:{style:{color:"#C9D1D9"}}},{content:"import",props:{style:{color:"#FF7B72"}}},{content:" Data",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"import",props:{style:{color:"#FF7B72"}}},{content:" re",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"class ",props:{style:{color:"#FF7B72"}}},{content:"TextAnalyzerComponent",props:{style:{color:"#FFA657"}}},{content:"(",props:{style:{color:"#C9D1D9"}}},{content:"Component",props:{style:{color:"#79C0FF"}}},{content:"):",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"Text Analyzer"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" description ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"Analyzes and transforms input text."',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" documentation: ",props:{style:{color:"#C9D1D9"}}},{content:"str ",props:{style:{color:"#79C0FF"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"http://docs.langflow.org/components/custom"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" icon ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"chart-bar"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:" name ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:'"TextAnalyzerComponent"',props:{style:{color:"#A5D6FF"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" inputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" MessageTextInput(",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"input_text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Input Text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" info",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Enter text to analyze"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Hello, World!"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tool_mode",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"True",props:{style:{color:"#79C0FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" outputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" Output(",props:{style:{color:"#C9D1D9"}}},{content:"display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Analysis Result"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:"name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"output"',props:{style:{color:"#A5D6FF"}}},{content:", ",props:{style:{color:"#C9D1D9"}}},{content:"method",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"analyze_text"',props:{style:{color:"#A5D6FF"}}},{content:"),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" def ",props:{style:{color:"#FF7B72"}}},{content:"analyze_text",props:{style:{color:"#D2A8FF"}}},{content:"(self) -> Data:",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" text ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"self",props:{style:{color:"#79C0FF"}}},{content:".input_text",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" # Perform text analysis",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" word_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(text.split())",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" char_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(text)",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" sentence_count ",props:{style:{color:"#C9D1D9"}}},{content:"= ",props:{style:{color:"#FF7B72"}}},{content:"len",props:{style:{color:"#79C0FF"}}},{content:"(re.findall(",props:{style:{color:"#C9D1D9"}}},{content:"r",props:{style:{color:"#FF7B72"}}},{content:"'",props:{style:{color:"#A5D6FF"}}},{content:"\\w",props:{style:{color:"#79C0FF"}}},{content:"+",props:{style:{color:"#FF7B72"}}},{content:"[.!?]",props:{style:{color:"#79C0FF"}}},{content:"'",props:{style:{color:"#A5D6FF"}}},{content:", text))",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" # Transform text",props:{style:{color:"#8B949E"}}}]},{tokens:[{content:" reversed_text ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" text[::",props:{style:{color:"#C9D1D9"}}},{content:"-",props:{style:{color:"#FF7B72"}}},{content:"1",props:{style:{color:"#79C0FF"}}},{content:"]",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" uppercase_text ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" text.upper()",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" analysis_result ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" {",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "original_text"',props:{style:{color:"#A5D6FF"}}},{content:": text,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "word_count"',props:{style:{color:"#A5D6FF"}}},{content:": word_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "character_count"',props:{style:{color:"#A5D6FF"}}},{content:": char_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "sentence_count"',props:{style:{color:"#A5D6FF"}}},{content:": sentence_count,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "reversed_text"',props:{style:{color:"#A5D6FF"}}},{content:": reversed_text,",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:' "uppercase_text"',props:{style:{color:"#A5D6FF"}}},{content:": uppercase_text",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" }",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" data ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" Data(",props:{style:{color:"#C9D1D9"}}},{content:"value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"analysis_result)",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" self",props:{style:{color:"#79C0FF"}}},{content:".status ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" data",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" return",props:{style:{color:"#FF7B72"}}},{content:" data",props:{style:{color:"#C9D1D9"}}}]}],lang:"python"},annotations:[]}]}),"\n",(0,s.jsxs)(t.ol,{start:"3",children:["\n",(0,s.jsxs)(t.li,{children:["To enable the custom component as a tool, click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the tool output to the agent's tools input."}),"\n",(0,s.jsxs)(t.li,{children:["Ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"}),"\nYour response will be similar to the following, and will include your custom component."]}),"\n"]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I have access to several tools that assist me in answering your questions, including:",props:{}}]},{tokens:[{content:"Search API: This allows me to search for recent information or results on the web.",props:{}}]},{tokens:[{content:"HTTP Requests: I can make HTTP requests to various URLs to retrieve data or interact with APIs.",props:{}}]},{tokens:[{content:"Calculator: I can evaluate basic arithmetic expressions.",props:{}}]},{tokens:[{content:"Text Analyzer: I can analyze and transform input text.",props:{}}]},{tokens:[{content:"Current Date and Time: I can retrieve the current date and time in various time zones.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.h2,{id:"make-any-component-a-tool",children:"Make any component a tool"}),"\n",(0,s.jsxs)(t.p,{children:["If the component you want to use as a tool doesn't have a ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," button, add ",(0,s.jsx)(t.code,{children:"tool_mode=True"})," to one of the component's inputs, and connect the new ",(0,s.jsx)(t.strong,{children:"Toolset"})," output to the agent's ",(0,s.jsx)(t.strong,{children:"Tools"})," input."]}),"\n",(0,s.jsxs)(t.p,{children:["Langflow supports ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," for the following data types:"]}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DataInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DataFrameInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"PromptInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"MessageTextInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"MultilineInput"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.code,{children:"DropdownInput"})}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["For example, the ",(0,s.jsx)(t.a,{href:"#components-as-tools",children:"components as tools"})," example above adds ",(0,s.jsx)(t.code,{children:"tool_mode=True"})," to the ",(0,s.jsx)(t.code,{children:"MessageTextInput"})," input so the custom component can be used as a tool."]}),"\n",(0,s.jsx)(p.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"inputs ",props:{style:{color:"#C9D1D9"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:" [",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" MessageTextInput(",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"input_text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" display_name",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Input Text"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" info",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Enter text to analyze"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" value",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:'"Hello, World!"',props:{style:{color:"#A5D6FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" tool_mode",props:{style:{color:"#FFA657"}}},{content:"=",props:{style:{color:"#FF7B72"}}},{content:"True",props:{style:{color:"#79C0FF"}}},{content:",",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:" ),",props:{style:{color:"#C9D1D9"}}}]},{tokens:[{content:"]",props:{style:{color:"#C9D1D9"}}}]}],lang:"python"},annotations:[]}]}),"\n",(0,s.jsx)(t.h2,{id:"use-the-run-flow-component-as-a-tool",children:"Use the Run Flow component as a tool"}),"\n",(0,s.jsxs)(t.p,{children:["An agent can use flows that are saved in your workspace as tools with the ",(0,s.jsx)(t.a,{href:"/components-logic#run-flow",children:"Run flow"})," component."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["To add a ",(0,s.jsx)(t.strong,{children:"Run flow"})," component, click and drag a ",(0,s.jsx)(t.strong,{children:"Run flow"})," component to your workspace."]}),"\n",(0,s.jsx)(t.li,{children:"Select the flow you want the agent to use as a tool."}),"\n",(0,s.jsxs)(t.li,{children:["Enable ",(0,s.jsx)(t.strong,{children:"Tool Mode"})," in the component."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the tool output to the agent's tools input."}),"\n",(0,s.jsxs)(t.li,{children:["To enable tool mode, select a ",(0,s.jsx)(t.strong,{children:"Flow"})," in the ",(0,s.jsx)(t.strong,{children:"Run flow"})," component, and then click ",(0,s.jsx)(t.strong,{children:"Tool Mode"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Ask the agent, ",(0,s.jsx)(t.code,{children:"What tools are you using to answer my questions?"}),"\nYour flow should be visible in the response as a tool."]}),"\n"]})]})}function u(o={}){const{wrapper:t}={...(0,l.R)(),...o.components};return t?(0,s.jsx)(t,{...o,children:(0,s.jsx)(g,{...o})}):g(o)}function y(o,t){throw new Error("Expected "+(t?"component":"object")+" `"+o+"` to be defined: you likely forgot to import, pass, or provide it.")}},50811:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-add-chat-add13631186c9475f8e74bdcb9b0446e.png"},77064:(o,t,e)=>{e.d(t,{A:()=>n});const n=e.p+"assets/images/tool-calling-agent-add-tools-c6a8fb643df51ff62d1da858d583d15b.png"}}]); \ No newline at end of file diff --git a/assets/js/921b5fc1.bc820cbe.js b/assets/js/921b5fc1.ce0affd3.js similarity index 99% rename from assets/js/921b5fc1.bc820cbe.js rename to assets/js/921b5fc1.ce0affd3.js index f3c95ca042..c448bdd0c7 100644 --- a/assets/js/921b5fc1.bc820cbe.js +++ b/assets/js/921b5fc1.ce0affd3.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[7462],{28453:(e,d,n)=>{n.d(d,{R:()=>r,x:()=>l});var s=n(96540);const t={},i=s.createContext(t);function r(e){const d=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(d):{...d,...e}}),[d,e])}function l(e){let d;return d=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:r(e.components),s.createElement(i.Provider,{value:d},e.children)}},56088:(e,d,n)=>{n.r(d),n.d(d,{assets:()=>h,contentTitle:()=>l,default:()=>a,frontMatter:()=>r,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/components-embedding-models","title":"Embeddings","description":"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context.","source":"@site/docs/Components/components-embedding-models.md","sourceDirName":"Components","slug":"/components-embedding-models","permalink":"/components-embedding-models","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Embeddings","slug":"/components-embedding-models"},"sidebar":"docs","previous":{"title":"Data","permalink":"/components-data"},"next":{"title":"Helpers","permalink":"/components-helpers"}}');var t=n(74848),i=n(28453);const r={title:"Embeddings",slug:"/components-embedding-models"},l="Embeddings models in Langflow",h={},c=[{value:"Use an embeddings model component in a flow",id:"use-an-embeddings-model-component-in-a-flow",level:2},{value:"AI/ML",id:"aiml",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Amazon Bedrock Embeddings",id:"amazon-bedrock-embeddings",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Astra DB vectorize",id:"astra-db-vectorize",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Azure OpenAI Embeddings",id:"azure-openai-embeddings",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Cloudflare Workers AI Embeddings",id:"cloudflare-workers-ai-embeddings",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Cohere Embeddings",id:"cohere-embeddings",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"Embedding similarity",id:"embedding-similarity",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"Google generative AI embeddings",id:"google-generative-ai-embeddings",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"Hugging Face Embeddings",id:"hugging-face-embeddings",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3},{value:"Hugging Face embeddings inference",id:"hugging-face-embeddings-inference",level:2},{value:"Inputs",id:"inputs-9",level:3},{value:"Outputs",id:"outputs-9",level:3},{value:"Connect the Hugging Face component to a local embeddings model",id:"connect-the-hugging-face-component-to-a-local-embeddings-model",level:3},{value:"LM Studio Embeddings",id:"lm-studio-embeddings",level:2},{value:"Inputs",id:"inputs-10",level:3},{value:"Outputs",id:"outputs-10",level:3},{value:"MistralAI",id:"mistralai",level:2},{value:"Inputs",id:"inputs-11",level:3},{value:"Outputs",id:"outputs-11",level:3},{value:"NVIDIA",id:"nvidia",level:2},{value:"Inputs",id:"inputs-12",level:3},{value:"Outputs",id:"outputs-12",level:3},{value:"Ollama Embeddings",id:"ollama-embeddings",level:2},{value:"Inputs",id:"inputs-13",level:3},{value:"Outputs",id:"outputs-13",level:3},{value:"OpenAI Embeddings",id:"openai-embeddings",level:2},{value:"Inputs",id:"inputs-14",level:3},{value:"Outputs",id:"outputs-14",level:3},{value:"Text embedder",id:"text-embedder",level:2},{value:"Inputs",id:"inputs-15",level:3},{value:"Outputs",id:"outputs-15",level:3},{value:"VertexAI Embeddings",id:"vertexai-embeddings",level:2},{value:"Inputs",id:"inputs-16",level:3},{value:"Outputs",id:"outputs-16",level:3}];function o(e){const d={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,i.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d.header,{children:(0,t.jsx)(d.h1,{id:"embeddings-models-in-langflow",children:"Embeddings models in Langflow"})}),"\n",(0,t.jsx)(d.p,{children:"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context."}),"\n",(0,t.jsx)(d.p,{children:"Refer to your specific component's documentation for more information on parameters."}),"\n",(0,t.jsx)(d.h2,{id:"use-an-embeddings-model-component-in-a-flow",children:"Use an embeddings model component in a flow"}),"\n",(0,t.jsxs)(d.p,{children:["In this example of a document ingestion pipeline, the ",(0,t.jsx)(d.strong,{children:"OpenAI"})," embeddings model is connected to a vector database. The component converts the text chunks into vectors and stores them in the vector database. The vectorized data can be used to inform AI workloads like chatbots, similarity searches, and agents."]}),"\n",(0,t.jsx)(d.p,{children:"This embeddings component uses an OpenAI API key for authentication. Refer to your specific embeddings component's documentation for more information on authentication."}),"\n",(0,t.jsx)(d.p,{children:(0,t.jsx)(d.img,{alt:"URL component in a data ingestion pipeline",src:n(80352).A+"",width:"2586",height:"1550"})}),"\n",(0,t.jsx)(d.h2,{id:"aiml",children:"AI/ML"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using the ",(0,t.jsx)(d.a,{href:"https://docs.aimlapi.com/api-overview/embeddings",children:"AI/ML API"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The name of the AI/ML embedding model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"aiml_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with the AI/ML service"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance of AIMLEmbeddingsImpl for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"amazon-bedrock-embeddings",children:"Amazon Bedrock Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://aws.amazon.com/bedrock/",children:"Amazon Bedrock"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"credentials_profile_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Name of the AWS credentials profile in ~/.aws/credentials or ~/.aws/config, which has access keys or role information"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_id"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["ID of the model to call, e.g., ",(0,t.jsx)(d.code,{children:"amazon.titan-embed-text-v1"}),". This is equivalent to the ",(0,t.jsx)(d.code,{children:"modelId"})," property in the ",(0,t.jsx)(d.code,{children:"list-foundation-models"})," API"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"endpoint_url"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"URL to set a specific service endpoint other than the default AWS endpoint"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"region_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["AWS region to use, e.g., ",(0,t.jsx)(d.code,{children:"us-west-2"}),". Falls back to ",(0,t.jsx)(d.code,{children:"AWS_DEFAULT_REGION"})," environment variable or region specified in ~/.aws/config if not provided"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Amazon Bedrock"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"astra-db-vectorize",children:"Astra DB vectorize"}),"\n",(0,t.jsx)(d.admonition,{type:"important",children:(0,t.jsxs)(d.p,{children:["This component is deprecated as of Langflow version 1.1.2.\nInstead, use the ",(0,t.jsx)(d.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store component"})]})}),"\n",(0,t.jsxs)(d.p,{children:["Connect this component to the ",(0,t.jsx)(d.strong,{children:"Embeddings"})," port of the ",(0,t.jsx)(d.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store component"})," to generate embeddings."]}),"\n",(0,t.jsxs)(d.p,{children:["This component requires that your Astra DB database has a collection that uses a vectorize embedding provider integration.\nFor more information and instructions, see ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Embedding Generation"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"provider"}),(0,t.jsx)(d.td,{children:"Embedding Provider"}),(0,t.jsx)(d.td,{children:"The embedding provider to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"The embedding model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"authentication"}),(0,t.jsx)(d.td,{children:"Authentication"}),(0,t.jsxs)(d.td,{children:["The name of the API key in Astra that stores your ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#embedding-provider-authentication",children:"vectorize embedding provider credentials"}),". (Not required if using an ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#supported-embedding-providers",children:"Astra-hosted embedding provider"}),".)"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"provider_api_key"}),(0,t.jsx)(d.td,{children:"Provider API Key"}),(0,t.jsxs)(d.td,{children:["As an alternative to ",(0,t.jsx)(d.code,{children:"authentication"}),", directly provide your embedding provider credentials."]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_parameters"}),(0,t.jsx)(d.td,{children:"Model Parameters"}),(0,t.jsx)(d.td,{children:"Additional model parameters"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Astra vectorize"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"azure-openai-embeddings",children:"Azure OpenAI Embeddings"}),"\n",(0,t.jsx)(d.p,{children:"This component generates embeddings using Azure OpenAI models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the model to use (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Azure Endpoint"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Your Azure endpoint, including the resource. Example: ",(0,t.jsx)(d.code,{children:"https://example-resource.azure.openai.com/"})]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Deployment Name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The name of the deployment"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Version"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API version to use, options include various dates"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API key to access the Azure OpenAI service"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Azure OpenAI"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"cloudflare-workers-ai-embeddings",children:"Cloudflare Workers AI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/workers-ai/",children:"Cloudflare Workers AI models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"account_id"}),(0,t.jsx)(d.td,{children:"Cloudflare account ID"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/fundamentals/setup/find-account-and-zone-ids/#find-account-id-workers-and-pages",children:"Find your Cloudflare account ID"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_token"}),(0,t.jsx)(d.td,{children:"Cloudflare API token"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/fundamentals/api/get-started/create-token/",children:"Create an API token"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/workers-ai/models/#text-embeddings",children:"List of supported models"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"strip_new_lines"}),(0,t.jsx)(d.td,{children:"Strip New Lines"}),(0,t.jsx)(d.td,{children:"Whether to strip new lines from the input text"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"batch_size"}),(0,t.jsx)(d.td,{children:"Batch Size"}),(0,t.jsx)(d.td,{children:"Number of texts to embed in each batch"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_base_url"}),(0,t.jsx)(d.td,{children:"Cloudflare API base URL"}),(0,t.jsx)(d.td,{children:"Base URL for the Cloudflare API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"headers"}),(0,t.jsx)(d.td,{children:"Headers"}),(0,t.jsx)(d.td,{children:"Additional request headers"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Cloudflare Workers"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"cohere-embeddings",children:"Cohere Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://cohere.com/",children:"Cohere"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"cohere_api_key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"API key required to authenticate with the Cohere service"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Language model used for embedding text documents and performing queries (default: ",(0,t.jsx)(d.code,{children:"embed-english-v2.0"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"truncate"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to truncate the input text to fit within the model's constraints (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Cohere"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"embedding-similarity",children:"Embedding similarity"}),"\n",(0,t.jsx)(d.p,{children:"This component computes selected forms of similarity between two embedding vectors."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embedding_vectors"}),(0,t.jsx)(d.td,{children:"Embedding Vectors"}),(0,t.jsx)(d.td,{children:"A list containing exactly two data objects with embedding vectors to compare."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"similarity_metric"}),(0,t.jsx)(d.td,{children:"Similarity Metric"}),(0,t.jsx)(d.td,{children:'Select the similarity metric to use. Options: "Cosine Similarity", "Euclidean Distance", "Manhattan Distance".'})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"similarity_data"}),(0,t.jsx)(d.td,{children:"Similarity Data"}),(0,t.jsx)(d.td,{children:"Data object containing the computed similarity score and additional information."})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"google-generative-ai-embeddings",children:"Google generative AI embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component connects to Google's generative AI embedding service using the GoogleGenerativeAIEmbeddings class from the ",(0,t.jsx)(d.code,{children:"langchain-google-genai"})," package."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_key"}),(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"Secret API key for accessing Google's generative AI service (required)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:'Name of the embedding model to use (default: "models/text-embedding-004")'})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"Built GoogleGenerativeAIEmbeddings object"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"hugging-face-embeddings",children:"Hugging Face Embeddings"}),"\n",(0,t.jsx)(d.admonition,{type:"note",children:(0,t.jsxs)(d.p,{children:["This component is deprecated as of Langflow version 1.0.18.\nInstead, use the ",(0,t.jsx)(d.a,{href:"#hugging-face-embeddings-inference",children:"Hugging Face Embeddings Inference component"}),"."]})}),"\n",(0,t.jsx)(d.p,{children:"This component loads embedding models from HuggingFace."}),"\n",(0,t.jsx)(d.p,{children:"Use this component to generate embeddings using locally downloaded Hugging Face models. Ensure you have sufficient computational resources to run the models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Folder path to cache HuggingFace models"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Encode Kwargs"}),(0,t.jsx)(d.td,{children:"Encoding Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the encoding process"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"Model Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the model"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Name of the HuggingFace model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Multi Process"}),(0,t.jsx)(d.td,{children:"Multi-Process"}),(0,t.jsx)(d.td,{children:"Whether to use multiple processes"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"hugging-face-embeddings-inference",children:"Hugging Face embeddings inference"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://huggingface.co/",children:"Hugging Face Inference API models"})," and requires a ",(0,t.jsx)(d.a,{href:"https://huggingface.co/docs/hub/security-tokens",children:"Hugging Face API token"})," to authenticate. Local inference models do not require an API key."]}),"\n",(0,t.jsx)(d.p,{children:"Use this component to create embeddings with Hugging Face's hosted models, or to connect to your own locally hosted models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-9",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"The API key for accessing the Hugging Face Inference API."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API URL"}),(0,t.jsx)(d.td,{children:"API URL"}),(0,t.jsx)(d.td,{children:"The URL of the Hugging Face Inference API."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"The name of the model to use for embeddings."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"The folder path to cache Hugging Face models."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Encode Kwargs"}),(0,t.jsx)(d.td,{children:"Encoding Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the encoding process."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"Model Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the model."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Multi Process"}),(0,t.jsx)(d.td,{children:"Multi-Process"}),(0,t.jsx)(d.td,{children:"Whether to use multiple processes."})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-9",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings."})]})})]}),"\n",(0,t.jsx)(d.h3,{id:"connect-the-hugging-face-component-to-a-local-embeddings-model",children:"Connect the Hugging Face component to a local embeddings model"}),"\n",(0,t.jsxs)(d.p,{children:["To run an embeddings inference locally, see the ",(0,t.jsx)(d.a,{href:"https://huggingface.co/docs/text-embeddings-inference/local_cpu",children:"HuggingFace documentation"}),"."]}),"\n",(0,t.jsxs)(d.p,{children:["To connect the local Hugging Face model to the ",(0,t.jsx)(d.strong,{children:"Hugging Face embeddings inference"})," component and use it in a flow, follow these steps:"]}),"\n",(0,t.jsxs)(d.ol,{children:["\n",(0,t.jsxs)(d.li,{children:["Create a ",(0,t.jsx)(d.a,{href:"/starter-projects-vector-store-rag",children:"Vector store RAG flow"}),".\nThere are two embeddings models in this flow that you can replace with ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," embeddings inference components."]}),"\n",(0,t.jsxs)(d.li,{children:["Replace both ",(0,t.jsx)(d.strong,{children:"OpenAI"})," embeddings model components with ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," model components."]}),"\n",(0,t.jsxs)(d.li,{children:["Connect both ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," components to the ",(0,t.jsx)(d.strong,{children:"Embeddings"})," ports of the ",(0,t.jsx)(d.strong,{children:"Astra DB vector store"})," components."]}),"\n",(0,t.jsxs)(d.li,{children:["In the ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," components, set the ",(0,t.jsx)(d.strong,{children:"Inference Endpoint"})," field to the URL of your local inference model. ",(0,t.jsxs)(d.strong,{children:["The ",(0,t.jsx)(d.strong,{children:"API Key"})," field is not required for local inference."]})]}),"\n",(0,t.jsx)(d.li,{children:"Run the flow. The local inference models generate embeddings for the input text."}),"\n"]}),"\n",(0,t.jsx)(d.h2,{id:"lm-studio-embeddings",children:"LM Studio Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://lmstudio.ai/docs",children:"LM Studio"})," models."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-10",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"The LM Studio model to use for generating embeddings"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"base_url"}),(0,t.jsx)(d.td,{children:"LM Studio Base URL"}),(0,t.jsx)(d.td,{children:"The base URL for the LM Studio API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_key"}),(0,t.jsx)(d.td,{children:"LM Studio API Key"}),(0,t.jsx)(d.td,{children:"API key for authentication with LM Studio"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Model Temperature"}),(0,t.jsx)(d.td,{children:"Temperature setting for the model"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-10",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"mistralai",children:"MistralAI"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://docs.mistral.ai/",children:"MistralAI"})," models."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-11",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:'The MistralAI model to use (default: "mistral-embed")'})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"mistral_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with MistralAI"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_concurrent_requests"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Maximum number of concurrent API requests (default: 64)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_retries"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Maximum number of retry attempts for failed requests (default: 5)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"timeout"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Request timeout in seconds (default: 120)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"endpoint"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Custom API endpoint URL (default: ",(0,t.jsx)(d.code,{children:"https://api.mistral.ai/v1/"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-11",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"MistralAIEmbeddings instance for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"nvidia",children:"NVIDIA"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://docs.nvidia.com",children:"NVIDIA models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-12",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The NVIDIA model to use for embeddings (e.g., ",(0,t.jsx)(d.code,{children:"nvidia/nv-embed-v1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"base_url"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Base URL for the NVIDIA API (default: ",(0,t.jsx)(d.code,{children:"https://integrate.api.nvidia.com/v1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"nvidia_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with NVIDIA's service"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Model temperature for embedding generation (default: ",(0,t.jsx)(d.code,{children:"0.1"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-12",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"NVIDIAEmbeddings instance for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"ollama-embeddings",children:"Ollama Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://ollama.com/",children:"Ollama models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-13",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Ollama Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the Ollama model to use (default: ",(0,t.jsx)(d.code,{children:"llama2"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Ollama Base URL"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Base URL of the Ollama API (default: ",(0,t.jsx)(d.code,{children:"http://localhost:11434"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsx)(d.td,{children:"Temperature parameter for the model. Adjusts the randomness in the generated embeddings"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-13",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Ollama"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"openai-embeddings",children:"OpenAI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://openai.com/",children:"OpenAI"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-14",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API key to use for accessing the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Default Headers"}),(0,t.jsx)(d.td,{children:"Dict"}),(0,t.jsx)(d.td,{children:"Default headers for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Default Query"}),(0,t.jsx)(d.td,{children:"NestedDict"}),(0,t.jsx)(d.td,{children:"Default query parameters for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Allowed Special"}),(0,t.jsx)(d.td,{children:"List"}),(0,t.jsxs)(d.td,{children:["Special tokens allowed for processing (default: ",(0,t.jsx)(d.code,{children:"[]"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Disallowed Special"}),(0,t.jsx)(d.td,{children:"List"}),(0,t.jsxs)(d.td,{children:["Special tokens disallowed for processing (default: ",(0,t.jsx)(d.code,{children:'["all"]'}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Chunk Size"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Chunk size for processing (default: ",(0,t.jsx)(d.code,{children:"1000"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Client"}),(0,t.jsx)(d.td,{children:"Any"}),(0,t.jsx)(d.td,{children:"HTTP client for making requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Deployment"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Deployment name for the model (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Embedding Context Length"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Length of embedding context (default: ",(0,t.jsx)(d.code,{children:"8191"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Max Retries"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Maximum number of retries for failed requests (default: ",(0,t.jsx)(d.code,{children:"6"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the model to use (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"NestedDict"}),(0,t.jsx)(d.td,{children:"Additional keyword arguments for the model"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Base"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Base URL of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Type"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Type of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Version"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Version of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI Organization"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Organization associated with the API key"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI Proxy"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Proxy server for the requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Request Timeout"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsx)(d.td,{children:"Timeout for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Show Progress Bar"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to show a progress bar for processing (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Skip Empty"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to skip empty inputs (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"TikToken Enable"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to enable TikToken (default: ",(0,t.jsx)(d.code,{children:"True"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"TikToken Model Name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Name of the TikToken model"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-14",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using OpenAI"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"text-embedder",children:"Text embedder"}),"\n",(0,t.jsx)(d.p,{children:"This component generates embeddings for a given message using a specified embedding model."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-15",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embedding_model"}),(0,t.jsx)(d.td,{children:"Embedding Model"}),(0,t.jsx)(d.td,{children:"The embedding model to use for generating embeddings."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"message"}),(0,t.jsx)(d.td,{children:"Message"}),(0,t.jsx)(d.td,{children:"The message for which to generate embeddings."})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-15",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embedding Data"}),(0,t.jsx)(d.td,{children:"Data object containing the original text and its embedding vector."})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"vertexai-embeddings",children:"VertexAI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is a wrapper around ",(0,t.jsx)(d.a,{href:"https://cloud.google.com/vertex-ai",children:"Google Vertex AI"})," ",(0,t.jsx)(d.a,{href:"https://cloud.google.com/vertex-ai/docs/generative-ai/embeddings/get-text-embeddings",children:"Embeddings API"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-16",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"credentials"}),(0,t.jsx)(d.td,{children:"Credentials"}),(0,t.jsx)(d.td,{children:"The default custom credentials to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"location"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The default location to use when making API calls (default: ",(0,t.jsx)(d.code,{children:"us-central1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_output_tokens"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Token limit determines the maximum amount of text output from one prompt (default: ",(0,t.jsx)(d.code,{children:"128"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The name of the Vertex AI large language model (default: ",(0,t.jsx)(d.code,{children:"text-bison"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"project"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The default GCP project to use when making Vertex API calls"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"request_parallelism"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["The amount of parallelism allowed for requests issued to VertexAI models (default: ",(0,t.jsx)(d.code,{children:"5"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Tunes the degree of randomness in text generations. Should be a non-negative value (default: ",(0,t.jsx)(d.code,{children:"0"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"top_k"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["How the model selects tokens for output, the next token is selected from the top ",(0,t.jsx)(d.code,{children:"k"})," tokens (default: ",(0,t.jsx)(d.code,{children:"40"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"top_p"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Tokens are selected from the most probable to least until the sum of their probabilities exceeds the top ",(0,t.jsx)(d.code,{children:"p"})," value (default: ",(0,t.jsx)(d.code,{children:"0.95"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"tuned_model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The name of a tuned model. If provided, ",(0,t.jsx)(d.code,{children:"model_name"})," is ignored"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"verbose"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["This parameter controls the level of detail in the output. When set to ",(0,t.jsx)(d.code,{children:"True"}),", it prints internal states of the chain to help debug (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-16",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using VertexAI"})]})})]})]})}function a(e={}){const{wrapper:d}={...(0,i.R)(),...e.components};return d?(0,t.jsx)(d,{...e,children:(0,t.jsx)(o,{...e})}):o(e)}},80352:(e,d,n)=>{n.d(d,{A:()=>s});const s=n.p+"assets/images/url-component-0ced1fa00ee3b97582421254b6d5be78.png"}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[7462],{28453:(e,d,n)=>{n.d(d,{R:()=>r,x:()=>l});var s=n(96540);const t={},i=s.createContext(t);function r(e){const d=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(d):{...d,...e}}),[d,e])}function l(e){let d;return d=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:r(e.components),s.createElement(i.Provider,{value:d},e.children)}},56088:(e,d,n)=>{n.r(d),n.d(d,{assets:()=>h,contentTitle:()=>l,default:()=>a,frontMatter:()=>r,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/components-embedding-models","title":"Embeddings","description":"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context.","source":"@site/docs/Components/components-embedding-models.md","sourceDirName":"Components","slug":"/components-embedding-models","permalink":"/components-embedding-models","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Embeddings","slug":"/components-embedding-models"},"sidebar":"docs","previous":{"title":"Data","permalink":"/components-data"},"next":{"title":"Helpers","permalink":"/components-helpers"}}');var t=n(74848),i=n(28453);const r={title:"Embeddings",slug:"/components-embedding-models"},l="Embeddings models in Langflow",h={},c=[{value:"Use an embeddings model component in a flow",id:"use-an-embeddings-model-component-in-a-flow",level:2},{value:"AI/ML",id:"aiml",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Amazon Bedrock Embeddings",id:"amazon-bedrock-embeddings",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Astra DB vectorize",id:"astra-db-vectorize",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Azure OpenAI Embeddings",id:"azure-openai-embeddings",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Cloudflare Workers AI Embeddings",id:"cloudflare-workers-ai-embeddings",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Cohere Embeddings",id:"cohere-embeddings",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"Embedding similarity",id:"embedding-similarity",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"Google generative AI embeddings",id:"google-generative-ai-embeddings",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"Hugging Face Embeddings",id:"hugging-face-embeddings",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3},{value:"Hugging Face embeddings inference",id:"hugging-face-embeddings-inference",level:2},{value:"Inputs",id:"inputs-9",level:3},{value:"Outputs",id:"outputs-9",level:3},{value:"Connect the Hugging Face component to a local embeddings model",id:"connect-the-hugging-face-component-to-a-local-embeddings-model",level:3},{value:"LM Studio Embeddings",id:"lm-studio-embeddings",level:2},{value:"Inputs",id:"inputs-10",level:3},{value:"Outputs",id:"outputs-10",level:3},{value:"MistralAI",id:"mistralai",level:2},{value:"Inputs",id:"inputs-11",level:3},{value:"Outputs",id:"outputs-11",level:3},{value:"NVIDIA",id:"nvidia",level:2},{value:"Inputs",id:"inputs-12",level:3},{value:"Outputs",id:"outputs-12",level:3},{value:"Ollama Embeddings",id:"ollama-embeddings",level:2},{value:"Inputs",id:"inputs-13",level:3},{value:"Outputs",id:"outputs-13",level:3},{value:"OpenAI Embeddings",id:"openai-embeddings",level:2},{value:"Inputs",id:"inputs-14",level:3},{value:"Outputs",id:"outputs-14",level:3},{value:"Text embedder",id:"text-embedder",level:2},{value:"Inputs",id:"inputs-15",level:3},{value:"Outputs",id:"outputs-15",level:3},{value:"VertexAI Embeddings",id:"vertexai-embeddings",level:2},{value:"Inputs",id:"inputs-16",level:3},{value:"Outputs",id:"outputs-16",level:3}];function o(e){const d={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,i.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(d.header,{children:(0,t.jsx)(d.h1,{id:"embeddings-models-in-langflow",children:"Embeddings models in Langflow"})}),"\n",(0,t.jsx)(d.p,{children:"Embeddings models convert text into numerical vectors. These embeddings capture semantic meaning of the input text, and allow LLMs to understand context."}),"\n",(0,t.jsx)(d.p,{children:"Refer to your specific component's documentation for more information on parameters."}),"\n",(0,t.jsx)(d.h2,{id:"use-an-embeddings-model-component-in-a-flow",children:"Use an embeddings model component in a flow"}),"\n",(0,t.jsxs)(d.p,{children:["In this example of a document ingestion pipeline, the ",(0,t.jsx)(d.strong,{children:"OpenAI"})," embeddings model is connected to a vector database. The component converts the text chunks into vectors and stores them in the vector database. The vectorized data can be used to inform AI workloads like chatbots, similarity searches, and agents."]}),"\n",(0,t.jsx)(d.p,{children:"This embeddings component uses an OpenAI API key for authentication. Refer to your specific embeddings component's documentation for more information on authentication."}),"\n",(0,t.jsx)(d.p,{children:(0,t.jsx)(d.img,{alt:"URL component in a data ingestion pipeline",src:n(80352).A+"",width:"2306",height:"1632"})}),"\n",(0,t.jsx)(d.h2,{id:"aiml",children:"AI/ML"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using the ",(0,t.jsx)(d.a,{href:"https://docs.aimlapi.com/api-overview/embeddings",children:"AI/ML API"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The name of the AI/ML embedding model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"aiml_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with the AI/ML service"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance of AIMLEmbeddingsImpl for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"amazon-bedrock-embeddings",children:"Amazon Bedrock Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://aws.amazon.com/bedrock/",children:"Amazon Bedrock"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"credentials_profile_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Name of the AWS credentials profile in ~/.aws/credentials or ~/.aws/config, which has access keys or role information"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_id"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["ID of the model to call, e.g., ",(0,t.jsx)(d.code,{children:"amazon.titan-embed-text-v1"}),". This is equivalent to the ",(0,t.jsx)(d.code,{children:"modelId"})," property in the ",(0,t.jsx)(d.code,{children:"list-foundation-models"})," API"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"endpoint_url"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"URL to set a specific service endpoint other than the default AWS endpoint"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"region_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["AWS region to use, e.g., ",(0,t.jsx)(d.code,{children:"us-west-2"}),". Falls back to ",(0,t.jsx)(d.code,{children:"AWS_DEFAULT_REGION"})," environment variable or region specified in ~/.aws/config if not provided"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Amazon Bedrock"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"astra-db-vectorize",children:"Astra DB vectorize"}),"\n",(0,t.jsx)(d.admonition,{type:"important",children:(0,t.jsxs)(d.p,{children:["This component is deprecated as of Langflow version 1.1.2.\nInstead, use the ",(0,t.jsx)(d.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store component"})]})}),"\n",(0,t.jsxs)(d.p,{children:["Connect this component to the ",(0,t.jsx)(d.strong,{children:"Embeddings"})," port of the ",(0,t.jsx)(d.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store component"})," to generate embeddings."]}),"\n",(0,t.jsxs)(d.p,{children:["This component requires that your Astra DB database has a collection that uses a vectorize embedding provider integration.\nFor more information and instructions, see ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Embedding Generation"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"provider"}),(0,t.jsx)(d.td,{children:"Embedding Provider"}),(0,t.jsx)(d.td,{children:"The embedding provider to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"The embedding model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"authentication"}),(0,t.jsx)(d.td,{children:"Authentication"}),(0,t.jsxs)(d.td,{children:["The name of the API key in Astra that stores your ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#embedding-provider-authentication",children:"vectorize embedding provider credentials"}),". (Not required if using an ",(0,t.jsx)(d.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html#supported-embedding-providers",children:"Astra-hosted embedding provider"}),".)"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"provider_api_key"}),(0,t.jsx)(d.td,{children:"Provider API Key"}),(0,t.jsxs)(d.td,{children:["As an alternative to ",(0,t.jsx)(d.code,{children:"authentication"}),", directly provide your embedding provider credentials."]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_parameters"}),(0,t.jsx)(d.td,{children:"Model Parameters"}),(0,t.jsx)(d.td,{children:"Additional model parameters"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Astra vectorize"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"azure-openai-embeddings",children:"Azure OpenAI Embeddings"}),"\n",(0,t.jsx)(d.p,{children:"This component generates embeddings using Azure OpenAI models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the model to use (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Azure Endpoint"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Your Azure endpoint, including the resource. Example: ",(0,t.jsx)(d.code,{children:"https://example-resource.azure.openai.com/"})]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Deployment Name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The name of the deployment"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Version"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API version to use, options include various dates"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API key to access the Azure OpenAI service"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Azure OpenAI"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"cloudflare-workers-ai-embeddings",children:"Cloudflare Workers AI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/workers-ai/",children:"Cloudflare Workers AI models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"account_id"}),(0,t.jsx)(d.td,{children:"Cloudflare account ID"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/fundamentals/setup/find-account-and-zone-ids/#find-account-id-workers-and-pages",children:"Find your Cloudflare account ID"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_token"}),(0,t.jsx)(d.td,{children:"Cloudflare API token"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/fundamentals/api/get-started/create-token/",children:"Create an API token"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:(0,t.jsx)(d.a,{href:"https://developers.cloudflare.com/workers-ai/models/#text-embeddings",children:"List of supported models"})})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"strip_new_lines"}),(0,t.jsx)(d.td,{children:"Strip New Lines"}),(0,t.jsx)(d.td,{children:"Whether to strip new lines from the input text"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"batch_size"}),(0,t.jsx)(d.td,{children:"Batch Size"}),(0,t.jsx)(d.td,{children:"Number of texts to embed in each batch"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_base_url"}),(0,t.jsx)(d.td,{children:"Cloudflare API base URL"}),(0,t.jsx)(d.td,{children:"Base URL for the Cloudflare API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"headers"}),(0,t.jsx)(d.td,{children:"Headers"}),(0,t.jsx)(d.td,{children:"Additional request headers"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Cloudflare Workers"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"cohere-embeddings",children:"Cohere Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://cohere.com/",children:"Cohere"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"cohere_api_key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"API key required to authenticate with the Cohere service"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Language model used for embedding text documents and performing queries (default: ",(0,t.jsx)(d.code,{children:"embed-english-v2.0"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"truncate"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to truncate the input text to fit within the model's constraints (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Cohere"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"embedding-similarity",children:"Embedding similarity"}),"\n",(0,t.jsx)(d.p,{children:"This component computes selected forms of similarity between two embedding vectors."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embedding_vectors"}),(0,t.jsx)(d.td,{children:"Embedding Vectors"}),(0,t.jsx)(d.td,{children:"A list containing exactly two data objects with embedding vectors to compare."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"similarity_metric"}),(0,t.jsx)(d.td,{children:"Similarity Metric"}),(0,t.jsx)(d.td,{children:'Select the similarity metric to use. Options: "Cosine Similarity", "Euclidean Distance", "Manhattan Distance".'})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"similarity_data"}),(0,t.jsx)(d.td,{children:"Similarity Data"}),(0,t.jsx)(d.td,{children:"Data object containing the computed similarity score and additional information."})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"google-generative-ai-embeddings",children:"Google generative AI embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component connects to Google's generative AI embedding service using the GoogleGenerativeAIEmbeddings class from the ",(0,t.jsx)(d.code,{children:"langchain-google-genai"})," package."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_key"}),(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"Secret API key for accessing Google's generative AI service (required)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:'Name of the embedding model to use (default: "models/text-embedding-004")'})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"Built GoogleGenerativeAIEmbeddings object"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"hugging-face-embeddings",children:"Hugging Face Embeddings"}),"\n",(0,t.jsx)(d.admonition,{type:"note",children:(0,t.jsxs)(d.p,{children:["This component is deprecated as of Langflow version 1.0.18.\nInstead, use the ",(0,t.jsx)(d.a,{href:"#hugging-face-embeddings-inference",children:"Hugging Face Embeddings Inference component"}),"."]})}),"\n",(0,t.jsx)(d.p,{children:"This component loads embedding models from HuggingFace."}),"\n",(0,t.jsx)(d.p,{children:"Use this component to generate embeddings using locally downloaded Hugging Face models. Ensure you have sufficient computational resources to run the models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Folder path to cache HuggingFace models"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Encode Kwargs"}),(0,t.jsx)(d.td,{children:"Encoding Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the encoding process"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"Model Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the model"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Name of the HuggingFace model to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Multi Process"}),(0,t.jsx)(d.td,{children:"Multi-Process"}),(0,t.jsx)(d.td,{children:"Whether to use multiple processes"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"hugging-face-embeddings-inference",children:"Hugging Face embeddings inference"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://huggingface.co/",children:"Hugging Face Inference API models"})," and requires a ",(0,t.jsx)(d.a,{href:"https://huggingface.co/docs/hub/security-tokens",children:"Hugging Face API token"})," to authenticate. Local inference models do not require an API key."]}),"\n",(0,t.jsx)(d.p,{children:"Use this component to create embeddings with Hugging Face's hosted models, or to connect to your own locally hosted models."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-9",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"API Key"}),(0,t.jsx)(d.td,{children:"The API key for accessing the Hugging Face Inference API."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"API URL"}),(0,t.jsx)(d.td,{children:"API URL"}),(0,t.jsx)(d.td,{children:"The URL of the Hugging Face Inference API."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"Model Name"}),(0,t.jsx)(d.td,{children:"The name of the model to use for embeddings."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"Cache Folder"}),(0,t.jsx)(d.td,{children:"The folder path to cache Hugging Face models."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Encode Kwargs"}),(0,t.jsx)(d.td,{children:"Encoding Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the encoding process."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"Model Arguments"}),(0,t.jsx)(d.td,{children:"Additional arguments for the model."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Multi Process"}),(0,t.jsx)(d.td,{children:"Multi-Process"}),(0,t.jsx)(d.td,{children:"Whether to use multiple processes."})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-9",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings."})]})})]}),"\n",(0,t.jsx)(d.h3,{id:"connect-the-hugging-face-component-to-a-local-embeddings-model",children:"Connect the Hugging Face component to a local embeddings model"}),"\n",(0,t.jsxs)(d.p,{children:["To run an embeddings inference locally, see the ",(0,t.jsx)(d.a,{href:"https://huggingface.co/docs/text-embeddings-inference/local_cpu",children:"HuggingFace documentation"}),"."]}),"\n",(0,t.jsxs)(d.p,{children:["To connect the local Hugging Face model to the ",(0,t.jsx)(d.strong,{children:"Hugging Face embeddings inference"})," component and use it in a flow, follow these steps:"]}),"\n",(0,t.jsxs)(d.ol,{children:["\n",(0,t.jsxs)(d.li,{children:["Create a ",(0,t.jsx)(d.a,{href:"/starter-projects-vector-store-rag",children:"Vector store RAG flow"}),".\nThere are two embeddings models in this flow that you can replace with ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," embeddings inference components."]}),"\n",(0,t.jsxs)(d.li,{children:["Replace both ",(0,t.jsx)(d.strong,{children:"OpenAI"})," embeddings model components with ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," model components."]}),"\n",(0,t.jsxs)(d.li,{children:["Connect both ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," components to the ",(0,t.jsx)(d.strong,{children:"Embeddings"})," ports of the ",(0,t.jsx)(d.strong,{children:"Astra DB vector store"})," components."]}),"\n",(0,t.jsxs)(d.li,{children:["In the ",(0,t.jsx)(d.strong,{children:"Hugging Face"})," components, set the ",(0,t.jsx)(d.strong,{children:"Inference Endpoint"})," field to the URL of your local inference model. ",(0,t.jsxs)(d.strong,{children:["The ",(0,t.jsx)(d.strong,{children:"API Key"})," field is not required for local inference."]})]}),"\n",(0,t.jsx)(d.li,{children:"Run the flow. The local inference models generate embeddings for the input text."}),"\n"]}),"\n",(0,t.jsx)(d.h2,{id:"lm-studio-embeddings",children:"LM Studio Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://lmstudio.ai/docs",children:"LM Studio"})," models."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-10",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"The LM Studio model to use for generating embeddings"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"base_url"}),(0,t.jsx)(d.td,{children:"LM Studio Base URL"}),(0,t.jsx)(d.td,{children:"The base URL for the LM Studio API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"api_key"}),(0,t.jsx)(d.td,{children:"LM Studio API Key"}),(0,t.jsx)(d.td,{children:"API key for authentication with LM Studio"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Model Temperature"}),(0,t.jsx)(d.td,{children:"Temperature setting for the model"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-10",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"The generated embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"mistralai",children:"MistralAI"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://docs.mistral.ai/",children:"MistralAI"})," models."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-11",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:'The MistralAI model to use (default: "mistral-embed")'})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"mistral_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with MistralAI"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_concurrent_requests"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Maximum number of concurrent API requests (default: 64)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_retries"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Maximum number of retry attempts for failed requests (default: 5)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"timeout"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsx)(d.td,{children:"Request timeout in seconds (default: 120)"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"endpoint"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Custom API endpoint URL (default: ",(0,t.jsx)(d.code,{children:"https://api.mistral.ai/v1/"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-11",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"MistralAIEmbeddings instance for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"nvidia",children:"NVIDIA"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://docs.nvidia.com",children:"NVIDIA models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-12",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The NVIDIA model to use for embeddings (e.g., ",(0,t.jsx)(d.code,{children:"nvidia/nv-embed-v1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"base_url"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Base URL for the NVIDIA API (default: ",(0,t.jsx)(d.code,{children:"https://integrate.api.nvidia.com/v1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"nvidia_api_key"}),(0,t.jsx)(d.td,{children:"SecretString"}),(0,t.jsx)(d.td,{children:"API key for authenticating with NVIDIA's service"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Model temperature for embedding generation (default: ",(0,t.jsx)(d.code,{children:"0.1"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-12",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"NVIDIAEmbeddings instance for generating embeddings"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"ollama-embeddings",children:"Ollama Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component generates embeddings using ",(0,t.jsx)(d.a,{href:"https://ollama.com/",children:"Ollama models"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-13",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Ollama Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the Ollama model to use (default: ",(0,t.jsx)(d.code,{children:"llama2"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Ollama Base URL"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Base URL of the Ollama API (default: ",(0,t.jsx)(d.code,{children:"http://localhost:11434"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsx)(d.td,{children:"Temperature parameter for the model. Adjusts the randomness in the generated embeddings"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-13",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using Ollama"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"openai-embeddings",children:"OpenAI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is used to load embedding models from ",(0,t.jsx)(d.a,{href:"https://openai.com/",children:"OpenAI"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-14",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Key"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The API key to use for accessing the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Default Headers"}),(0,t.jsx)(d.td,{children:"Dict"}),(0,t.jsx)(d.td,{children:"Default headers for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Default Query"}),(0,t.jsx)(d.td,{children:"NestedDict"}),(0,t.jsx)(d.td,{children:"Default query parameters for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Allowed Special"}),(0,t.jsx)(d.td,{children:"List"}),(0,t.jsxs)(d.td,{children:["Special tokens allowed for processing (default: ",(0,t.jsx)(d.code,{children:"[]"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Disallowed Special"}),(0,t.jsx)(d.td,{children:"List"}),(0,t.jsxs)(d.td,{children:["Special tokens disallowed for processing (default: ",(0,t.jsx)(d.code,{children:'["all"]'}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Chunk Size"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Chunk size for processing (default: ",(0,t.jsx)(d.code,{children:"1000"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Client"}),(0,t.jsx)(d.td,{children:"Any"}),(0,t.jsx)(d.td,{children:"HTTP client for making requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Deployment"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Deployment name for the model (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Embedding Context Length"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Length of embedding context (default: ",(0,t.jsx)(d.code,{children:"8191"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Max Retries"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Maximum number of retries for failed requests (default: ",(0,t.jsx)(d.code,{children:"6"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["Name of the model to use (default: ",(0,t.jsx)(d.code,{children:"text-embedding-3-small"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Model Kwargs"}),(0,t.jsx)(d.td,{children:"NestedDict"}),(0,t.jsx)(d.td,{children:"Additional keyword arguments for the model"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Base"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Base URL of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Type"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Type of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI API Version"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Version of the OpenAI API"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI Organization"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Organization associated with the API key"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"OpenAI Proxy"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Proxy server for the requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Request Timeout"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsx)(d.td,{children:"Timeout for the HTTP requests"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Show Progress Bar"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to show a progress bar for processing (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"Skip Empty"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to skip empty inputs (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"TikToken Enable"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["Whether to enable TikToken (default: ",(0,t.jsx)(d.code,{children:"True"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"TikToken Model Name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"Name of the TikToken model"})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-14",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using OpenAI"})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"text-embedder",children:"Text embedder"}),"\n",(0,t.jsx)(d.p,{children:"This component generates embeddings for a given message using a specified embedding model."}),"\n",(0,t.jsx)(d.h3,{id:"inputs-15",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embedding_model"}),(0,t.jsx)(d.td,{children:"Embedding Model"}),(0,t.jsx)(d.td,{children:"The embedding model to use for generating embeddings."})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"message"}),(0,t.jsx)(d.td,{children:"Message"}),(0,t.jsx)(d.td,{children:"The message for which to generate embeddings."})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-15",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Display Name"}),(0,t.jsx)(d.th,{children:"Info"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embedding Data"}),(0,t.jsx)(d.td,{children:"Data object containing the original text and its embedding vector."})]})})]}),"\n",(0,t.jsx)(d.h2,{id:"vertexai-embeddings",children:"VertexAI Embeddings"}),"\n",(0,t.jsxs)(d.p,{children:["This component is a wrapper around ",(0,t.jsx)(d.a,{href:"https://cloud.google.com/vertex-ai",children:"Google Vertex AI"})," ",(0,t.jsx)(d.a,{href:"https://cloud.google.com/vertex-ai/docs/generative-ai/embeddings/get-text-embeddings",children:"Embeddings API"}),"."]}),"\n",(0,t.jsx)(d.h3,{id:"inputs-16",children:"Inputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsxs)(d.tbody,{children:[(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"credentials"}),(0,t.jsx)(d.td,{children:"Credentials"}),(0,t.jsx)(d.td,{children:"The default custom credentials to use"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"location"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The default location to use when making API calls (default: ",(0,t.jsx)(d.code,{children:"us-central1"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"max_output_tokens"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["Token limit determines the maximum amount of text output from one prompt (default: ",(0,t.jsx)(d.code,{children:"128"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The name of the Vertex AI large language model (default: ",(0,t.jsx)(d.code,{children:"text-bison"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"project"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsx)(d.td,{children:"The default GCP project to use when making Vertex API calls"})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"request_parallelism"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["The amount of parallelism allowed for requests issued to VertexAI models (default: ",(0,t.jsx)(d.code,{children:"5"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"temperature"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Tunes the degree of randomness in text generations. Should be a non-negative value (default: ",(0,t.jsx)(d.code,{children:"0"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"top_k"}),(0,t.jsx)(d.td,{children:"Integer"}),(0,t.jsxs)(d.td,{children:["How the model selects tokens for output, the next token is selected from the top ",(0,t.jsx)(d.code,{children:"k"})," tokens (default: ",(0,t.jsx)(d.code,{children:"40"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"top_p"}),(0,t.jsx)(d.td,{children:"Float"}),(0,t.jsxs)(d.td,{children:["Tokens are selected from the most probable to least until the sum of their probabilities exceeds the top ",(0,t.jsx)(d.code,{children:"p"})," value (default: ",(0,t.jsx)(d.code,{children:"0.95"}),")"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"tuned_model_name"}),(0,t.jsx)(d.td,{children:"String"}),(0,t.jsxs)(d.td,{children:["The name of a tuned model. If provided, ",(0,t.jsx)(d.code,{children:"model_name"})," is ignored"]})]}),(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"verbose"}),(0,t.jsx)(d.td,{children:"Boolean"}),(0,t.jsxs)(d.td,{children:["This parameter controls the level of detail in the output. When set to ",(0,t.jsx)(d.code,{children:"True"}),", it prints internal states of the chain to help debug (default: ",(0,t.jsx)(d.code,{children:"False"}),")"]})]})]})]}),"\n",(0,t.jsx)(d.h3,{id:"outputs-16",children:"Outputs"}),"\n",(0,t.jsxs)(d.table,{children:[(0,t.jsx)(d.thead,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.th,{children:"Name"}),(0,t.jsx)(d.th,{children:"Type"}),(0,t.jsx)(d.th,{children:"Description"})]})}),(0,t.jsx)(d.tbody,{children:(0,t.jsxs)(d.tr,{children:[(0,t.jsx)(d.td,{children:"embeddings"}),(0,t.jsx)(d.td,{children:"Embeddings"}),(0,t.jsx)(d.td,{children:"An instance for generating embeddings using VertexAI"})]})})]})]})}function a(e={}){const{wrapper:d}={...(0,i.R)(),...e.components};return d?(0,t.jsx)(d,{...e,children:(0,t.jsx)(o,{...e})}):o(e)}},80352:(e,d,n)=>{n.d(d,{A:()=>s});const s=n.p+"assets/images/url-component-fb712df73581345c0f344013ce6ff2fd.png"}}]); \ No newline at end of file diff --git a/assets/js/9822a706.18f1c9af.js b/assets/js/9822a706.18f1c9af.js deleted file mode 100644 index af7b918fc5..0000000000 --- a/assets/js/9822a706.18f1c9af.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[5634],{19680:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-simple-agent-71d0dec218a5da8e3110c51716f1c91e.png"},90172:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>d,assets:()=>l,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>u,frontMatter:()=>a,metadata:()=>o,toc:()=>p});const o=JSON.parse('{"id":"Starter-Projects/starter-projects-simple-agent","title":"Simple agent","description":"Build a Simple Agent flow for an agentic application using the Tool-calling agent component.","source":"@site/docs/Starter-Projects/starter-projects-simple-agent.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-simple-agent","permalink":"/starter-projects-simple-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Simple agent","slug":"/starter-projects-simple-agent"},"sidebar":"docs","previous":{"title":"Vector store RAG","permalink":"/starter-projects-vector-store-rag"},"next":{"title":"Blog writer","permalink":"/blog-writer"}}');var r=n(74848),s=n(28453),i=n(24754);const a={title:"Simple agent",slug:"/starter-projects-simple-agent"},c=void 0,l={},d={annotations:i.hk,Code:i.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new flow",id:"open-langflow-and-start-a-new-flow",level:2},{value:"Simple Agent flow",id:"simple-agent-flow",level:2},{value:"Run the Simple Agent flow",id:"run-the-simple-agent-flow",level:2}];function g(e){const t={code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return d||f("CH",!1),d.Code||f("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.jsxs)(t.p,{children:["Build a ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow for an agentic application using the ",(0,r.jsx)(t.strong,{children:"Tool-calling agent"})," component."]}),"\n",(0,r.jsxs)(t.p,{children:["An ",(0,r.jsx)(t.strong,{children:"agent"}),' uses an LLM as its "brain" to select among the connected tools and complete its tasks.']}),"\n",(0,r.jsxs)(t.p,{children:["In this flow, the ",(0,r.jsx)(t.strong,{children:"Tool-calling agent"})," reasons using an ",(0,r.jsx)(t.strong,{children:"Open AI"})," LLM.\nThe agent selects the ",(0,r.jsx)(t.strong,{children:"Calculator"})," tool for simple math problems and the ",(0,r.jsx)(t.strong,{children:"URL"})," tool to search a URL for content."]}),"\n",(0,r.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsx)(t.p,{children:"To use this flow, you need an OpenAI API key."}),"\n",(0,r.jsx)(t.h2,{id:"open-langflow-and-start-a-new-flow",children:"Open Langflow and start a new flow"}),"\n",(0,r.jsxs)(t.p,{children:["Click ",(0,r.jsx)(t.strong,{children:"New Flow"}),", and then select the ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow."]}),"\n",(0,r.jsx)(t.p,{children:"This opens a starter flow with the necessary components to run an agentic application using the Tool-calling agent."}),"\n",(0,r.jsx)(t.h2,{id:"simple-agent-flow",children:"Simple Agent flow"}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"Simple agent starter flow",src:n(19680).A+"",width:"1732",height:"1748"})}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow consists of these components:"]}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Tool calling agent"})," component uses the connected LLM to reason through the user's input and select among the connected tools to complete its task."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," tool component searches a list of URLs for content."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Calculator"})," component performs basic arithmetic operations."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"run-the-simple-agent-flow",children:"Run the Simple Agent flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Add your credentials to the ",(0,r.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["Click ",(0,r.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n",(0,r.jsxs)(t.li,{children:["To confirm the tools are connected, ask the agent, ",(0,r.jsx)(t.code,{children:"What tools are available to you?"}),"\nThe response is similar to the following:"]}),"\n"]}),"\n",(0,r.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I have access to the following tools:",props:{}}]},{tokens:[{content:"Calculator: Perform basic arithmetic operations.",props:{}}]},{tokens:[{content:"fetch_content: Load and retrieve data from specified URLs.",props:{}}]},{tokens:[{content:"fetch_content_text: Load and retrieve text data from specified URLs.",props:{}}]},{tokens:[{content:"as_dataframe: Load and retrieve data in a structured format (dataframe) from specified URLs.",props:{}}]},{tokens:[{content:"get_current_date: Returns the current date and time in a selected timezone.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.ol,{start:"4",children:["\n",(0,r.jsxs)(t.li,{children:["Ask the agent a question. For example, ask it to create a tabletop character using your favorite rules set.\nThe agent will tell you when it's using the ",(0,r.jsx)(t.code,{children:"URL-fetch_content_text"})," tool to search for rules information, and when it's using ",(0,r.jsx)(t.code,{children:"CalculatorComponent-evaluate_expression"})," to generate attributes with dice rolls.\nThe final output should be similar to this:"]}),"\n"]}),"\n",(0,r.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Final Attributes",props:{}}]},{tokens:[{content:"Strength (STR): 10",props:{}}]},{tokens:[{content:"Constitution (CON): 12",props:{}}]},{tokens:[{content:"Size (SIZ): 14",props:{}}]},{tokens:[{content:"Dexterity (DEX): 9",props:{}}]},{tokens:[{content:"Intelligence (INT): 11",props:{}}]},{tokens:[{content:"Power (POW): 13",props:{}}]},{tokens:[{content:"Charisma (CHA): 8",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["Now that your query has completed the journey from ",(0,r.jsx)(t.strong,{children:"Chat input"})," to ",(0,r.jsx)(t.strong,{children:"Chat output"}),", you have completed the ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow."]})]})}function u(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(g,{...e})}):g(e)}function f(e,t){throw new Error("Expected "+(t?"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/9822a706.f0694192.js b/assets/js/9822a706.f0694192.js new file mode 100644 index 0000000000..348dc245e7 --- /dev/null +++ b/assets/js/9822a706.f0694192.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[5634],{19680:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-simple-agent-71d0dec218a5da8e3110c51716f1c91e.png"},90172:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>d,assets:()=>l,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>u,frontMatter:()=>a,metadata:()=>o,toc:()=>p});const o=JSON.parse('{"id":"Starter-Projects/starter-projects-simple-agent","title":"Simple agent","description":"Build a Simple Agent flow for an agentic application using the Tool-calling agent component.","source":"@site/docs/Starter-Projects/starter-projects-simple-agent.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-simple-agent","permalink":"/starter-projects-simple-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Simple agent","slug":"/starter-projects-simple-agent"},"sidebar":"docs","previous":{"title":"Vector store RAG","permalink":"/starter-projects-vector-store-rag"},"next":{"title":"Blog writer","permalink":"/blog-writer"}}');var r=n(74848),s=n(28453),i=n(24754);const a={title:"Simple agent",slug:"/starter-projects-simple-agent"},c=void 0,l={},d={annotations:i.hk,Code:i.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new flow",id:"open-langflow-and-start-a-new-flow",level:2},{value:"Simple Agent flow",id:"simple-agent-flow",level:2},{value:"Run the Simple Agent flow",id:"run-the-simple-agent-flow",level:2}];function g(e){const t={a:"a",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return d||f("CH",!1),d.Code||f("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.jsxs)(t.p,{children:["Build a ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow for an agentic application using the ",(0,r.jsx)(t.a,{href:"/agents-tool-calling-agent-component",children:"Tool-calling agent"})," component."]}),"\n",(0,r.jsxs)(t.p,{children:["An ",(0,r.jsx)(t.strong,{children:"agent"}),' uses an LLM as its "brain" to select among the connected tools and complete its tasks.']}),"\n",(0,r.jsxs)(t.p,{children:["In this flow, the ",(0,r.jsx)(t.strong,{children:"Tool-calling agent"})," reasons using an ",(0,r.jsx)(t.strong,{children:"Open AI"})," LLM.\nThe agent selects the ",(0,r.jsx)(t.strong,{children:"Calculator"})," tool for simple math problems and the ",(0,r.jsx)(t.strong,{children:"URL"})," tool to search a URL for content."]}),"\n",(0,r.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"open-langflow-and-start-a-new-flow",children:"Open Langflow and start a new flow"}),"\n",(0,r.jsxs)(t.p,{children:["Click ",(0,r.jsx)(t.strong,{children:"New Flow"}),", and then select the ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow."]}),"\n",(0,r.jsx)(t.p,{children:"This opens a starter flow with the necessary components to run an agentic application using the Tool-calling agent."}),"\n",(0,r.jsx)(t.h2,{id:"simple-agent-flow",children:"Simple Agent flow"}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"Simple agent starter flow",src:n(19680).A+"",width:"1732",height:"1748"})}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow consists of these components:"]}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Tool calling agent"})," component uses the connected LLM to reason through the user's input and select among the connected tools to complete its task."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," tool component searches a list of URLs for content."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Calculator"})," component performs basic arithmetic operations."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"run-the-simple-agent-flow",children:"Run the Simple Agent flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Add your credentials to the ",(0,r.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["Click ",(0,r.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n",(0,r.jsxs)(t.li,{children:["To confirm the tools are connected, ask the agent, ",(0,r.jsx)(t.code,{children:"What tools are available to you?"}),"\nThe response is similar to the following:"]}),"\n"]}),"\n",(0,r.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I have access to the following tools:",props:{}}]},{tokens:[{content:"Calculator: Perform basic arithmetic operations.",props:{}}]},{tokens:[{content:"fetch_content: Load and retrieve data from specified URLs.",props:{}}]},{tokens:[{content:"fetch_content_text: Load and retrieve text data from specified URLs.",props:{}}]},{tokens:[{content:"as_dataframe: Load and retrieve data in a structured format (dataframe) from specified URLs.",props:{}}]},{tokens:[{content:"get_current_date: Returns the current date and time in a selected timezone.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.ol,{start:"4",children:["\n",(0,r.jsxs)(t.li,{children:["Ask the agent a question. For example, ask it to create a tabletop character using your favorite rules set.\nThe agent tells you when it's using the ",(0,r.jsx)(t.code,{children:"URL-fetch_content_text"})," tool to search for rules information, and when it's using ",(0,r.jsx)(t.code,{children:"CalculatorComponent-evaluate_expression"})," to generate attributes with dice rolls.\nThe final output should be similar to this:"]}),"\n"]}),"\n",(0,r.jsx)(d.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Final Attributes",props:{}}]},{tokens:[{content:"Strength (STR): 10",props:{}}]},{tokens:[{content:"Constitution (CON): 12",props:{}}]},{tokens:[{content:"Size (SIZ): 14",props:{}}]},{tokens:[{content:"Dexterity (DEX): 9",props:{}}]},{tokens:[{content:"Intelligence (INT): 11",props:{}}]},{tokens:[{content:"Power (POW): 13",props:{}}]},{tokens:[{content:"Charisma (CHA): 8",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["Now that your query has completed the journey from ",(0,r.jsx)(t.strong,{children:"Chat input"})," to ",(0,r.jsx)(t.strong,{children:"Chat output"}),", you have completed the ",(0,r.jsx)(t.strong,{children:"Simple Agent"})," flow."]})]})}function u(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(g,{...e})}):g(e)}function f(e,t){throw new Error("Expected "+(t?"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/a83bc7c0.42006513.js b/assets/js/a83bc7c0.42006513.js new file mode 100644 index 0000000000..65e25c8a6e --- /dev/null +++ b/assets/js/a83bc7c0.42006513.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[5628],{28453:(e,n,t)=>{t.d(n,{R:()=>i,x:()=>a});var r=t(96540);const s={},o=r.createContext(s);function i(e){const n=r.useContext(o);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(s):e.components||s:i(e.components),r.createElement(o.Provider,{value:n},e.children)}},60228:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>g,frontMatter:()=>a,metadata:()=>r,toc:()=>d});const r=JSON.parse('{"id":"Starter-Projects/starter-projects-vector-store-rag","title":"Vector store RAG","description":"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it.","source":"@site/docs/Starter-Projects/starter-projects-vector-store-rag.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-vector-store-rag","permalink":"/starter-projects-vector-store-rag","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Vector store RAG","slug":"/starter-projects-vector-store-rag"},"sidebar":"docs","previous":{"title":"Basic prompting","permalink":"/starter-projects-basic-prompting"},"next":{"title":"Simple agent","permalink":"/starter-projects-simple-agent"}}');var s=t(74848),o=t(28453),i=t(84443);const a={title:"Vector store RAG",slug:"/starter-projects-vector-store-rag"},l=void 0,c={},d=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new project",id:"open-langflow-and-start-a-new-project",level:2},{value:"Build the vector RAG flow",id:"build-the-vector-rag-flow",level:2},{value:"Run the Vector Store RAG flow",id:"run-the-vector-store-rag-flow",level:2}];function h(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,o.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.p,{children:"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it."}),"\n",(0,s.jsxs)(n.p,{children:["RAG is backed by a\xa0",(0,s.jsx)(n.strong,{children:"vector store"}),", a vector database which stores embeddings of the ingested data."]}),"\n",(0,s.jsxs)(n.p,{children:["This enables\xa0",(0,s.jsx)(n.strong,{children:"vector search"}),", a more powerful and context-aware search."]}),"\n",(0,s.jsxs)(n.p,{children:["We've chosen\xa0",(0,s.jsx)(n.a,{href:"https://astra.datastax.com/signup?utm_source=langflow-pre-release&utm_medium=referral&utm_campaign=langflow-announcement&utm_content=create-a-free-astra-db-account",children:"Astra DB"}),"\xa0as the vector database for this starter flow, but you can follow along with any of Langflow's vector database options."]}),"\n",(0,s.jsx)(n.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/get-started/quickstart.html",children:"An Astra DB vector database"}),"\xa0with the following:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"An Astra DB application token scoped to read and write to the database"}),"\n",(0,s.jsxs)(n.li,{children:["A collection created in ",(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/manage-collections.html#create-collection",children:"Astra"})," or a new collection created in the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"open-langflow-and-start-a-new-project",children:"Open Langflow and start a new project"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(n.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select\xa0",(0,s.jsx)(n.strong,{children:"Vector Store RAG"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Vector Store RAG"}),"\xa0flow is created."]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"build-the-vector-rag-flow",children:"Build the vector RAG flow"}),"\n",(0,s.jsx)(n.p,{children:"The vector store RAG flow is built of two separate flows for ingestion and query."}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{src:t(85410).A+"",width:"2694",height:"1558"})}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Load Data Flow"})," (bottom of the screen) creates a searchable index to be queried for contextual similarity.\nThis flow populates the vector store with data from a local file.\nIt ingests data from a local file, splits it into chunks, indexes it in Astra DB, and computes embeddings for the chunks using the OpenAI embeddings model."]}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Retriever Flow"})," (top of the screen) embeds the user's queries into vectors, which are compared to the vector store data from the ",(0,s.jsx)(n.strong,{children:"Load Data Flow"})," for contextual similarity."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Chat Input"})," receives user input from the ",(0,s.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"OpenAI Embeddings"})," converts the user query into vector form."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Astra DB"})," performs similarity search using the query vector."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Parser"})," processes the retrieved chunks."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Prompt"})," combines the user query with relevant context."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"OpenAI"})," generates the response using the prompt."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Chat Output"})," returns the response to the ",(0,s.jsx)(n.strong,{children:"Playground"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Configure the ",(0,s.jsx)(n.strong,{children:"OpenAI"})," model component."]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["To create a global variable for the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),"\xa0component, in the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI API Key"}),"\xa0field, click the\xa0",(0,s.jsx)(i.A,{name:"Globe","aria-label":"Globe"})," ",(0,s.jsx)(n.strong,{children:"Globe"}),"\xa0button, and then click\xa0",(0,s.jsx)(n.strong,{children:"Add New Variable"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["In the\xa0",(0,s.jsx)(n.strong,{children:"Variable Name"}),"\xa0field, enter\xa0",(0,s.jsx)(n.code,{children:"openai_api_key"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["In the\xa0",(0,s.jsx)(n.strong,{children:"Value"}),"\xa0field, paste your OpenAI API Key (",(0,s.jsx)(n.code,{children:"sk-..."}),")."]}),"\n",(0,s.jsxs)(n.li,{children:["Click\xa0",(0,s.jsx)(n.strong,{children:"Save Variable"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Configure the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["In the ",(0,s.jsx)(n.strong,{children:"Astra DB Application Token"})," field, add your ",(0,s.jsx)(n.strong,{children:"Astra DB"})," application token.\nThe component connects to your database and populates the menus with existing databases and collections."]}),"\n",(0,s.jsxs)(n.li,{children:["Select your ",(0,s.jsx)(n.strong,{children:"Database"}),".\nIf you don't have a collection, select ",(0,s.jsx)(n.strong,{children:"New database"}),".\nComplete the ",(0,s.jsx)(n.strong,{children:"Name"}),", ",(0,s.jsx)(n.strong,{children:"Cloud provider"}),", and ",(0,s.jsx)(n.strong,{children:"Region"})," fields, and then click ",(0,s.jsx)(n.strong,{children:"Create"}),". ",(0,s.jsx)(n.strong,{children:"Database creation takes a few minutes"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select your ",(0,s.jsx)(n.strong,{children:"Collection"}),". Collections are created in your ",(0,s.jsx)(n.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"})," for storing vector data."]}),"\n"]}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsxs)(n.p,{children:["If you select a collection embedded with Nvidia through Astra's vectorize service, the ",(0,s.jsx)(n.strong,{children:"Embedding Model"})," port is removed, because you have already generated embeddings for this collection with the Nvidia ",(0,s.jsx)(n.code,{children:"NV-Embed-QA"})," model. The component fetches the data from the collection, and uses the same embeddings for queries."]})}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsx)(n.p,{children:"If you don't have a collection, create a new one within the component."}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Select ",(0,s.jsx)(n.strong,{children:"New collection"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Complete the ",(0,s.jsx)(n.strong,{children:"Name"}),", ",(0,s.jsx)(n.strong,{children:"Embedding generation method"}),", ",(0,s.jsx)(n.strong,{children:"Embedding model"}),", and ",(0,s.jsx)(n.strong,{children:"Dimensions"})," fields, and then click ",(0,s.jsx)(n.strong,{children:"Create"}),"."]}),"\n",(0,s.jsxs)(n.p,{children:["Your choice for the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(n.strong,{children:"Embedding model"})," depends on whether you want to use embeddings generated by a provider through Astra's vectorize service, or generated by a component in Langflow."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["To use embeddings generated by a provider through Astra's vectorize service, select the model from the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," dropdown menu, and then select the model from the ",(0,s.jsx)(n.strong,{children:"Embedding model"})," dropdown menu."]}),"\n",(0,s.jsxs)(n.li,{children:["To use embeddings generated by a component in Langflow, select ",(0,s.jsx)(n.strong,{children:"Bring your own"})," for both the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(n.strong,{children:"Embedding model"})," fields. In this starter project, the option for the embeddings method and model is the ",(0,s.jsx)(n.strong,{children:"OpenAI Embeddings"})," component connected to the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(n.li,{children:["The ",(0,s.jsx)(n.strong,{children:"Dimensions"})," value must match the dimensions of your collection. This field is ",(0,s.jsx)(n.strong,{children:"not required"})," if you use embeddings generated through Astra's vectorize service. You can find this value in the ",(0,s.jsx)(n.strong,{children:"Collection"})," in your ",(0,s.jsx)(n.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["For more information, see the ",(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"DataStax Astra DB Serverless documentation"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["If you used Langflow's ",(0,s.jsx)(n.strong,{children:"Global Variables"})," feature, the RAG application flow components are already configured with the necessary credentials."]}),"\n",(0,s.jsx)(n.h2,{id:"run-the-vector-store-rag-flow",children:"Run the Vector Store RAG flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["Click the\xa0",(0,s.jsx)(n.strong,{children:"Playground"}),"\xa0button. Here you can chat with the AI that uses context from the database you created."]}),"\n",(0,s.jsx)(n.li,{children:'Type a message and press Enter. (Try something like "What topics do you know about?")'}),"\n",(0,s.jsx)(n.li,{children:"The bot will respond with a summary of the data you've embedded."}),"\n"]})]})}function g(e={}){const{wrapper:n}={...(0,o.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(h,{...e})}):h(e)}},84443:(e,n,t)=>{t.d(n,{A:()=>o});t(96540);var r=t(64058),s=t(74848);function o(e){let{name:n,...t}=e;const o=r[n];return o?(0,s.jsx)(o,{...t}):null}},85410:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/starter-flow-vector-rag-53aa6c362abccc7e01e69c80d6194315.png"}}]); \ No newline at end of file diff --git a/assets/js/a83bc7c0.c592eecf.js b/assets/js/a83bc7c0.c592eecf.js deleted file mode 100644 index 296dceee50..0000000000 --- a/assets/js/a83bc7c0.c592eecf.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[5628],{28453:(e,n,t)=>{t.d(n,{R:()=>i,x:()=>a});var r=t(96540);const s={},o=r.createContext(s);function i(e){const n=r.useContext(o);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(s):e.components||s:i(e.components),r.createElement(o.Provider,{value:n},e.children)}},60228:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>g,frontMatter:()=>a,metadata:()=>r,toc:()=>d});const r=JSON.parse('{"id":"Starter-Projects/starter-projects-vector-store-rag","title":"Vector store RAG","description":"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it.","source":"@site/docs/Starter-Projects/starter-projects-vector-store-rag.md","sourceDirName":"Starter-Projects","slug":"/starter-projects-vector-store-rag","permalink":"/starter-projects-vector-store-rag","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Vector store RAG","slug":"/starter-projects-vector-store-rag"},"sidebar":"docs","previous":{"title":"Basic prompting","permalink":"/starter-projects-basic-prompting"},"next":{"title":"Simple agent","permalink":"/starter-projects-simple-agent"}}');var s=t(74848),o=t(28453),i=t(84443);const a={title:"Vector store RAG",slug:"/starter-projects-vector-store-rag"},l=void 0,c={},d=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new project",id:"open-langflow-and-start-a-new-project",level:2},{value:"Build the vector RAG flow",id:"build-the-vector-rag-flow",level:2},{value:"Run the Vector Store RAG flow",id:"run-the-vector-store-rag-flow",level:2}];function h(e){const n={a:"a",admonition:"admonition",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,o.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.p,{children:"Retrieval Augmented Generation, or RAG, is a pattern for training LLMs on your data and querying it."}),"\n",(0,s.jsxs)(n.p,{children:["RAG is backed by a\xa0",(0,s.jsx)(n.strong,{children:"vector store"}),", a vector database which stores embeddings of the ingested data."]}),"\n",(0,s.jsxs)(n.p,{children:["This enables\xa0",(0,s.jsx)(n.strong,{children:"vector search"}),", a more powerful and context-aware search."]}),"\n",(0,s.jsxs)(n.p,{children:["We've chosen\xa0",(0,s.jsx)(n.a,{href:"https://astra.datastax.com/signup?utm_source=langflow-pre-release&utm_medium=referral&utm_campaign=langflow-announcement&utm_content=create-a-free-astra-db-account",children:"Astra DB"}),"\xa0as the vector database for this starter flow, but you can follow along with any of Langflow's vector database options."]}),"\n",(0,s.jsx)(n.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/get-started/quickstart.html",children:"An Astra DB vector database"}),"\xa0with the following:","\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:"An Astra DB application token scoped to read and write to the database"}),"\n",(0,s.jsxs)(n.li,{children:["A collection created in ",(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/manage-collections.html#create-collection",children:"Astra"})," or a new collection created in the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"open-langflow-and-start-a-new-project",children:"Open Langflow and start a new project"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(n.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select\xa0",(0,s.jsx)(n.strong,{children:"Vector Store RAG"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Vector Store RAG"}),"\xa0flow is created."]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"build-the-vector-rag-flow",children:"Build the vector RAG flow"}),"\n",(0,s.jsx)(n.p,{children:"The vector store RAG flow is built of two separate flows for ingestion and query."}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.img,{src:t(85410).A+"",width:"2740",height:"1550"})}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Load Data Flow"})," (bottom of the screen) creates a searchable index to be queried for contextual similarity.\nThis flow populates the vector store with data from a local file.\nIt ingests data from a local file, splits it into chunks, indexes it in Astra DB, and computes embeddings for the chunks using the OpenAI embeddings model."]}),"\n",(0,s.jsxs)(n.p,{children:["The\xa0",(0,s.jsx)(n.strong,{children:"Retriever Flow"})," (top of the screen) embeds the user's queries into vectors, which are compared to the vector store data from the ",(0,s.jsx)(n.strong,{children:"Load Data Flow"})," for contextual similarity."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Chat Input"})," receives user input from the ",(0,s.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"OpenAI Embeddings"})," converts the user query into vector form."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Astra DB"})," performs similarity search using the query vector."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Parse Data"})," processes the retrieved chunks."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Prompt"})," combines the user query with relevant context."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"OpenAI"})," generates the response using the prompt."]}),"\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.strong,{children:"Chat Output"})," returns the response to the ",(0,s.jsx)(n.strong,{children:"Playground"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Configure the ",(0,s.jsx)(n.strong,{children:"OpenAI"})," model component."]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["To create a global variable for the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI"}),"\xa0component, in the\xa0",(0,s.jsx)(n.strong,{children:"OpenAI API Key"}),"\xa0field, click the\xa0",(0,s.jsx)(i.A,{name:"Globe","aria-label":"Globe"})," ",(0,s.jsx)(n.strong,{children:"Globe"}),"\xa0button, and then click\xa0",(0,s.jsx)(n.strong,{children:"Add New Variable"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["In the\xa0",(0,s.jsx)(n.strong,{children:"Variable Name"}),"\xa0field, enter\xa0",(0,s.jsx)(n.code,{children:"openai_api_key"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["In the\xa0",(0,s.jsx)(n.strong,{children:"Value"}),"\xa0field, paste your OpenAI API Key (",(0,s.jsx)(n.code,{children:"sk-..."}),")."]}),"\n",(0,s.jsxs)(n.li,{children:["Click\xa0",(0,s.jsx)(n.strong,{children:"Save Variable"}),"."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Configure the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["In the ",(0,s.jsx)(n.strong,{children:"Astra DB Application Token"})," field, add your ",(0,s.jsx)(n.strong,{children:"Astra DB"})," application token.\nThe component connects to your database and populates the menus with existing databases and collections."]}),"\n",(0,s.jsxs)(n.li,{children:["Select your ",(0,s.jsx)(n.strong,{children:"Database"}),".\nIf you don't have a collection, select ",(0,s.jsx)(n.strong,{children:"New database"}),".\nComplete the ",(0,s.jsx)(n.strong,{children:"Name"}),", ",(0,s.jsx)(n.strong,{children:"Cloud provider"}),", and ",(0,s.jsx)(n.strong,{children:"Region"})," fields, and then click ",(0,s.jsx)(n.strong,{children:"Create"}),". ",(0,s.jsx)(n.strong,{children:"Database creation takes a few minutes"}),"."]}),"\n",(0,s.jsxs)(n.li,{children:["Select your ",(0,s.jsx)(n.strong,{children:"Collection"}),". Collections are created in your ",(0,s.jsx)(n.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"})," for storing vector data."]}),"\n"]}),"\n",(0,s.jsx)(n.admonition,{type:"info",children:(0,s.jsxs)(n.p,{children:["If you select a collection embedded with Nvidia through Astra's vectorize service, the ",(0,s.jsx)(n.strong,{children:"Embedding Model"})," port is removed, because you have already generated embeddings for this collection with the Nvidia ",(0,s.jsx)(n.code,{children:"NV-Embed-QA"})," model. The component fetches the data from the collection, and uses the same embeddings for queries."]})}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsx)(n.p,{children:"If you don't have a collection, create a new one within the component."}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Select ",(0,s.jsx)(n.strong,{children:"New collection"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:["Complete the ",(0,s.jsx)(n.strong,{children:"Name"}),", ",(0,s.jsx)(n.strong,{children:"Embedding generation method"}),", ",(0,s.jsx)(n.strong,{children:"Embedding model"}),", and ",(0,s.jsx)(n.strong,{children:"Dimensions"})," fields, and then click ",(0,s.jsx)(n.strong,{children:"Create"}),"."]}),"\n",(0,s.jsxs)(n.p,{children:["Your choice for the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(n.strong,{children:"Embedding model"})," depends on whether you want to use embeddings generated by a provider through Astra's vectorize service, or generated by a component in Langflow."]}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["To use embeddings generated by a provider through Astra's vectorize service, select the model from the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," dropdown menu, and then select the model from the ",(0,s.jsx)(n.strong,{children:"Embedding model"})," dropdown menu."]}),"\n",(0,s.jsxs)(n.li,{children:["To use embeddings generated by a component in Langflow, select ",(0,s.jsx)(n.strong,{children:"Bring your own"})," for both the ",(0,s.jsx)(n.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(n.strong,{children:"Embedding model"})," fields. In this starter project, the option for the embeddings method and model is the ",(0,s.jsx)(n.strong,{children:"OpenAI Embeddings"})," component connected to the ",(0,s.jsx)(n.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(n.li,{children:["The ",(0,s.jsx)(n.strong,{children:"Dimensions"})," value must match the dimensions of your collection. This field is ",(0,s.jsx)(n.strong,{children:"not required"})," if you use embeddings generated through Astra's vectorize service. You can find this value in the ",(0,s.jsx)(n.strong,{children:"Collection"})," in your ",(0,s.jsx)(n.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["For more information, see the ",(0,s.jsx)(n.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"DataStax Astra DB Serverless documentation"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["If you used Langflow's ",(0,s.jsx)(n.strong,{children:"Global Variables"})," feature, the RAG application flow components are already configured with the necessary credentials."]}),"\n",(0,s.jsx)(n.h2,{id:"run-the-vector-store-rag-flow",children:"Run the Vector Store RAG flow"}),"\n",(0,s.jsxs)(n.ol,{children:["\n",(0,s.jsxs)(n.li,{children:["Click the\xa0",(0,s.jsx)(n.strong,{children:"Playground"}),"\xa0button. Here you can chat with the AI that uses context from the database you created."]}),"\n",(0,s.jsx)(n.li,{children:'Type a message and press Enter. (Try something like "What topics do you know about?")'}),"\n",(0,s.jsx)(n.li,{children:"The bot will respond with a summary of the data you've embedded."}),"\n"]})]})}function g(e={}){const{wrapper:n}={...(0,o.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(h,{...e})}):h(e)}},84443:(e,n,t)=>{t.d(n,{A:()=>o});t(96540);var r=t(64058),s=t(74848);function o(e){let{name:n,...t}=e;const o=r[n];return o?(0,s.jsx)(o,{...t}):null}},85410:(e,n,t)=>{t.d(n,{A:()=>r});const r=t.p+"assets/images/starter-flow-vector-rag-d83743e5e049082b9c7a37aaa7b930e9.png"}}]); \ No newline at end of file diff --git a/assets/js/a9b4f8aa.1f0853a9.js b/assets/js/a9b4f8aa.1f0853a9.js new file mode 100644 index 0000000000..a80ced1eec --- /dev/null +++ b/assets/js/a9b4f8aa.1f0853a9.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4931],{15459:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>l,chCodeConfig:()=>p,contentTitle:()=>d,default:()=>x,frontMatter:()=>a,metadata:()=>o,toc:()=>g});const o=JSON.parse('{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get to know Langflow by building an OpenAI-powered chatbot application. After you\'ve constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data.","source":"@site/docs/Get-Started/get-started-quickstart.md","sourceDirName":"Get-Started","slug":"/get-started-quickstart","permalink":"/get-started-quickstart","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Quickstart","slug":"/get-started-quickstart"},"sidebar":"docs","previous":{"title":"Install Langflow","permalink":"/get-started-installation"},"next":{"title":"Basic prompting","permalink":"/starter-projects-basic-prompting"}}');var s=n(74848),r=n(28453),i=n(24754),c=n(84443);const a={title:"Quickstart",slug:"/get-started-quickstart"},d=void 0,l={},h={annotations:i.hk,Code:i.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new project",id:"open-langflow-and-start-a-new-project",level:2},{value:"Build the basic prompting flow",id:"build-the-basic-prompting-flow",level:2},{value:"Run the Basic Prompting flow",id:"run-basic-prompting-flow",level:3},{value:"Add vector RAG to your application",id:"add-vector-rag-to-your-application",level:2},{value:"Add vector RAG with the Astra DB component",id:"add-vector-rag-with-the-astra-db-component",level:2},{value:"Run the chatbot with retrieved context",id:"run-the-chatbot-with-retrieved-context",level:3},{value:"Next steps",id:"next-steps",level:2}];function u(e){const t={a:"a",admonition:"admonition",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return h||m("CH",!1),h.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.jsx)(t.p,{children:"Get to know Langflow by building an OpenAI-powered chatbot application. After you've constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data."}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsxs)(t.li,{children:[(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/get-started/quickstart.html",children:"An Astra DB vector database"}),"\xa0with:","\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:"An Astra DB application token scoped to read and write to the database"}),"\n",(0,s.jsxs)(t.li,{children:["A collection created in ",(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/manage-collections.html#create-collection",children:"Astra"})," or a new collection created in the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"open-langflow-and-start-a-new-project",children:"Open Langflow and start a new project"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Blank Flow"}),". A blank workspace opens where you can build your flow."]}),"\n"]}),"\n",(0,s.jsx)(t.admonition,{type:"tip",children:(0,s.jsxs)(t.p,{children:["If you want a pre-built flow, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Basic Prompting"}),".\nContinue to ",(0,s.jsx)(t.a,{href:"#run-basic-prompting-flow",children:"Run the basic prompting flow"}),"."]})}),"\n",(0,s.jsxs)(t.ol,{start:"2",children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Select\xa0",(0,s.jsx)(t.strong,{children:"Basic Prompting"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["The\xa0",(0,s.jsx)(t.strong,{children:"Basic Prompting"}),"\xa0flow is created."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"build-the-basic-prompting-flow",children:"Build the basic prompting flow"}),"\n",(0,s.jsx)(t.p,{children:"The Basic Prompting flow will look like this when it's completed:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Completed basic prompting flow",src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,s.jsxs)(t.p,{children:["To build the ",(0,s.jsx)(t.strong,{children:"Basic Prompting"})," flow, follow these steps:"]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Inputs"}),", select the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-io#chat-input",children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Prompt"}),", select the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-prompts",children:"Prompt"})," component combines the user input with a user-defined prompt."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Outputs"}),", select the ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-io#chat-output",children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Models"}),", select the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"components-models#openai",children:"OpenAI"})," model component sends the user input and prompt to the OpenAI API and receives a response."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"You should now have a flow that looks like this:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Basic prompting flow with no connections",src:n(32358).A+"",width:"2528",height:"1530"})}),"\n",(0,s.jsxs)(t.p,{children:["With no connections between them, the components won't interact with each other.\nYou want data to flow from ",(0,s.jsx)(t.strong,{children:"Chat Input"})," to ",(0,s.jsx)(t.strong,{children:"Chat Output"})," through the connections between the components.\nEach component accepts inputs on its left side, and sends outputs on its right side.\nHover over the connection ports to see the data types that the component accepts.\nFor more on component inputs and outputs, see ",(0,s.jsx)(t.a,{href:"/concepts-components",children:"Components overview"}),"."]}),"\n",(0,s.jsxs)(t.ol,{start:"5",children:["\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component to the OpenAI model component, click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Message"})," port to the OpenAI model component's ",(0,s.jsx)(t.strong,{children:"Input"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to the OpenAI model component, click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Prompt Message"})," port to the OpenAI model component's ",(0,s.jsx)(t.strong,{children:"System Message"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," model component to the ",(0,s.jsx)(t.strong,{children:"Chat Output"}),", click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Text"})," port to the ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component's ",(0,s.jsx)(t.strong,{children:"Text"})," port."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"Your finished basic prompting flow should look like this:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,s.jsx)(t.h3,{id:"run-basic-prompting-flow",children:"Run the Basic Prompting flow"}),"\n",(0,s.jsx)(t.p,{children:"Add your OpenAI API key to the OpenAI model component, and add a prompt to the Prompt component to instruct the model how to respond."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Add your credentials to the OpenAI component. The fastest way to complete these fields is with Langflow\u2019s ",(0,s.jsx)(t.a,{href:"/configuration-global-variables",children:"Global Variables"}),"."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the OpenAI component\u2019s OpenAI API Key field, click the ",(0,s.jsx)(c.A,{name:"Globe","aria-label":"Globe"})," ",(0,s.jsx)(t.strong,{children:"Globe"}),"\xa0button, and then click ",(0,s.jsx)(t.strong,{children:"Add New Variable"}),".\nAlternatively, click your user icon in the top right corner, and then click ",(0,s.jsx)(t.strong,{children:"Settings"}),", ",(0,s.jsx)(t.strong,{children:"Global Variables"}),", and then ",(0,s.jsx)(t.strong,{children:"Add New"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Name your variable. Paste your OpenAI API key (sk-\u2026\u200b) in the Value field."}),"\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Apply To Fields"})," field, select the OpenAI API Key field to apply this variable to all OpenAI Embeddings components."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["To add a prompt to the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,s.jsx)(t.strong,{children:"Template"})," field, and then enter your prompt.\nThe prompt guides the bot's responses to input.\nIf you're unsure, use ",(0,s.jsx)(t.code,{children:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh."})]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Enter a query, and then make sure the bot responds according to the prompt you set in the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"You have successfully created a chatbot application using OpenAI in the Langflow Workspace."}),"\n",(0,s.jsx)(t.h2,{id:"add-vector-rag-to-your-application",children:"Add vector RAG to your application"}),"\n",(0,s.jsx)(t.p,{children:"You created a chatbot application with Langflow, but let's try an experiment."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Ask the bot: ",(0,s.jsx)(t.code,{children:"Who won the Oscar in 2024 for best movie?"})]}),"\n",(0,s.jsx)(t.li,{children:"The bot's response is similar to this:"}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I'm sorry, but I don't have information on events or awards that occurred after",props:{}}]},{tokens:[{content:"October 2023, including the Oscars in 2024.",props:{}}]},{tokens:[{content:"You may want to check the latest news or the official Oscars website",props:{}}]},{tokens:[{content:"for the most current information.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["Well, that's unfortunate, but you can load more up-to-date data with ",(0,s.jsx)(t.strong,{children:"Retrieval Augmented Generation"}),", or ",(0,s.jsx)(t.strong,{children:"RAG"}),"."]}),"\n",(0,s.jsx)(t.p,{children:"Vector RAG allows you to load your own data and chat with it, unlocking a wider range of possibilities for your chatbot application."}),"\n",(0,s.jsx)(t.h2,{id:"add-vector-rag-with-the-astra-db-component",children:"Add vector RAG with the Astra DB component"}),"\n",(0,s.jsxs)(t.p,{children:["Build on the basic prompting flow and add vector RAG to your chatbot application with the ",(0,s.jsx)(t.strong,{children:"Astra DB Vector Store"})," component."]}),"\n",(0,s.jsxs)(t.p,{children:["Add document ingestion to your basic prompting flow, with the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component as the vector store."]}),"\n",(0,s.jsx)(t.admonition,{type:"tip",children:(0,s.jsxs)(t.p,{children:["If you don't want to create a blank flow, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Vector RAG"})," for a pre-built flow."]})}),"\n",(0,s.jsx)(t.p,{children:"Adding vector RAG to the basic prompting flow will look like this when completed:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Add document ingestion to the basic prompting flow",src:n(69645).A+"",width:"2868",height:"1566"})}),"\n",(0,s.jsx)(t.p,{children:"To build the flow, follow these steps:"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Disconnect the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component from the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component by double-clicking on the connecting line."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Vector Stores"}),", select the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store"})," component connects to your ",(0,s.jsx)(t.strong,{children:"Astra DB"})," database."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Data"}),", select the ",(0,s.jsx)(t.strong,{children:"File"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-data#file",children:"File"})," component loads files from your local machine."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Processing"}),", select the ",(0,s.jsx)(t.strong,{children:"Split Text"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-processing#split-text",children:"Split Text"})," component splits the loaded text into smaller chunks."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Processing"}),", select the ",(0,s.jsx)(t.strong,{children:"Parser"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-processing#parser",children:"Parser"})," component converts the data from the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component into plain text."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Embeddings"}),", select the ",(0,s.jsx)(t.strong,{children:"OpenAI Embeddings"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-embedding-models#openai-embeddings",children:"OpenAI Embeddings"})," component generates embeddings for the user's input, which are compared to the vector data in the database."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the new components into the existing flow, so your flow looks like this:"}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Add document ingestion to the basic prompting flow",src:n(69645).A+"",width:"2868",height:"1566"})}),"\n",(0,s.jsxs)(t.ol,{start:"8",children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Configure the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Astra DB Application Token"})," field, add your ",(0,s.jsx)(t.strong,{children:"Astra DB"})," application token.\nThe component connects to your database and populates the menus with existing databases and collections."]}),"\n",(0,s.jsxs)(t.li,{children:["Select your ",(0,s.jsx)(t.strong,{children:"Database"}),".\nIf you don't have a collection, select ",(0,s.jsx)(t.strong,{children:"New database"}),".\nComplete the ",(0,s.jsx)(t.strong,{children:"Name"}),", ",(0,s.jsx)(t.strong,{children:"Cloud provider"}),", and ",(0,s.jsx)(t.strong,{children:"Region"})," fields, and then click ",(0,s.jsx)(t.strong,{children:"Create"}),". ",(0,s.jsx)(t.strong,{children:"Database creation takes a few minutes"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Select your ",(0,s.jsx)(t.strong,{children:"Collection"}),". Collections are created in your ",(0,s.jsx)(t.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"})," for storing vector data."]}),"\n"]}),"\n",(0,s.jsx)(t.admonition,{type:"info",children:(0,s.jsxs)(t.p,{children:["If you select a collection embedded with NVIDIA through Astra's vectorize service, the ",(0,s.jsx)(t.strong,{children:"Embedding Model"})," port is removed, because you have already generated embeddings for this collection with the NVIDIA ",(0,s.jsx)(t.code,{children:"NV-Embed-QA"})," model. The component fetches the data from the collection, and uses the same embeddings for queries."]})}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsx)(t.p,{children:"If you don't have a collection, create a new one within the component."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Select ",(0,s.jsx)(t.strong,{children:"New collection"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Complete the ",(0,s.jsx)(t.strong,{children:"Name"}),", ",(0,s.jsx)(t.strong,{children:"Embedding generation method"}),", ",(0,s.jsx)(t.strong,{children:"Embedding model"}),", and ",(0,s.jsx)(t.strong,{children:"Dimensions"})," fields, and then click ",(0,s.jsx)(t.strong,{children:"Create"}),"."]}),"\n",(0,s.jsxs)(t.p,{children:["Your choice for the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(t.strong,{children:"Embedding model"})," depends on whether you want to use embeddings generated by a provider through Astra's vectorize service, or generated by a component in Langflow."]}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["To use embeddings generated by a provider through Astra's vectorize service, select the model from the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," dropdown menu, and then select the model from the ",(0,s.jsx)(t.strong,{children:"Embedding model"})," dropdown menu."]}),"\n",(0,s.jsxs)(t.li,{children:["To use embeddings generated by a component in Langflow, select ",(0,s.jsx)(t.strong,{children:"Bring your own"})," for both the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(t.strong,{children:"Embedding model"})," fields. In this starter project, the option for the embeddings method and model is the ",(0,s.jsx)(t.strong,{children:"OpenAI Embeddings"})," component connected to the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Dimensions"})," value must match the dimensions of your collection. This field is ",(0,s.jsx)(t.strong,{children:"not required"})," if you use embeddings generated through Astra's vectorize service. You can find this value in the ",(0,s.jsx)(t.strong,{children:"Collection"})," in your ",(0,s.jsx)(t.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["For more information, see the ",(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"DataStax Astra DB Serverless documentation"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["If you used Langflow's ",(0,s.jsx)(t.strong,{children:"Global Variables"})," feature, the RAG application flow components are already configured with the necessary credentials."]}),"\n",(0,s.jsx)(t.h3,{id:"run-the-chatbot-with-retrieved-context",children:"Run the chatbot with retrieved context"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Modify the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to contain variables for both ",(0,s.jsx)(t.code,{children:"{user_question}"})," and ",(0,s.jsx)(t.code,{children:"{context}"}),".\nThe ",(0,s.jsx)(t.code,{children:"{context}"})," variable gives the bot additional context for answering ",(0,s.jsx)(t.code,{children:"{user_question}"})," beyond what the LLM was trained on."]}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Given the context",props:{}}]},{tokens:[{content:"{context}",props:{}}]},{tokens:[{content:"Answer the question",props:{}}]},{tokens:[{content:"{user_question}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.ol,{start:"2",children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"File"})," component, upload a text file from your local machine with data you want to ingest into the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component database.\nThis example uploads an up-to-date CSV about Oscar winners."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n",(0,s.jsxs)(t.li,{children:["Ask the bot: ",(0,s.jsx)(t.code,{children:"Who won the Oscar in 2024 for best movie?"})]}),"\n",(0,s.jsx)(t.li,{children:"The bot's response should be similar to this:"}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'The Oscar for Best Picture in 2024 was awarded to "Oppenheimer,"',props:{}}]},{tokens:[{content:"produced by Emma Thomas, Charles Roven, and Christopher Nolan.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["Adding an ",(0,s.jsx)(t.strong,{children:"Astra DB"})," vector store brought your chatbot all the way into 2024.\nYou have successfully added RAG to your chatbot application using the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsx)(t.h2,{id:"next-steps",children:"Next steps"}),"\n",(0,s.jsx)(t.p,{children:"This example used movie data, but the RAG pattern can be used with any data you want to load and chat with."}),"\n",(0,s.jsxs)(t.p,{children:["Make the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," database the brain that ",(0,s.jsx)(t.a,{href:"/agents-overview",children:"Agents"})," use to make decisions."]}),"\n",(0,s.jsxs)(t.p,{children:["Publish this flow as an ",(0,s.jsx)(t.a,{href:"/concepts-publish",children:"API"})," and call it from your external applications."]}),"\n",(0,s.jsxs)(t.p,{children:["For more on the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component, see ",(0,s.jsx)(t.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store"}),"."]})]})}function x(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(u,{...e})}):u(e)}function m(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},32358:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-basic-prompt-no-connections-f5887f67c3448c39b74f7e28b65a0b18.png"},69645:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-add-document-ingestion-6c34bac012400e3d35f6cebdd350ecf7.png"},84443:(e,t,n)=>{n.d(t,{A:()=>r});n(96540);var o=n(64058),s=n(74848);function r(e){let{name:t,...n}=e;const r=o[t];return r?(0,s.jsx)(r,{...n}):null}},90567:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-basic-prompting-09331815d7282bd6a3feedf84838ba20.png"}}]); \ No newline at end of file diff --git a/assets/js/a9b4f8aa.fa339860.js b/assets/js/a9b4f8aa.fa339860.js deleted file mode 100644 index 096bed5b0c..0000000000 --- a/assets/js/a9b4f8aa.fa339860.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4931],{15459:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>l,chCodeConfig:()=>p,contentTitle:()=>d,default:()=>m,frontMatter:()=>a,metadata:()=>o,toc:()=>g});const o=JSON.parse('{"id":"Get-Started/get-started-quickstart","title":"Quickstart","description":"Get to know Langflow by building an OpenAI-powered chatbot application. After you\'ve constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data.","source":"@site/docs/Get-Started/get-started-quickstart.md","sourceDirName":"Get-Started","slug":"/get-started-quickstart","permalink":"/get-started-quickstart","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Quickstart","slug":"/get-started-quickstart"},"sidebar":"docs","previous":{"title":"Install Langflow","permalink":"/get-started-installation"},"next":{"title":"Basic prompting","permalink":"/starter-projects-basic-prompting"}}');var s=n(74848),r=n(28453),i=n(24754),c=n(84443);const a={title:"Quickstart",slug:"/get-started-quickstart"},d=void 0,l={},h={annotations:i.hk,Code:i.Cy},p={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new project",id:"open-langflow-and-start-a-new-project",level:2},{value:"Build the basic prompting flow",id:"build-the-basic-prompting-flow",level:2},{value:"Run the Basic Prompting flow",id:"run-basic-prompting-flow",level:3},{value:"Add vector RAG to your application",id:"add-vector-rag-to-your-application",level:2},{value:"Add vector RAG with the Astra DB component",id:"add-vector-rag-with-the-astra-db-component",level:2},{value:"Run the chatbot with retrieved context",id:"run-the-chatbot-with-retrieved-context",level:3},{value:"Next steps",id:"next-steps",level:2}];function u(e){const t={a:"a",admonition:"admonition",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.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)(t.p,{children:"Get to know Langflow by building an OpenAI-powered chatbot application. After you've constructed a chatbot, add Retrieval Augmented Generation (RAG) to chat with your own data."}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsxs)(t.li,{children:[(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/get-started/quickstart.html",children:"An Astra DB vector database"}),"\xa0with:","\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:"An Astra DB application token scoped to read and write to the database"}),"\n",(0,s.jsxs)(t.li,{children:["A collection created in ",(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/manage-collections.html#create-collection",children:"Astra"})," or a new collection created in the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"open-langflow-and-start-a-new-project",children:"Open Langflow and start a new project"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["From the Langflow dashboard, click\xa0",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Blank Flow"}),". A blank workspace opens where you can build your flow."]}),"\n"]}),"\n",(0,s.jsx)(t.admonition,{type:"tip",children:(0,s.jsxs)(t.p,{children:["If you don't want to create a blank flow, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Basic Prompting"})," for a pre-built flow.\nContinue to ",(0,s.jsx)(t.a,{href:"#run-basic-prompting-flow",children:"Run the basic prompting flow"}),"."]})}),"\n",(0,s.jsxs)(t.ol,{start:"2",children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Select\xa0",(0,s.jsx)(t.strong,{children:"Basic Prompting"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["The\xa0",(0,s.jsx)(t.strong,{children:"Basic Prompting"}),"\xa0flow is created."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"build-the-basic-prompting-flow",children:"Build the basic prompting flow"}),"\n",(0,s.jsx)(t.p,{children:"The Basic Prompting flow will look like this when it's completed:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Completed basic prompting flow",src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,s.jsxs)(t.p,{children:["To build the ",(0,s.jsx)(t.strong,{children:"Basic Prompting"})," flow, follow these steps:"]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Inputs"}),", select the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-io#chat-input",children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Prompt"}),", select the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-prompts",children:"Prompt"})," component combines the user input with a user-defined prompt."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Outputs"}),", select the ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-io#chat-output",children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Models"}),", select the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"components-models#openai",children:"OpenAI"})," model component sends the user input and prompt to the OpenAI API and receives a response."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"You should now have a flow that looks like this:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Basic prompting flow with no connections",src:n(32358).A+"",width:"2528",height:"1530"})}),"\n",(0,s.jsxs)(t.p,{children:["With no connections between them, the components won't interact with each other.\nYou want data to flow from ",(0,s.jsx)(t.strong,{children:"Chat Input"})," to ",(0,s.jsx)(t.strong,{children:"Chat Output"})," through the connections between the components.\nEach component accepts inputs on its left side, and sends outputs on its right side.\nHover over the connection ports to see the data types that the component accepts.\nFor more on component inputs and outputs, see ",(0,s.jsx)(t.a,{href:"/concepts-components",children:"Components overview"}),"."]}),"\n",(0,s.jsxs)(t.ol,{start:"5",children:["\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component to the OpenAI model component, click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Message"})," port to the OpenAI model component's ",(0,s.jsx)(t.strong,{children:"Input"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to the OpenAI model component, click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Prompt Message"})," port to the OpenAI model component's ",(0,s.jsx)(t.strong,{children:"System Message"})," port."]}),"\n",(0,s.jsxs)(t.li,{children:["To connect the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," model component to the ",(0,s.jsx)(t.strong,{children:"Chat Output"}),", click and drag a line from the blue ",(0,s.jsx)(t.strong,{children:"Text"})," port to the ",(0,s.jsx)(t.strong,{children:"Chat Output"})," component's ",(0,s.jsx)(t.strong,{children:"Text"})," port."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"Your finished basic prompting flow should look like this:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:n(90567).A+"",width:"2500",height:"1528"})}),"\n",(0,s.jsx)(t.h3,{id:"run-basic-prompting-flow",children:"Run the Basic Prompting flow"}),"\n",(0,s.jsx)(t.p,{children:"Add your OpenAI API key to the OpenAI model component, and add a prompt to the Prompt component to instruct the model how to respond."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Add your credentials to the OpenAI component. The fastest way to complete these fields is with Langflow\u2019s ",(0,s.jsx)(t.a,{href:"/configuration-global-variables",children:"Global Variables"}),"."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the OpenAI component\u2019s OpenAI API Key field, click the ",(0,s.jsx)(c.A,{name:"Globe","aria-label":"Globe"})," ",(0,s.jsx)(t.strong,{children:"Globe"}),"\xa0button, and then click ",(0,s.jsx)(t.strong,{children:"Add New Variable"}),".\nAlternatively, click your username in the top right corner, and then click ",(0,s.jsx)(t.strong,{children:"Settings"}),", ",(0,s.jsx)(t.strong,{children:"Global Variables"}),", and then ",(0,s.jsx)(t.strong,{children:"Add New"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Name your variable. Paste your OpenAI API key (sk-\u2026\u200b) in the Value field."}),"\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Apply To Fields"})," field, select the OpenAI API Key field to apply this variable to all OpenAI Embeddings components."]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["To add a prompt to the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component, click the ",(0,s.jsx)(t.strong,{children:"Template"})," field, and then enter your prompt.\nThe prompt guides the bot's responses to input.\nIf you're unsure, use ",(0,s.jsx)(t.code,{children:"Answer the user as if you were a GenAI expert, enthusiastic about helping them get started building something fresh."})]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Enter a query, and then make sure the bot responds according to the prompt you set in the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component."]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:"You have successfully created a chatbot application using OpenAI in the Langflow Workspace."}),"\n",(0,s.jsx)(t.h2,{id:"add-vector-rag-to-your-application",children:"Add vector RAG to your application"}),"\n",(0,s.jsx)(t.p,{children:"You created a chatbot application with Langflow, but let's try an experiment."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Ask the bot: ",(0,s.jsx)(t.code,{children:"Who won the Oscar in 2024 for best movie?"})]}),"\n",(0,s.jsx)(t.li,{children:"The bot's response is similar to this:"}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"I'm sorry, but I don't have information on events or awards that occurred after",props:{}}]},{tokens:[{content:"October 2023, including the Oscars in 2024.",props:{}}]},{tokens:[{content:"You may want to check the latest news or the official Oscars website",props:{}}]},{tokens:[{content:"for the most current information.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["Well, that's unfortunate, but you can load more up-to-date data with ",(0,s.jsx)(t.strong,{children:"Retrieval Augmented Generation"}),", or ",(0,s.jsx)(t.strong,{children:"RAG"}),"."]}),"\n",(0,s.jsx)(t.p,{children:"Vector RAG allows you to load your own data and chat with it, unlocking a wider range of possibilities for your chatbot application."}),"\n",(0,s.jsx)(t.h2,{id:"add-vector-rag-with-the-astra-db-component",children:"Add vector RAG with the Astra DB component"}),"\n",(0,s.jsxs)(t.p,{children:["Build on the basic prompting flow and add vector RAG to your chatbot application with the ",(0,s.jsx)(t.strong,{children:"Astra DB Vector Store"})," component."]}),"\n",(0,s.jsxs)(t.p,{children:["Add document ingestion to your basic prompting flow, with the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component as the vector store."]}),"\n",(0,s.jsx)(t.admonition,{type:"tip",children:(0,s.jsxs)(t.p,{children:["If you don't want to create a blank flow, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),", and then select ",(0,s.jsx)(t.strong,{children:"Vector RAG"})," for a pre-built flow."]})}),"\n",(0,s.jsx)(t.p,{children:"Adding vector RAG to the basic prompting flow will look like this when completed:"}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Add document ingestion to the basic prompting flow",src:n(69645).A+"",width:"2848",height:"1324"})}),"\n",(0,s.jsx)(t.p,{children:"To build the flow, follow these steps:"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Disconnect the ",(0,s.jsx)(t.strong,{children:"Chat Input"})," component from the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component by double-clicking on the connecting line."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Vector Stores"}),", select the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store"})," component connects to your ",(0,s.jsx)(t.strong,{children:"Astra DB"})," database."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Data"}),", select the ",(0,s.jsx)(t.strong,{children:"File"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-data#file",children:"File"})," component loads files from your local machine."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Processing"}),", select the ",(0,s.jsx)(t.strong,{children:"Split Text"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-processing#split-text",children:"Split Text"})," component splits the loaded text into smaller chunks."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Processing"}),", select the ",(0,s.jsx)(t.strong,{children:"Parse Data"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-processing#data-to-message",children:"Data to Message"})," component converts the data from the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component into plain text."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Embeddings"}),", select the ",(0,s.jsx)(t.strong,{children:"OpenAI Embeddings"})," component, and then drag it to the canvas.\nThe ",(0,s.jsx)(t.a,{href:"/components-embedding-models#openai-embeddings",children:"OpenAI Embeddings"})," component generates embeddings for the user's input, which are compared to the vector data in the database."]}),"\n",(0,s.jsx)(t.li,{children:"Connect the new components into the existing flow, so your flow looks like this:"}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{alt:"Add document ingestion to the basic prompting flow",src:n(69645).A+"",width:"2848",height:"1324"})}),"\n",(0,s.jsxs)(t.ol,{start:"8",children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Configure the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Astra DB Application Token"})," field, add your ",(0,s.jsx)(t.strong,{children:"Astra DB"})," application token.\nThe component connects to your database and populates the menus with existing databases and collections."]}),"\n",(0,s.jsxs)(t.li,{children:["Select your ",(0,s.jsx)(t.strong,{children:"Database"}),".\nIf you don't have a collection, select ",(0,s.jsx)(t.strong,{children:"New database"}),".\nComplete the ",(0,s.jsx)(t.strong,{children:"Name"}),", ",(0,s.jsx)(t.strong,{children:"Cloud provider"}),", and ",(0,s.jsx)(t.strong,{children:"Region"})," fields, and then click ",(0,s.jsx)(t.strong,{children:"Create"}),". ",(0,s.jsx)(t.strong,{children:"Database creation takes a few minutes"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Select your ",(0,s.jsx)(t.strong,{children:"Collection"}),". Collections are created in your ",(0,s.jsx)(t.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"})," for storing vector data."]}),"\n"]}),"\n",(0,s.jsx)(t.admonition,{type:"info",children:(0,s.jsxs)(t.p,{children:["If you select a collection embedded with NVIDIA through Astra's vectorize service, the ",(0,s.jsx)(t.strong,{children:"Embedding Model"})," port is removed, because you have already generated embeddings for this collection with the NVIDIA ",(0,s.jsx)(t.code,{children:"NV-Embed-QA"})," model. The component fetches the data from the collection, and uses the same embeddings for queries."]})}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsx)(t.p,{children:"If you don't have a collection, create a new one within the component."}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Select ",(0,s.jsx)(t.strong,{children:"New collection"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.li,{children:["\n",(0,s.jsxs)(t.p,{children:["Complete the ",(0,s.jsx)(t.strong,{children:"Name"}),", ",(0,s.jsx)(t.strong,{children:"Embedding generation method"}),", ",(0,s.jsx)(t.strong,{children:"Embedding model"}),", and ",(0,s.jsx)(t.strong,{children:"Dimensions"})," fields, and then click ",(0,s.jsx)(t.strong,{children:"Create"}),"."]}),"\n",(0,s.jsxs)(t.p,{children:["Your choice for the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(t.strong,{children:"Embedding model"})," depends on whether you want to use embeddings generated by a provider through Astra's vectorize service, or generated by a component in Langflow."]}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsxs)(t.li,{children:["To use embeddings generated by a provider through Astra's vectorize service, select the model from the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," dropdown menu, and then select the model from the ",(0,s.jsx)(t.strong,{children:"Embedding model"})," dropdown menu."]}),"\n",(0,s.jsxs)(t.li,{children:["To use embeddings generated by a component in Langflow, select ",(0,s.jsx)(t.strong,{children:"Bring your own"})," for both the ",(0,s.jsx)(t.strong,{children:"Embedding generation method"})," and ",(0,s.jsx)(t.strong,{children:"Embedding model"})," fields. In this starter project, the option for the embeddings method and model is the ",(0,s.jsx)(t.strong,{children:"OpenAI Embeddings"})," component connected to the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Dimensions"})," value must match the dimensions of your collection. This field is ",(0,s.jsx)(t.strong,{children:"not required"})," if you use embeddings generated through Astra's vectorize service. You can find this value in the ",(0,s.jsx)(t.strong,{children:"Collection"})," in your ",(0,s.jsx)(t.a,{href:"https://astra.datastax.com",children:"Astra DB deployment"}),"."]}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["For more information, see the ",(0,s.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"DataStax Astra DB Serverless documentation"}),"."]}),"\n"]}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["If you used Langflow's ",(0,s.jsx)(t.strong,{children:"Global Variables"})," feature, the RAG application flow components are already configured with the necessary credentials."]}),"\n",(0,s.jsx)(t.h3,{id:"run-the-chatbot-with-retrieved-context",children:"Run the chatbot with retrieved context"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Modify the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to contain variables for both ",(0,s.jsx)(t.code,{children:"{user_question}"})," and ",(0,s.jsx)(t.code,{children:"{context}"}),".\nThe ",(0,s.jsx)(t.code,{children:"{context}"})," variable gives the bot additional context for answering ",(0,s.jsx)(t.code,{children:"{user_question}"})," beyond what the LLM was trained on."]}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Given the context",props:{}}]},{tokens:[{content:"{context}",props:{}}]},{tokens:[{content:"Answer the question",props:{}}]},{tokens:[{content:"{user_question}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.ol,{start:"2",children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"File"})," component, upload a text file from your local machine with data you want to ingest into the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component database.\nThis example uploads an up-to-date CSV about Oscar winners."]}),"\n",(0,s.jsxs)(t.li,{children:["Click ",(0,s.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n",(0,s.jsxs)(t.li,{children:["Ask the bot: ",(0,s.jsx)(t.code,{children:"Who won the Oscar in 2024 for best movie?"})]}),"\n",(0,s.jsx)(t.li,{children:"The bot's response should be similar to this:"}),"\n"]}),"\n",(0,s.jsx)(h.Code,{codeConfig:p,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:'The Oscar for Best Picture in 2024 was awarded to "Oppenheimer,"',props:{}}]},{tokens:[{content:"produced by Emma Thomas, Charles Roven, and Christopher Nolan.",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["Adding an ",(0,s.jsx)(t.strong,{children:"Astra DB"})," vector store brought your chatbot all the way into 2024.\nYou have successfully added RAG to your chatbot application using the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component."]}),"\n",(0,s.jsx)(t.h2,{id:"next-steps",children:"Next steps"}),"\n",(0,s.jsx)(t.p,{children:"This example used movie data, but the RAG pattern can be used with any data you want to load and chat with."}),"\n",(0,s.jsxs)(t.p,{children:["Make the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," database the brain that ",(0,s.jsx)(t.a,{href:"/agents-overview",children:"Agents"})," use to make decisions."]}),"\n",(0,s.jsxs)(t.p,{children:["Publish this flow as an ",(0,s.jsx)(t.a,{href:"/concepts-publish",children:"API"})," and call it from your external applications."]}),"\n",(0,s.jsxs)(t.p,{children:["For more on the ",(0,s.jsx)(t.strong,{children:"Astra DB"})," component, see ",(0,s.jsx)(t.a,{href:"/components-vector-stores#astra-db-vector-store",children:"Astra DB vector store"}),"."]})]})}function m(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(u,{...e})}):u(e)}function x(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},32358:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-basic-prompt-no-connections-f5887f67c3448c39b74f7e28b65a0b18.png"},69645:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/quickstart-add-document-ingestion-5f9756b0a4b7e232b1507e12f335b15e.png"},84443:(e,t,n)=>{n.d(t,{A:()=>r});n(96540);var o=n(64058),s=n(74848);function r(e){let{name:t,...n}=e;const r=o[t];return r?(0,s.jsx)(r,{...n}):null}},90567:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-basic-prompting-09331815d7282bd6a3feedf84838ba20.png"}}]); \ No newline at end of file diff --git a/assets/js/adef6868.913fad87.js b/assets/js/adef6868.f5324ebd.js similarity index 98% rename from assets/js/adef6868.913fad87.js rename to assets/js/adef6868.f5324ebd.js index 08350d63ca..30c1c98bbe 100644 --- a/assets/js/adef6868.913fad87.js +++ b/assets/js/adef6868.f5324ebd.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8953],{28453:(e,t,n)=>{n.d(t,{R:()=>i,x:()=>l});var s=n(96540);const r={},d=s.createContext(r);function i(e){const t=s.useContext(d);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(r):e.components||r:i(e.components),s.createElement(d.Provider,{value:t},e.children)}},46571:(e,t,n)=>{n.d(t,{A:()=>s});const s=n.p+"assets/images/starter-flow-unstructured-qa-c029fa3529d7098a59549e3dfc1517a8.png"},67836:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>o,contentTitle:()=>l,default:()=>h,frontMatter:()=>i,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/components-loaders","title":"Loaders","description":"As of Langflow 1.1, loader components are now found in the Components menu under Bundles.","source":"@site/docs/Components/components-loaders.md","sourceDirName":"Components","slug":"/components-loaders","permalink":"/components-loaders","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Loaders","slug":"/components-loaders"},"sidebar":"docs","previous":{"title":"Inputs and outputs","permalink":"/components-io"},"next":{"title":"Logic","permalink":"/components-logic"}}');var r=n(74848),d=n(28453);const i={title:"Loaders",slug:"/components-loaders"},l="Loader components in Langflow",o={},c=[{value:"Use a loader component in a flow",id:"use-a-loader-component-in-a-flow",level:2},{value:"Confluence",id:"confluence",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"GitLoader",id:"gitloader",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Unstructured",id:"unstructured",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3}];function a(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(t.header,{children:(0,r.jsx)(t.h1,{id:"loader-components-in-langflow",children:"Loader components in Langflow"})}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["As of Langflow 1.1, loader components are now found in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"Loaders fetch data into Langflow from various sources, such as databases, websites, and local files."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-loader-component-in-a-flow",children:"Use a loader component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["This flow creates a question-and-answer chatbot for documents that are loaded into the flow.\nThe ",(0,r.jsx)(t.a,{href:"https://unstructured.io/",children:"Unstructured.io"})," loader component loads files from your local machine, and then parses them into a list of structured ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects.\nThis loaded data informs the ",(0,r.jsx)(t.strong,{children:"Open AI"})," component's responses to your questions."]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"Sample Flow retrieving data with unstructured",src:n(46571).A+"",width:"2930",height:"1198"})}),"\n",(0,r.jsx)(t.h2,{id:"confluence",children:"Confluence"}),"\n",(0,r.jsx)(t.p,{children:"The Confluence component integrates with the Confluence wiki collaboration platform to load and process documents. It utilizes the ConfluenceLoader from LangChain to fetch content from a specified Confluence space."}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"url"}),(0,r.jsx)(t.td,{children:"Site URL"}),(0,r.jsxs)(t.td,{children:["The base URL of the Confluence Space (e.g., ",(0,r.jsx)(t.code,{children:"https://company.atlassian.net/wiki"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"username"}),(0,r.jsx)(t.td,{children:"Username"}),(0,r.jsxs)(t.td,{children:["Atlassian User E-mail (e.g., ",(0,r.jsx)(t.code,{children:"email@example.com"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_key"}),(0,r.jsx)(t.td,{children:"API Key"}),(0,r.jsxs)(t.td,{children:["Atlassian API Key (Create an API key at: ",(0,r.jsx)(t.a,{href:"https://id.atlassian.com/manage-profile/security/api-tokens",children:"Atlassian"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"space_key"}),(0,r.jsx)(t.td,{children:"Space Key"}),(0,r.jsx)(t.td,{children:"The key of the Confluence space to access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"cloud"}),(0,r.jsx)(t.td,{children:"Use Cloud?"}),(0,r.jsx)(t.td,{children:"Whether to use Confluence Cloud (default: true)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"content_format"}),(0,r.jsx)(t.td,{children:"Content Format"}),(0,r.jsx)(t.td,{children:"Specify content format (default: STORAGE)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_pages"}),(0,r.jsx)(t.td,{children:"Max Pages"}),(0,r.jsx)(t.td,{children:"Maximum number of pages to retrieve (default: 1000)"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the loaded Confluence documents"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"gitloader",children:"GitLoader"}),"\n",(0,r.jsx)(t.p,{children:"The GitLoader component uses the GitLoader from LangChain to fetch and load documents from a specified Git repository."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"repo_path"}),(0,r.jsx)(t.td,{children:"Repository Path"}),(0,r.jsx)(t.td,{children:"The local path to the Git repository"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"clone_url"}),(0,r.jsx)(t.td,{children:"Clone URL"}),(0,r.jsx)(t.td,{children:"The URL to clone the Git repository from (optional)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"branch"}),(0,r.jsx)(t.td,{children:"Branch"}),(0,r.jsx)(t.td,{children:"The branch to load files from (default: 'main')"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file_filter"}),(0,r.jsx)(t.td,{children:"File Filter"}),(0,r.jsx)(t.td,{children:"Patterns to filter files (e.g., '.py' to include only .py files, '!.py' to exclude .py files)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"content_filter"}),(0,r.jsx)(t.td,{children:"Content Filter"}),(0,r.jsx)(t.td,{children:"A regex pattern to filter files based on their content"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the loaded Git repository documents"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"unstructured",children:"Unstructured"}),"\n",(0,r.jsxs)(t.p,{children:["This component uses the ",(0,r.jsx)(t.a,{href:"https://unstructured.io/",children:"Unstructured.io"})," Serverless API to load and parse files into a list of structured ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file"}),(0,r.jsx)(t.td,{children:"File"}),(0,r.jsxs)(t.td,{children:["The path to the file to be parsed (supported types are listed ",(0,r.jsx)(t.a,{href:"https://docs.unstructured.io/api-reference/api-services/overview#supported-file-types",children:"here"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_key"}),(0,r.jsx)(t.td,{children:"API Key"}),(0,r.jsx)(t.td,{children:"Unstructured.io Serverless API Key"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_url"}),(0,r.jsx)(t.td,{children:"Unstructured.io API URL"}),(0,r.jsx)(t.td,{children:"Optional URL for the Unstructured API"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"chunking_strategy"}),(0,r.jsx)(t.td,{children:"Chunking Strategy"}),(0,r.jsx)(t.td,{children:'Strategy for chunking the document (options: "", "basic", "by_title", "by_page", "by_similarity")'})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"unstructured_args"}),(0,r.jsx)(t.td,{children:"Additional Arguments"}),(0,r.jsx)(t.td,{children:"Optional dictionary of additional arguments for the Unstructured.io API"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the parsed content from the input file"})]})})]})]})}function h(e={}){const{wrapper:t}={...(0,d.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8953],{28453:(e,t,n)=>{n.d(t,{R:()=>i,x:()=>l});var s=n(96540);const r={},d=s.createContext(r);function i(e){const t=s.useContext(d);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(r):e.components||r:i(e.components),s.createElement(d.Provider,{value:t},e.children)}},46571:(e,t,n)=>{n.d(t,{A:()=>s});const s=n.p+"assets/images/starter-flow-unstructured-qa-4260fdd42821cf2cbd056661b96be655.png"},67836:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>o,contentTitle:()=>l,default:()=>h,frontMatter:()=>i,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Components/components-loaders","title":"Loaders","description":"As of Langflow 1.1, loader components are now found in the Components menu under Bundles.","source":"@site/docs/Components/components-loaders.md","sourceDirName":"Components","slug":"/components-loaders","permalink":"/components-loaders","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Loaders","slug":"/components-loaders"},"sidebar":"docs","previous":{"title":"Inputs and outputs","permalink":"/components-io"},"next":{"title":"Logic","permalink":"/components-logic"}}');var r=n(74848),d=n(28453);const i={title:"Loaders",slug:"/components-loaders"},l="Loader components in Langflow",o={},c=[{value:"Use a loader component in a flow",id:"use-a-loader-component-in-a-flow",level:2},{value:"Confluence",id:"confluence",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"GitLoader",id:"gitloader",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Unstructured",id:"unstructured",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3}];function a(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(t.header,{children:(0,r.jsx)(t.h1,{id:"loader-components-in-langflow",children:"Loader components in Langflow"})}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["As of Langflow 1.1, loader components are now found in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"Loaders fetch data into Langflow from various sources, such as databases, websites, and local files."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-loader-component-in-a-flow",children:"Use a loader component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["This flow creates a question-and-answer chatbot for documents that are loaded into the flow.\nThe ",(0,r.jsx)(t.a,{href:"https://unstructured.io/",children:"Unstructured.io"})," loader component loads files from your local machine, and then parses them into a list of structured ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects.\nThis loaded data informs the ",(0,r.jsx)(t.strong,{children:"Open AI"})," component's responses to your questions."]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"Sample Flow retrieving data with unstructured",src:n(46571).A+"",width:"2950",height:"1238"})}),"\n",(0,r.jsx)(t.h2,{id:"confluence",children:"Confluence"}),"\n",(0,r.jsx)(t.p,{children:"The Confluence component integrates with the Confluence wiki collaboration platform to load and process documents. It utilizes the ConfluenceLoader from LangChain to fetch content from a specified Confluence space."}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"url"}),(0,r.jsx)(t.td,{children:"Site URL"}),(0,r.jsxs)(t.td,{children:["The base URL of the Confluence Space (e.g., ",(0,r.jsx)(t.code,{children:"https://company.atlassian.net/wiki"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"username"}),(0,r.jsx)(t.td,{children:"Username"}),(0,r.jsxs)(t.td,{children:["Atlassian User E-mail (e.g., ",(0,r.jsx)(t.code,{children:"email@example.com"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_key"}),(0,r.jsx)(t.td,{children:"API Key"}),(0,r.jsxs)(t.td,{children:["Atlassian API Key (Create an API key at: ",(0,r.jsx)(t.a,{href:"https://id.atlassian.com/manage-profile/security/api-tokens",children:"Atlassian"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"space_key"}),(0,r.jsx)(t.td,{children:"Space Key"}),(0,r.jsx)(t.td,{children:"The key of the Confluence space to access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"cloud"}),(0,r.jsx)(t.td,{children:"Use Cloud?"}),(0,r.jsx)(t.td,{children:"Whether to use Confluence Cloud (default: true)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"content_format"}),(0,r.jsx)(t.td,{children:"Content Format"}),(0,r.jsx)(t.td,{children:"Specify content format (default: STORAGE)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_pages"}),(0,r.jsx)(t.td,{children:"Max Pages"}),(0,r.jsx)(t.td,{children:"Maximum number of pages to retrieve (default: 1000)"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the loaded Confluence documents"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"gitloader",children:"GitLoader"}),"\n",(0,r.jsx)(t.p,{children:"The GitLoader component uses the GitLoader from LangChain to fetch and load documents from a specified Git repository."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"repo_path"}),(0,r.jsx)(t.td,{children:"Repository Path"}),(0,r.jsx)(t.td,{children:"The local path to the Git repository"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"clone_url"}),(0,r.jsx)(t.td,{children:"Clone URL"}),(0,r.jsx)(t.td,{children:"The URL to clone the Git repository from (optional)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"branch"}),(0,r.jsx)(t.td,{children:"Branch"}),(0,r.jsx)(t.td,{children:"The branch to load files from (default: 'main')"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file_filter"}),(0,r.jsx)(t.td,{children:"File Filter"}),(0,r.jsx)(t.td,{children:"Patterns to filter files (e.g., '.py' to include only .py files, '!.py' to exclude .py files)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"content_filter"}),(0,r.jsx)(t.td,{children:"Content Filter"}),(0,r.jsx)(t.td,{children:"A regex pattern to filter files based on their content"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the loaded Git repository documents"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"unstructured",children:"Unstructured"}),"\n",(0,r.jsxs)(t.p,{children:["This component uses the ",(0,r.jsx)(t.a,{href:"https://unstructured.io/",children:"Unstructured.io"})," Serverless API to load and parse files into a list of structured ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file"}),(0,r.jsx)(t.td,{children:"File"}),(0,r.jsxs)(t.td,{children:["The path to the file to be parsed (supported types are listed ",(0,r.jsx)(t.a,{href:"https://docs.unstructured.io/api-reference/api-services/overview#supported-file-types",children:"here"}),")"]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_key"}),(0,r.jsx)(t.td,{children:"API Key"}),(0,r.jsx)(t.td,{children:"Unstructured.io Serverless API Key"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"api_url"}),(0,r.jsx)(t.td,{children:"Unstructured.io API URL"}),(0,r.jsx)(t.td,{children:"Optional URL for the Unstructured API"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"chunking_strategy"}),(0,r.jsx)(t.td,{children:"Chunking Strategy"}),(0,r.jsx)(t.td,{children:'Strategy for chunking the document (options: "", "basic", "by_title", "by_page", "by_similarity")'})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"unstructured_args"}),(0,r.jsx)(t.td,{children:"Additional Arguments"}),(0,r.jsx)(t.td,{children:"Optional dictionary of additional arguments for the Unstructured.io API"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"List of Data objects containing the parsed content from the input file"})]})})]})]})}function h(e={}){const{wrapper:t}={...(0,d.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}}}]); \ No newline at end of file diff --git a/assets/js/af2091ee.afddc62d.js b/assets/js/af2091ee.afddc62d.js deleted file mode 100644 index f90155ca80..0000000000 --- a/assets/js/af2091ee.afddc62d.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[600],{6623:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>h,assets:()=>c,chCodeConfig:()=>d,contentTitle:()=>l,default:()=>p,frontMatter:()=>i,metadata:()=>o,toc:()=>g});const o=JSON.parse('{"id":"Sample-Flows/math-agent","title":"Math agent","description":"Build a Math Agent flow for an agentic application using the Tool-calling agent component.","source":"@site/docs/Sample-Flows/math-agent.md","sourceDirName":"Sample-Flows","slug":"/math-agent","permalink":"/math-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Math agent","slug":"/math-agent"},"sidebar":"docs","previous":{"title":"Memory chatbot","permalink":"/memory-chatbot"},"next":{"title":"Sequential tasks agent","permalink":"/sequential-agent"}}');var r=n(74848),s=n(28453),a=n(24754);n(84443);const i={title:"Math agent",slug:"/math-agent"},l=void 0,c={},h={annotations:a.hk,Code:a.Cy},d={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new flow",id:"open-langflow-and-start-a-new-flow",level:2},{value:"Math Agent flow",id:"math-agent-flow",level:2},{value:"Run the Math Agent flow",id:"run-the-math-agent-flow",level:2}];function u(e){const t={code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return h||m("CH",!1),h.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","\n",(0,r.jsxs)(t.p,{children:["Build a ",(0,r.jsx)(t.strong,{children:"Math Agent"})," flow for an agentic application using the ",(0,r.jsx)(t.strong,{children:"Tool-calling agent"})," component."]}),"\n",(0,r.jsxs)(t.p,{children:["In this flow, the ",(0,r.jsx)(t.strong,{children:"Tool-calling agent"})," reasons using an ",(0,r.jsx)(t.strong,{children:"Open AI"})," LLM to solve math problems.\nIt selects the ",(0,r.jsx)(t.strong,{children:"Calculator"})," tool for simpler math and the ",(0,r.jsx)(t.strong,{children:"Python REPL"})," tool (with the Python ",(0,r.jsx)(t.code,{children:"math"})," library) for more complex problems."]}),"\n",(0,r.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsx)(t.p,{children:"To use this flow, you need an OpenAI API key."}),"\n",(0,r.jsx)(t.h2,{id:"open-langflow-and-start-a-new-flow",children:"Open Langflow and start a new flow"}),"\n",(0,r.jsxs)(t.p,{children:["Click ",(0,r.jsx)(t.strong,{children:"New Flow"}),", and then select the ",(0,r.jsx)(t.strong,{children:"Math Agent"})," flow."]}),"\n",(0,r.jsx)(t.p,{children:"This opens a starter flow with the necessary components to run an agentic application using the Tool-calling agent."}),"\n",(0,r.jsx)(t.h2,{id:"math-agent-flow",children:"Math Agent flow"}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{src:n(45832).A+"",width:"2104",height:"1746"})}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"Math Agent"})," flow consists of these components:"]}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Tool calling agent"})," component uses the connected LLM to reason through the user's input and select among the connected tools to complete its task."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Python REPL tool"})," component executes Python code in a REPL (Read-Evaluate-Print Loop) interpreter."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Calculator"})," component performs basic arithmetic operations."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"run-the-math-agent-flow",children:"Run the Math Agent flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Add your credentials to the ",(0,r.jsx)(t.strong,{children:"Agent"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["Click ",(0,r.jsx)(t.strong,{children:"Playground"})," to start a chat session."]}),"\n",(0,r.jsxs)(t.li,{children:["Enter a simple math problem, like ",(0,r.jsx)(t.code,{children:"2 + 2"}),", and then make sure the bot responds with the correct answer."]}),"\n",(0,r.jsxs)(t.li,{children:["To confirm the REPL interpreter is working, prompt the ",(0,r.jsx)(t.code,{children:"math"})," library directly with ",(0,r.jsx)(t.code,{children:"math.sqrt(4)"})," and see if the bot responds with ",(0,r.jsx)(t.code,{children:"4"}),"."]}),"\n",(0,r.jsx)(t.li,{children:"The agent will also reason through more complex word problems. For example, prompt the agent with the following math problem:"}),"\n"]}),"\n",(0,r.jsx)(h.Code,{codeConfig:d,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"The equation 24x2+25x\u221247ax\u22122=\u22128x\u22123\u221253ax\u22122 is true for all values of x\u22602a, where a is a constant.",props:{}}]},{tokens:[{content:"What is the value of a?",props:{}}]},{tokens:[{content:"A) -16",props:{}}]},{tokens:[{content:"B) -3",props:{}}]},{tokens:[{content:"C) 3",props:{}}]},{tokens:[{content:"D) 16",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["The agent should respond with ",(0,r.jsx)(t.code,{children:"B"}),"."]}),"\n",(0,r.jsxs)(t.p,{children:["Now that your query has completed the journey from ",(0,r.jsx)(t.strong,{children:"Chat input"})," to ",(0,r.jsx)(t.strong,{children:"Chat output"}),", you have completed the ",(0,r.jsx)(t.strong,{children:"Math Agent"})," flow."]})]})}function p(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(u,{...e})}):u(e)}function m(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},45832:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-simple-agent-repl-6c6df85ce6d01bfafebe3e4247cefc83.png"},84443:(e,t,n)=>{n.d(t,{A:()=>s});n(96540);var o=n(64058),r=n(74848);function s(e){let{name:t,...n}=e;const s=o[t];return s?(0,r.jsx)(s,{...n}):null}}}]); \ No newline at end of file diff --git a/assets/js/b1ab2a41.e6ae1894.js b/assets/js/b1ab2a41.bebcd954.js similarity index 81% rename from assets/js/b1ab2a41.e6ae1894.js rename to assets/js/b1ab2a41.bebcd954.js index f913fe1f80..d387761928 100644 --- a/assets/js/b1ab2a41.e6ae1894.js +++ b/assets/js/b1ab2a41.bebcd954.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[5195],{58235:(e,s,o)=>{o.r(s),o.d(s,{CH:()=>l,assets:()=>d,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>m,frontMatter:()=>a,metadata:()=>n,toc:()=>u});const n=JSON.parse('{"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.","source":"@site/docs/Develop/session-id.md","sourceDirName":"Develop","slug":"/session-id","permalink":"/session-id","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Use session ID to manage communication between components","slug":"/session-id"},"sidebar":"docs","previous":{"title":"Memory management options","permalink":"/memory"},"next":{"title":"Logging options in Langflow","permalink":"/logging"}}');var t=o(74848),i=o(28453),r=o(24754);const a={title:"Use session ID to manage communication between components",slug:"/session-id"},c=void 0,d={},l={annotations:r.hk,Code:r.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Customize session ID",id:"customize-session-id",level:2},{value:"Retrieval of messages from memory by session ID",id:"retrieval-of-messages-from-memory-by-session-id",level:2}];function p(e){const s={a:"a",code:"code",h2:"h2",p:"p",strong:"strong",...(0,i.R)(),...e.components};return l||g("CH",!1),l.Code||g("CH.Code",!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)(s.p,{children:"Session ID is a unique identifier for client/server connections. A single session equals the duration of a client's connection to a server."}),"\n",(0,t.jsxs)(s.p,{children:["In the Langflow ",(0,t.jsx)(s.strong,{children:"Playground"}),", current sessions are listed on the left side of the pane."]}),"\n",(0,t.jsx)(s.p,{children:"Langflow uses session IDs to track different chat interactions within flows. This allows multiple chat sessions to exist in a single flow. Messages are stored in the database with session IDs as a reference."}),"\n",(0,t.jsx)(s.p,{children:"This differentiation between users per session is helpful in managing client/server connections, but is also important in maintaining separate conversational contexts within a single flow. LLMs rely on past interactions to generate responses to queries, and if these conversations aren't separated, the responses becomes less useful, or even confused."}),"\n",(0,t.jsx)(s.h2,{id:"customize-session-id",children:"Customize session ID"}),"\n",(0,t.jsx)(s.p,{children:"Custom session IDs can be set as part of the payload in API calls, or as advanced settings in individual components. The API session ID value takes precedence. If no session ID is specified, the flow ID is assigned."}),"\n",(0,t.jsx)(s.p,{children:"If you set a custom session ID in a payload, all downstream components use the upstream component's session ID value."}),"\n",(0,t.jsx)(l.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl --request POST \\",props:{}}]},{tokens:[{content:" --url 'http://127.0.0.1:7860/api/v1/run/$FLOW_ID' \\",props:{}}]},{tokens:[{content:" --header 'Content-Type: application/json' \\",props:{}}]},{tokens:[{content:" --data '{",props:{}}]},{tokens:[{content:' "input_value": "Hello",',props:{}}]},{tokens:[{content:' "output_type": "chat",',props:{}}]},{tokens:[{content:' "input_type": "chat",',props:{}}]},{tokens:[{content:' "session_id": "my_custom_session_value"',props:{}}]},{tokens:[{content:"}'",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(s.p,{children:["The ",(0,t.jsx)(s.code,{children:"my_custom_session_value"})," value is used in components that accept it, and the stored messages from this flow are stored in ",(0,t.jsx)(s.code,{children:"langflow.db"})," with their respective ",(0,t.jsx)(s.code,{children:"session_id"})," values."]}),"\n",(0,t.jsx)(s.h2,{id:"retrieval-of-messages-from-memory-by-session-id",children:"Retrieval of messages from memory by session ID"}),"\n",(0,t.jsxs)(s.p,{children:["Add a ",(0,t.jsx)(s.a,{href:"/components-helpers#message-store",children:"Message store"})," component to a flow to access the default ",(0,t.jsx)(s.code,{children:"langflow.db"})," database. The component accepts ",(0,t.jsx)(s.code,{children:"sessionID"})," as a filter parameter, and uses the session ID value from upstream automatically to retrieve message history by session ID from storage."]}),"\n",(0,t.jsxs)(s.p,{children:["Messages can be retrieved by ",(0,t.jsx)(s.code,{children:"session_id"})," from the ",(0,t.jsx)(s.code,{children:"/monitor"})," endpoint in the API. For more information, see the ",(0,t.jsx)(s.a,{href:"https://docs.langflow.org/api-reference-api-examples#get-messages",children:"API examples"}),"."]}),"\n",(0,t.jsxs)(s.p,{children:["For an example of session ID in action, see ",(0,t.jsx)(s.a,{href:"https://www.youtube.com/watch?v=nJiF_eF21MY",children:"Use Session IDs in Langflow"}),"."]})]})}function m(e={}){const{wrapper:s}={...(0,i.R)(),...e.components};return s?(0,t.jsx)(s,{...e,children:(0,t.jsx)(p,{...e})}):p(e)}function g(e,s){throw new Error("Expected "+(s?"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([[5195],{58235:(e,s,o)=>{o.r(s),o.d(s,{CH:()=>l,assets:()=>d,chCodeConfig:()=>h,contentTitle:()=>c,default:()=>m,frontMatter:()=>a,metadata:()=>n,toc:()=>u});const n=JSON.parse('{"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.","source":"@site/docs/Develop/session-id.md","sourceDirName":"Develop","slug":"/session-id","permalink":"/session-id","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Use session ID to manage communication between components","slug":"/session-id"},"sidebar":"docs","previous":{"title":"Memory management options","permalink":"/memory"},"next":{"title":"Logging options in Langflow","permalink":"/logging"}}');var t=o(74848),i=o(28453),r=o(24754);const a={title:"Use session ID to manage communication between components",slug:"/session-id"},c=void 0,d={},l={annotations:r.hk,Code:r.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},u=[{value:"Customize session ID",id:"customize-session-id",level:2},{value:"Retrieval of messages from memory by session ID",id:"retrieval-of-messages-from-memory-by-session-id",level:2}];function p(e){const s={a:"a",code:"code",h2:"h2",p:"p",strong:"strong",...(0,i.R)(),...e.components};return l||g("CH",!1),l.Code||g("CH.Code",!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)(s.p,{children:"Session ID is a unique identifier for client/server connections. A single session equals the duration of a client's connection to a server."}),"\n",(0,t.jsxs)(s.p,{children:["In the Langflow ",(0,t.jsx)(s.strong,{children:"Playground"}),", current sessions are listed on the left side of the pane."]}),"\n",(0,t.jsx)(s.p,{children:"Langflow uses session IDs to track different chat interactions within flows. This allows multiple chat sessions to exist in a single flow. Messages are stored in the database with session IDs as a reference."}),"\n",(0,t.jsx)(s.p,{children:"This differentiation between users per session is helpful in managing client/server connections, but is also important in maintaining separate conversational contexts within a single flow. LLMs rely on past interactions to generate responses to queries, and if these conversations aren't separated, the responses becomes less useful, or even confused."}),"\n",(0,t.jsx)(s.h2,{id:"customize-session-id",children:"Customize session ID"}),"\n",(0,t.jsx)(s.p,{children:"Custom session IDs can be set as part of the payload in API calls, or as advanced settings in individual components. The API session ID value takes precedence. If no session ID is specified, the flow ID is assigned."}),"\n",(0,t.jsx)(s.p,{children:"If you set a custom session ID in a payload, all downstream components use the upstream component's session ID value."}),"\n",(0,t.jsx)(l.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"curl --request POST \\",props:{}}]},{tokens:[{content:" --url 'http://127.0.0.1:7860/api/v1/run/$FLOW_ID' \\",props:{}}]},{tokens:[{content:" --header 'Content-Type: application/json' \\",props:{}}]},{tokens:[{content:" --data '{",props:{}}]},{tokens:[{content:' "input_value": "Hello",',props:{}}]},{tokens:[{content:' "output_type": "chat",',props:{}}]},{tokens:[{content:' "input_type": "chat",',props:{}}]},{tokens:[{content:' "session_id": "my_custom_session_value"',props:{}}]},{tokens:[{content:"}'",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,t.jsxs)(s.p,{children:["The ",(0,t.jsx)(s.code,{children:"my_custom_session_value"})," value is used in components that accept it, and the stored messages from this flow are stored in ",(0,t.jsx)(s.code,{children:"langflow.db"})," with their respective ",(0,t.jsx)(s.code,{children:"session_id"})," values."]}),"\n",(0,t.jsx)(s.h2,{id:"retrieval-of-messages-from-memory-by-session-id",children:"Retrieval of messages from memory by session ID"}),"\n",(0,t.jsxs)(s.p,{children:["To retrieve messages from local Langflow memory, add a ",(0,t.jsx)(s.a,{href:"/components-helpers#message-history",children:"Message history"})," component to your flow.\nThe component accepts ",(0,t.jsx)(s.code,{children:"sessionID"})," as a filter parameter, and uses the session ID value from upstream automatically to retrieve message history by session ID from storage."]}),"\n",(0,t.jsxs)(s.p,{children:["Messages can be retrieved by ",(0,t.jsx)(s.code,{children:"session_id"})," from the ",(0,t.jsx)(s.code,{children:"/monitor"})," endpoint in the API. For more information, see the ",(0,t.jsx)(s.a,{href:"https://docs.langflow.org/api-reference-api-examples#get-messages",children:"API examples"}),"."]}),"\n",(0,t.jsxs)(s.p,{children:["For an example of session ID in action, see ",(0,t.jsx)(s.a,{href:"https://www.youtube.com/watch?v=nJiF_eF21MY",children:"Use Session IDs in Langflow"}),"."]})]})}function m(e={}){const{wrapper:s}={...(0,i.R)(),...e.components};return s?(0,t.jsx)(s,{...e,children:(0,t.jsx)(p,{...e})}):p(e)}function g(e,s){throw new Error("Expected "+(s?"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/b3c57e4b.69fcbaa3.js b/assets/js/b3c57e4b.69fcbaa3.js new file mode 100644 index 0000000000..29a65b7ecd --- /dev/null +++ b/assets/js/b3c57e4b.69fcbaa3.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9836],{17286:(n,e,t)=>{t.d(e,{A:()=>l});const l=t.p+"assets/images/starter-flow-travel-agent-a7119af3c35c0a13a7321377ddbd0bde.png"},28453:(n,e,t)=>{t.d(e,{R:()=>r,x:()=>i});var l=t(96540);const s={},a=l.createContext(s);function r(n){const e=l.useContext(a);return l.useMemo((function(){return"function"==typeof n?n(e):{...e,...n}}),[e,n])}function i(n){let e;return e=n.disableParentContext?"function"==typeof n.components?n.components(s):n.components||s:r(n.components),l.createElement(a.Provider,{value:e},n.children)}},92196:(n,e,t)=>{t.r(e),t.d(e,{assets:()=>o,contentTitle:()=>i,default:()=>d,frontMatter:()=>r,metadata:()=>l,toc:()=>c});const l=JSON.parse('{"id":"Sample-Flows/travel-planning-agent","title":"Travel planning agent","description":"Build a Travel Planning Agent flow for an agentic application using the multiple Tool-calling agents.","source":"@site/docs/Sample-Flows/travel-planning-agent.md","sourceDirName":"Sample-Flows","slug":"/travel-planning-agent","permalink":"/travel-planning-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Travel planning agent","slug":"/travel-planning-agent"},"sidebar":"docs","previous":{"title":"Sequential tasks agent","permalink":"/sequential-agent"},"next":{"title":"Langflow overview","permalink":"/concepts-overview"}}');var s=t(74848),a=t(28453);const r={title:"Travel planning agent",slug:"/travel-planning-agent"},i=void 0,o={},c=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new flow",id:"open-langflow-and-start-a-new-flow",level:2},{value:"Create the travel planning agent flow",id:"create-the-travel-planning-agent-flow",level:2},{value:"Run the travel planning agent flow",id:"run-the-travel-planning-agent-flow",level:2}];function h(n){const e={a:"a",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,a.R)(),...n.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(e.p,{children:["Build a ",(0,s.jsx)(e.strong,{children:"Travel Planning Agent"})," flow for an agentic application using the multiple Tool-calling agents."]}),"\n",(0,s.jsxs)(e.p,{children:["An ",(0,s.jsx)(e.strong,{children:"agent"}),' uses an LLM as its "brain" to select among the connected tools and complete its tasks.']}),"\n",(0,s.jsxs)(e.p,{children:["In this flow, multiple ",(0,s.jsx)(e.strong,{children:"Tool-calling agents"})," reason using an ",(0,s.jsx)(e.strong,{children:"Open AI"})," LLM to plan a travel journey. Each agent is given a different responsibility defined by its ",(0,s.jsx)(e.strong,{children:"System Prompt"})," field."]}),"\n",(0,s.jsxs)(e.p,{children:["The ",(0,s.jsx)(e.strong,{children:"Chat input"})," defines where the user wants to go, and passes the result to the ",(0,s.jsx)(e.strong,{children:"City Selection"})," agent. The ",(0,s.jsx)(e.strong,{children:"Local Expert"})," agent then adds information based on the selected cities, and the ",(0,s.jsx)(e.strong,{children:"Travel Concierge"})," assembles a seven day travel plan in Markdown."]}),"\n",(0,s.jsxs)(e.p,{children:["All agents have access to the ",(0,s.jsx)(e.strong,{children:"Search API"})," and ",(0,s.jsx)(e.strong,{children:"URL Content Fetcher"})," components, while only the Travel Concierge can use the ",(0,s.jsx)(e.strong,{children:"Calculator"})," for computing the trip costs."]}),"\n",(0,s.jsx)(e.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(e.ul,{children:["\n",(0,s.jsx)(e.li,{children:(0,s.jsx)(e.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(e.li,{children:(0,s.jsx)(e.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n",(0,s.jsx)(e.li,{children:(0,s.jsx)(e.a,{href:"https://www.searchapi.io/",children:"A Search API key"})}),"\n"]}),"\n",(0,s.jsx)(e.h2,{id:"open-langflow-and-start-a-new-flow",children:"Open Langflow and start a new flow"}),"\n",(0,s.jsxs)(e.p,{children:["Click ",(0,s.jsx)(e.strong,{children:"New Flow"}),", and then select the ",(0,s.jsx)(e.strong,{children:"Travel Planning Agent"})," flow."]}),"\n",(0,s.jsx)(e.p,{children:"This opens a starter flow with the necessary components to run an agentic application using multiple Tool-calling agents."}),"\n",(0,s.jsx)(e.h2,{id:"create-the-travel-planning-agent-flow",children:"Create the travel planning agent flow"}),"\n",(0,s.jsx)(e.p,{children:(0,s.jsx)(e.img,{src:t(17286).A+"",width:"2348",height:"1322"})}),"\n",(0,s.jsxs)(e.p,{children:["The ",(0,s.jsx)(e.strong,{children:"Travel Planning Agent"})," flow consists of these components:"]}),"\n",(0,s.jsxs)(e.ul,{children:["\n",(0,s.jsxs)(e.li,{children:["Multiple ",(0,s.jsx)(e.strong,{children:"Tool calling agent"})," components that use the connected LLM to reason through the user's input and select among the connected tools to complete their tasks."]}),"\n",(0,s.jsxs)(e.li,{children:["The ",(0,s.jsx)(e.strong,{children:"Calculator"})," component performs basic arithmetic operations."]}),"\n",(0,s.jsxs)(e.li,{children:["The ",(0,s.jsx)(e.strong,{children:"URL Content Fetcher"})," component scrapes content from a given URL."]}),"\n",(0,s.jsxs)(e.li,{children:["The ",(0,s.jsx)(e.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,s.jsxs)(e.li,{children:["The ",(0,s.jsx)(e.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,s.jsxs)(e.li,{children:["The ",(0,s.jsx)(e.strong,{children:"OpenAI"})," model component sends the user input and prompt to the OpenAI API and receives a response."]}),"\n"]}),"\n",(0,s.jsx)(e.h2,{id:"run-the-travel-planning-agent-flow",children:"Run the travel planning agent flow"}),"\n",(0,s.jsxs)(e.ol,{children:["\n",(0,s.jsx)(e.li,{children:"Add your credentials to the Open AI and Search API components."}),"\n",(0,s.jsxs)(e.li,{children:["Click ",(0,s.jsx)(e.strong,{children:"Playground"})," to start a chat session.\nYou should receive a detailed, helpful answer to the journey defined in the ",(0,s.jsx)(e.strong,{children:"Chat input"})," component."]}),"\n"]}),"\n",(0,s.jsxs)(e.p,{children:["Now that your query has completed the journey from ",(0,s.jsx)(e.strong,{children:"Chat input"})," to ",(0,s.jsx)(e.strong,{children:"Chat output"}),", you have completed the ",(0,s.jsx)(e.strong,{children:"Travel Planning Agent"})," flow."]})]})}function d(n={}){const{wrapper:e}={...(0,a.R)(),...n.components};return e?(0,s.jsx)(e,{...n,children:(0,s.jsx)(h,{...n})}):h(n)}}}]); \ No newline at end of file diff --git a/assets/js/b3c57e4b.d51480b8.js b/assets/js/b3c57e4b.d51480b8.js deleted file mode 100644 index 2a815d4bb0..0000000000 --- a/assets/js/b3c57e4b.d51480b8.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[9836],{17286:(e,n,t)=>{t.d(n,{A:()=>s});const s=t.p+"assets/images/starter-flow-travel-agent-a7119af3c35c0a13a7321377ddbd0bde.png"},28453:(e,n,t)=>{t.d(n,{R:()=>o,x:()=>r});var s=t(96540);const l={},a=s.createContext(l);function o(e){const n=s.useContext(a);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function r(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:o(e.components),s.createElement(a.Provider,{value:n},e.children)}},92196:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>i,contentTitle:()=>r,default:()=>d,frontMatter:()=>o,metadata:()=>s,toc:()=>c});const s=JSON.parse('{"id":"Sample-Flows/travel-planning-agent","title":"Travel planning agent","description":"Build a Travel Planning Agent flow for an agentic application using the multiple Tool-calling agents.","source":"@site/docs/Sample-Flows/travel-planning-agent.md","sourceDirName":"Sample-Flows","slug":"/travel-planning-agent","permalink":"/travel-planning-agent","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Travel planning agent","slug":"/travel-planning-agent"},"sidebar":"docs","previous":{"title":"Sequential tasks agent","permalink":"/sequential-agent"},"next":{"title":"Langflow overview","permalink":"/concepts-overview"}}');var l=t(74848),a=t(28453);const o={title:"Travel planning agent",slug:"/travel-planning-agent"},r=void 0,i={},c=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Open Langflow and start a new flow",id:"open-langflow-and-start-a-new-flow",level:2},{value:"Create the travel planning agent flow",id:"create-the-travel-planning-agent-flow",level:2},{value:"Run the travel planning agent flow",id:"run-the-travel-planning-agent-flow",level:2}];function h(e){const n={a:"a",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,a.R)(),...e.components};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsxs)(n.p,{children:["Build a ",(0,l.jsx)(n.strong,{children:"Travel Planning Agent"})," flow for an agentic application using the multiple Tool-calling agents."]}),"\n",(0,l.jsxs)(n.p,{children:["An ",(0,l.jsx)(n.strong,{children:"agent"}),' uses an LLM as its "brain" to select among the connected tools and complete its tasks.']}),"\n",(0,l.jsxs)(n.p,{children:["In this flow, multiple ",(0,l.jsx)(n.strong,{children:"Tool-calling agents"})," reason using an ",(0,l.jsx)(n.strong,{children:"Open AI"})," LLM to plan a travel journey. Each agent is given a different responsibility defined by its ",(0,l.jsx)(n.strong,{children:"System Prompt"})," field."]}),"\n",(0,l.jsxs)(n.p,{children:["The ",(0,l.jsx)(n.strong,{children:"Chat input"})," defines where the user wants to go, and passes the result to the ",(0,l.jsx)(n.strong,{children:"City Selection"})," agent. The ",(0,l.jsx)(n.strong,{children:"Local Expert"})," agent then adds information based on the selected cities, and the ",(0,l.jsx)(n.strong,{children:"Travel Concierge"})," assembles a seven day travel plan in Markdown."]}),"\n",(0,l.jsxs)(n.p,{children:["All agents have access to the ",(0,l.jsx)(n.strong,{children:"Search API"})," and ",(0,l.jsx)(n.strong,{children:"URL Content Fetcher"})," components, while only the Travel Concierge can use the ",(0,l.jsx)(n.strong,{children:"Calculator"})," for computing the trip costs."]}),"\n",(0,l.jsx)(n.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,l.jsxs)(n.p,{children:["To use this flow, you need an ",(0,l.jsx)(n.a,{href:"https://platform.openai.com/",children:"OpenAI API key"})," and a ",(0,l.jsx)(n.a,{href:"https://www.searchapi.io/",children:"Search API key"}),"."]}),"\n",(0,l.jsx)(n.h2,{id:"open-langflow-and-start-a-new-flow",children:"Open Langflow and start a new flow"}),"\n",(0,l.jsxs)(n.p,{children:["Click ",(0,l.jsx)(n.strong,{children:"New Flow"}),", and then select the ",(0,l.jsx)(n.strong,{children:"Travel Planning Agent"})," flow."]}),"\n",(0,l.jsx)(n.p,{children:"This opens a starter flow with the necessary components to run an agentic application using multiple Tool-calling agents."}),"\n",(0,l.jsx)(n.h2,{id:"create-the-travel-planning-agent-flow",children:"Create the travel planning agent flow"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.img,{src:t(17286).A+"",width:"2348",height:"1322"})}),"\n",(0,l.jsxs)(n.p,{children:["The ",(0,l.jsx)(n.strong,{children:"Travel Planning Agent"})," flow consists of these components:"]}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["Multiple ",(0,l.jsx)(n.strong,{children:"Tool calling agent"})," components that use the connected LLM to reason through the user's input and select among the connected tools to complete their tasks."]}),"\n",(0,l.jsxs)(n.li,{children:["The ",(0,l.jsx)(n.strong,{children:"Calculator"})," component performs basic arithmetic operations."]}),"\n",(0,l.jsxs)(n.li,{children:["The ",(0,l.jsx)(n.strong,{children:"URL Content Fetcher"})," component scrapes content from a given URL."]}),"\n",(0,l.jsxs)(n.li,{children:["The ",(0,l.jsx)(n.strong,{children:"Chat Input"})," component accepts user input to the chat."]}),"\n",(0,l.jsxs)(n.li,{children:["The ",(0,l.jsx)(n.strong,{children:"Chat Output"})," component prints the flow's output to the chat."]}),"\n",(0,l.jsxs)(n.li,{children:["The ",(0,l.jsx)(n.strong,{children:"OpenAI"})," model component sends the user input and prompt to the OpenAI API and receives a response."]}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"run-the-travel-planning-agent-flow",children:"Run the travel planning agent flow"}),"\n",(0,l.jsxs)(n.ol,{children:["\n",(0,l.jsx)(n.li,{children:"Add your credentials to the Open AI and Search API components."}),"\n",(0,l.jsxs)(n.li,{children:["Click ",(0,l.jsx)(n.strong,{children:"Playground"})," to start a chat session.\nYou should receive a detailed, helpful answer to the journey defined in the ",(0,l.jsx)(n.strong,{children:"Chat input"})," component."]}),"\n"]}),"\n",(0,l.jsxs)(n.p,{children:["Now that your query has completed the journey from ",(0,l.jsx)(n.strong,{children:"Chat input"})," to ",(0,l.jsx)(n.strong,{children:"Chat output"}),", you have completed the ",(0,l.jsx)(n.strong,{children:"Travel Planning Agent"})," flow."]})]})}function d(e={}){const{wrapper:n}={...(0,a.R)(),...e.components};return n?(0,l.jsx)(n,{...e,children:(0,l.jsx)(h,{...e})}):h(e)}}}]); \ No newline at end of file diff --git a/assets/js/de94873f.2b011ec8.js b/assets/js/de94873f.2b011ec8.js new file mode 100644 index 0000000000..856b067325 --- /dev/null +++ b/assets/js/de94873f.2b011ec8.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1841],{84443:(e,t,o)=>{o.d(t,{A:()=>r});o(96540);var n=o(64058),s=o(74848);function r(e){let{name:t,...o}=e;const r=n[t];return r?(0,s.jsx)(r,{...o}):null}},85629:(e,t,o)=>{o.d(t,{A:()=>n});const n=o.p+"assets/images/messages-logs-aec5213dc668ee51c2a40eab2ba0718c.png"},86074:(e,t,o)=>{o.r(t),o.d(t,{CH:()=>l,assets:()=>d,chCodeConfig:()=>m,contentTitle:()=>h,default:()=>g,frontMatter:()=>a,metadata:()=>n,toc:()=>p});const n=JSON.parse('{"id":"Sample-Flows/memory-chatbot","title":"Memory chatbot","description":"This flow extends the basic prompting flow with a Chat memory component that stores up to 100 previous chat messages and uses them to provide context for the current conversation.","source":"@site/docs/Sample-Flows/memory-chatbot.md","sourceDirName":"Sample-Flows","slug":"/memory-chatbot","permalink":"/memory-chatbot","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Memory chatbot","slug":"/memory-chatbot"},"sidebar":"docs","previous":{"title":"Document QA","permalink":"/document-qa"},"next":{"title":"Sequential tasks agent","permalink":"/sequential-agent"}}');var s=o(74848),r=o(28453),i=o(24754),c=o(84443);const a={title:"Memory chatbot",slug:"/memory-chatbot"},h=void 0,d={},l={annotations:i.hk,Code:i.Cy},m={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the memory chatbot flow",id:"create-the-memory-chatbot-flow",level:2},{value:"Run the memory chatbot flow",id:"run-the-memory-chatbot-flow",level:2},{value:"Use Session ID with the memory chatbot flow",id:"use-session-id-with-the-memory-chatbot-flow",level:2}];function u(e){const t={a:"a",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return l||x("CH",!1),l.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.jsxs)(t.p,{children:["This flow extends the ",(0,s.jsx)(t.a,{href:"/starter-projects-basic-prompting",children:"basic prompting flow"})," with a ",(0,s.jsx)(t.strong,{children:"Chat memory"})," component that stores up to 100 previous chat messages and uses them to provide context for the current conversation."]}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"create-the-memory-chatbot-flow",children:"Create the memory chatbot flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["From the Langflow dashboard, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Select ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"})," flow is created."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:o(97829).A+"",width:"2662",height:"1372"})}),"\n",(0,s.jsxs)(t.p,{children:["This flow adds a ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component to the Basic Prompting flow.\nThis component retrieves previous messages and sends them to the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to fill a part of the ",(0,s.jsx)(t.strong,{children:"Template"})," with context."]}),"\n",(0,s.jsxs)(t.p,{children:["To examine the template, click the ",(0,s.jsx)(t.strong,{children:"Template"})," field in the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component.\nThe ",(0,s.jsx)(t.strong,{children:"Prompt"})," tells the ",(0,s.jsx)(t.strong,{children:"OpenAI model"})," component how to respond to input."]}),"\n",(0,s.jsx)(l.Code,{codeConfig:m,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"You are a helpful assistant that answers questions.",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"Use markdown to format your answer, properly embedding images and urls.",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"History:",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{memory}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["The ",(0,s.jsx)(t.code,{children:"{memory}"})," code in the prompt creates a new input port in the component called ",(0,s.jsx)(t.strong,{children:"memory"}),".\nThe ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component is connected to this port to store chat messages from the ",(0,s.jsx)(t.strong,{children:"Playground"}),", and provide the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component with a memory of previous chat messages."]}),"\n",(0,s.jsx)(t.h2,{id:"run-the-memory-chatbot-flow",children:"Run the memory chatbot flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Open the ",(0,s.jsx)(t.strong,{children:"Playground"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Enter multiple questions. For example, try entering this conversation:"}),"\n"]}),"\n",(0,s.jsx)(l.Code,{codeConfig:m,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Hi, my name is Luca.",props:{}}]},{tokens:[{content:"Please tell me about PostgreSQL.",props:{}}]},{tokens:[{content:"What is my name?",props:{}}]},{tokens:[{content:"What is the second subject I asked you about?",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.p,{children:"The chatbot remembers your name and previous questions."}),"\n",(0,s.jsxs)(t.ol,{start:"3",children:["\n",(0,s.jsxs)(t.li,{children:["To view the ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane, click ",(0,s.jsx)(c.A,{name:"Ellipsis","aria-label":"Horizontal ellipsis"}),", and then click ",(0,s.jsx)(t.strong,{children:"Message Logs"}),".\nThe ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane displays all previous messages, with each conversation sorted by ",(0,s.jsx)(t.code,{children:"session_id"}),"."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:o(85629).A+"",width:"3250",height:"1778"})}),"\n",(0,s.jsx)(t.h2,{id:"use-session-id-with-the-memory-chatbot-flow",children:"Use Session ID with the memory chatbot flow"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)(t.code,{children:"session_id"})," is a unique identifier in Langflow that stores conversation sessions between the AI and a user. A ",(0,s.jsx)(t.code,{children:"session_id"})," is created when a conversation is initiated, and then associated with all subsequent messages during that session."]}),"\n",(0,s.jsxs)(t.p,{children:["In the ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"})," flow you created, the ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component references past interactions by ",(0,s.jsx)(t.strong,{children:"Session ID"}),". You can demonstrate this by modifying the ",(0,s.jsx)(t.strong,{children:"Session ID"})," value to switch between conversation histories."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Session ID"})," field of the ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," and ",(0,s.jsx)(t.strong,{children:"Chat Input"})," components, add a ",(0,s.jsx)(t.strong,{children:"Session ID"})," value like ",(0,s.jsx)(t.code,{children:"MySessionID"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Now, once you send a new message the ",(0,s.jsx)(t.strong,{children:"Playground"}),", you should have a new memory created in the ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane."]}),"\n",(0,s.jsx)(t.li,{children:"Notice how your conversation is being stored in different memory sessions."}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["Learn more about chat memories in the ",(0,s.jsx)(t.a,{href:"/components-memories",children:"Memory"})," section."]})]})}function g(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(u,{...e})}):u(e)}function x(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},97829:(e,t,o)=>{o.d(t,{A:()=>n});const n=o.p+"assets/images/starter-flow-memory-chatbot-af37fecb79d125009712e4c1128bc461.png"}}]); \ No newline at end of file diff --git a/assets/js/de94873f.b0c08d42.js b/assets/js/de94873f.b0c08d42.js deleted file mode 100644 index 73b66deacd..0000000000 --- a/assets/js/de94873f.b0c08d42.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[1841],{84443:(e,t,o)=>{o.d(t,{A:()=>r});o(96540);var n=o(64058),s=o(74848);function r(e){let{name:t,...o}=e;const r=n[t];return r?(0,s.jsx)(r,{...o}):null}},85629:(e,t,o)=>{o.d(t,{A:()=>n});const n=o.p+"assets/images/messages-logs-aec5213dc668ee51c2a40eab2ba0718c.png"},86074:(e,t,o)=>{o.r(t),o.d(t,{CH:()=>l,assets:()=>d,chCodeConfig:()=>m,contentTitle:()=>h,default:()=>u,frontMatter:()=>a,metadata:()=>n,toc:()=>p});const n=JSON.parse('{"id":"Sample-Flows/memory-chatbot","title":"Memory chatbot","description":"This flow extends the basic prompting flow with a Chat memory component that stores up to 100 previous chat messages and uses them to provide context for the current conversation.","source":"@site/docs/Sample-Flows/memory-chatbot.md","sourceDirName":"Sample-Flows","slug":"/memory-chatbot","permalink":"/memory-chatbot","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Memory chatbot","slug":"/memory-chatbot"},"sidebar":"docs","previous":{"title":"Document QA","permalink":"/document-qa"},"next":{"title":"Math agent","permalink":"/math-agent"}}');var s=o(74848),r=o(28453),i=o(24754),c=o(84443);const a={title:"Memory chatbot",slug:"/memory-chatbot"},h=void 0,d={},l={annotations:i.hk,Code:i.Cy},m={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},p=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the memory chatbot flow",id:"create-the-memory-chatbot-flow",level:2},{value:"Run the memory chatbot flow",id:"run-the-memory-chatbot-flow",level:2},{value:"Use Session ID with the memory chatbot flow",id:"use-session-id-with-the-memory-chatbot-flow",level:2}];function g(e){const t={a:"a",code:"code",h2:"h2",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,r.R)(),...e.components};return l||x("CH",!1),l.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.jsxs)(t.p,{children:["This flow extends the ",(0,s.jsx)(t.a,{href:"/starter-projects-basic-prompting",children:"basic prompting flow"})," with a ",(0,s.jsx)(t.strong,{children:"Chat memory"})," component that stores up to 100 previous chat messages and uses them to provide context for the current conversation."]}),"\n",(0,s.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,s.jsxs)(t.ul,{children:["\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"/get-started-installation",children:"Langflow installed and running"})}),"\n",(0,s.jsx)(t.li,{children:(0,s.jsx)(t.a,{href:"https://platform.openai.com/",children:"OpenAI API key created"})}),"\n"]}),"\n",(0,s.jsx)(t.h2,{id:"create-the-memory-chatbot-flow",children:"Create the memory chatbot flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["From the Langflow dashboard, click ",(0,s.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Select ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["The ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"})," flow is created."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:o(97829).A+"",width:"2662",height:"1372"})}),"\n",(0,s.jsxs)(t.p,{children:["This flow adds a ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component to the Basic Prompting flow.\nThis component retrieves previous messages and sends them to the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component to fill a part of the ",(0,s.jsx)(t.strong,{children:"Template"})," with context."]}),"\n",(0,s.jsxs)(t.p,{children:["To examine the template, click the ",(0,s.jsx)(t.strong,{children:"Template"})," field in the ",(0,s.jsx)(t.strong,{children:"Prompt"})," component.\nThe ",(0,s.jsx)(t.strong,{children:"Prompt"})," tells the ",(0,s.jsx)(t.strong,{children:"OpenAI model"})," component how to respond to input."]}),"\n",(0,s.jsx)(l.Code,{codeConfig:m,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"You are a helpful assistant that answers questions.",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"Use markdown to format your answer, properly embedding images and urls.",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"History:",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{memory}",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsxs)(t.p,{children:["The ",(0,s.jsx)(t.code,{children:"{memory}"})," code in the prompt creates a new input port in the component called ",(0,s.jsx)(t.strong,{children:"memory"}),".\nThe ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component is connected to this port to store chat messages from the ",(0,s.jsx)(t.strong,{children:"Playground"}),"."]}),"\n",(0,s.jsxs)(t.p,{children:["This gives the ",(0,s.jsx)(t.strong,{children:"OpenAI"})," component a memory of previous chat messages."]}),"\n",(0,s.jsx)(t.h2,{id:"run-the-memory-chatbot-flow",children:"Run the memory chatbot flow"}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["Open the ",(0,s.jsx)(t.strong,{children:"Playground"}),"."]}),"\n",(0,s.jsx)(t.li,{children:"Type multiple questions. For example, try entering this conversation:"}),"\n"]}),"\n",(0,s.jsx)(l.Code,{codeConfig:m,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Hi, my name is Luca.",props:{}}]},{tokens:[{content:"Please tell me about PostgreSQL.",props:{}}]},{tokens:[{content:"What is my name?",props:{}}]},{tokens:[{content:"What is the second subject I asked you about?",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,s.jsx)(t.p,{children:"The chatbot remembers your name and previous questions."}),"\n",(0,s.jsxs)(t.ol,{start:"3",children:["\n",(0,s.jsxs)(t.li,{children:["To view the ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane, click ",(0,s.jsx)(c.A,{name:"Ellipsis","aria-label":"Horizontal ellipsis"}),", and then click ",(0,s.jsx)(t.strong,{children:"Message Logs"}),".\nThe ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane displays all previous messages, with each conversation sorted by ",(0,s.jsx)(t.code,{children:"session_id"}),"."]}),"\n"]}),"\n",(0,s.jsx)(t.p,{children:(0,s.jsx)(t.img,{src:o(85629).A+"",width:"3250",height:"1778"})}),"\n",(0,s.jsx)(t.h2,{id:"use-session-id-with-the-memory-chatbot-flow",children:"Use Session ID with the memory chatbot flow"}),"\n",(0,s.jsxs)(t.p,{children:[(0,s.jsx)(t.code,{children:"session_id"})," is a unique identifier in Langflow that stores conversation sessions between the AI and a user. A ",(0,s.jsx)(t.code,{children:"session_id"})," is created when a conversation is initiated, and then associated with all subsequent messages during that session."]}),"\n",(0,s.jsxs)(t.p,{children:["In the ",(0,s.jsx)(t.strong,{children:"Memory Chatbot"})," flow you created, the ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," component references past interactions by ",(0,s.jsx)(t.strong,{children:"Session ID"}),". You can demonstrate this by modifying the ",(0,s.jsx)(t.strong,{children:"Session ID"})," value to switch between conversation histories."]}),"\n",(0,s.jsxs)(t.ol,{children:["\n",(0,s.jsxs)(t.li,{children:["In the ",(0,s.jsx)(t.strong,{children:"Session ID"})," field of the ",(0,s.jsx)(t.strong,{children:"Chat Memory"})," and ",(0,s.jsx)(t.strong,{children:"Chat Input"})," components, add a ",(0,s.jsx)(t.strong,{children:"Session ID"})," value like ",(0,s.jsx)(t.code,{children:"MySessionID"}),"."]}),"\n",(0,s.jsxs)(t.li,{children:["Now, once you send a new message the ",(0,s.jsx)(t.strong,{children:"Playground"}),", you should have a new memory created in the ",(0,s.jsx)(t.strong,{children:"Message Logs"})," pane."]}),"\n",(0,s.jsx)(t.li,{children:"Notice how your conversation is being stored in different memory sessions."}),"\n"]}),"\n",(0,s.jsxs)(t.p,{children:["Learn more about chat memories in the ",(0,s.jsx)(t.a,{href:"/components-memories",children:"Memory"})," section."]})]})}function u(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(g,{...e})}):g(e)}function x(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},97829:(e,t,o)=>{o.d(t,{A:()=>n});const n=o.p+"assets/images/starter-flow-memory-chatbot-af37fecb79d125009712e4c1128bc461.png"}}]); \ No newline at end of file diff --git a/assets/js/e5eb12ce.637025ee.js b/assets/js/e5eb12ce.637025ee.js new file mode 100644 index 0000000000..afb852462e --- /dev/null +++ b/assets/js/e5eb12ce.637025ee.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8977],{1272:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-blog-writer-410606fc158b41f5c719c5801801befb.png"},8940:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>a,assets:()=>d,chCodeConfig:()=>h,contentTitle:()=>l,default:()=>u,frontMatter:()=>c,metadata:()=>o,toc:()=>g});const o=JSON.parse('{"id":"Sample-Flows/blog-writer","title":"Blog writer","description":"Build a Blog Writer flow for a one-shot application using OpenAI.","source":"@site/docs/Sample-Flows/blog-writer.md","sourceDirName":"Sample-Flows","slug":"/blog-writer","permalink":"/blog-writer","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Blog writer","slug":"/blog-writer"},"sidebar":"docs","previous":{"title":"Simple agent","permalink":"/starter-projects-simple-agent"},"next":{"title":"Document QA","permalink":"/document-qa"}}');var r=n(74848),s=n(28453),i=n(24754);const c={title:"Blog writer",slug:"/blog-writer"},l=void 0,d={},a={annotations:i.hk,Code:i.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the blog writer flow",id:"create-the-blog-writer-flow",level:2},{value:"Run the blog writer flow",id:"run-the-blog-writer-flow",level:3}];function p(e){const t={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,s.R)(),...e.components};return a||f("CH",!1),a.Code||f("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)(t.p,{children:"Build a Blog Writer flow for a one-shot application using OpenAI."}),"\n",(0,r.jsxs)(t.p,{children:["This flow extends the Basic Prompting flow with the ",(0,r.jsx)(t.strong,{children:"URL"})," and ",(0,r.jsx)(t.strong,{children:"Parser"})," components that fetch content from multiple URLs and convert the loaded data into plain text."]}),"\n",(0,r.jsxs)(t.p,{children:["OpenAI uses this loaded data to generate a blog post, as instructed by the ",(0,r.jsx)(t.strong,{children:"Text Input"})," and ",(0,r.jsx)(t.strong,{children:"Prompt"})," components."]}),"\n",(0,r.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"/get-started-installation",children:"A running Langflow instance"})}),"\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"create-the-blog-writer-flow",children:"Create the blog writer flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["From the Langflow dashboard, click ",(0,r.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["Select ",(0,r.jsx)(t.strong,{children:"Blog Writer"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Blog Writer"})," flow is created."]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{src:n(1272).A+"",width:"2948",height:"1324"})}),"\n",(0,r.jsxs)(t.p,{children:["This flow creates a blog article generator with ",(0,r.jsx)(t.strong,{children:"Prompt"}),", ",(0,r.jsx)(t.strong,{children:"OpenAI"}),", and ",(0,r.jsx)(t.strong,{children:"Chat Output"})," components, augmented with reference content and instructions from the ",(0,r.jsx)(t.strong,{children:"URL"})," and ",(0,r.jsx)(t.strong,{children:"Text Input"})," components."]}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," component extracts raw text and metadata from one or more web links.\nThe ",(0,r.jsx)(t.strong,{children:"Parser"})," component converts the data coming from the ",(0,r.jsx)(t.strong,{children:"URL"})," component into plain text to feed the prompt."]}),"\n",(0,r.jsxs)(t.p,{children:["To examine the flow's prompt, click the ",(0,r.jsx)(t.strong,{children:"Template"})," field of the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component."]}),"\n",(0,r.jsx)(a.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Reference 1:",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{references}",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"---",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{instructions}",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"Blog:",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.code,{children:"{instructions}"})," value is received from the ",(0,r.jsx)(t.strong,{children:"Text Input"})," component, and one or more ",(0,r.jsx)(t.code,{children:"{references}"})," are received from a list of URLs parsed from the ",(0,r.jsx)(t.strong,{children:"URL"})," component."]}),"\n",(0,r.jsx)(t.h3,{id:"run-the-blog-writer-flow",children:"Run the blog writer flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Click the ",(0,r.jsx)(t.strong,{children:"Playground"})," button, and then click ",(0,r.jsx)(t.strong,{children:"Run Flow"}),".\nA blog post about Langflow is generated, with content sourced from ",(0,r.jsx)(t.code,{children:"langflow.org"})," and ",(0,r.jsx)(t.code,{children:"docs.langflow.org"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["To write about something different, change the values in the ",(0,r.jsx)(t.strong,{children:"URL"})," component and adjust the instructions on the left side bar of the ",(0,r.jsx)(t.strong,{children:"Playground"}),". Try again and see what the LLM constructs."]}),"\n"]})]})}function u(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(p,{...e})}):p(e)}function f(e,t){throw new Error("Expected "+(t?"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/e5eb12ce.9ef48378.js b/assets/js/e5eb12ce.9ef48378.js deleted file mode 100644 index 3438084e53..0000000000 --- a/assets/js/e5eb12ce.9ef48378.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8977],{1272:(e,t,n)=>{n.d(t,{A:()=>o});const o=n.p+"assets/images/starter-flow-blog-writer-05ef4634a1c68dba46a1144f98116700.png"},8940:(e,t,n)=>{n.r(t),n.d(t,{CH:()=>a,assets:()=>l,chCodeConfig:()=>h,contentTitle:()=>d,default:()=>u,frontMatter:()=>c,metadata:()=>o,toc:()=>g});const o=JSON.parse('{"id":"Sample-Flows/blog-writer","title":"Blog writer","description":"Build a Blog Writer flow for a one-shot application using OpenAI.","source":"@site/docs/Sample-Flows/blog-writer.md","sourceDirName":"Sample-Flows","slug":"/blog-writer","permalink":"/blog-writer","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Blog writer","slug":"/blog-writer"},"sidebar":"docs","previous":{"title":"Simple agent","permalink":"/starter-projects-simple-agent"},"next":{"title":"Document QA","permalink":"/document-qa"}}');var r=n(74848),i=n(28453),s=n(24754);const c={title:"Blog writer",slug:"/blog-writer"},d=void 0,l={},a={annotations:s.hk,Code:s.Cy},h={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},g=[{value:"Prerequisites",id:"prerequisites",level:2},{value:"Create the blog writer flow",id:"create-the-blog-writer-flow",level:2},{value:"Run the blog writer flow",id:"run-the-blog-writer-flow",level:3}];function p(e){const t={a:"a",code:"code",h2:"h2",h3:"h3",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,i.R)(),...e.components};return a||f("CH",!1),a.Code||f("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)(t.p,{children:"Build a Blog Writer flow for a one-shot application using OpenAI."}),"\n",(0,r.jsxs)(t.p,{children:["This flow extends the Basic Prompting flow with the ",(0,r.jsx)(t.strong,{children:"URL"})," and ",(0,r.jsx)(t.strong,{children:"Parse data"})," components that fetch content from multiple URLs and convert the loaded data into plain text."]}),"\n",(0,r.jsxs)(t.p,{children:["OpenAI uses this loaded data to generate a blog post, as instructed by the ",(0,r.jsx)(t.strong,{children:"Text input"})," component."]}),"\n",(0,r.jsx)(t.h2,{id:"prerequisites",children:"Prerequisites"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"/get-started-installation",children:"Langflow installed and running"})}),"\n",(0,r.jsx)(t.li,{children:(0,r.jsx)(t.a,{href:"https://platform.openai.com/",children:"OpenAI API key created"})}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"create-the-blog-writer-flow",children:"Create the blog writer flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["From the Langflow dashboard, click ",(0,r.jsx)(t.strong,{children:"New Flow"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["Select ",(0,r.jsx)(t.strong,{children:"Blog Writer"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["The ",(0,r.jsx)(t.strong,{children:"Blog Writer"})," flow is created."]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{src:n(1272).A+"",width:"2958",height:"1200"})}),"\n",(0,r.jsxs)(t.p,{children:["This flow creates a one-shot article generator with ",(0,r.jsx)(t.strong,{children:"Prompt"}),", ",(0,r.jsx)(t.strong,{children:"OpenAI"}),", and ",(0,r.jsx)(t.strong,{children:"Chat Output"})," components, augmented with reference content and instructions from the ",(0,r.jsx)(t.strong,{children:"URL"})," and ",(0,r.jsx)(t.strong,{children:"Text Input"})," components."]}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," component extracts raw text and metadata from one or more web links.\nThe ",(0,r.jsx)(t.strong,{children:"Parse Data"})," component converts the data coming from the ",(0,r.jsx)(t.strong,{children:"URL"})," component into plain text to feed the prompt."]}),"\n",(0,r.jsxs)(t.p,{children:["To examine the flow's prompt, click the ",(0,r.jsx)(t.strong,{children:"Template"})," field of the ",(0,r.jsx)(t.strong,{children:"Prompt"})," component."]}),"\n",(0,r.jsx)(a.Code,{codeConfig:h,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{tokens:[{content:"Reference 1:",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{references}",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"---",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"{instructions}",props:{}}]},{tokens:[{content:"",props:{}}]},{tokens:[{content:"Blog:",props:{}}]}],lang:"text"},annotations:[]}]}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.code,{children:"{instructions}"})," value is received from the ",(0,r.jsx)(t.strong,{children:"Text input"})," component, and one or more ",(0,r.jsx)(t.code,{children:"{references}"})," are received from a list of URLs parsed from the ",(0,r.jsx)(t.strong,{children:"URL"})," component."]}),"\n",(0,r.jsx)(t.h3,{id:"run-the-blog-writer-flow",children:"Run the blog writer flow"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Click the ",(0,r.jsx)(t.strong,{children:"Playground"})," button, and then click ",(0,r.jsx)(t.strong,{children:"Run Flow"}),".\nA blog post about Langflow is generated, with content sourced from ",(0,r.jsx)(t.code,{children:"langflow.org"})," and ",(0,r.jsx)(t.code,{children:"docs.langflow.org"}),"."]}),"\n",(0,r.jsxs)(t.li,{children:["To write about something different, change the values in the ",(0,r.jsx)(t.strong,{children:"URL"})," component and adjust the instructions on the left side bar of the ",(0,r.jsx)(t.strong,{children:"Playground"}),". Try again and see what the LLM constructs."]}),"\n"]})]})}function u(e={}){const{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(p,{...e})}):p(e)}function f(e,t){throw new Error("Expected "+(t?"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.ec5e1ec0.js b/assets/js/e6c6a4d2.094758b9.js similarity index 56% rename from assets/js/e6c6a4d2.ec5e1ec0.js rename to assets/js/e6c6a4d2.094758b9.js index edcb62e9d8..1b274b7d89 100644 --- a/assets/js/e6c6a4d2.ec5e1ec0.js +++ b/assets/js/e6c6a4d2.094758b9.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.2.0"},"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 \\"Excepteur07c\\": \\"\\",\\n \\"ad5\\": \\"\\",\\n \\"dolor_b82\\": \\"\\",\\n \\"labore9e9\\": \\"\\"\\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.2.0"},"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 \\"veniam_70_\\": \\"\\"\\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/f66238ae.afcec807.js b/assets/js/f66238ae.95fb56ce.js similarity index 99% rename from assets/js/f66238ae.afcec807.js rename to assets/js/f66238ae.95fb56ce.js index 17fd9bc5d6..32529bdb06 100644 --- a/assets/js/f66238ae.afcec807.js +++ b/assets/js/f66238ae.95fb56ce.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[3391],{28453:(e,t,r)=>{r.d(t,{R:()=>i,x:()=>c});var s=r(96540);const d={},n=s.createContext(d);function i(e){const t=s.useContext(n);return s.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:i(e.components),s.createElement(n.Provider,{value:t},e.children)}},42638:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/component-hcd-example-flow-b82057600ce5e9e4a0f7ea0a61dcbf7f.png"},45175:(e,t,r)=>{r.r(t),r.d(t,{assets:()=>h,contentTitle:()=>c,default:()=>o,frontMatter:()=>i,metadata:()=>s,toc:()=>l});const s=JSON.parse('{"id":"Components/components-vector-stores","title":"Vector stores","description":"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation.","source":"@site/docs/Components/components-vector-stores.md","sourceDirName":"Components","slug":"/components-vector-stores","permalink":"/components-vector-stores","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Vector stores","slug":"/components-vector-stores"},"sidebar":"docs","previous":{"title":"Tools","permalink":"/components-tools"},"next":{"title":"Agents overview","permalink":"/agents-overview"}}');var d=r(74848),n=r(28453);const i={title:"Vector stores",slug:"/components-vector-stores"},c="Vector store components in Langflow",h={},l=[{value:"Use a vector store component in a flow",id:"use-a-vector-store-component-in-a-flow",level:2},{value:"Astra DB Vector Store",id:"astra-db-vector-store",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Generate embeddings",id:"generate-embeddings",level:3},{value:"AstraDB Graph vector store",id:"astradb-graph-vector-store",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Cassandra",id:"cassandra",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Cassandra Graph Vector Store",id:"cassandra-graph-vector-store",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Chroma DB",id:"chroma-db",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Clickhouse",id:"clickhouse",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"Couchbase",id:"couchbase",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"Elasticsearch",id:"elasticsearch",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"FAISS",id:"faiss",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3},{value:"Graph RAG",id:"graph-rag",level:2},{value:"Inputs",id:"inputs-9",level:3},{value:"Outputs",id:"outputs-9",level:3},{value:"Hyper-Converged Database (HCD) Vector Store",id:"hyper-converged-database-hcd-vector-store",level:2},{value:"Inputs",id:"inputs-10",level:3},{value:"Outputs",id:"outputs-10",level:3},{value:"Milvus",id:"milvus",level:2},{value:"Inputs",id:"inputs-11",level:3},{value:"Outputs",id:"outputs-11",level:3},{value:"MongoDB Atlas",id:"mongodb-atlas",level:2},{value:"Inputs",id:"inputs-12",level:3},{value:"Outputs",id:"outputs-12",level:3},{value:"Opensearch",id:"opensearch",level:2},{value:"Inputs",id:"inputs-13",level:3},{value:"Outputs",id:"outputs-13",level:3},{value:"PGVector",id:"pgvector",level:2},{value:"Inputs",id:"inputs-14",level:3},{value:"Outputs",id:"outputs-14",level:3},{value:"Pinecone",id:"pinecone",level:2},{value:"Inputs",id:"inputs-15",level:3},{value:"Outputs",id:"outputs-15",level:3},{value:"Qdrant",id:"qdrant",level:2},{value:"Inputs",id:"inputs-16",level:3},{value:"Outputs",id:"outputs-16",level:3},{value:"Redis",id:"redis",level:2},{value:"Inputs",id:"inputs-17",level:3},{value:"Outputs",id:"outputs-17",level:3},{value:"Supabase",id:"supabase",level:2},{value:"Inputs",id:"inputs-18",level:3},{value:"Outputs",id:"outputs-18",level:3},{value:"Upstash",id:"upstash",level:2},{value:"Inputs",id:"inputs-19",level:3},{value:"Outputs",id:"outputs-19",level:3},{value:"Vectara",id:"vectara",level:2},{value:"Inputs",id:"inputs-20",level:3},{value:"Outputs",id:"outputs-20",level:3},{value:"Vectara Search",id:"vectara-search",level:2},{value:"Inputs",id:"inputs-21",level:3},{value:"Outputs",id:"outputs-21",level:3},{value:"Weaviate",id:"weaviate",level:2},{value:"Inputs",id:"inputs-22",level:3},{value:"Outputs",id:"outputs-22",level:3},{value:"Weaviate Search",id:"weaviate-search",level:2},{value:"Inputs",id:"inputs-23",level:3},{value:"Outputs",id:"outputs-23",level:3}];function a(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,n.R)(),...e.components};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(t.header,{children:(0,d.jsx)(t.h1,{id:"vector-store-components-in-langflow",children:"Vector store components in Langflow"})}),"\n",(0,d.jsx)(t.p,{children:"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation."}),"\n",(0,d.jsx)(t.p,{children:"Vector database components establish connections to existing vector databases or create in-memory vector stores for storing and retrieving vector data."}),"\n",(0,d.jsxs)(t.p,{children:["Vector database components are distinct from ",(0,d.jsx)(t.a,{href:"/components-memories",children:"memory components"}),", which are built specifically for storing and retrieving chat messages from external databases."]}),"\n",(0,d.jsx)(t.h2,{id:"use-a-vector-store-component-in-a-flow",children:"Use a vector store component in a flow"}),"\n",(0,d.jsxs)(t.p,{children:["This example uses the ",(0,d.jsx)(t.strong,{children:"Astra DB vector store"})," component. Your vector store component's parameters and authentication may be different, but the document ingestion workflow is the same. A document is loaded from a local machine and chunked. The Astra DB vector store generates embeddings with the connected ",(0,d.jsx)(t.a,{href:"/components-models",children:"model"})," component, and stores them in the connected Astra DB database."]}),"\n",(0,d.jsx)(t.p,{children:"This vector data can then be retrieved for workloads like Retrieval Augmented Generation."}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{src:r(67719).A+"",width:"2898",height:"1110"})}),"\n",(0,d.jsxs)(t.p,{children:["The user's chat input is embedded and compared to the vectors embedded during document ingestion for a similarity search.\nThe results are output from the vector database component as a ",(0,d.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object and parsed into text.\nThis text fills the ",(0,d.jsx)(t.code,{children:"{context}"})," variable in the ",(0,d.jsx)(t.strong,{children:"Prompt"})," component, which informs the ",(0,d.jsx)(t.strong,{children:"Open AI model"})," component's responses."]}),"\n",(0,d.jsxs)(t.p,{children:["Alternatively, connect the vector database component's ",(0,d.jsx)(t.strong,{children:"Retriever"})," port to a ",(0,d.jsx)(t.a,{href:"components-tools#retriever-tool",children:"retriever tool"}),", and then to an ",(0,d.jsx)(t.a,{href:"/components-agents",children:"agent"})," component. This enables the agent to use your vector database as a tool and make decisions based on the available data."]}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{src:r(59072).A+"",width:"2414",height:"1602"})}),"\n",(0,d.jsx)(t.h2,{id:"astra-db-vector-store",children:"Astra DB Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Vector Store using Astra DB with search capabilities."}),"\n",(0,d.jsxs)(t.p,{children:["For more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/create-database.html",children:"DataStax documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Astra DB Application Token"}),(0,d.jsx)(t.td,{children:"The authentication token for accessing Astra DB."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"environment"}),(0,d.jsx)(t.td,{children:"Environment"}),(0,d.jsxs)(t.td,{children:["The environment for the Astra DB API Endpoint. For example, ",(0,d.jsx)(t.code,{children:"dev"})," or ",(0,d.jsx)(t.code,{children:"prod"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_name"}),(0,d.jsx)(t.td,{children:"Database"}),(0,d.jsx)(t.td,{children:"The database name for the Astra DB instance."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"Astra DB API Endpoint"}),(0,d.jsx)(t.td,{children:"The API endpoint for the Astra DB instance. This supersedes the database selection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection"}),(0,d.jsx)(t.td,{children:"The name of the collection within Astra DB where the vectors are stored."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"Keyspace"}),(0,d.jsx)(t.td,{children:"An optional keyspace within Astra DB to use for the collection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_choice"}),(0,d.jsx)(t.td,{children:"Embedding Model or Astra Vectorize"}),(0,d.jsx)(t.td,{children:"Choose an embedding model or use Astra vectorize."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_model"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsx)(t.td,{children:"Specify the embedding model. Not required for Astra vectorize collections."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Search Results"}),(0,d.jsxs)(t.td,{children:["The number of search results to return (default: ",(0,d.jsx)(t.code,{children:"4"}),")."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsxs)(t.td,{children:["The search type to use. The options are ",(0,d.jsx)(t.code,{children:"Similarity"}),", ",(0,d.jsx)(t.code,{children:"Similarity with score threshold"}),", and ",(0,d.jsx)(t.code,{children:"MMR (Max Marginal Relevance)"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsxs)(t.td,{children:["The minimum similarity score threshold for search results when using the ",(0,d.jsx)(t.code,{children:"Similarity with score threshold"})," option."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"advanced_search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"An optional dictionary of filters to apply to the search query."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"autodetect_collection"}),(0,d.jsx)(t.td,{children:"Autodetect Collection"}),(0,d.jsx)(t.td,{children:"A boolean flag to determine whether to autodetect the collection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"content_field"}),(0,d.jsx)(t.td,{children:"Content Field"}),(0,d.jsx)(t.td,{children:"A field to use as the text content field for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"deletion_field"}),(0,d.jsx)(t.td,{children:"Deletion Based On Field"}),(0,d.jsx)(t.td,{children:"When provided, documents in the target collection with metadata field values matching the input metadata field value are deleted before new data is loaded."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ignore_invalid_documents"}),(0,d.jsx)(t.td,{children:"Ignore Invalid Documents"}),(0,d.jsx)(t.td,{children:"A boolean flag to determine whether to ignore invalid documents at runtime."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"astradb_vectorstore_kwargs"}),(0,d.jsx)(t.td,{children:"AstraDBVectorStore Parameters"}),(0,d.jsx)(t.td,{children:"An optional dictionary of additional parameters for the AstraDBVectorStore."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Astra DB vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.a,{href:"/concepts-objects#data-object",children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"generate-embeddings",children:"Generate embeddings"}),"\n",(0,d.jsxs)(t.p,{children:["The ",(0,d.jsx)(t.strong,{children:"Astra DB Vector Store"})," component offers two methods for generating embeddings."]}),"\n",(0,d.jsxs)(t.ol,{children:["\n",(0,d.jsxs)(t.li,{children:["\n",(0,d.jsxs)(t.p,{children:[(0,d.jsx)(t.strong,{children:"Embedding Model"}),": Use your own embedding model by connecting an ",(0,d.jsx)(t.a,{href:"/components-embedding-models",children:"Embeddings"})," component in Langflow."]}),"\n"]}),"\n",(0,d.jsxs)(t.li,{children:["\n",(0,d.jsxs)(t.p,{children:[(0,d.jsx)(t.strong,{children:"Astra Vectorize"}),": Use Astra DB's built-in embedding generation service. When creating a new collection, choose the embeddings provider and models, including NVIDIA's ",(0,d.jsx)(t.code,{children:"NV-Embed-QA"})," model hosted by Datastax."]}),"\n"]}),"\n"]}),"\n",(0,d.jsx)(t.admonition,{type:"important",children:(0,d.jsx)(t.p,{children:"The embedding model selection is made when creating a new collection and cannot be changed later."})}),"\n",(0,d.jsxs)(t.p,{children:["For an example of using the ",(0,d.jsx)(t.strong,{children:"Astra DB Vector Store"})," component with an embedding model, see the ",(0,d.jsx)(t.a,{href:"/starter-projects-vector-store-rag",children:"Vector Store RAG starter project"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["For more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Astra DB Serverless documentation"}),"."]}),"\n",(0,d.jsx)(t.h2,{id:"astradb-graph-vector-store",children:"AstraDB Graph vector store"}),"\n",(0,d.jsxs)(t.p,{children:["This component implements a Vector Store using AstraDB with graph capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/tutorials/graph-rag.html",children:"Astra DB Serverless documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection Name"}),(0,d.jsx)(t.td,{children:"The name of the collection within AstraDB where the vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Astra DB Application Token"}),(0,d.jsx)(t.td,{children:"Authentication token for accessing AstraDB (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"API Endpoint"}),(0,d.jsx)(t.td,{children:"API endpoint URL for the AstraDB service (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"Search Input"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"Namespace"}),(0,d.jsx)(t.td,{children:"Optional namespace within AstraDB to use for the collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"Metric"}),(0,d.jsx)(t.td,{children:'Distance metric for vector comparisons (options: "cosine", "euclidean", "dot_product")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the vector store (options: "Sync", "Async", "Off")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Pre Delete Collection"}),(0,d.jsx)(t.td,{children:"Boolean flag to determine whether to delete the collection before creating a new one"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Similarity", "Graph Traversal", "Hybrid")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"traversal_depth"}),(0,d.jsx)(t.td,{children:"Traversal Depth"}),(0,d.jsx)(t.td,{children:"Maximum depth for graph traversal searches (default: 1)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Astra DB graph vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"cassandra",children:"Cassandra"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Cassandra Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://cassandra.apache.org/doc/latest/cassandra/vector-search/overview.html",children:"Cassandra documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_ref"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Contact points for the database or AstraDB database ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Username for the database (leave empty for AstraDB)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"User password for the database or AstraDB token"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Table Keyspace or AstraDB namespace"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the table or AstraDB collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ttl_seconds"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Time-to-live for added texts"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Configuration mode for setting up the Cassandra table"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"cluster_kwargs"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Additional keyword arguments for the Cassandra cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Type of search to perform"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Metadata filters for search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"body_search"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Document textual search terms"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"enable_body_search"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Flag to enable body search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Cassandra"}),(0,d.jsx)(t.td,{children:"A Cassandra vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"cassandra-graph-vector-store",children:"Cassandra Graph Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Cassandra Graph Vector Store with search capabilities."}),"\n",(0,d.jsx)(t.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_ref"}),(0,d.jsx)(t.td,{children:"Contact Points / Astra Database ID"}),(0,d.jsx)(t.td,{children:"Contact points for the database or AstraDB database ID (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"Username"}),(0,d.jsx)(t.td,{children:"Username for the database (leave empty for AstraDB)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Password / AstraDB Token"}),(0,d.jsx)(t.td,{children:"User password for the database or AstraDB token (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"Keyspace"}),(0,d.jsx)(t.td,{children:"Table Keyspace or AstraDB namespace (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"Table Name"}),(0,d.jsx)(t.td,{children:"The name of the table or AstraDB collection where vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the Cassandra table (options: "Sync", "Off", default: "Sync")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"cluster_kwargs"}),(0,d.jsx)(t.td,{children:"Cluster arguments"}),(0,d.jsx)(t.td,{children:"Optional dictionary of additional keyword arguments for the Cassandra cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store (list of Data objects)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Traversal", "MMR traversal", "Similarity", "Similarity with score threshold", "MMR (Max Marginal Relevance)", default: "Traversal")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"depth"}),(0,d.jsx)(t.td,{children:"Depth of traversal"}),(0,d.jsx)(t.td,{children:'The maximum depth of edges to traverse (for "Traversal" or "MMR traversal" search types, default: 1)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:'Minimum similarity score threshold for search results (for "Similarity with score threshold" search type)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"A Cassandra Graph vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"chroma-db",children:"Chroma DB"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Chroma Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.trychroma.com/",children:"Chroma documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The name of the Chroma collection. Default: "langflow".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"persist_directory"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The directory to persist the Chroma database."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_cors_allow_origins"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"CORS allow origins for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_host"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Host for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_http_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"HTTP port for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_grpc_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"gRPC port for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_ssl_enabled"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Enable SSL for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"allow_duplicates"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Allow duplicate documents in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search to perform: "Similarity" or "MMR".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 10."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"limit"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Limit the number of records to compare when Allow Duplicates is False."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Chroma"}),(0,d.jsx)(t.td,{children:"Chroma vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"clickhouse",children:"Clickhouse"}),"\n",(0,d.jsxs)(t.p,{children:["This component implements a Clickhouse Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://clickhouse.com/docs/en/intro",children:"CLickhouse Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"host"}),(0,d.jsx)(t.td,{children:"hostname"}),(0,d.jsx)(t.td,{children:'Clickhouse server hostname (required, default: "localhost")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"Clickhouse server port (required, default: 8123)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database"}),(0,d.jsx)(t.td,{children:"database"}),(0,d.jsx)(t.td,{children:"Clickhouse database name (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table"}),(0,d.jsx)(t.td,{children:"Table name"}),(0,d.jsx)(t.td,{children:"Clickhouse table name (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"The ClickHouse user name."}),(0,d.jsx)(t.td,{children:"Username for authentication (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"The password for username."}),(0,d.jsx)(t.td,{children:"Password for authentication (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_type"}),(0,d.jsx)(t.td,{children:"index_type"}),(0,d.jsx)(t.td,{children:'Type of the index (options: "annoy", "vector_similarity", default: "annoy")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:'Metric to compute distance (options: "angular", "euclidean", "manhattan", "hamming", "dot", default: "angular")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"secure"}),(0,d.jsx)(t.td,{children:"Use https/TLS"}),(0,d.jsx)(t.td,{children:"Overrides inferred values from the interface or port arguments (default: false)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_param"}),(0,d.jsx)(t.td,{children:"Param of the index"}),(0,d.jsx)(t.td,{children:"Index parameters (default: \"'L2Distance',100\")"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_query_params"}),(0,d.jsx)(t.td,{children:"index query params"}),(0,d.jsx)(t.td,{children:"Additional index query parameters"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"score_threshold"}),(0,d.jsx)(t.td,{children:"Score threshold"}),(0,d.jsx)(t.td,{children:"Threshold for similarity scores"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Built Clickhouse vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsx)(t.td,{children:"Results of the similarity search as a list of Data objects"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"couchbase",children:"Couchbase"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Couchbase Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.couchbase.com/home/index.html",children:"Couchbase documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_connection_string"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Couchbase Cluster connection string (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Couchbase username (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Couchbase password (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bucket_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase bucket (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"scope_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase scope (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase collection (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase index (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 4 (advanced)."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"CouchbaseVectorStore"}),(0,d.jsx)(t.td,{children:"A Couchbase vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"elasticsearch",children:"Elasticsearch"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Elasticsearch Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://www.elastic.co/guide/en/elasticsearch/reference/current/dense-vector.html",children:"Elasticsearch documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Elasticsearch server URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_user"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Username for Elasticsearch authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Password for Elasticsearch authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Elasticsearch index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Strategy for vector search ("approximate_k_nearest_neighbors" or "script_scoring")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Strategy for distance calculation ("COSINE", "EUCLIDEAN_DISTANCE", "DOT_PRODUCT")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search (default: 4)"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"ElasticsearchStore"}),(0,d.jsx)(t.td,{children:"Elasticsearch vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"faiss",children:"FAISS"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a FAISS Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://faiss.ai/index.html",children:"FAISS documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The name of the FAISS index. Default: "langflow_index".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"persist_directory"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Path to save the FAISS index. It will be relative to where Langflow is running."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects or documents)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"allow_dangerous_deserialization"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Set to True to allow loading pickle files from untrusted sources. Default: True (advanced)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 4 (advanced)."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"FAISS"}),(0,d.jsx)(t.td,{children:"A FAISS vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"graph-rag",children:"Graph RAG"}),"\n",(0,d.jsxs)(t.p,{children:["This component performs Graph RAG (Retrieval Augmented Generation) traversal in a vector store, enabling graph-based document retrieval.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/",children:"Graph RAG documentation"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["For an example flow, see the ",(0,d.jsx)(t.strong,{children:"Graph RAG"})," template."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-9",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_model"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsxs)(t.td,{children:["Specify the embedding model. This is not required for collections embedded with ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Astra vectorize"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store Connection"}),(0,d.jsx)(t.td,{children:"Connection to the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"edge_definition"}),(0,d.jsx)(t.td,{children:"Edge Definition"}),(0,d.jsxs)(t.td,{children:["Edge definition for the graph traversal. For more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/reference/graph_retriever/edges/",children:"GraphRAG documentation"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"strategy"}),(0,d.jsx)(t.td,{children:"Traversal Strategies"}),(0,d.jsx)(t.td,{children:"The strategy to use for graph traversal. Strategy options are dynamically loaded from available strategies."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"graphrag_strategy_kwargs"}),(0,d.jsx)(t.td,{children:"Strategy Parameters"}),(0,d.jsxs)(t.td,{children:["Optional dictionary of additional parameters for the retrieval strategy. For more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/reference/graph_retriever/strategies/",children:"strategy documentation"}),"."]})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-9",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsxs)(t.td,{children:["Results of the graph-based document retrieval as a list of ",(0,d.jsx)(t.a,{href:"/concepts-objects#data-object",children:"Data"})," objects."]})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"hyper-converged-database-hcd-vector-store",children:"Hyper-Converged Database (HCD) Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Vector Store using HCD."}),"\n",(0,d.jsxs)(t.p,{children:["To use the HCD vector store, add your deployment's collection name, username, password, and HCD Data API endpoint.\nThe endpoint must be formatted like ",(0,d.jsx)(t.code,{children:"http[s]://**DOMAIN_NAME** or **IP_ADDRESS**[:port]"}),", for example, ",(0,d.jsx)(t.code,{children:"http://192.0.2.250:8181"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["Replace ",(0,d.jsx)(t.strong,{children:"DOMAIN_NAME"})," or ",(0,d.jsx)(t.strong,{children:"IP_ADDRESS"})," with the domain name or IP address of your HCD Data API connection."]}),"\n",(0,d.jsx)(t.p,{children:"To use the HCD vector store for embeddings ingestion, connect it to an embeddings model and a file loader:"}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{alt:"HCD vector store embeddings ingestion",src:r(42638).A+"",width:"2294",height:"1684"})}),"\n",(0,d.jsx)(t.h3,{id:"inputs-10",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection Name"}),(0,d.jsx)(t.td,{children:"The name of the collection within HCD where the vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"HCD Username"}),(0,d.jsx)(t.td,{children:'Authentication username for accessing HCD (default: "hcd-superuser", required)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"HCD Password"}),(0,d.jsx)(t.td,{children:"Authentication password for accessing HCD (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"HCD API Endpoint"}),(0,d.jsx)(t.td,{children:"API endpoint URL for the HCD service (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"Search Input"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"Namespace"}),(0,d.jsx)(t.td,{children:'Optional namespace within HCD to use for the collection (default: "default_namespace")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ca_certificate"}),(0,d.jsx)(t.td,{children:"CA Certificate"}),(0,d.jsx)(t.td,{children:"Optional CA certificate for TLS connections to HCD"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"Metric"}),(0,d.jsx)(t.td,{children:'Optional distance metric for vector comparisons (options: "cosine", "dot_product", "euclidean")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Batch Size"}),(0,d.jsx)(t.td,{children:"Optional number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_insert_batch_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Insert Batch Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk insert operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_insert_overwrite_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Insert Overwrite Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk insert operations that overwrite existing data"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_delete_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Delete Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk delete operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the vector store (options: "Sync", "Async", "Off", default: "Sync")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Pre Delete Collection"}),(0,d.jsx)(t.td,{children:"Boolean flag to determine whether to delete the collection before creating a new one"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_indexing_include"}),(0,d.jsx)(t.td,{children:"Metadata Indexing Include"}),(0,d.jsx)(t.td,{children:"Optional list of metadata fields to include in the indexing"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding or Astra Vectorize"}),(0,d.jsx)(t.td,{children:"Allows either an embedding model or an Astra Vectorize configuration"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_indexing_exclude"}),(0,d.jsx)(t.td,{children:"Metadata Indexing Exclude"}),(0,d.jsx)(t.td,{children:"Optional list of metadata fields to exclude from the indexing"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_indexing_policy"}),(0,d.jsx)(t.td,{children:"Collection Indexing Policy"}),(0,d.jsx)(t.td,{children:"Optional dictionary defining the indexing policy for the collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Similarity", "Similarity with score threshold", "MMR (Max Marginal Relevance)", default: "Similarity")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results (default: 0)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-10",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsxs)(t.td,{children:["An HCD vector store instance The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"milvus",children:"Milvus"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Milvus Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://milvus.io/docs",children:"Milvus documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-11",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Milvus collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_description"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Description of the Milvus collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"uri"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Connection URI for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Password for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Username for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Type of search to perform"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Metadata filters for search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Configuration mode for setting up the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_dimensions"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of dimensions of the vectors"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Whether to delete the collection before creating a new one"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-11",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Milvus"}),(0,d.jsx)(t.td,{children:"A Milvus vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"mongodb-atlas",children:"MongoDB Atlas"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a MongoDB Atlas Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://www.mongodb.com/docs/atlas/atlas-vector-search/tutorials/vector-search-quick-start/",children:"MongoDB Atlas documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-12",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"mongodb_atlas_cluster_uri"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"The connection URI for your MongoDB Atlas cluster (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"enable_mtls"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Enable mutual TLS authentication (default: false)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"mongodb_atlas_client_cert"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Client certificate combined with private key for mTLS authentication (required if mTLS is enabled)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"db_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the database to use (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the collection to use (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the Atlas Search index, it should be a Vector Search (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"insert_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'How to insert new documents into the collection (options: "append", "overwrite", default: "append")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_field"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The field to index (default: "embedding")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"filter_field"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The field to filter the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_dimensions"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Embedding context length (default: 1536)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"similarity"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The method used to measure similarity between vectors (options: "cosine", "euclidean", "dotProduct", default: "cosine")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"quantization"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Quantization reduces memory costs by converting 32-bit floats to smaller data types (options: "scalar", "binary")'})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-12",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"MongoDBAtlasVectorSearch"}),(0,d.jsx)(t.td,{children:"MongoDB Atlas vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"opensearch",children:"Opensearch"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Opensearch vector store with search capabilities\nFor more information, see ",(0,d.jsx)(t.a,{href:"https://opensearch.org/platform/search/vector-database.html",children:"Opensearch documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-13",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"opensearch_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsxs)(t.td,{children:["URL for OpenSearch cluster (e.g. ",(0,d.jsx)(t.a,{href:"https://192.168.1.1:9200",children:"https://192.168.1.1:9200"}),")"]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The index name where the vectors will be stored in OpenSearch cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Enter a search query. Leave empty to retrieve all documents or if hybrid search is being used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Valid values are "similarity", "similarity_score_threshold", "mmr"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"username for the opensource cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"password for the opensource cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"use_ssl"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Use SSL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"verify_certs"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Verify certificates"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"hybrid_search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Provide a custom hybrid search query in JSON format. This allows you to combine vector similarity and keyword matching"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-13",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"OpenSearchVectorSearch"}),(0,d.jsx)(t.td,{children:"OpenSearch vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"pgvector",children:"PGVector"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a PGVector Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://github.com/pgvector/pgvector",children:"PGVector documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-14",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pg_server_url"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"PostgreSQL server connection string"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Table name for the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-14",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"PGVector"}),(0,d.jsx)(t.td,{children:"PGVector vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"pinecone",children:"Pinecone"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Pinecone Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.pinecone.io/home",children:"Pinecone documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-15",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Pinecone index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Namespace for the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Strategy for calculating distance between vectors"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pinecone_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"API key for Pinecone"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key in the record to use as text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-15",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Pinecone"}),(0,d.jsx)(t.td,{children:"Pinecone vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"qdrant",children:"Qdrant"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Qdrant Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://qdrant.tech/documentation/",children:"Qdrant documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-16",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Qdrant collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"host"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Qdrant server host"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Qdrant server port"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"grpc_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Qdrant gRPC port"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"API key for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"prefix"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Prefix for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"timeout"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Timeout for Qdrant operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"path"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Path for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"URL for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_func"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Distance function for vector similarity"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"content_payload_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key for content payload"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_payload_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key for metadata payload"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-16",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Qdrant"}),(0,d.jsx)(t.td,{children:"Qdrant vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"redis",children:"Redis"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Redis Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://redis.io/docs/latest/develop/interact/search-and-query/advanced-concepts/vectors/",children:"Redis documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-17",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"redis_server_url"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Redis server connection string"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"redis_index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Redis index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"code"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Custom code for Redis (advanced)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"schema"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Schema for Redis index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-17",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Redis"}),(0,d.jsx)(t.td,{children:"Redis vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"supabase",children:"Supabase"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a connection to a Supabase Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://supabase.com/docs/guides/ai",children:"Supabase documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-18",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"supabase_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"URL of the Supabase instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"supabase_service_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Service key for Supabase authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the table in Supabase"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"query_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the query to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-18",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"SupabaseVectorStore"}),(0,d.jsx)(t.td,{children:"Supabase vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"upstash",children:"Upstash"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Upstash Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://upstash.com/docs/introduction",children:"Upstash documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-19",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The URL of the Upstash index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_token"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"The token for the Upstash index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The key in the record to use as text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Namespace for the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_filter"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Filters documents by metadata"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use (optional)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-19",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"UpstashVectorStore"}),(0,d.jsx)(t.td,{children:"Upstash vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"vectara",children:"Vectara"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Vectara Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.vectara.com/docs/",children:"Vectara documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-20",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_customer_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara customer ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_corpus_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara corpus ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Vectara API key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use (optional)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"List[Document/Data]"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-20",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"VectaraVectorStore"}),(0,d.jsx)(t.td,{children:"Vectara vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"vectara-search",children:"Vectara Search"}),"\n",(0,d.jsxs)(t.p,{children:["This component searches a Vectara Vector Store for documents based on the provided input.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.vectara.com/docs/",children:"Vectara documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-21",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search, such as "Similarity" or "MMR"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input_value"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_customer_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara customer ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_corpus_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara corpus ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Vectara API key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"files_url"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional URLs for file initialization"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-21",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"weaviate",children:"Weaviate"}),"\n",(0,d.jsxs)(t.p,{children:["This component facilitates a Weaviate Vector Store setup, optimizing text and document indexing and retrieval.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://weaviate.io/developers/weaviate",children:"Weaviate Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-22",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"weaviate_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default instance URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_by_text"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Indicates whether to search by text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Optional API key for authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Optional index name"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default text extraction key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input"}),(0,d.jsx)(t.td,{children:"Document"}),(0,d.jsx)(t.td,{children:"Document or record"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Model used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"attributes"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional additional attributes"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-22",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"WeaviateVectorStore"}),(0,d.jsx)(t.td,{children:"Weaviate vector store instance"})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"weaviate-search",children:"Weaviate Search"}),"\n",(0,d.jsxs)(t.p,{children:["This component searches a Weaviate Vector Store for documents similar to the input.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://weaviate.io/developers/weaviate",children:"Weaviate Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-23",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search, such as "Similarity" or "MMR"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input_value"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"weaviate_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default instance URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_by_text"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Indicates whether to search by text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Optional API key for authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Optional index name"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default text extraction key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Model used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"attributes"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional additional attributes"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-23",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})})]})]})}function o(e={}){const{wrapper:t}={...(0,n.R)(),...e.components};return t?(0,d.jsx)(t,{...e,children:(0,d.jsx)(a,{...e})}):a(e)}},59072:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/vector-store-agent-retrieval-tool-79066d11008a74c40390f55f7c73bd71.png"},67719:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/vector-store-retrieval-452b8316c734a28f85fcddf9ff7a32e4.png"}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[3391],{28453:(e,t,r)=>{r.d(t,{R:()=>i,x:()=>c});var s=r(96540);const d={},n=s.createContext(d);function i(e){const t=s.useContext(n);return s.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:i(e.components),s.createElement(n.Provider,{value:t},e.children)}},42638:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/component-hcd-example-flow-b82057600ce5e9e4a0f7ea0a61dcbf7f.png"},45175:(e,t,r)=>{r.r(t),r.d(t,{assets:()=>h,contentTitle:()=>c,default:()=>o,frontMatter:()=>i,metadata:()=>s,toc:()=>l});const s=JSON.parse('{"id":"Components/components-vector-stores","title":"Vector stores","description":"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation.","source":"@site/docs/Components/components-vector-stores.md","sourceDirName":"Components","slug":"/components-vector-stores","permalink":"/components-vector-stores","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Vector stores","slug":"/components-vector-stores"},"sidebar":"docs","previous":{"title":"Tools","permalink":"/components-tools"},"next":{"title":"Agents overview","permalink":"/agents-overview"}}');var d=r(74848),n=r(28453);const i={title:"Vector stores",slug:"/components-vector-stores"},c="Vector store components in Langflow",h={},l=[{value:"Use a vector store component in a flow",id:"use-a-vector-store-component-in-a-flow",level:2},{value:"Astra DB Vector Store",id:"astra-db-vector-store",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Generate embeddings",id:"generate-embeddings",level:3},{value:"AstraDB Graph vector store",id:"astradb-graph-vector-store",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"Cassandra",id:"cassandra",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Cassandra Graph Vector Store",id:"cassandra-graph-vector-store",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Chroma DB",id:"chroma-db",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Clickhouse",id:"clickhouse",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"Couchbase",id:"couchbase",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"Elasticsearch",id:"elasticsearch",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"FAISS",id:"faiss",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3},{value:"Graph RAG",id:"graph-rag",level:2},{value:"Inputs",id:"inputs-9",level:3},{value:"Outputs",id:"outputs-9",level:3},{value:"Hyper-Converged Database (HCD) Vector Store",id:"hyper-converged-database-hcd-vector-store",level:2},{value:"Inputs",id:"inputs-10",level:3},{value:"Outputs",id:"outputs-10",level:3},{value:"Milvus",id:"milvus",level:2},{value:"Inputs",id:"inputs-11",level:3},{value:"Outputs",id:"outputs-11",level:3},{value:"MongoDB Atlas",id:"mongodb-atlas",level:2},{value:"Inputs",id:"inputs-12",level:3},{value:"Outputs",id:"outputs-12",level:3},{value:"Opensearch",id:"opensearch",level:2},{value:"Inputs",id:"inputs-13",level:3},{value:"Outputs",id:"outputs-13",level:3},{value:"PGVector",id:"pgvector",level:2},{value:"Inputs",id:"inputs-14",level:3},{value:"Outputs",id:"outputs-14",level:3},{value:"Pinecone",id:"pinecone",level:2},{value:"Inputs",id:"inputs-15",level:3},{value:"Outputs",id:"outputs-15",level:3},{value:"Qdrant",id:"qdrant",level:2},{value:"Inputs",id:"inputs-16",level:3},{value:"Outputs",id:"outputs-16",level:3},{value:"Redis",id:"redis",level:2},{value:"Inputs",id:"inputs-17",level:3},{value:"Outputs",id:"outputs-17",level:3},{value:"Supabase",id:"supabase",level:2},{value:"Inputs",id:"inputs-18",level:3},{value:"Outputs",id:"outputs-18",level:3},{value:"Upstash",id:"upstash",level:2},{value:"Inputs",id:"inputs-19",level:3},{value:"Outputs",id:"outputs-19",level:3},{value:"Vectara",id:"vectara",level:2},{value:"Inputs",id:"inputs-20",level:3},{value:"Outputs",id:"outputs-20",level:3},{value:"Vectara Search",id:"vectara-search",level:2},{value:"Inputs",id:"inputs-21",level:3},{value:"Outputs",id:"outputs-21",level:3},{value:"Weaviate",id:"weaviate",level:2},{value:"Inputs",id:"inputs-22",level:3},{value:"Outputs",id:"outputs-22",level:3},{value:"Weaviate Search",id:"weaviate-search",level:2},{value:"Inputs",id:"inputs-23",level:3},{value:"Outputs",id:"outputs-23",level:3}];function a(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,n.R)(),...e.components};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(t.header,{children:(0,d.jsx)(t.h1,{id:"vector-store-components-in-langflow",children:"Vector store components in Langflow"})}),"\n",(0,d.jsx)(t.p,{children:"Vector databases store vector data, which backs AI workloads like chatbots and Retrieval Augmented Generation."}),"\n",(0,d.jsx)(t.p,{children:"Vector database components establish connections to existing vector databases or create in-memory vector stores for storing and retrieving vector data."}),"\n",(0,d.jsxs)(t.p,{children:["Vector database components are distinct from ",(0,d.jsx)(t.a,{href:"/components-memories",children:"memory components"}),", which are built specifically for storing and retrieving chat messages from external databases."]}),"\n",(0,d.jsx)(t.h2,{id:"use-a-vector-store-component-in-a-flow",children:"Use a vector store component in a flow"}),"\n",(0,d.jsxs)(t.p,{children:["This example uses the ",(0,d.jsx)(t.strong,{children:"Astra DB vector store"})," component. Your vector store component's parameters and authentication may be different, but the document ingestion workflow is the same. A document is loaded from a local machine and chunked. The Astra DB vector store generates embeddings with the connected ",(0,d.jsx)(t.a,{href:"/components-models",children:"model"})," component, and stores them in the connected Astra DB database."]}),"\n",(0,d.jsx)(t.p,{children:"This vector data can then be retrieved for workloads like Retrieval Augmented Generation."}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{src:r(67719).A+"",width:"2894",height:"1014"})}),"\n",(0,d.jsxs)(t.p,{children:["The user's chat input is embedded and compared to the vectors embedded during document ingestion for a similarity search.\nThe results are output from the vector database component as a ",(0,d.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object and parsed into text.\nThis text fills the ",(0,d.jsx)(t.code,{children:"{context}"})," variable in the ",(0,d.jsx)(t.strong,{children:"Prompt"})," component, which informs the ",(0,d.jsx)(t.strong,{children:"Open AI model"})," component's responses."]}),"\n",(0,d.jsxs)(t.p,{children:["Alternatively, connect the vector database component's ",(0,d.jsx)(t.strong,{children:"Retriever"})," port to a ",(0,d.jsx)(t.a,{href:"components-tools#retriever-tool",children:"retriever tool"}),", and then to an ",(0,d.jsx)(t.a,{href:"/components-agents",children:"agent"})," component. This enables the agent to use your vector database as a tool and make decisions based on the available data."]}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{src:r(59072).A+"",width:"2414",height:"1602"})}),"\n",(0,d.jsx)(t.h2,{id:"astra-db-vector-store",children:"Astra DB Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Vector Store using Astra DB with search capabilities."}),"\n",(0,d.jsxs)(t.p,{children:["For more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/create-database.html",children:"DataStax documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Astra DB Application Token"}),(0,d.jsx)(t.td,{children:"The authentication token for accessing Astra DB."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"environment"}),(0,d.jsx)(t.td,{children:"Environment"}),(0,d.jsxs)(t.td,{children:["The environment for the Astra DB API Endpoint. For example, ",(0,d.jsx)(t.code,{children:"dev"})," or ",(0,d.jsx)(t.code,{children:"prod"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_name"}),(0,d.jsx)(t.td,{children:"Database"}),(0,d.jsx)(t.td,{children:"The database name for the Astra DB instance."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"Astra DB API Endpoint"}),(0,d.jsx)(t.td,{children:"The API endpoint for the Astra DB instance. This supersedes the database selection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection"}),(0,d.jsx)(t.td,{children:"The name of the collection within Astra DB where the vectors are stored."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"Keyspace"}),(0,d.jsx)(t.td,{children:"An optional keyspace within Astra DB to use for the collection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_choice"}),(0,d.jsx)(t.td,{children:"Embedding Model or Astra Vectorize"}),(0,d.jsx)(t.td,{children:"Choose an embedding model or use Astra vectorize."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_model"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsx)(t.td,{children:"Specify the embedding model. Not required for Astra vectorize collections."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Search Results"}),(0,d.jsxs)(t.td,{children:["The number of search results to return (default: ",(0,d.jsx)(t.code,{children:"4"}),")."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsxs)(t.td,{children:["The search type to use. The options are ",(0,d.jsx)(t.code,{children:"Similarity"}),", ",(0,d.jsx)(t.code,{children:"Similarity with score threshold"}),", and ",(0,d.jsx)(t.code,{children:"MMR (Max Marginal Relevance)"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsxs)(t.td,{children:["The minimum similarity score threshold for search results when using the ",(0,d.jsx)(t.code,{children:"Similarity with score threshold"})," option."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"advanced_search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"An optional dictionary of filters to apply to the search query."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"autodetect_collection"}),(0,d.jsx)(t.td,{children:"Autodetect Collection"}),(0,d.jsx)(t.td,{children:"A boolean flag to determine whether to autodetect the collection."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"content_field"}),(0,d.jsx)(t.td,{children:"Content Field"}),(0,d.jsx)(t.td,{children:"A field to use as the text content field for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"deletion_field"}),(0,d.jsx)(t.td,{children:"Deletion Based On Field"}),(0,d.jsx)(t.td,{children:"When provided, documents in the target collection with metadata field values matching the input metadata field value are deleted before new data is loaded."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ignore_invalid_documents"}),(0,d.jsx)(t.td,{children:"Ignore Invalid Documents"}),(0,d.jsx)(t.td,{children:"A boolean flag to determine whether to ignore invalid documents at runtime."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"astradb_vectorstore_kwargs"}),(0,d.jsx)(t.td,{children:"AstraDBVectorStore Parameters"}),(0,d.jsx)(t.td,{children:"An optional dictionary of additional parameters for the AstraDBVectorStore."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Astra DB vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.a,{href:"/concepts-objects#data-object",children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"generate-embeddings",children:"Generate embeddings"}),"\n",(0,d.jsxs)(t.p,{children:["The ",(0,d.jsx)(t.strong,{children:"Astra DB Vector Store"})," component offers two methods for generating embeddings."]}),"\n",(0,d.jsxs)(t.ol,{children:["\n",(0,d.jsxs)(t.li,{children:["\n",(0,d.jsxs)(t.p,{children:[(0,d.jsx)(t.strong,{children:"Embedding Model"}),": Use your own embedding model by connecting an ",(0,d.jsx)(t.a,{href:"/components-embedding-models",children:"Embeddings"})," component in Langflow."]}),"\n"]}),"\n",(0,d.jsxs)(t.li,{children:["\n",(0,d.jsxs)(t.p,{children:[(0,d.jsx)(t.strong,{children:"Astra Vectorize"}),": Use Astra DB's built-in embedding generation service. When creating a new collection, choose the embeddings provider and models, including NVIDIA's ",(0,d.jsx)(t.code,{children:"NV-Embed-QA"})," model hosted by Datastax."]}),"\n"]}),"\n"]}),"\n",(0,d.jsx)(t.admonition,{type:"important",children:(0,d.jsx)(t.p,{children:"The embedding model selection is made when creating a new collection and cannot be changed later."})}),"\n",(0,d.jsxs)(t.p,{children:["For an example of using the ",(0,d.jsx)(t.strong,{children:"Astra DB Vector Store"})," component with an embedding model, see the ",(0,d.jsx)(t.a,{href:"/starter-projects-vector-store-rag",children:"Vector Store RAG starter project"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["For more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Astra DB Serverless documentation"}),"."]}),"\n",(0,d.jsx)(t.h2,{id:"astradb-graph-vector-store",children:"AstraDB Graph vector store"}),"\n",(0,d.jsxs)(t.p,{children:["This component implements a Vector Store using AstraDB with graph capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/tutorials/graph-rag.html",children:"Astra DB Serverless documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection Name"}),(0,d.jsx)(t.td,{children:"The name of the collection within AstraDB where the vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Astra DB Application Token"}),(0,d.jsx)(t.td,{children:"Authentication token for accessing AstraDB (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"API Endpoint"}),(0,d.jsx)(t.td,{children:"API endpoint URL for the AstraDB service (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"Search Input"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"Namespace"}),(0,d.jsx)(t.td,{children:"Optional namespace within AstraDB to use for the collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"Metric"}),(0,d.jsx)(t.td,{children:'Distance metric for vector comparisons (options: "cosine", "euclidean", "dot_product")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the vector store (options: "Sync", "Async", "Off")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Pre Delete Collection"}),(0,d.jsx)(t.td,{children:"Boolean flag to determine whether to delete the collection before creating a new one"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Similarity", "Graph Traversal", "Hybrid")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"traversal_depth"}),(0,d.jsx)(t.td,{children:"Traversal Depth"}),(0,d.jsx)(t.td,{children:"Maximum depth for graph traversal searches (default: 1)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Astra DB graph vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"cassandra",children:"Cassandra"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Cassandra Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://cassandra.apache.org/doc/latest/cassandra/vector-search/overview.html",children:"Cassandra documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_ref"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Contact points for the database or AstraDB database ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Username for the database (leave empty for AstraDB)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"User password for the database or AstraDB token"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Table Keyspace or AstraDB namespace"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the table or AstraDB collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ttl_seconds"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Time-to-live for added texts"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Configuration mode for setting up the Cassandra table"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"cluster_kwargs"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Additional keyword arguments for the Cassandra cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Type of search to perform"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Metadata filters for search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"body_search"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Document textual search terms"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"enable_body_search"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Flag to enable body search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Cassandra"}),(0,d.jsx)(t.td,{children:"A Cassandra vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"cassandra-graph-vector-store",children:"Cassandra Graph Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Cassandra Graph Vector Store with search capabilities."}),"\n",(0,d.jsx)(t.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database_ref"}),(0,d.jsx)(t.td,{children:"Contact Points / Astra Database ID"}),(0,d.jsx)(t.td,{children:"Contact points for the database or AstraDB database ID (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"Username"}),(0,d.jsx)(t.td,{children:"Username for the database (leave empty for AstraDB)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"token"}),(0,d.jsx)(t.td,{children:"Password / AstraDB Token"}),(0,d.jsx)(t.td,{children:"User password for the database or AstraDB token (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"keyspace"}),(0,d.jsx)(t.td,{children:"Keyspace"}),(0,d.jsx)(t.td,{children:"Table Keyspace or AstraDB namespace (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"Table Name"}),(0,d.jsx)(t.td,{children:"The name of the table or AstraDB collection where vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the Cassandra table (options: "Sync", "Off", default: "Sync")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"cluster_kwargs"}),(0,d.jsx)(t.td,{children:"Cluster arguments"}),(0,d.jsx)(t.td,{children:"Optional dictionary of additional keyword arguments for the Cassandra cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store (list of Data objects)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Traversal", "MMR traversal", "Similarity", "Similarity with score threshold", "MMR (Max Marginal Relevance)", default: "Traversal")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"depth"}),(0,d.jsx)(t.td,{children:"Depth of traversal"}),(0,d.jsx)(t.td,{children:'The maximum depth of edges to traverse (for "Traversal" or "MMR traversal" search types, default: 1)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:'Minimum similarity score threshold for search results (for "Similarity with score threshold" search type)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"A Cassandra Graph vector store instance configured with the specified parameters."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"chroma-db",children:"Chroma DB"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Chroma Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.trychroma.com/",children:"Chroma documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The name of the Chroma collection. Default: "langflow".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"persist_directory"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The directory to persist the Chroma database."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_cors_allow_origins"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"CORS allow origins for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_host"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Host for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_http_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"HTTP port for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_grpc_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"gRPC port for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"chroma_server_ssl_enabled"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Enable SSL for the Chroma server."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"allow_duplicates"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Allow duplicate documents in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search to perform: "Similarity" or "MMR".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 10."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"limit"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Limit the number of records to compare when Allow Duplicates is False."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Chroma"}),(0,d.jsx)(t.td,{children:"Chroma vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"clickhouse",children:"Clickhouse"}),"\n",(0,d.jsxs)(t.p,{children:["This component implements a Clickhouse Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://clickhouse.com/docs/en/intro",children:"CLickhouse Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"host"}),(0,d.jsx)(t.td,{children:"hostname"}),(0,d.jsx)(t.td,{children:'Clickhouse server hostname (required, default: "localhost")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"Clickhouse server port (required, default: 8123)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"database"}),(0,d.jsx)(t.td,{children:"database"}),(0,d.jsx)(t.td,{children:"Clickhouse database name (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table"}),(0,d.jsx)(t.td,{children:"Table name"}),(0,d.jsx)(t.td,{children:"Clickhouse table name (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"The ClickHouse user name."}),(0,d.jsx)(t.td,{children:"Username for authentication (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"The password for username."}),(0,d.jsx)(t.td,{children:"Password for authentication (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_type"}),(0,d.jsx)(t.td,{children:"index_type"}),(0,d.jsx)(t.td,{children:'Type of the index (options: "annoy", "vector_similarity", default: "annoy")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:'Metric to compute distance (options: "angular", "euclidean", "manhattan", "hamming", "dot", default: "angular")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"secure"}),(0,d.jsx)(t.td,{children:"Use https/TLS"}),(0,d.jsx)(t.td,{children:"Overrides inferred values from the interface or port arguments (default: false)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_param"}),(0,d.jsx)(t.td,{children:"Param of the index"}),(0,d.jsx)(t.td,{children:"Index parameters (default: \"'L2Distance',100\")"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_query_params"}),(0,d.jsx)(t.td,{children:"index query params"}),(0,d.jsx)(t.td,{children:"Additional index query parameters"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding"}),(0,d.jsx)(t.td,{children:"Embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"score_threshold"}),(0,d.jsx)(t.td,{children:"Score threshold"}),(0,d.jsx)(t.td,{children:"Threshold for similarity scores"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsx)(t.td,{children:"Built Clickhouse vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsx)(t.td,{children:"Results of the similarity search as a list of Data objects"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"couchbase",children:"Couchbase"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Couchbase Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.couchbase.com/home/index.html",children:"Couchbase documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_connection_string"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Couchbase Cluster connection string (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Couchbase username (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"couchbase_password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Couchbase password (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bucket_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase bucket (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"scope_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase scope (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase collection (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Couchbase index (required)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 4 (advanced)."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"CouchbaseVectorStore"}),(0,d.jsx)(t.td,{children:"A Couchbase vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"elasticsearch",children:"Elasticsearch"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Elasticsearch Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://www.elastic.co/guide/en/elasticsearch/reference/current/dense-vector.html",children:"Elasticsearch documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Elasticsearch server URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_user"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Username for Elasticsearch authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"es_password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Password for Elasticsearch authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Elasticsearch index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Strategy for vector search ("approximate_k_nearest_neighbors" or "script_scoring")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Strategy for distance calculation ("COSINE", "EUCLIDEAN_DISTANCE", "DOT_PRODUCT")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search (default: 4)"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"ElasticsearchStore"}),(0,d.jsx)(t.td,{children:"Elasticsearch vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"faiss",children:"FAISS"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a FAISS Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://faiss.ai/index.html",children:"FAISS documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The name of the FAISS index. Default: "langflow_index".'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"persist_directory"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Path to save the FAISS index. It will be relative to where Langflow is running."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"The data to ingest into the vector store (list of Data objects or documents)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"allow_dangerous_deserialization"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Set to True to allow loading pickle files from untrusted sources. Default: True (advanced)."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding function to use for the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return from the search. Default: 4 (advanced)."})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"FAISS"}),(0,d.jsx)(t.td,{children:"A FAISS vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"graph-rag",children:"Graph RAG"}),"\n",(0,d.jsxs)(t.p,{children:["This component performs Graph RAG (Retrieval Augmented Generation) traversal in a vector store, enabling graph-based document retrieval.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/",children:"Graph RAG documentation"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["For an example flow, see the ",(0,d.jsx)(t.strong,{children:"Graph RAG"})," template."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-9",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding_model"}),(0,d.jsx)(t.td,{children:"Embedding Model"}),(0,d.jsxs)(t.td,{children:["Specify the embedding model. This is not required for collections embedded with ",(0,d.jsx)(t.a,{href:"https://docs.datastax.com/en/astra-db-serverless/databases/embedding-generation.html",children:"Astra vectorize"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store Connection"}),(0,d.jsx)(t.td,{children:"Connection to the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"edge_definition"}),(0,d.jsx)(t.td,{children:"Edge Definition"}),(0,d.jsxs)(t.td,{children:["Edge definition for the graph traversal. For more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/reference/graph_retriever/edges/",children:"GraphRAG documentation"}),"."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"strategy"}),(0,d.jsx)(t.td,{children:"Traversal Strategies"}),(0,d.jsx)(t.td,{children:"The strategy to use for graph traversal. Strategy options are dynamically loaded from available strategies."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"Search Query"}),(0,d.jsx)(t.td,{children:"The query to search for in the vector store."})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"graphrag_strategy_kwargs"}),(0,d.jsx)(t.td,{children:"Strategy Parameters"}),(0,d.jsxs)(t.td,{children:["Optional dictionary of additional parameters for the retrieval strategy. For more information, see the ",(0,d.jsx)(t.a,{href:"https://datastax.github.io/graph-rag/reference/graph_retriever/strategies/",children:"strategy documentation"}),"."]})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-9",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsxs)(t.td,{children:["Results of the graph-based document retrieval as a list of ",(0,d.jsx)(t.a,{href:"/concepts-objects#data-object",children:"Data"})," objects."]})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"hyper-converged-database-hcd-vector-store",children:"Hyper-Converged Database (HCD) Vector Store"}),"\n",(0,d.jsx)(t.p,{children:"This component implements a Vector Store using HCD."}),"\n",(0,d.jsxs)(t.p,{children:["To use the HCD vector store, add your deployment's collection name, username, password, and HCD Data API endpoint.\nThe endpoint must be formatted like ",(0,d.jsx)(t.code,{children:"http[s]://**DOMAIN_NAME** or **IP_ADDRESS**[:port]"}),", for example, ",(0,d.jsx)(t.code,{children:"http://192.0.2.250:8181"}),"."]}),"\n",(0,d.jsxs)(t.p,{children:["Replace ",(0,d.jsx)(t.strong,{children:"DOMAIN_NAME"})," or ",(0,d.jsx)(t.strong,{children:"IP_ADDRESS"})," with the domain name or IP address of your HCD Data API connection."]}),"\n",(0,d.jsx)(t.p,{children:"To use the HCD vector store for embeddings ingestion, connect it to an embeddings model and a file loader:"}),"\n",(0,d.jsx)(t.p,{children:(0,d.jsx)(t.img,{alt:"HCD vector store embeddings ingestion",src:r(42638).A+"",width:"2294",height:"1684"})}),"\n",(0,d.jsx)(t.h3,{id:"inputs-10",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"Collection Name"}),(0,d.jsx)(t.td,{children:"The name of the collection within HCD where the vectors will be stored (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"HCD Username"}),(0,d.jsx)(t.td,{children:'Authentication username for accessing HCD (default: "hcd-superuser", required)'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"HCD Password"}),(0,d.jsx)(t.td,{children:"Authentication password for accessing HCD (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_endpoint"}),(0,d.jsx)(t.td,{children:"HCD API Endpoint"}),(0,d.jsx)(t.td,{children:"API endpoint URL for the HCD service (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"Search Input"}),(0,d.jsx)(t.td,{children:"Query string for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Ingest Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"Namespace"}),(0,d.jsx)(t.td,{children:'Optional namespace within HCD to use for the collection (default: "default_namespace")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ca_certificate"}),(0,d.jsx)(t.td,{children:"CA Certificate"}),(0,d.jsx)(t.td,{children:"Optional CA certificate for TLS connections to HCD"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metric"}),(0,d.jsx)(t.td,{children:"Metric"}),(0,d.jsx)(t.td,{children:'Optional distance metric for vector comparisons (options: "cosine", "dot_product", "euclidean")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Batch Size"}),(0,d.jsx)(t.td,{children:"Optional number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_insert_batch_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Insert Batch Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk insert operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_insert_overwrite_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Insert Overwrite Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk insert operations that overwrite existing data"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"bulk_delete_concurrency"}),(0,d.jsx)(t.td,{children:"Bulk Delete Concurrency"}),(0,d.jsx)(t.td,{children:"Optional concurrency level for bulk delete operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"Setup Mode"}),(0,d.jsx)(t.td,{children:'Configuration mode for setting up the vector store (options: "Sync", "Async", "Off", default: "Sync")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Pre Delete Collection"}),(0,d.jsx)(t.td,{children:"Boolean flag to determine whether to delete the collection before creating a new one"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_indexing_include"}),(0,d.jsx)(t.td,{children:"Metadata Indexing Include"}),(0,d.jsx)(t.td,{children:"Optional list of metadata fields to include in the indexing"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embedding or Astra Vectorize"}),(0,d.jsx)(t.td,{children:"Allows either an embedding model or an Astra Vectorize configuration"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_indexing_exclude"}),(0,d.jsx)(t.td,{children:"Metadata Indexing Exclude"}),(0,d.jsx)(t.td,{children:"Optional list of metadata fields to exclude from the indexing"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_indexing_policy"}),(0,d.jsx)(t.td,{children:"Collection Indexing Policy"}),(0,d.jsx)(t.td,{children:"Optional dictionary defining the indexing policy for the collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Number of Results"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"Search Type"}),(0,d.jsx)(t.td,{children:'Search type to use (options: "Similarity", "Similarity with score threshold", "MMR (Max Marginal Relevance)", default: "Similarity")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Search Score Threshold"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results (default: 0)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Search Metadata Filter"}),(0,d.jsx)(t.td,{children:"Optional dictionary of filters to apply to the search query"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-10",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Display Name"}),(0,d.jsx)(t.th,{children:"Info"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Vector Store"}),(0,d.jsxs)(t.td,{children:["An HCD vector store instance The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"Search Results"}),(0,d.jsxs)(t.td,{children:["The results of the similarity search as a list of ",(0,d.jsx)(t.code,{children:"Data"})," objects."]})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"milvus",children:"Milvus"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Milvus Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://milvus.io/docs",children:"Milvus documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-11",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Milvus collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_description"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Description of the Milvus collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"uri"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Connection URI for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Password for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Username for Milvus"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"batch_size"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of data to process in a single batch"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Type of search to perform"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_filter"}),(0,d.jsx)(t.td,{children:"Dict"}),(0,d.jsx)(t.td,{children:"Metadata filters for search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"setup_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Configuration mode for setting up the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_dimensions"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of dimensions of the vectors"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pre_delete_collection"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Whether to delete the collection before creating a new one"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-11",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Milvus"}),(0,d.jsx)(t.td,{children:"A Milvus vector store instance configured with the specified parameters."})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"mongodb-atlas",children:"MongoDB Atlas"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a MongoDB Atlas Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://www.mongodb.com/docs/atlas/atlas-vector-search/tutorials/vector-search-quick-start/",children:"MongoDB Atlas documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-12",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"mongodb_atlas_cluster_uri"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"The connection URI for your MongoDB Atlas cluster (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"enable_mtls"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Enable mutual TLS authentication (default: false)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"mongodb_atlas_client_cert"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Client certificate combined with private key for mTLS authentication (required if mTLS is enabled)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"db_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the database to use (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the collection to use (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The name of the Atlas Search index, it should be a Vector Search (required)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"insert_mode"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'How to insert new documents into the collection (options: "append", "overwrite", default: "append")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"The embedding model to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in similarity search (default: 4)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_field"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The field to index (default: "embedding")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"filter_field"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The field to filter the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_dimensions"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Embedding context length (default: 1536)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"similarity"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'The method used to measure similarity between vectors (options: "cosine", "euclidean", "dotProduct", default: "cosine")'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"quantization"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Quantization reduces memory costs by converting 32-bit floats to smaller data types (options: "scalar", "binary")'})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-12",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"MongoDBAtlasVectorSearch"}),(0,d.jsx)(t.td,{children:"MongoDB Atlas vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"opensearch",children:"Opensearch"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Opensearch vector store with search capabilities\nFor more information, see ",(0,d.jsx)(t.a,{href:"https://opensearch.org/platform/search/vector-database.html",children:"Opensearch documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-13",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"opensearch_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsxs)(t.td,{children:["URL for OpenSearch cluster (e.g. ",(0,d.jsx)(t.a,{href:"https://192.168.1.1:9200",children:"https://192.168.1.1:9200"}),")"]})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The index name where the vectors will be stored in OpenSearch cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_input"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Enter a search query. Leave empty to retrieve all documents or if hybrid search is being used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Valid values are "similarity", "similarity_score_threshold", "mmr"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_score_threshold"}),(0,d.jsx)(t.td,{children:"Float"}),(0,d.jsx)(t.td,{children:"Minimum similarity score threshold for search results"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"username"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"username for the opensource cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"password"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"password for the opensource cluster"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"use_ssl"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Use SSL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"verify_certs"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Verify certificates"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"hybrid_search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Provide a custom hybrid search query in JSON format. This allows you to combine vector similarity and keyword matching"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-13",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"OpenSearchVectorSearch"}),(0,d.jsx)(t.td,{children:"OpenSearch vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"pgvector",children:"PGVector"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a PGVector Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://github.com/pgvector/pgvector",children:"PGVector documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-14",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pg_server_url"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"PostgreSQL server connection string"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Table name for the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-14",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"PGVector"}),(0,d.jsx)(t.td,{children:"PGVector vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"pinecone",children:"Pinecone"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Pinecone Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.pinecone.io/home",children:"Pinecone documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-15",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Pinecone index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Namespace for the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_strategy"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Strategy for calculating distance between vectors"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"pinecone_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"API key for Pinecone"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key in the record to use as text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-15",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Pinecone"}),(0,d.jsx)(t.td,{children:"Pinecone vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"qdrant",children:"Qdrant"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Qdrant Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://qdrant.tech/documentation/",children:"Qdrant documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-16",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"collection_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Qdrant collection"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"host"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Qdrant server host"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Qdrant server port"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"grpc_port"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Qdrant gRPC port"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"API key for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"prefix"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Prefix for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"timeout"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Timeout for Qdrant operations"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"path"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Path for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"URL for Qdrant"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"distance_func"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Distance function for vector similarity"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"content_payload_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key for content payload"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_payload_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Key for metadata payload"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-16",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Qdrant"}),(0,d.jsx)(t.td,{children:"Qdrant vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"redis",children:"Redis"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Redis Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://redis.io/docs/latest/develop/interact/search-and-query/advanced-concepts/vectors/",children:"Redis documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-17",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"redis_server_url"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Redis server connection string"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"redis_index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the Redis index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"code"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Custom code for Redis (advanced)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"schema"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Schema for Redis index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-17",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"Redis"}),(0,d.jsx)(t.td,{children:"Redis vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"supabase",children:"Supabase"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a connection to a Supabase Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://supabase.com/docs/guides/ai",children:"Supabase documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-18",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"supabase_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"URL of the Supabase instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"supabase_service_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Service key for Supabase authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"table_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the table in Supabase"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"query_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Name of the query to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-18",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"SupabaseVectorStore"}),(0,d.jsx)(t.td,{children:"Supabase vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"upstash",children:"Upstash"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates an Upstash Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://upstash.com/docs/introduction",children:"Upstash documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-19",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The URL of the Upstash index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_token"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"The token for the Upstash index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"The key in the record to use as text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"namespace"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Namespace for the index"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"metadata_filter"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Filters documents by metadata"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"Data"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use (optional)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-19",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"UpstashVectorStore"}),(0,d.jsx)(t.td,{children:"Upstash vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"vectara",children:"Vectara"}),"\n",(0,d.jsxs)(t.p,{children:["This component creates a Vectara Vector Store with search capabilities.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.vectara.com/docs/",children:"Vectara documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-20",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_customer_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara customer ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_corpus_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara corpus ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Vectara API key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Embedding function to use (optional)"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"ingest_data"}),(0,d.jsx)(t.td,{children:"List[Document/Data]"}),(0,d.jsx)(t.td,{children:"Data to be ingested into the vector store"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_query"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Query for similarity search"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"number_of_results"}),(0,d.jsx)(t.td,{children:"Integer"}),(0,d.jsx)(t.td,{children:"Number of results to return in search"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-20",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"VectaraVectorStore"}),(0,d.jsx)(t.td,{children:"Vectara vector store instance"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})]})]}),"\n",(0,d.jsx)(t.h2,{id:"vectara-search",children:"Vectara Search"}),"\n",(0,d.jsxs)(t.p,{children:["This component searches a Vectara Vector Store for documents based on the provided input.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://docs.vectara.com/docs/",children:"Vectara documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-21",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search, such as "Similarity" or "MMR"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input_value"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_customer_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara customer ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_corpus_id"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Vectara corpus ID"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vectara_api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Vectara API key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"files_url"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional URLs for file initialization"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-21",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"weaviate",children:"Weaviate"}),"\n",(0,d.jsxs)(t.p,{children:["This component facilitates a Weaviate Vector Store setup, optimizing text and document indexing and retrieval.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://weaviate.io/developers/weaviate",children:"Weaviate Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-22",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"weaviate_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default instance URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_by_text"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Indicates whether to search by text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Optional API key for authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Optional index name"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default text extraction key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input"}),(0,d.jsx)(t.td,{children:"Document"}),(0,d.jsx)(t.td,{children:"Document or record"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Model used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"attributes"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional additional attributes"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-22",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"vector_store"}),(0,d.jsx)(t.td,{children:"WeaviateVectorStore"}),(0,d.jsx)(t.td,{children:"Weaviate vector store instance"})]})})]}),"\n",(0,d.jsx)(t.h2,{id:"weaviate-search",children:"Weaviate Search"}),"\n",(0,d.jsxs)(t.p,{children:["This component searches a Weaviate Vector Store for documents similar to the input.\nFor more information, see the ",(0,d.jsx)(t.a,{href:"https://weaviate.io/developers/weaviate",children:"Weaviate Documentation"}),"."]}),"\n",(0,d.jsx)(t.h3,{id:"inputs-23",children:"Inputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsxs)(t.tbody,{children:[(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_type"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:'Type of search, such as "Similarity" or "MMR"'})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"input_value"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Search query"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"weaviate_url"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default instance URL"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_by_text"}),(0,d.jsx)(t.td,{children:"Boolean"}),(0,d.jsx)(t.td,{children:"Indicates whether to search by text"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"api_key"}),(0,d.jsx)(t.td,{children:"SecretString"}),(0,d.jsx)(t.td,{children:"Optional API key for authentication"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"index_name"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Optional index name"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"text_key"}),(0,d.jsx)(t.td,{children:"String"}),(0,d.jsx)(t.td,{children:"Default text extraction key"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"embedding"}),(0,d.jsx)(t.td,{children:"Embeddings"}),(0,d.jsx)(t.td,{children:"Model used"})]}),(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"attributes"}),(0,d.jsx)(t.td,{children:"List[String]"}),(0,d.jsx)(t.td,{children:"Optional additional attributes"})]})]})]}),"\n",(0,d.jsx)(t.h3,{id:"outputs-23",children:"Outputs"}),"\n",(0,d.jsxs)(t.table,{children:[(0,d.jsx)(t.thead,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.th,{children:"Name"}),(0,d.jsx)(t.th,{children:"Type"}),(0,d.jsx)(t.th,{children:"Description"})]})}),(0,d.jsx)(t.tbody,{children:(0,d.jsxs)(t.tr,{children:[(0,d.jsx)(t.td,{children:"search_results"}),(0,d.jsx)(t.td,{children:"List[Data]"}),(0,d.jsx)(t.td,{children:"Results of similarity search"})]})})]})]})}function o(e={}){const{wrapper:t}={...(0,n.R)(),...e.components};return t?(0,d.jsx)(t,{...e,children:(0,d.jsx)(a,{...e})}):a(e)}},59072:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/vector-store-agent-retrieval-tool-79066d11008a74c40390f55f7c73bd71.png"},67719:(e,t,r)=>{r.d(t,{A:()=>s});const s=r.p+"assets/images/vector-store-retrieval-3d2d30b0bfef46783987efd758fc5497.png"}}]); \ No newline at end of file diff --git a/assets/js/fba42286.0f85ccb8.js b/assets/js/fba42286.0f85ccb8.js new file mode 100644 index 0000000000..2e3bba858c --- /dev/null +++ b/assets/js/fba42286.0f85ccb8.js @@ -0,0 +1 @@ +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4806],{28453:(e,n,o)=>{o.d(n,{R:()=>r,x:()=>c});var s=o(96540);const i={},t=s.createContext(i);function r(e){const n=s.useContext(t);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:r(e.components),s.createElement(t.Provider,{value:n},e.children)}},47136:(e,n,o)=>{o.r(n),o.d(n,{assets:()=>a,contentTitle:()=>l,default:()=>u,frontMatter:()=>c,metadata:()=>s,toc:()=>h});const s=JSON.parse('{"id":"Concepts/concepts-voice-mode","title":"Voice mode","description":"The Langflow Playground supports voice mode for interacting with your applications through a microphone.","source":"@site/docs/Concepts/concepts-voice-mode.md","sourceDirName":"Concepts","slug":"/concepts-voice-mode","permalink":"/concepts-voice-mode","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Voice mode","slug":"/concepts-voice-mode"},"sidebar":"docs","previous":{"title":"Manage files","permalink":"/concepts-file-management"},"next":{"title":"Agents","permalink":"/components-agents"}}');var i=o(74848),t=o(28453),r=o(84443);const c={title:"Voice mode",slug:"/concepts-voice-mode"},l=void 0,a={},h=[{value:"Prerequisite",id:"prerequisite",level:2},{value:"Use voice mode in the Langflow Playground",id:"use-voice-mode-in-the-langflow-playground",level:2}];function d(e){const n={a:"a",admonition:"admonition",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,t.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.p,{children:["The Langflow ",(0,i.jsx)(n.strong,{children:"Playground"})," supports ",(0,i.jsx)(n.strong,{children:"voice mode"})," for interacting with your applications through a microphone."]}),"\n",(0,i.jsxs)(n.p,{children:["An ",(0,i.jsx)(n.a,{href:"https://platform.openai.com/",children:"OpenAI API key"})," is required to use ",(0,i.jsx)(n.strong,{children:"voice mode"}),". An ",(0,i.jsx)(n.a,{href:"https://elevenlabs.io",children:"ElevenLabs"})," API key enables more voices in the chat, but is optional."]}),"\n",(0,i.jsxs)(n.p,{children:["Your flow must have a ",(0,i.jsx)(n.a,{href:"/components-io#chat-input",children:"Chat input"})," component to interact with the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"prerequisite",children:"Prerequisite"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:(0,i.jsx)(n.a,{href:"https://platform.openai.com/",children:"An OpenAI API key"})}),"\n"]}),"\n",(0,i.jsx)(n.h2,{id:"use-voice-mode-in-the-langflow-playground",children:"Use voice mode in the Langflow Playground"}),"\n",(0,i.jsxs)(n.p,{children:["Chat with an agent in the ",(0,i.jsx)(n.strong,{children:"Playground"}),", and get more recent results by asking the agent to use tools."]}),"\n",(0,i.jsxs)(n.ol,{children:["\n",(0,i.jsxs)(n.li,{children:["Create a ",(0,i.jsx)(n.a,{href:"/starter-projects-simple-agent",children:"Simple agent starter project"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["Add your ",(0,i.jsx)(n.strong,{children:"OpenAI API key"})," credentials to the ",(0,i.jsx)(n.strong,{children:"Agent"})," component."]}),"\n",(0,i.jsxs)(n.li,{children:["To start a chat session, click ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["To enable voice mode, click the ",(0,i.jsx)(r.A,{name:"Mic","aria-label":"Microphone"})," icon.\nThe ",(0,i.jsx)(n.strong,{children:"Voice mode"})," pane opens."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"OpenAI API Key"})," field, add your ",(0,i.jsx)(n.strong,{children:"OpenAI API key"})," credentials.\nThis key is saved as a ",(0,i.jsx)(n.a,{href:"/configuration-global-variables",children:"global variable"})," in Langflow and is accessible from any component or flow."]}),"\n",(0,i.jsxs)(n.li,{children:["Your browser may prompt you for microphone access.\nBrowser access is ",(0,i.jsx)(n.strong,{children:"required"})," to use voice mode.\nTo continue, allow microphone access in your browser."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"Audio Input"})," menu, select the input device to use with voice mode."]}),"\n"]}),"\n",(0,i.jsx)(n.admonition,{type:"tip",children:(0,i.jsx)(n.p,{children:"A higher quality microphone improves OpenAI's voice chat comprehension."})}),"\n",(0,i.jsxs)(n.ol,{start:"8",children:["\n",(0,i.jsxs)(n.li,{children:["Optionally, add your ",(0,i.jsx)(n.strong,{children:"ElevenLabs API key"})," in the ",(0,i.jsx)(n.strong,{children:"ElevenLabs API Key"})," field.\nThis makes more voices available for your AI responses.\nThis key is saved as a ",(0,i.jsx)(n.a,{href:"/configuration-global-variables",children:"global variable"})," in Langflow and is accessible from any component or flow."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"Preferred Language"})," menu, select your language for conversing with Langflow.\nThis option changes both the spoken conversation and the chat responses in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["Talk into your microphone.\nThe waveform in the voice mode pane should register your input, and the agent should respond in voice and in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.li,{children:"Ask the agent to use the tools available to find recent news about a subject."}),"\n"]}),"\n",(0,i.jsxs)(n.p,{children:["The agent describes its search process, including accessing the ",(0,i.jsx)(n.strong,{children:"URL"})," tool to fetch recent news.\nThe agent summarizes the recent news in speech and in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.p,{children:"Be aware of the following considerations when using voice mode:"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["Name and describe your tools accurately, so the ",(0,i.jsx)(n.strong,{children:"Agent"})," chooses tools correctly."]}),"\n",(0,i.jsxs)(n.li,{children:["Voice mode does not use the instructions in the Agent component's ",(0,i.jsx)(n.strong,{children:"Agent Instructions"})," field, because your spoken instructions override this value."]}),"\n",(0,i.jsxs)(n.li,{children:["Voice mode only maintains context within the conversation session you are currently in.\nIf you exit a conversation and close the ",(0,i.jsx)(n.strong,{children:"Playground"}),", your conversational context is not available in the next chat session."]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(d,{...e})}):d(e)}},84443:(e,n,o)=>{o.d(n,{A:()=>t});o(96540);var s=o(64058),i=o(74848);function t(e){let{name:n,...o}=e;const t=s[n];return t?(0,i.jsx)(t,{...o}):null}}}]); \ No newline at end of file diff --git a/assets/js/fba42286.63018b69.js b/assets/js/fba42286.63018b69.js deleted file mode 100644 index b60677d179..0000000000 --- a/assets/js/fba42286.63018b69.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[4806],{28453:(e,n,o)=>{o.d(n,{R:()=>r,x:()=>c});var s=o(96540);const i={},t=s.createContext(i);function r(e){const n=s.useContext(t);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:r(e.components),s.createElement(t.Provider,{value:n},e.children)}},47136:(e,n,o)=>{o.r(n),o.d(n,{assets:()=>a,contentTitle:()=>l,default:()=>u,frontMatter:()=>c,metadata:()=>s,toc:()=>d});const s=JSON.parse('{"id":"Concepts/concepts-voice-mode","title":"Voice mode","description":"The Langflow Playground supports voice mode for interacting with your applications through a microphone.","source":"@site/docs/Concepts/concepts-voice-mode.md","sourceDirName":"Concepts","slug":"/concepts-voice-mode","permalink":"/concepts-voice-mode","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Voice mode","slug":"/concepts-voice-mode"},"sidebar":"docs","previous":{"title":"Manage files","permalink":"/concepts-file-management"},"next":{"title":"Agents","permalink":"/components-agents"}}');var i=o(74848),t=o(28453),r=o(84443);const c={title:"Voice mode",slug:"/concepts-voice-mode"},l=void 0,a={},d=[{value:"Prerequisite",id:"prerequisite",level:2},{value:"Use voice mode in the Langflow Playground",id:"use-voice-mode-in-the-langflow-playground",level:2}];function h(e){const n={a:"a",admonition:"admonition",h2:"h2",li:"li",ol:"ol",p:"p",strong:"strong",ul:"ul",...(0,t.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.p,{children:["The Langflow ",(0,i.jsx)(n.strong,{children:"Playground"})," supports ",(0,i.jsx)(n.strong,{children:"voice mode"})," for interacting with your applications through a microphone."]}),"\n",(0,i.jsxs)(n.p,{children:["An ",(0,i.jsx)(n.a,{href:"https://platform.openai.com/",children:"OpenAI API key"})," is required to use ",(0,i.jsx)(n.strong,{children:"voice mode"}),". An ",(0,i.jsx)(n.a,{href:"https://elevenlabs.io",children:"ElevenLabs"})," API key enables more voices in the chat, but is optional."]}),"\n",(0,i.jsxs)(n.p,{children:["Your flow must have a ",(0,i.jsx)(n.a,{href:"/components-io#chat-input",children:"Chat input"})," component to interact with the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.h2,{id:"prerequisite",children:"Prerequisite"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:(0,i.jsx)(n.a,{href:"https://platform.openai.com/",children:"OpenAI API key created"})}),"\n"]}),"\n",(0,i.jsx)(n.h2,{id:"use-voice-mode-in-the-langflow-playground",children:"Use voice mode in the Langflow Playground"}),"\n",(0,i.jsxs)(n.p,{children:["Chat with an agent in the ",(0,i.jsx)(n.strong,{children:"Playground"}),", and get more recent results by asking the agent to use tools."]}),"\n",(0,i.jsxs)(n.ol,{children:["\n",(0,i.jsxs)(n.li,{children:["Create a ",(0,i.jsx)(n.a,{href:"/starter-projects-simple-agent",children:"Simple agent starter project"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["Add your ",(0,i.jsx)(n.strong,{children:"OpenAI API key"})," credentials to the ",(0,i.jsx)(n.strong,{children:"Agent"})," component."]}),"\n",(0,i.jsxs)(n.li,{children:["To start a chat session, click ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["To enable voice mode, click the ",(0,i.jsx)(r.A,{name:"Mic","aria-label":"Microphone"})," icon.\nThe ",(0,i.jsx)(n.strong,{children:"Voice mode"})," pane opens."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"OpenAI API Key"})," field, add your ",(0,i.jsx)(n.strong,{children:"OpenAI API key"})," credentials.\nThis key is saved as a ",(0,i.jsx)(n.a,{href:"/configuration-global-variables",children:"global variable"})," in Langflow and is accessible from any component or flow."]}),"\n",(0,i.jsxs)(n.li,{children:["Your browser may prompt you for microphone access.\nBrowser access is ",(0,i.jsx)(n.strong,{children:"required"})," to use voice mode.\nTo continue, allow microphone access in your browser."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"Audio Input"})," menu, select the input device to use with voice mode."]}),"\n"]}),"\n",(0,i.jsx)(n.admonition,{type:"tip",children:(0,i.jsx)(n.p,{children:"A higher quality microphone improves OpenAI's voice chat comprehension."})}),"\n",(0,i.jsxs)(n.ol,{start:"8",children:["\n",(0,i.jsxs)(n.li,{children:["Optionally, add your ",(0,i.jsx)(n.strong,{children:"ElevenLabs API key"})," in the ",(0,i.jsx)(n.strong,{children:"ElevenLabs API Key"})," field.\nThis makes more voices available for your AI responses.\nThis key is saved as a ",(0,i.jsx)(n.a,{href:"/configuration-global-variables",children:"global variable"})," in Langflow and is accessible from any component or flow."]}),"\n",(0,i.jsxs)(n.li,{children:["In the ",(0,i.jsx)(n.strong,{children:"Preferred Language"})," menu, select your language for conversing with Langflow.\nThis option changes both the spoken conversation and the chat responses in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsxs)(n.li,{children:["Talk into your microphone.\nThe waveform in the voice mode pane should register your input, and the agent should respond in voice and in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.li,{children:"Ask the agent to use the tools available to find recent news about a subject."}),"\n"]}),"\n",(0,i.jsxs)(n.p,{children:["The agent describes its search process, including accessing the ",(0,i.jsx)(n.strong,{children:"URL"})," tool to fetch recent news.\nThe agent summarizes the recent news in speech and in the ",(0,i.jsx)(n.strong,{children:"Playground"}),"."]}),"\n",(0,i.jsx)(n.p,{children:"Be aware of the following considerations when using voice mode:"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["Name and describe your tools accurately, so the ",(0,i.jsx)(n.strong,{children:"Agent"})," chooses tools correctly."]}),"\n",(0,i.jsxs)(n.li,{children:["Voice mode does not use the instructions in the Agent component's ",(0,i.jsx)(n.strong,{children:"Agent Instructions"})," field, because your spoken instructions override this value."]}),"\n",(0,i.jsxs)(n.li,{children:["Voice mode only maintains context within the conversation session you are currently in.\nIf you exit a conversation and close the ",(0,i.jsx)(n.strong,{children:"Playground"}),", your conversational context is not available in the next chat session."]}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(h,{...e})}):h(e)}},84443:(e,n,o)=>{o.d(n,{A:()=>t});o(96540);var s=o(64058),i=o(74848);function t(e){let{name:n,...o}=e;const t=s[n];return t?(0,i.jsx)(t,{...o}):null}}}]); \ No newline at end of file diff --git a/assets/js/fdefa9a8.f5e1acb1.js b/assets/js/fdefa9a8.c05bd7d6.js similarity index 99% rename from assets/js/fdefa9a8.f5e1acb1.js rename to assets/js/fdefa9a8.c05bd7d6.js index 878c51ed31..2fcf12aeec 100644 --- a/assets/js/fdefa9a8.f5e1acb1.js +++ b/assets/js/fdefa9a8.c05bd7d6.js @@ -1 +1 @@ -"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[7453],{39245:(e,t,s)=>{s.r(t),s.d(t,{CH:()=>h,assets:()=>o,chCodeConfig:()=>a,contentTitle:()=>c,default:()=>p,frontMatter:()=>l,metadata:()=>n,toc:()=>x});const n=JSON.parse('{"id":"Components/components-data","title":"Data","description":"Data components load data from a source into your flow.","source":"@site/docs/Components/components-data.md","sourceDirName":"Components","slug":"/components-data","permalink":"/components-data","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Data","slug":"/components-data"},"sidebar":"docs","previous":{"title":"Create custom Python components","permalink":"/components-custom-components"},"next":{"title":"Embeddings","permalink":"/components-embedding-models"}}');var r=s(74848),d=s(28453),i=s(24754);const l={title:"Data",slug:"/components-data"},c="Data components in Langflow",o={},h={annotations:i.hk,Code:i.Cy},a={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},x=[{value:"Use a data component in a flow",id:"use-a-data-component-in-a-flow",level:2},{value:"API Request",id:"api-request",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Directory",id:"directory",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"File",id:"file",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Supported File Types",id:"supported-file-types",level:3},{value:"Gmail Loader",id:"gmail-loader",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Google Drive Loader",id:"google-drive-loader",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Google Drive Search",id:"google-drive-search",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"SQL Query",id:"sql-query",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"URL",id:"url",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"Webhook",id:"webhook",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3}];function j(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return h||u("CH",!1),h.Code||u("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)(t.header,{children:(0,r.jsx)(t.h1,{id:"data-components-in-langflow",children:"Data components in Langflow"})}),"\n",(0,r.jsx)(t.p,{children:"Data components load data from a source into your flow."}),"\n",(0,r.jsx)(t.p,{children:"They may perform some processing or type checking, like converting raw HTML data into text, or ensuring your loaded file is of an acceptable type."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-data-component-in-a-flow",children:"Use a data component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," data component loads content from a list of URLs."]}),"\n",(0,r.jsxs)(t.p,{children:["In the component's ",(0,r.jsx)(t.strong,{children:"URLs"})," field, enter a comma-separated list of URLs you want to load. Alternatively, connect a component that outputs the ",(0,r.jsx)(t.code,{children:"Message"})," type, like the ",(0,r.jsx)(t.strong,{children:"Chat Input"})," component, to supply your URLs with a component."]}),"\n",(0,r.jsxs)(t.p,{children:["To output a ",(0,r.jsx)(t.code,{children:"Data"})," type, in the ",(0,r.jsx)(t.strong,{children:"Output Format"})," dropdown, select ",(0,r.jsx)(t.strong,{children:"Raw HTML"}),".\nTo output a ",(0,r.jsx)(t.code,{children:"Message"})," type, in the ",(0,r.jsx)(t.strong,{children:"Output Format"})," dropdown, select ",(0,r.jsx)(t.strong,{children:"Text"}),". This option applies postprocessing with the ",(0,r.jsx)(t.code,{children:"data_to_text"})," helper function."]}),"\n",(0,r.jsx)(t.p,{children:"In this example of a document ingestion pipeline, the URL component outputs raw HTML to a text splitter, which splits the raw content into chunks for a vector database to ingest."}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"URL component in a data ingestion pipeline",src:s(80352).A+"",width:"2586",height:"1550"})}),"\n",(0,r.jsx)(t.h2,{id:"api-request",children:"API Request"}),"\n",(0,r.jsx)(t.p,{children:"This component makes HTTP requests using URLs or cURL commands."}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"urls"}),(0,r.jsx)(t.td,{children:"URLs"}),(0,r.jsx)(t.td,{children:"Enter one or more URLs, separated by commas."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"curl"}),(0,r.jsx)(t.td,{children:"cURL"}),(0,r.jsx)(t.td,{children:"Paste a curl command to populate the dictionary fields for headers and body."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"method"}),(0,r.jsx)(t.td,{children:"Method"}),(0,r.jsx)(t.td,{children:"The HTTP method to use."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_curl"}),(0,r.jsx)(t.td,{children:"Use cURL"}),(0,r.jsx)(t.td,{children:"Enable cURL mode to populate fields from a cURL command."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_params"}),(0,r.jsx)(t.td,{children:"Query Parameters"}),(0,r.jsx)(t.td,{children:"The query parameters to append to the URL."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"body"}),(0,r.jsx)(t.td,{children:"Body"}),(0,r.jsxs)(t.td,{children:["The body to send with the request as a dictionary (for ",(0,r.jsx)(t.code,{children:"POST"}),", ",(0,r.jsx)(t.code,{children:"PATCH"}),", ",(0,r.jsx)(t.code,{children:"PUT"}),")."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"headers"}),(0,r.jsx)(t.td,{children:"Headers"}),(0,r.jsx)(t.td,{children:"The headers to send with the request as a dictionary."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"timeout"}),(0,r.jsx)(t.td,{children:"Timeout"}),(0,r.jsx)(t.td,{children:"The timeout to use for the request."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"follow_redirects"}),(0,r.jsx)(t.td,{children:"Follow Redirects"}),(0,r.jsx)(t.td,{children:"Whether to follow http redirects."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"save_to_file"}),(0,r.jsx)(t.td,{children:"Save to File"}),(0,r.jsx)(t.td,{children:"Save the API response to a temporary file"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"include_httpx_metadata"}),(0,r.jsx)(t.td,{children:"Include HTTPx Metadata"}),(0,r.jsxs)(t.td,{children:["Include properties such as ",(0,r.jsx)(t.code,{children:"headers"}),", ",(0,r.jsx)(t.code,{children:"status_code"}),", ",(0,r.jsx)(t.code,{children:"response_headers"}),", and ",(0,r.jsx)(t.code,{children:"redirection_history"})," in the output."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"The result of the API requests."})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"directory",children:"Directory"}),"\n",(0,r.jsx)(t.p,{children:"This component recursively loads files from a directory, with options for file types, depth, and concurrency."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"path"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Path to the directory to load files from"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"types"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"File types to load (leave empty to load all types)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"depth"}),(0,r.jsx)(t.td,{children:"IntInput"}),(0,r.jsx)(t.td,{children:"Depth to search for files"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_concurrency"}),(0,r.jsx)(t.td,{children:"IntInput"}),(0,r.jsx)(t.td,{children:"Maximum concurrency for loading files"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"load_hidden"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, hidden files are loaded"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"recursive"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, the search is recursive"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"silent_errors"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, errors do not raise an exception"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_multithreading"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, multithreading is used"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"List[Data]"}),(0,r.jsx)(t.td,{children:"Loaded file data from the directory"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"file",children:"File"}),"\n",(0,r.jsxs)(t.p,{children:["This component loads and parses files of various supported formats and converts the content into a ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object. It supports multiple file types and provides options for parallel processing and error handling."]}),"\n",(0,r.jsx)(t.p,{children:"To load a document, follow these steps:"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Click the ",(0,r.jsx)(t.strong,{children:"Select files"})," button."]}),"\n",(0,r.jsxs)(t.li,{children:["Select a local file or a file loaded with ",(0,r.jsx)(t.a,{href:"/concepts-file-management",children:"File management"}),", and then click ",(0,r.jsx)(t.strong,{children:"Select file"}),"."]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:"The loaded file name appears in the component."}),"\n",(0,r.jsxs)(t.p,{children:["The default maximum supported file size is 100 MB.\nTo modify this value, see ",(0,r.jsx)(t.a,{href:"/environment-variables#LANGFLOW_MAX_FILE_SIZE_UPLOAD",children:"--max-file-size-upload"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"path"}),(0,r.jsx)(t.td,{children:"Files"}),(0,r.jsx)(t.td,{children:"Path to file(s) to load. Supports individual files or bundled archives."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file_path"}),(0,r.jsx)(t.td,{children:"Server File Path"}),(0,r.jsxs)(t.td,{children:["Data object with a ",(0,r.jsx)(t.code,{children:"file_path"})," property pointing to the server file or a Message object with a path to the file. Supersedes 'Path' but supports the same file types."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"separator"}),(0,r.jsx)(t.td,{children:"Separator"}),(0,r.jsx)(t.td,{children:"Specify the separator to use between multiple outputs in Message format."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"silent_errors"}),(0,r.jsx)(t.td,{children:"Silent Errors"}),(0,r.jsx)(t.td,{children:"If true, errors do not raise an exception."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"delete_server_file_after_processing"}),(0,r.jsx)(t.td,{children:"Delete Server File After Processing"}),(0,r.jsx)(t.td,{children:"If true, the Server File Path is deleted after processing."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"ignore_unsupported_extensions"}),(0,r.jsx)(t.td,{children:"Ignore Unsupported Extensions"}),(0,r.jsx)(t.td,{children:"If true, files with unsupported extensions are not processed."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"ignore_unspecified_files"}),(0,r.jsx)(t.td,{children:"Ignore Unspecified Files"}),(0,r.jsxs)(t.td,{children:["If true, ",(0,r.jsx)(t.code,{children:"Data"})," with no ",(0,r.jsx)(t.code,{children:"file_path"})," property is ignored."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_multithreading"}),(0,r.jsx)(t.td,{children:"[Deprecated] Use Multithreading"}),(0,r.jsxs)(t.td,{children:["Set 'Processing Concurrency' greater than ",(0,r.jsx)(t.code,{children:"1"})," to enable multithreading. This option is deprecated."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"concurrency_multithreading"}),(0,r.jsx)(t.td,{children:"Processing Concurrency"}),(0,r.jsx)(t.td,{children:"When multiple files are being processed, the number of files to process concurrently. Default is 1. Values greater than 1 enable parallel processing for 2 or more files."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["Parsed content of the file as a ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"dataframe"}),(0,r.jsx)(t.td,{children:"DataFrame"}),(0,r.jsxs)(t.td,{children:["File content as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#dataframe-object",children:"DataFrame"})," object."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"message"}),(0,r.jsx)(t.td,{children:"Message"}),(0,r.jsxs)(t.td,{children:["File content as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#message-object",children:"Message"})," object."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"supported-file-types",children:"Supported File Types"}),"\n",(0,r.jsx)(t.p,{children:"Text files:"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".txt"})," - Text files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".md"}),", ",(0,r.jsx)(t.code,{children:".mdx"})," - Markdown files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".csv"})," - CSV files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".json"})," - JSON files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".yaml"}),", ",(0,r.jsx)(t.code,{children:".yml"})," - YAML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".xml"})," - XML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".html"}),", ",(0,r.jsx)(t.code,{children:".htm"})," - HTML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".pdf"})," - PDF files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".docx"})," - Word documents"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".py"})," - Python files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".sh"})," - Shell scripts"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".sql"})," - SQL files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".js"})," - JavaScript files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".ts"}),", ",(0,r.jsx)(t.code,{children:".tsx"})," - TypeScript files"]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:"Archive formats (for bundling multiple files):"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".zip"})," - ZIP archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".tar"})," - TAR archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".tgz"})," - Gzipped TAR archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".bz2"})," - Bzip2 compressed files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".gz"})," - Gzip compressed files"]}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"gmail-loader",children:"Gmail Loader"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component loads emails from Gmail using provided credentials and filters."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"json_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"label_ids"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Comma-separated list of label IDs to filter emails"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_results"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Maximum number of emails to load"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Loaded email data"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"google-drive-loader",children:"Google Drive Loader"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component loads documents from Google Drive using provided credentials and a single document ID."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"json_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"document_id"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Single Google Drive document ID"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"docs"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Loaded document data"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"google-drive-search",children:"Google Drive Search"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component searches Google Drive files using provided credentials and query parameters."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"token_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_item"}),(0,r.jsx)(t.td,{children:"DropdownInput"}),(0,r.jsx)(t.td,{children:"The field to query"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"valid_operator"}),(0,r.jsx)(t.td,{children:"DropdownInput"}),(0,r.jsx)(t.td,{children:"Operator to use in the query"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"search_term"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"The value to search for in the specified query item"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_string"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"The query string used for searching (can be edited manually)"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_urls"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"URLs of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_ids"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"IDs of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_titles"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"Titles of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Document titles and URLs in a structured format"})]})]})]}),"\n",(0,r.jsx)(t.h2,{id:"sql-query",children:"SQL Query"}),"\n",(0,r.jsx)(t.p,{children:"This component executes SQL queries on a specified database."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query"}),(0,r.jsx)(t.td,{children:"Query"}),(0,r.jsx)(t.td,{children:"The SQL query to execute."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"database_url"}),(0,r.jsx)(t.td,{children:"Database URL"}),(0,r.jsx)(t.td,{children:"The URL of the database."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"include_columns"}),(0,r.jsx)(t.td,{children:"Include Columns"}),(0,r.jsx)(t.td,{children:"Include columns in the result."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"passthrough"}),(0,r.jsx)(t.td,{children:"Passthrough"}),(0,r.jsx)(t.td,{children:"If an error occurs, return the query instead of raising an exception."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"add_error"}),(0,r.jsx)(t.td,{children:"Add Error"}),(0,r.jsx)(t.td,{children:"Add the error to the result."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"result"}),(0,r.jsx)(t.td,{children:"Result"}),(0,r.jsx)(t.td,{children:"The result of the SQL query execution."})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"url",children:"URL"}),"\n",(0,r.jsx)(t.p,{children:"This component fetches content from one or more URLs, processes the content, and returns it in various formats. It supports output in plain text, raw HTML, or JSON, with options for cleaning and separating multiple outputs."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"urls"}),(0,r.jsx)(t.td,{children:"URLs"}),(0,r.jsx)(t.td,{children:"Enter one or more URLs. URLs are automatically validated and cleaned."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"format"}),(0,r.jsx)(t.td,{children:"Output Format"}),(0,r.jsxs)(t.td,{children:["Output Format. Use ",(0,r.jsx)(t.strong,{children:"Text"})," to extract text from the HTML, ",(0,r.jsx)(t.strong,{children:"Raw HTML"})," for the raw HTML content, or ",(0,r.jsx)(t.strong,{children:"JSON"})," to extract JSON from the HTML."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"separator"}),(0,r.jsx)(t.td,{children:"Separator"}),(0,r.jsxs)(t.td,{children:["Specify the separator to use between multiple outputs. Default for ",(0,r.jsx)(t.strong,{children:"Text"})," is ",(0,r.jsx)(t.code,{children:"\\n\\n"}),". Default for ",(0,r.jsx)(t.strong,{children:"Raw HTML"})," is ",(0,r.jsx)(t.code,{children:"\\n\x3c!-- Separator --\x3e\\n"}),"."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"clean_extra_whitespace"}),(0,r.jsx)(t.td,{children:"Clean Extra Whitespace"}),(0,r.jsxs)(t.td,{children:["Whether to clean excessive blank lines in the text output. Only applies to ",(0,r.jsx)(t.code,{children:"Text"})," format."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["List of ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects containing fetched content and metadata."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"text"}),(0,r.jsx)(t.td,{children:"Text"}),(0,r.jsx)(t.td,{children:"Fetched content as formatted text, with applied separators and cleaning."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"dataframe"}),(0,r.jsx)(t.td,{children:"DataFrame"}),(0,r.jsxs)(t.td,{children:["Content formatted as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#dataframe-object",children:"Data"})," object."]})]})]})]}),"\n",(0,r.jsx)(t.h2,{id:"webhook",children:"Webhook"}),"\n",(0,r.jsx)(t.p,{children:"This component defines a webhook trigger that runs a flow when it receives an HTTP POST request."}),"\n",(0,r.jsxs)(t.p,{children:["If the input is not valid JSON, the component wraps it in a ",(0,r.jsx)(t.code,{children:"payload"})," object so that it can be processed and still trigger the flow. The component does not require an API key."]}),"\n",(0,r.jsxs)(t.p,{children:["When a ",(0,r.jsx)(t.strong,{children:"Webhook"})," component is added to the workspace, a new ",(0,r.jsx)(t.strong,{children:"Webhook cURL"})," tab becomes available in the ",(0,r.jsx)(t.strong,{children:"API"})," pane that contains an HTTP POST request for triggering the webhook component. For example:"]}),"\n",(0,r.jsx)(h.Code,{codeConfig:a,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{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://127.0.0.1:7860/api/v1/webhook/**YOUR_FLOW_ID**" ',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:'\'{"any": "data"}\'',props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,r.jsx)(t.p,{children:"To test the webhook component:"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Add a ",(0,r.jsx)(t.strong,{children:"Webhook"})," component to the flow."]}),"\n",(0,r.jsxs)(t.li,{children:["Connect the ",(0,r.jsx)(t.strong,{children:"Webhook"})," component's ",(0,r.jsx)(t.strong,{children:"Data"})," output to the ",(0,r.jsx)(t.strong,{children:"Data"})," input of a ",(0,r.jsx)(t.a,{href:"/components-processing#data-to-message",children:"Data to Message"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["Connect the ",(0,r.jsx)(t.strong,{children:"Data to Message"})," component's ",(0,r.jsx)(t.strong,{children:"Message"})," output to the ",(0,r.jsx)(t.strong,{children:"Text"})," input of a ",(0,r.jsx)(t.a,{href:"/components-io#chat-output",children:"Chat Output"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["To send a POST request, copy the code from the ",(0,r.jsx)(t.strong,{children:"Webhook cURL"})," tab in the ",(0,r.jsx)(t.strong,{children:"API"})," pane and paste it into a terminal."]}),"\n",(0,r.jsx)(t.li,{children:"Send the POST request."}),"\n",(0,r.jsxs)(t.li,{children:["Open the ",(0,r.jsx)(t.strong,{children:"Playground"}),".\nYour JSON data is posted to the ",(0,r.jsx)(t.strong,{children:"Chat Output"})," component, which indicates that the webhook component is correctly triggering the flow."]}),"\n"]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Payload"}),(0,r.jsx)(t.td,{children:"Receives a payload from external systems through HTTP POST requests."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"curl"}),(0,r.jsx)(t.td,{children:"cURL"}),(0,r.jsx)(t.td,{children:"The cURL command template for making requests to this webhook."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"endpoint"}),(0,r.jsx)(t.td,{children:"Endpoint"}),(0,r.jsx)(t.td,{children:"The endpoint URL where this webhook receives requests."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"output_data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["Outputs processed data from the webhook input, and returns an empty ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object if no input is provided. If the input is not valid JSON, the component wraps it in a ",(0,r.jsx)(t.code,{children:"payload"})," object."]})]})})]})]})}function p(e={}){const{wrapper:t}={...(0,d.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(j,{...e})}):j(e)}function u(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},80352:(e,t,s)=>{s.d(t,{A:()=>n});const n=s.p+"assets/images/url-component-0ced1fa00ee3b97582421254b6d5be78.png"}}]); \ No newline at end of file +"use strict";(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[7453],{39245:(e,t,s)=>{s.r(t),s.d(t,{CH:()=>h,assets:()=>o,chCodeConfig:()=>a,contentTitle:()=>c,default:()=>p,frontMatter:()=>l,metadata:()=>n,toc:()=>x});const n=JSON.parse('{"id":"Components/components-data","title":"Data","description":"Data components load data from a source into your flow.","source":"@site/docs/Components/components-data.md","sourceDirName":"Components","slug":"/components-data","permalink":"/components-data","draft":false,"unlisted":false,"tags":[],"version":"current","frontMatter":{"title":"Data","slug":"/components-data"},"sidebar":"docs","previous":{"title":"Create custom Python components","permalink":"/components-custom-components"},"next":{"title":"Embeddings","permalink":"/components-embedding-models"}}');var r=s(74848),d=s(28453),i=s(24754);const l={title:"Data",slug:"/components-data"},c="Data components in Langflow",o={},h={annotations:i.hk,Code:i.Cy},a={staticMediaQuery:"not screen, (max-width: 768px)",lineNumbers:!0,showCopyButton:!0,themeName:"github-dark"},x=[{value:"Use a data component in a flow",id:"use-a-data-component-in-a-flow",level:2},{value:"API Request",id:"api-request",level:2},{value:"Inputs",id:"inputs",level:3},{value:"Outputs",id:"outputs",level:3},{value:"Directory",id:"directory",level:2},{value:"Inputs",id:"inputs-1",level:3},{value:"Outputs",id:"outputs-1",level:3},{value:"File",id:"file",level:2},{value:"Inputs",id:"inputs-2",level:3},{value:"Outputs",id:"outputs-2",level:3},{value:"Supported File Types",id:"supported-file-types",level:3},{value:"Gmail Loader",id:"gmail-loader",level:2},{value:"Inputs",id:"inputs-3",level:3},{value:"Outputs",id:"outputs-3",level:3},{value:"Google Drive Loader",id:"google-drive-loader",level:2},{value:"Inputs",id:"inputs-4",level:3},{value:"Outputs",id:"outputs-4",level:3},{value:"Google Drive Search",id:"google-drive-search",level:2},{value:"Inputs",id:"inputs-5",level:3},{value:"Outputs",id:"outputs-5",level:3},{value:"SQL Query",id:"sql-query",level:2},{value:"Inputs",id:"inputs-6",level:3},{value:"Outputs",id:"outputs-6",level:3},{value:"URL",id:"url",level:2},{value:"Inputs",id:"inputs-7",level:3},{value:"Outputs",id:"outputs-7",level:3},{value:"Webhook",id:"webhook",level:2},{value:"Inputs",id:"inputs-8",level:3},{value:"Outputs",id:"outputs-8",level:3}];function j(e){const t={a:"a",admonition:"admonition",code:"code",h1:"h1",h2:"h2",h3:"h3",header:"header",img:"img",li:"li",ol:"ol",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return h||u("CH",!1),h.Code||u("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)(t.header,{children:(0,r.jsx)(t.h1,{id:"data-components-in-langflow",children:"Data components in Langflow"})}),"\n",(0,r.jsx)(t.p,{children:"Data components load data from a source into your flow."}),"\n",(0,r.jsx)(t.p,{children:"They may perform some processing or type checking, like converting raw HTML data into text, or ensuring your loaded file is of an acceptable type."}),"\n",(0,r.jsx)(t.h2,{id:"use-a-data-component-in-a-flow",children:"Use a data component in a flow"}),"\n",(0,r.jsxs)(t.p,{children:["The ",(0,r.jsx)(t.strong,{children:"URL"})," data component loads content from a list of URLs."]}),"\n",(0,r.jsxs)(t.p,{children:["In the component's ",(0,r.jsx)(t.strong,{children:"URLs"})," field, enter a comma-separated list of URLs you want to load. Alternatively, connect a component that outputs the ",(0,r.jsx)(t.code,{children:"Message"})," type, like the ",(0,r.jsx)(t.strong,{children:"Chat Input"})," component, to supply your URLs with a component."]}),"\n",(0,r.jsxs)(t.p,{children:["To output a ",(0,r.jsx)(t.code,{children:"Data"})," type, in the ",(0,r.jsx)(t.strong,{children:"Output Format"})," dropdown, select ",(0,r.jsx)(t.strong,{children:"Raw HTML"}),".\nTo output a ",(0,r.jsx)(t.code,{children:"Message"})," type, in the ",(0,r.jsx)(t.strong,{children:"Output Format"})," dropdown, select ",(0,r.jsx)(t.strong,{children:"Text"}),". This option applies postprocessing with the ",(0,r.jsx)(t.code,{children:"data_to_text"})," helper function."]}),"\n",(0,r.jsx)(t.p,{children:"In this example of a document ingestion pipeline, the URL component outputs raw HTML to a text splitter, which splits the raw content into chunks for a vector database to ingest."}),"\n",(0,r.jsx)(t.p,{children:(0,r.jsx)(t.img,{alt:"URL component in a data ingestion pipeline",src:s(80352).A+"",width:"2306",height:"1632"})}),"\n",(0,r.jsx)(t.h2,{id:"api-request",children:"API Request"}),"\n",(0,r.jsx)(t.p,{children:"This component makes HTTP requests using URLs or cURL commands."}),"\n",(0,r.jsx)(t.h3,{id:"inputs",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"urls"}),(0,r.jsx)(t.td,{children:"URLs"}),(0,r.jsx)(t.td,{children:"Enter one or more URLs, separated by commas."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"curl"}),(0,r.jsx)(t.td,{children:"cURL"}),(0,r.jsx)(t.td,{children:"Paste a curl command to populate the dictionary fields for headers and body."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"method"}),(0,r.jsx)(t.td,{children:"Method"}),(0,r.jsx)(t.td,{children:"The HTTP method to use."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_curl"}),(0,r.jsx)(t.td,{children:"Use cURL"}),(0,r.jsx)(t.td,{children:"Enable cURL mode to populate fields from a cURL command."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_params"}),(0,r.jsx)(t.td,{children:"Query Parameters"}),(0,r.jsx)(t.td,{children:"The query parameters to append to the URL."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"body"}),(0,r.jsx)(t.td,{children:"Body"}),(0,r.jsxs)(t.td,{children:["The body to send with the request as a dictionary (for ",(0,r.jsx)(t.code,{children:"POST"}),", ",(0,r.jsx)(t.code,{children:"PATCH"}),", ",(0,r.jsx)(t.code,{children:"PUT"}),")."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"headers"}),(0,r.jsx)(t.td,{children:"Headers"}),(0,r.jsx)(t.td,{children:"The headers to send with the request as a dictionary."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"timeout"}),(0,r.jsx)(t.td,{children:"Timeout"}),(0,r.jsx)(t.td,{children:"The timeout to use for the request."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"follow_redirects"}),(0,r.jsx)(t.td,{children:"Follow Redirects"}),(0,r.jsx)(t.td,{children:"Whether to follow http redirects."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"save_to_file"}),(0,r.jsx)(t.td,{children:"Save to File"}),(0,r.jsx)(t.td,{children:"Save the API response to a temporary file"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"include_httpx_metadata"}),(0,r.jsx)(t.td,{children:"Include HTTPx Metadata"}),(0,r.jsxs)(t.td,{children:["Include properties such as ",(0,r.jsx)(t.code,{children:"headers"}),", ",(0,r.jsx)(t.code,{children:"status_code"}),", ",(0,r.jsx)(t.code,{children:"response_headers"}),", and ",(0,r.jsx)(t.code,{children:"redirection_history"})," in the output."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"The result of the API requests."})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"directory",children:"Directory"}),"\n",(0,r.jsx)(t.p,{children:"This component recursively loads files from a directory, with options for file types, depth, and concurrency."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-1",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"path"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Path to the directory to load files from"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"types"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"File types to load (leave empty to load all types)"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"depth"}),(0,r.jsx)(t.td,{children:"IntInput"}),(0,r.jsx)(t.td,{children:"Depth to search for files"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_concurrency"}),(0,r.jsx)(t.td,{children:"IntInput"}),(0,r.jsx)(t.td,{children:"Maximum concurrency for loading files"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"load_hidden"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, hidden files are loaded"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"recursive"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, the search is recursive"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"silent_errors"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, errors do not raise an exception"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_multithreading"}),(0,r.jsx)(t.td,{children:"BoolInput"}),(0,r.jsx)(t.td,{children:"If true, multithreading is used"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-1",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"List[Data]"}),(0,r.jsx)(t.td,{children:"Loaded file data from the directory"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"file",children:"File"}),"\n",(0,r.jsxs)(t.p,{children:["This component loads and parses files of various supported formats and converts the content into a ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object. It supports multiple file types and provides options for parallel processing and error handling."]}),"\n",(0,r.jsx)(t.p,{children:"To load a document, follow these steps:"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Click the ",(0,r.jsx)(t.strong,{children:"Select files"})," button."]}),"\n",(0,r.jsxs)(t.li,{children:["Select a local file or a file loaded with ",(0,r.jsx)(t.a,{href:"/concepts-file-management",children:"File management"}),", and then click ",(0,r.jsx)(t.strong,{children:"Select file"}),"."]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:"The loaded file name appears in the component."}),"\n",(0,r.jsxs)(t.p,{children:["The default maximum supported file size is 100 MB.\nTo modify this value, see ",(0,r.jsx)(t.a,{href:"/environment-variables#LANGFLOW_MAX_FILE_SIZE_UPLOAD",children:"--max-file-size-upload"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-2",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"path"}),(0,r.jsx)(t.td,{children:"Files"}),(0,r.jsx)(t.td,{children:"Path to file(s) to load. Supports individual files or bundled archives."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"file_path"}),(0,r.jsx)(t.td,{children:"Server File Path"}),(0,r.jsxs)(t.td,{children:["Data object with a ",(0,r.jsx)(t.code,{children:"file_path"})," property pointing to the server file or a Message object with a path to the file. Supersedes 'Path' but supports the same file types."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"separator"}),(0,r.jsx)(t.td,{children:"Separator"}),(0,r.jsx)(t.td,{children:"Specify the separator to use between multiple outputs in Message format."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"silent_errors"}),(0,r.jsx)(t.td,{children:"Silent Errors"}),(0,r.jsx)(t.td,{children:"If true, errors do not raise an exception."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"delete_server_file_after_processing"}),(0,r.jsx)(t.td,{children:"Delete Server File After Processing"}),(0,r.jsx)(t.td,{children:"If true, the Server File Path is deleted after processing."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"ignore_unsupported_extensions"}),(0,r.jsx)(t.td,{children:"Ignore Unsupported Extensions"}),(0,r.jsx)(t.td,{children:"If true, files with unsupported extensions are not processed."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"ignore_unspecified_files"}),(0,r.jsx)(t.td,{children:"Ignore Unspecified Files"}),(0,r.jsxs)(t.td,{children:["If true, ",(0,r.jsx)(t.code,{children:"Data"})," with no ",(0,r.jsx)(t.code,{children:"file_path"})," property is ignored."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"use_multithreading"}),(0,r.jsx)(t.td,{children:"[Deprecated] Use Multithreading"}),(0,r.jsxs)(t.td,{children:["Set 'Processing Concurrency' greater than ",(0,r.jsx)(t.code,{children:"1"})," to enable multithreading. This option is deprecated."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"concurrency_multithreading"}),(0,r.jsx)(t.td,{children:"Processing Concurrency"}),(0,r.jsx)(t.td,{children:"When multiple files are being processed, the number of files to process concurrently. Default is 1. Values greater than 1 enable parallel processing for 2 or more files."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-2",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["Parsed content of the file as a ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"dataframe"}),(0,r.jsx)(t.td,{children:"DataFrame"}),(0,r.jsxs)(t.td,{children:["File content as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#dataframe-object",children:"DataFrame"})," object."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"message"}),(0,r.jsx)(t.td,{children:"Message"}),(0,r.jsxs)(t.td,{children:["File content as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#message-object",children:"Message"})," object."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"supported-file-types",children:"Supported File Types"}),"\n",(0,r.jsx)(t.p,{children:"Text files:"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".txt"})," - Text files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".md"}),", ",(0,r.jsx)(t.code,{children:".mdx"})," - Markdown files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".csv"})," - CSV files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".json"})," - JSON files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".yaml"}),", ",(0,r.jsx)(t.code,{children:".yml"})," - YAML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".xml"})," - XML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".html"}),", ",(0,r.jsx)(t.code,{children:".htm"})," - HTML files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".pdf"})," - PDF files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".docx"})," - Word documents"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".py"})," - Python files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".sh"})," - Shell scripts"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".sql"})," - SQL files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".js"})," - JavaScript files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".ts"}),", ",(0,r.jsx)(t.code,{children:".tsx"})," - TypeScript files"]}),"\n"]}),"\n",(0,r.jsx)(t.p,{children:"Archive formats (for bundling multiple files):"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".zip"})," - ZIP archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".tar"})," - TAR archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".tgz"})," - Gzipped TAR archives"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".bz2"})," - Bzip2 compressed files"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:".gz"})," - Gzip compressed files"]}),"\n"]}),"\n",(0,r.jsx)(t.h2,{id:"gmail-loader",children:"Gmail Loader"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component loads emails from Gmail using provided credentials and filters."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-3",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"json_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"label_ids"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Comma-separated list of label IDs to filter emails"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"max_results"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Maximum number of emails to load"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-3",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Loaded email data"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"google-drive-loader",children:"Google Drive Loader"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component loads documents from Google Drive using provided credentials and a single document ID."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-4",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"json_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"document_id"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"Single Google Drive document ID"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-4",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"docs"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Loaded document data"})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"google-drive-search",children:"Google Drive Search"}),"\n",(0,r.jsx)(t.admonition,{type:"info",children:(0,r.jsxs)(t.p,{children:["Google components are available in the ",(0,r.jsx)(t.strong,{children:"Components"})," menu under ",(0,r.jsx)(t.strong,{children:"Bundles"}),".\nFor more information, see ",(0,r.jsx)(t.a,{href:"/integrations-setup-google-oauth-langflow",children:"Integrate Google OAuth with Langflow"}),"."]})}),"\n",(0,r.jsx)(t.p,{children:"This component searches Google Drive files using provided credentials and query parameters."}),"\n",(0,r.jsxs)(t.p,{children:["For more on creating a service account JSON, see ",(0,r.jsx)(t.a,{href:"https://developers.google.com/identity/protocols/oauth2/service-account",children:"Service Account JSON"}),"."]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-5",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Input"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"token_string"}),(0,r.jsx)(t.td,{children:"SecretStrInput"}),(0,r.jsx)(t.td,{children:"JSON string containing OAuth 2.0 access token information for service account access"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_item"}),(0,r.jsx)(t.td,{children:"DropdownInput"}),(0,r.jsx)(t.td,{children:"The field to query"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"valid_operator"}),(0,r.jsx)(t.td,{children:"DropdownInput"}),(0,r.jsx)(t.td,{children:"Operator to use in the query"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"search_term"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"The value to search for in the specified query item"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query_string"}),(0,r.jsx)(t.td,{children:"MessageTextInput"}),(0,r.jsx)(t.td,{children:"The query string used for searching (can be edited manually)"})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-5",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Output"}),(0,r.jsx)(t.th,{children:"Type"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_urls"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"URLs of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_ids"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"IDs of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"doc_titles"}),(0,r.jsx)(t.td,{children:"List[str]"}),(0,r.jsx)(t.td,{children:"Titles of the found documents"})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsx)(t.td,{children:"Document titles and URLs in a structured format"})]})]})]}),"\n",(0,r.jsx)(t.h2,{id:"sql-query",children:"SQL Query"}),"\n",(0,r.jsx)(t.p,{children:"This component executes SQL queries on a specified database."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-6",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"query"}),(0,r.jsx)(t.td,{children:"Query"}),(0,r.jsx)(t.td,{children:"The SQL query to execute."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"database_url"}),(0,r.jsx)(t.td,{children:"Database URL"}),(0,r.jsx)(t.td,{children:"The URL of the database."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"include_columns"}),(0,r.jsx)(t.td,{children:"Include Columns"}),(0,r.jsx)(t.td,{children:"Include columns in the result."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"passthrough"}),(0,r.jsx)(t.td,{children:"Passthrough"}),(0,r.jsx)(t.td,{children:"If an error occurs, return the query instead of raising an exception."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"add_error"}),(0,r.jsx)(t.td,{children:"Add Error"}),(0,r.jsx)(t.td,{children:"Add the error to the result."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-6",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"result"}),(0,r.jsx)(t.td,{children:"Result"}),(0,r.jsx)(t.td,{children:"The result of the SQL query execution."})]})})]}),"\n",(0,r.jsx)(t.h2,{id:"url",children:"URL"}),"\n",(0,r.jsx)(t.p,{children:"This component fetches content from one or more URLs, processes the content, and returns it in various formats. It supports output in plain text, raw HTML, or JSON, with options for cleaning and separating multiple outputs."}),"\n",(0,r.jsx)(t.h3,{id:"inputs-7",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"urls"}),(0,r.jsx)(t.td,{children:"URLs"}),(0,r.jsx)(t.td,{children:"Enter one or more URLs. URLs are automatically validated and cleaned."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"format"}),(0,r.jsx)(t.td,{children:"Output Format"}),(0,r.jsxs)(t.td,{children:["Output Format. Use ",(0,r.jsx)(t.strong,{children:"Text"})," to extract text from the HTML, ",(0,r.jsx)(t.strong,{children:"Raw HTML"})," for the raw HTML content, or ",(0,r.jsx)(t.strong,{children:"JSON"})," to extract JSON from the HTML."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"separator"}),(0,r.jsx)(t.td,{children:"Separator"}),(0,r.jsxs)(t.td,{children:["Specify the separator to use between multiple outputs. Default for ",(0,r.jsx)(t.strong,{children:"Text"})," is ",(0,r.jsx)(t.code,{children:"\\n\\n"}),". Default for ",(0,r.jsx)(t.strong,{children:"Raw HTML"})," is ",(0,r.jsx)(t.code,{children:"\\n\x3c!-- Separator --\x3e\\n"}),"."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"clean_extra_whitespace"}),(0,r.jsx)(t.td,{children:"Clean Extra Whitespace"}),(0,r.jsxs)(t.td,{children:["Whether to clean excessive blank lines in the text output. Only applies to ",(0,r.jsx)(t.code,{children:"Text"})," format."]})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-7",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Info"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["List of ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," objects containing fetched content and metadata."]})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"text"}),(0,r.jsx)(t.td,{children:"Text"}),(0,r.jsx)(t.td,{children:"Fetched content as formatted text, with applied separators and cleaning."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"dataframe"}),(0,r.jsx)(t.td,{children:"DataFrame"}),(0,r.jsxs)(t.td,{children:["Content formatted as a ",(0,r.jsx)(t.a,{href:"/concepts-objects#dataframe-object",children:"Data"})," object."]})]})]})]}),"\n",(0,r.jsx)(t.h2,{id:"webhook",children:"Webhook"}),"\n",(0,r.jsx)(t.p,{children:"This component defines a webhook trigger that runs a flow when it receives an HTTP POST request."}),"\n",(0,r.jsxs)(t.p,{children:["If the input is not valid JSON, the component wraps it in a ",(0,r.jsx)(t.code,{children:"payload"})," object so that it can be processed and still trigger the flow. The component does not require an API key."]}),"\n",(0,r.jsxs)(t.p,{children:["When a ",(0,r.jsx)(t.strong,{children:"Webhook"})," component is added to the workspace, a new ",(0,r.jsx)(t.strong,{children:"Webhook cURL"})," tab becomes available in the ",(0,r.jsx)(t.strong,{children:"API"})," pane that contains an HTTP POST request for triggering the webhook component. For example:"]}),"\n",(0,r.jsx)(h.Code,{codeConfig:a,northPanel:{tabs:[""],active:"",heightRatio:1},files:[{name:"",focus:"",code:{lines:[{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://127.0.0.1:7860/api/v1/webhook/**YOUR_FLOW_ID**" ',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:'\'{"any": "data"}\'',props:{style:{color:"#A5D6FF"}}}]}],lang:"bash"},annotations:[]}]}),"\n",(0,r.jsx)(t.p,{children:"To test the webhook component:"}),"\n",(0,r.jsxs)(t.ol,{children:["\n",(0,r.jsxs)(t.li,{children:["Add a ",(0,r.jsx)(t.strong,{children:"Webhook"})," component to the flow."]}),"\n",(0,r.jsxs)(t.li,{children:["Connect the ",(0,r.jsx)(t.strong,{children:"Webhook"})," component's ",(0,r.jsx)(t.strong,{children:"Data"})," output to the ",(0,r.jsx)(t.strong,{children:"Data"})," input of a ",(0,r.jsx)(t.a,{href:"/components-processing#data-to-message",children:"Data to Message"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["Connect the ",(0,r.jsx)(t.strong,{children:"Data to Message"})," component's ",(0,r.jsx)(t.strong,{children:"Message"})," output to the ",(0,r.jsx)(t.strong,{children:"Text"})," input of a ",(0,r.jsx)(t.a,{href:"/components-io#chat-output",children:"Chat Output"})," component."]}),"\n",(0,r.jsxs)(t.li,{children:["To send a POST request, copy the code from the ",(0,r.jsx)(t.strong,{children:"Webhook cURL"})," tab in the ",(0,r.jsx)(t.strong,{children:"API"})," pane and paste it into a terminal."]}),"\n",(0,r.jsx)(t.li,{children:"Send the POST request."}),"\n",(0,r.jsxs)(t.li,{children:["Open the ",(0,r.jsx)(t.strong,{children:"Playground"}),".\nYour JSON data is posted to the ",(0,r.jsx)(t.strong,{children:"Chat Output"})," component, which indicates that the webhook component is correctly triggering the flow."]}),"\n"]}),"\n",(0,r.jsx)(t.h3,{id:"inputs-8",children:"Inputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsxs)(t.tbody,{children:[(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"data"}),(0,r.jsx)(t.td,{children:"Payload"}),(0,r.jsx)(t.td,{children:"Receives a payload from external systems through HTTP POST requests."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"curl"}),(0,r.jsx)(t.td,{children:"cURL"}),(0,r.jsx)(t.td,{children:"The cURL command template for making requests to this webhook."})]}),(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"endpoint"}),(0,r.jsx)(t.td,{children:"Endpoint"}),(0,r.jsx)(t.td,{children:"The endpoint URL where this webhook receives requests."})]})]})]}),"\n",(0,r.jsx)(t.h3,{id:"outputs-8",children:"Outputs"}),"\n",(0,r.jsxs)(t.table,{children:[(0,r.jsx)(t.thead,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.th,{children:"Name"}),(0,r.jsx)(t.th,{children:"Display Name"}),(0,r.jsx)(t.th,{children:"Description"})]})}),(0,r.jsx)(t.tbody,{children:(0,r.jsxs)(t.tr,{children:[(0,r.jsx)(t.td,{children:"output_data"}),(0,r.jsx)(t.td,{children:"Data"}),(0,r.jsxs)(t.td,{children:["Outputs processed data from the webhook input, and returns an empty ",(0,r.jsx)(t.a,{href:"/concepts-objects",children:"Data"})," object if no input is provided. If the input is not valid JSON, the component wraps it in a ",(0,r.jsx)(t.code,{children:"payload"})," object."]})]})})]})]})}function p(e={}){const{wrapper:t}={...(0,d.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(j,{...e})}):j(e)}function u(e,t){throw new Error("Expected "+(t?"component":"object")+" `"+e+"` to be defined: you likely forgot to import, pass, or provide it.")}},80352:(e,t,s)=>{s.d(t,{A:()=>n});const n=s.p+"assets/images/url-component-fb712df73581345c0f344013ce6ff2fd.png"}}]); \ No newline at end of file diff --git a/assets/js/main.474ff10e.js b/assets/js/main.474ff10e.js deleted file mode 100644 index e3bdf805f8..0000000000 --- a/assets/js/main.474ff10e.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! For license information please see main.474ff10e.js.LICENSE.txt */ -(self.webpackChunklangflow_docs=self.webpackChunklangflow_docs||[]).push([[8792],{204:(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}`},layout:{},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"}}},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),l=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)?l(r.call(e)):l(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 l=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 l.name="Invariant Violation",l}}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 l=Object.prototype.hasOwnProperty.bind(t),s=0;s{"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="",k="",x="",S="",E={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){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 y(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,l="",s=!1,c=j(e),u=c.split("\n"),p=j(t).split("\n"),d=0,f="";if("strictEqual"===n&&"object"===h(e)&&"object"===h(t)&&null!==e&&null!==t&&(n="strictEqualObject"),1===u.length&&1===p.length&&u[0]!==p[0]){var m=u[0].length+p[0].length;if(m<=10){if(!("object"===h(e)&&null!==e||"object"===h(t)&&null!==t||0===e&&0===t))return"".concat(E[n],"\n\n")+"".concat(u[0]," !== ").concat(p[0],"\n")}else if("strictEqualObject"!==n){if(m<(r.stderr&&r.stderr.isTTY?r.stderr.columns:80)){for(;u[0][d]===p[0][d];)d++;d>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)}(" ",d),"^"),d=0)}}}for(var g=u[u.length-1],y=p[p.length-1];g===y&&(d++<2?l="\n ".concat(g).concat(l):o=g,u.pop(),p.pop(),0!==u.length&&0!==p.length);)g=u[u.length-1],y=p[p.length-1];var b=Math.max(u.length,p.length);if(0===b){var _=c.split("\n");if(_.length>30)for(_[26]="".concat(w,"...").concat(S);_.length>27;)_.pop();return"".concat(E.notIdentical,"\n\n").concat(_.join("\n"),"\n")}d>3&&(l="\n".concat(w,"...").concat(S).concat(l),s=!0),""!==o&&(l="\n ".concat(o).concat(l),o="");var O=0,A=E[n]+"\n".concat(k,"+ actual").concat(S," ").concat(x,"- expected").concat(S),C=" ".concat(w,"...").concat(S," Lines skipped");for(d=0;d1&&d>2&&(P>4?(a+="\n".concat(w,"...").concat(S),s=!0):P>3&&(a+="\n ".concat(p[d-2]),O++),a+="\n ".concat(p[d-1]),O++),i=d,o+="\n".concat(x,"-").concat(S," ").concat(p[d]),O++;else if(p.length1&&d>2&&(P>4?(a+="\n".concat(w,"...").concat(S),s=!0):P>3&&(a+="\n ".concat(u[d-2]),O++),a+="\n ".concat(u[d-1]),O++),i=d,a+="\n".concat(k,"+").concat(S," ").concat(u[d]),O++;else{var T=p[d],I=u[d],R=I!==T&&(!v(I,",")||I.slice(0,-1)!==T);R&&v(T,",")&&T.slice(0,-1)===I&&(R=!1,I+=","),R?(P>1&&d>2&&(P>4?(a+="\n".concat(w,"...").concat(S),s=!0):P>3&&(a+="\n ".concat(u[d-2]),O++),a+="\n ".concat(u[d-1]),O++),i=d,a+="\n".concat(k,"+").concat(S," ").concat(I),o+="\n".concat(x,"-").concat(S," ").concat(T),O+=2):(a+=o,o="",1!==P&&0!==d||(a+="\n ".concat(I),O++))}if(O>20&&d30)for(f[26]="".concat(w,"...").concat(S);f.length>27;)f.pop();t=1===f.length?d.call(this,"".concat(p," ").concat(f[0])):d.call(this,"".concat(p,"\n\n").concat(f.join("\n"),"\n"))}else{var m=j(i),g="",y=E[o];"notDeepEqual"===o||"notEqual"===o?(m="".concat(E[o],"\n\n").concat(m)).length>1024&&(m="".concat(m.slice(0,1021),"...")):(g="".concat(j(l)),m.length>512&&(m="".concat(m.slice(0,509),"...")),g.length>512&&(g="".concat(g.slice(0,509),"...")),"deepEqual"===o||"equal"===o?m="".concat(y,"\n\n").concat(m,"\n\nshould equal\n\n"):g=" ".concat(o," ").concat(g)),t=d.call(this,"".concat(m).concat(g))}return Error.stackTraceLimit=s,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=l,t.operator=o,Error.captureStackTrace&&Error.captureStackTrace(u(t),a),t.stack,t.name="AssertionError",c(t)}return i=v,(s=[{key:"toString",value:function(){return"".concat(this.name," [").concat(this.code,"]: ").concat(this.message)}},{key:t,value:function(e,t){return y(this,a(a({},t),{},{customInspect:!1,depth:0}))}}])&&l(i.prototype,s),p&&l(i,p),Object.defineProperty(i,"prototype",{writable:!1}),v}(p(Error),y.custom);e.exports=A},4023:(e,t,n)=>{"use strict";n.d(t,{A:()=>g});var r=n(96540),o=n(61934),a=n(27143),i=n(30099),l=n(54051),s=n(75313),c=n(74848);function u(e){let{error:t,tryAgain:n}=e;return(0,c.jsxs)("div",{style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",minHeight:"100vh",width:"100%",maxWidth:"80ch",fontSize:"20px",margin:"0 auto",padding:"1rem"},children:[(0,c.jsx)("h1",{style:{fontSize:"3rem"},children:"This page crashed"}),(0,c.jsx)("button",{type:"button",onClick:n,style:{margin:"1rem 0",fontSize:"2rem",cursor:"pointer",borderRadius:20,padding:"1rem"},children:"Try again"}),(0,c.jsx)(p,{error:t})]})}function p(e){let{error:t}=e;const n=(0,i.rA)(t).map((e=>e.message)).join("\n\nCause:\n");return(0,c.jsx)("p",{style:{whiteSpace:"pre-wrap"},children:n})}function d(e){let{children:t}=e;return(0,c.jsx)(s.W,{value:{plugin:{name:"docusaurus-core-error-boundary",id:"default"}},children:t})}function f(e){let{error:t,tryAgain:n}=e;return(0,c.jsx)(d,{children:(0,c.jsxs)(g,{fallback:()=>(0,c.jsx)(u,{error:t,tryAgain:n}),children:[(0,c.jsx)(a.A,{children:(0,c.jsx)("title",{children:"Page Error"})}),(0,c.jsx)(l.A,{children:(0,c.jsx)(u,{error:t,tryAgain:n})})]})})}const m=e=>(0,c.jsx)(f,{...e});class g extends r.Component{constructor(e){super(e),this.state={error:null}}componentDidCatch(e){o.A.canUseDOM&&this.setState({error:e})}render(){const{children:e}=this.props,{error:t}=this.state;if(t){const e={error:t,tryAgain:()=>this.setState({error:null})};return(this.props.fallback??m)(e)}return e??null}}},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},l={};function s(e){return r.isMemo(e)?i:l[e.$$typeof]||o}l[r.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},l[r.Memo]=i;var c=Object.defineProperty,u=Object.getOwnPropertyNames,p=Object.getOwnPropertySymbols,d=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);p&&(i=i.concat(p(n)));for(var l=s(t),g=s(n),h=0;h{"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"}}],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},gtag:{trackingID:"G-XHC7G628ZP",anonymizeIP:!0},googleTagManager:{containerId:"GTM-NK5M4ZT8"},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",["@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:"/concepts-objects",from:["/guides-data-message","/configuration-objects"]},{to:"/blog-writer",from:["/starter-projects-blog-writer","/tutorials-blog-writer"]},{to:"/memory-chatbot",from:["/starter-projects-memory-chatbot","/tutorials-memory-chatbot"]},{to:"/document-qa",from:["/starter-projects-document-qa","/tutorials-document-qa"]},{to:"/math-agent",from:["/starter-projects-math-agent","/tutorials-math-agent"]},{to:"/sequential-agent",from:["/starter-projects-sequential-agent","/tutorials-sequential-agent"]},{to:"/travel-planning-agent",from:["/starter-projects-travel-planning-agent","/tutorials-travel-planning-agent","/starter-projects-dynamic-agent/"]},{to:"/components-vector-stores",from:"/components-rag"},{to:"/concepts-publish",from:["/concepts-api","/workspace-api"]},{to:"/components-custom-components",from:"/components/custom"}]}],null],themeConfig:{navbar:{hideOnScroll:!0,logo:{alt:"Langflow",src:"img/langflow-logo-black.svg",srcDark:"img/langflow-logo-white.svg"},items:[{position:"right",href:"https://github.com/langflow-ai/langflow",className:"header-github-link",target:"_blank",rel:null},{position:"right",href:"https://twitter.com/langflow_ai",className:"header-twitter-link",target:"_blank",rel:null},{position:"right",href:"https://discord.gg/EqksyE2EX9",className:"header-discord-link",target:"_blank",rel:null}]},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"},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:{experimental_faster:{swcJsLoader:!1,swcJsMinimizer:!1,swcHtmlMinimizer:!1,lightningCssMinimizer:!1,mdxCrossCompilerCache:!1,rspackBundler:!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}}}},5338:(e,t,n)=>{"use strict";var r=n(40961);t.createRoot=r.createRoot,t.hydrateRoot=r.hydrateRoot},5528:(e,t,n)=>{"use strict";n.d(t,{M:()=>f,e:()=>d});var r=n(96540),o=n(63065),a=n(86682),i=n(30604),l=n(53115),s=n(26849),c=n(74848);const u=r.createContext(void 0);function p(){const e=function(){const e=(0,o.YL)(),{items:t}=(0,l.p)().navbar;return 0===t.length&&!e.component}(),t=(0,a.l)(),n=!e&&"mobile"===t,[s,c]=(0,r.useState)(!1);(0,i.$Z)((()=>{if(s)return c(!1),!1}));const u=(0,r.useCallback)((()=>{c((e=>!e))}),[]);return(0,r.useEffect)((()=>{"desktop"===t&&c(!1)}),[t]),(0,r.useMemo)((()=>({disabled:e,shouldRender:n,toggle:u,shown:s})),[e,n,u,s])}function d(e){let{children:t}=e;const n=p();return(0,c.jsx)(u.Provider,{value:n,children:t})}function f(){const e=r.useContext(u);if(void 0===e)throw new s.dV("NavbarMobileSidebarProvider");return e}},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,p=r.easing;return a.offsetWidth,l((function(t){""===r.positionUsing&&(r.positionUsing=n.getPositioningCSS()),s(c,i(e,u,p)),1===e?(s(a,{transition:"none",opacity:1}),a.offsetWidth,setTimeout((function(){s(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),l=e?"-100":a(n.status||0),c=document.querySelector(r.parent);return s(i,{transition:"all 0 linear",transform:"translate3d("+l+"%,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(){p(document.documentElement,"nprogress-busy"),p(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 l=function(){var e=[];function t(){var n=e.shift();n&&n(t)}return function(n){e.push(n),1==e.length&&t()}}(),s=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:d(e)).indexOf(" "+t+" ")>=0}function u(e,t){var n=d(e),r=n+t;c(n,t)||(e.className=r.substring(1))}function p(e,t){var n,r=d(e);c(e,t)&&(n=r.replace(" "+t+" "," "),e.className=n.substring(1,n.length-1))}function d(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)},6188:e=>{"use strict";e.exports=Math.max},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__"),l=Object,s=l.getPrototypeOf;e.exports=i&&"function"==typeof i.get?o([i.get]):"function"==typeof s&&function(e){return s(null==e?e:l(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;rl(s,n))cl(u,s)?(e[r]=u,e[c]=n,r=c):(e[r]=s,e[i]=n,r=i);else{if(!(cl(u,n)))break e;e[r]=u,e[c]=n,r=c}}}return t}function l(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 s=performance;t.unstable_now=function(){return s.now()}}else{var c=Date,u=c.now();t.unstable_now=function(){return c.now()-u}}var p=[],d=[],f=1,m=null,g=3,h=!1,y=!1,b=!1,v="function"==typeof setTimeout?setTimeout:null,w="function"==typeof clearTimeout?clearTimeout:null,k="undefined"!=typeof setImmediate?setImmediate:null;function x(e){for(var t=a(d);null!==t;){if(null===t.callback)i(d);else{if(!(t.startTime<=e))break;i(d),t.sortIndex=t.expirationTime,o(p,t)}t=a(d)}}function S(e){if(b=!1,x(e),!y)if(null!==a(p))y=!0,D(E);else{var t=a(d);null!==t&&L(S,t.startTime-e)}}function E(e,n){y=!1,b&&(b=!1,w(A),A=-1),h=!0;var r=g;try{for(x(n),m=a(p);null!==m&&(!(m.expirationTime>n)||e&&!T());){var o=m.callback;if("function"==typeof o){m.callback=null,g=m.priorityLevel;var l=o(m.expirationTime<=n);n=t.unstable_now(),"function"==typeof l?m.callback=l:m===a(p)&&i(p),x(n)}else i(p);m=a(p)}if(null!==m)var s=!0;else{var c=a(d);null!==c&&L(S,c.startTime-n),s=!1}return s}finally{m=null,g=r,h=!1}}"undefined"!=typeof navigator&&void 0!==navigator.scheduling&&void 0!==navigator.scheduling.isInputPending&&navigator.scheduling.isInputPending.bind(navigator.scheduling);var _,j=!1,O=null,A=-1,C=5,P=-1;function T(){return!(t.unstable_now()-Pe||125i?(e.sortIndex=r,o(d,e),null===a(p)&&e===a(d)&&(b?(w(A),A=-1):b=!0,L(S,r-i))):(e.sortIndex=l,o(p,e),y||h||(y=!0,D(E))),e},t.unstable_shouldYield=T,t.unstable_wrapCallback=function(e){var t=g;return function(){var n=g;g=t;try{return e.apply(this,arguments)}finally{g=n}}}},8505:(e,t,n)=>{var r=n(64634);e.exports=m,e.exports.parse=a,e.exports.compile=function(e,t){return s(a(e,t),t)},e.exports.tokensToFunction=s,e.exports.tokensToRegExp=f;var o=new RegExp(["(\\\\.)","([\\/.])?(?:(?:\\:(\\w+)(?:\\(((?:\\\\.|[^\\\\()])+)\\))?|\\(((?:\\\\.|[^\\\\()])+)\\))([+*?])?|(\\*))"].join("|"),"g");function a(e,t){for(var n,r=[],a=0,l=0,s="",c=t&&t.delimiter||"/";null!=(n=o.exec(e));){var p=n[0],d=n[1],f=n.index;if(s+=e.slice(l,f),l=f+p.length,d)s+=d[1];else{var m=e[l],g=n[2],h=n[3],y=n[4],b=n[5],v=n[6],w=n[7];s&&(r.push(s),s="");var k=null!=g&&null!=m&&m!==g,x="+"===v||"*"===v,S="?"===v||"*"===v,E=g||c,_=y||b,j=g||("string"==typeof r[r.length-1]?r[r.length-1]:"");r.push({name:h||a++,prefix:g||"",delimiter:E,optional:S,repeat:x,partial:k,asterisk:!!w,pattern:_?u(_):w?".*":i(E,j)})}}return l-1?"[^"+c(e)+"]+?":c(t)+"|(?:(?!"+c(t)+")[^"+c(e)+"])+?"}function l(e){return encodeURI(e).replace(/[\/?#]/g,(function(e){return"%"+e.charCodeAt(0).toString(16).toUpperCase()}))}function s(e,t){for(var n=new Array(e.length),o=0;o{"use strict";n.d(t,{G:()=>y,a:()=>h});var r=n(96540),o=n(61934),a=n(26849),i=n(78749),l=n(53115),s=n(74848);const c=r.createContext(void 0),u="theme",p=(0,i.Wf)(u),d={light:"light",dark:"dark"},f=e=>e===d.dark?d.dark:d.light,m=e=>o.A.canUseDOM?f(document.documentElement.getAttribute("data-theme")):f(e),g=e=>{p.set(f(e))};function h(e){let{children:t}=e;const n=function(){const{colorMode:{defaultMode:e,disableSwitch:t,respectPrefersColorScheme:n}}=(0,l.p)(),[o,a]=(0,r.useState)(m(e));(0,r.useEffect)((()=>{t&&p.del()}),[t]);const i=(0,r.useCallback)((function(t,r){void 0===r&&(r={});const{persist:o=!0}=r;t?(a(t),o&&g(t)):(a(n?window.matchMedia("(prefers-color-scheme: dark)").matches?d.dark:d.light:e),p.del())}),[n,e]);(0,r.useEffect)((()=>{document.documentElement.setAttribute("data-theme",f(o))}),[o]),(0,r.useEffect)((()=>{if(t)return;const e=e=>{if(e.key!==u)return;const t=p.get();null!==t&&i(f(t))};return window.addEventListener("storage",e),()=>window.removeEventListener("storage",e)}),[t,i]);const s=(0,r.useRef)(!1);return(0,r.useEffect)((()=>{if(t&&!n)return;const e=window.matchMedia("(prefers-color-scheme: dark)"),r=()=>{window.matchMedia("print").matches||s.current?s.current=window.matchMedia("print").matches:i(null)};return e.addListener(r),()=>e.removeListener(r)}),[i,t,n]),(0,r.useMemo)((()=>({colorMode:o,setColorMode:i,get isDarkTheme(){return o===d.dark},setLightTheme(){i(d.light)},setDarkTheme(){i(d.dark)}})),[o,i])}();return(0,s.jsx)(c.Provider,{value:n,children:t})}function y(){const e=(0,r.useContext)(c);if(null==e)throw new a.dV("ColorModeProvider","Please see https://docusaurus.io/docs/api/themes/configuration#use-color-mode.");return e}},8722:(e,t,n)=>{var r=n(96763);const o=n(6969),a=n(98380),i=new Set;function l(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(l.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)}))}l.silent=!1,e.exports=l},9136:(e,t,n)=>{"use strict";n.d(t,{A:()=>a});var r=n(96540),o=n(84974);function a(){return(0,r.useContext)(o.o)}},9303:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});n(96540);var r=n(18215),o=n(50539),a=n(53115),i=n(56289),l=n(25246);const s={anchorWithStickyNavbar:"anchorWithStickyNavbar_LWe7",anchorWithHideOnScrollNavbar:"anchorWithHideOnScrollNavbar_WYt5"};var c=n(74848);function u(e){let{as:t,id:n,...u}=e;const p=(0,l.A)(),{navbar:{hideOnScroll:d}}=(0,a.p)();if("h1"===t||!n)return(0,c.jsx)(t,{...u,id:void 0});p.collectAnchor(n);const f=(0,o.T)({id:"theme.common.headingLinkTitle",message:"Direct link to {heading}",description:"Title for link to heading"},{heading:"string"==typeof u.children?u.children:n});return(0,c.jsxs)(t,{...u,className:(0,r.A)("anchor",d?s.anchorWithHideOnScrollNavbar:s.anchorWithStickyNavbar,u.className),id:n,children:[u.children,(0,c.jsx)(i.A,{className:"hash-link",to:`#${n}`,"aria-label":f,title:f,children:"\u200b"})]})}},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},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)}}},11835:(e,t,n)=>{"use strict";n.d(t,{c:()=>o});var r=n(40797);function o(){const{siteConfig:{themeConfig:e}}=(0,r.A)();return e}},11861:(e,t,n)=>{"use strict";function r(e,t){return void 0===t&&(t=(e,t)=>e===t),e.filter(((n,r)=>e.findIndex((e=>t(e,n)))!==r))}function o(e){return Array.from(new Set(e))}n.d(t,{XI:()=>r,sb:()=>o})},12205:(e,t,n)=>{"use strict";var r=n(66743),o=n(11002),a=n(13144);e.exports=function(){return a(r,o,arguments)}},12862:(e,t,n)=>{"use strict";n.d(t,{A:()=>u});n(96540);var r=n(56289),o=n(29030),a=n(40797),i=n(53115),l=n(39324),s=n(74848);function c(e){let{logo:t,alt:n,imageClassName:r}=e;const a={light:(0,o.Ay)(t.src),dark:(0,o.Ay)(t.srcDark||t.src)},i=(0,s.jsx)(l.A,{className:t.className,sources:a,height:t.height,width:t.width,alt:n,style:t.style});return r?(0,s.jsx)("div",{className:r,children:i}):i}function u(e){const{siteConfig:{title:t}}=(0,a.A)(),{navbar:{title:n,logo:l}}=(0,i.p)(),{imageClassName:u,titleClassName:p,...d}=e,f=(0,o.Ay)(l?.href||"/"),m=n?"":t,g=l?.alt??m;return(0,s.jsxs)(r.A,{to:f,...d,...l?.target&&{target:l.target},children:[l&&(0,s.jsx)(c,{logo:l,alt:g,imageClassName:u}),null!=n&&(0,s.jsx)("b",{className:p,children:n})]})}},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)},13722:(e,t,n)=>{"use strict";n.d(t,{A:()=>o});const r=e=>"object"==typeof e&&!!e&&Object.keys(e).length>0;function o(e){const t={};return function e(n,o){Object.entries(n).forEach((n=>{let[a,i]=n;const l=o?`${o}.${a}`:a;r(i)?e(i,l):t[l]=i}))}(e),t}},14035:(e,t,n)=>{"use strict";var r,o=n(36556),a=n(49092)(),i=n(9957),l=n(75795);if(a){var s=o("RegExp.prototype.exec"),c={},u=function(){throw c},p={toString:u,valueOf:u};"symbol"==typeof Symbol.toPrimitive&&(p[Symbol.toPrimitive]=u),r=function(e){if(!e||"object"!=typeof e)return!1;var t=l(e,"lastIndex");if(!(t&&i(t,"value")))return!1;try{s(e,p)}catch(n){return n===c}}}else{var d=o("Object.prototype.toString");r=function(e){return!(!e||"object"!=typeof e&&"function"!=typeof e)&&"[object RegExp]"===d(e)}}e.exports=r},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"),l=Symbol.for("react.provider"),s=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),u=Symbol.for("react.suspense"),p=Symbol.for("react.memo"),d=Symbol.for("react.lazy"),f=Symbol.iterator;var m={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},g=Object.assign,h={};function y(e,t,n){this.props=e,this.context=t,this.refs=h,this.updater=n||m}function b(){}function v(e,t,n){this.props=e,this.context=t,this.refs=h,this.updater=n||m}y.prototype.isReactComponent={},y.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")},y.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")},b.prototype=y.prototype;var w=v.prototype=new b;w.constructor=v,g(w,y.prototype),w.isPureReactComponent=!0;var k=Array.isArray,x=Object.prototype.hasOwnProperty,S={current:null},E={key:!0,ref:!0,__self:!0,__source:!0};function _(e,t,r){var o,a={},i=null,l=null;if(null!=t)for(o in void 0!==t.ref&&(l=t.ref),void 0!==t.key&&(i=""+t.key),t)x.call(t,o)&&!E.hasOwnProperty(o)&&(a[o]=t[o]);var s=arguments.length-2;if(1===s)a.children=r;else if(1{"use strict";n.d(t,{A:()=>a});n(96540);const r={iconExternalLink:"iconExternalLink_nPIU"};var o=n(74848);function a(e){let{width:t=13.5,height:n=13.5}=e;return(0,o.jsx)("svg",{width:t,height:n,"aria-hidden":"true",viewBox:"0 0 24 24",className:r.iconExternalLink,children:(0,o.jsx)("path",{fill:"currentColor",d:"M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"})})}},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,l=i.length;-1!==n.code.indexOf(o=t(r,l));)++l;return i[l]=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(l){for(var s=0;s=a.length);s++){var c=l[s];if("string"==typeof c||c.content&&"string"==typeof c.content){var u=a[o],p=n.tokenStack[u],d="string"==typeof c?c:c.content,f=t(r,u),m=d.indexOf(f);if(m>-1){++o;var g=d.substring(0,m),h=new e.Token(r,e.tokenize(p,n.grammar),"language-"+r,p),y=d.substring(m+f.length),b=[];g&&b.push.apply(b,i([g])),b.push(h),y&&b.push.apply(b,i([y])),"string"==typeof c?l.splice.apply(l,[s,1].concat(b)):c.content=b}}else c.content&&i(c.content)}return l}(n.tokens)}}}})}(Prism)},20311:e=>{"use strict";e.exports=function(e,t,n,r,o,a,i,l){if(!e){var s;if(void 0===t)s=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,l],u=0;(s=new Error(t.replace(/%s/g,(function(){return c[u++]})))).name="Invariant Violation"}throw s.framesToPop=1,s}}},21020:(e,t,n)=>{"use strict";var r=n(96540),o=Symbol.for("react.element"),a=Symbol.for("react.fragment"),i=Object.prototype.hasOwnProperty,l=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={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)&&!s.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:l.current}}t.Fragment=a,t.jsx=c,t.jsxs=c},21683:(e,t,n)=>{"use strict";n.r(t)},21858:(e,t,n)=>{"use strict";n.d(t,{n:()=>l,r:()=>s});var r=n(96540),o=n(26849),a=n(74848);const i=r.createContext(null);function l(e){let{children:t,version:n}=e;return(0,a.jsx)(i.Provider,{value:n,children:t})}function s(){const e=(0,r.useContext)(i);if(null===e)throw new o.dV("DocsVersionProvider");return e}},22306:(e,t,n)=>{"use strict";n.d(t,{V:()=>s,t:()=>c});var r=n(96540),o=n(26849),a=n(74848);const i=Symbol("EmptyContext"),l=r.createContext(i);function s(e){let{children:t,name:n,items:o}=e;const i=(0,r.useMemo)((()=>n&&o?{name:n,items:o}:null),[n,o]);return(0,a.jsx)(l.Provider,{value:i,children:t})}function c(){const e=(0,r.useContext)(l);if(e===i)throw new o.dV("DocsSidebarProvider");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