merge fix

This commit is contained in:
cristhianzl 2024-03-27 16:29:32 -03:00
commit cfc2913e9c
87 changed files with 4957 additions and 485 deletions

View file

@ -32,12 +32,15 @@ jobs:
pipx install poetry==$POETRY_VERSION
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
id: setup-python
with:
python-version: ${{ matrix.python-version }}
cache: poetry
- name: Install dependencies
- name: Install Python dependencies
run: |
poetry env use ${{ matrix.python-version }}
poetry install
if: ${{ steps.setup-python.outputs.cache-hit != 'true' }}
- name: Analysing the code with our lint
run: |
make lint

View file

@ -15,7 +15,7 @@ on:
- "src/backend/**"
env:
POETRY_VERSION: "1.5.0"
POETRY_VERSION: "1.8.2"
jobs:
build:
@ -33,11 +33,15 @@ jobs:
run: pipx install poetry==$POETRY_VERSION
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
id: setup-python
with:
python-version: ${{ matrix.python-version }}
cache: "poetry"
- name: Install dependencies
run: poetry install
- name: Install Python dependencies
run: |
poetry env use ${{ matrix.python-version }}
poetry install
if: ${{ steps.setup-python.outputs.cache-hit != 'true' }}
- name: Run unit tests
run: |
make tests

149
.github/workflows/typescript_test.yml vendored Normal file
View file

@ -0,0 +1,149 @@
name: Run Frontend Tests
on:
pull_request:
paths:
- "src/frontend/**"
env:
POETRY_VERSION: "1.8.2"
NODE_VERSION: "21"
PYTHON_VERSION: "3.10"
# Define the directory where Playwright browsers will be installed.
# Adjust if your project uses a different path.
PLAYWRIGHT_BROWSERS_PATH: "ms-playwright"
jobs:
setup-and-test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
shardIndex: [1, 2, 3, 4]
shardTotal: [4]
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v3
id: setup-node
with:
node-version: ${{ env.NODE_VERSION }}
cache: "npm"
- name: Install Node.js dependencies
run: |
cd src/frontend
npm ci
if: ${{ steps.setup-node.outputs.cache-hit != 'true' }}
# Attempt to restore the correct Playwright browser binaries based on the
# currently installed version of Playwright (The browser binary versions
# may change with Playwright versions).
# Note: Playwright's cache directory is hard coded because that's what it
# says to do in the docs. There doesn't appear to be a command that prints
# it out for us.
# - uses: actions/cache@v4
# id: playwright-cache
# with:
# path: ${{ env.PLAYWRIGHT_BROWSERS_PATH }}
# key: "${{ runner.os }}-playwright-${{ hashFiles('src/frontend/package-lock.json') }}"
# # As a fallback, if the Playwright version has changed, try use the
# # most recently cached version. There's a good chance that at least one
# # of the browser binary versions haven't been updated, so Playwright can
# # skip installing that in the next step.
# # Note: When falling back to an old cache, `cache-hit` (used below)
# # will be `false`. This allows us to restore the potentially out of
# # date cache, but still let Playwright decide if it needs to download
# # new binaries or not.
# restore-keys: |
# ${{ runner.os }}-playwright-
- name: Cache playwright binaries
uses: actions/cache@v4
id: playwright-cache
with:
path: |
~/.cache/ms-playwright
key: ${{ runner.os }}-playwright-${{ hashFiles('src/frontend/package-lock.json') }}
- name: Install Frontend dependencies
run: |
cd src/frontend
npm ci
- name: Install Playwright's browser binaries
run: |
cd src/frontend
npx playwright install --with-deps
if: steps.playwright-cache.outputs.cache-hit != 'true'
- name: Install Playwright's dependencies
run: |
cd src/frontend
npx playwright install-deps
if: steps.playwright-cache.outputs.cache-hit != 'true'
# If the Playwright browser binaries weren't able to be restored, we tell
# paywright to install everything for us.
# - name: Install Playwright's dependencies
# if: steps.playwright-cache.outputs.cache-hit != 'true'
# run: npx playwright install --with-deps
- name: Install Poetry
run: pipx install "poetry==${{ env.POETRY_VERSION }}"
- name: Set up Python
uses: actions/setup-python@v5
id: setup-python
with:
python-version: ${{ env.PYTHON_VERSION }}
cache: "poetry"
- name: Install Python dependencies
run: |
poetry env use ${{ env.PYTHON_VERSION }}
poetry install
if: ${{ steps.setup-python.outputs.cache-hit != 'true' }}
- name: Run Playwright Tests
run: |
cd src/frontend
npx playwright test --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
- name: Upload blob report to GitHub Actions Artifacts
if: always()
uses: actions/upload-artifact@v4
with:
name: blob-report-${{ matrix.shardIndex }}
path: src/frontend/blob-report
retention-days: 1
merge-reports:
needs: setup-and-test
runs-on: ubuntu-latest
if: always()
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: ${{ env.NODE_VERSION }}
- name: Download blob reports from GitHub Actions Artifacts
uses: actions/download-artifact@v4
with:
path: all-blob-reports
pattern: blob-report-*
merge-multiple: true
- name: Merge into HTML Report
run: |
npx playwright merge-reports --reporter html ./all-blob-reports
- name: Upload HTML report
uses: actions/upload-artifact@v4
with:
name: html-report--attempt-${{ github.run_attempt }}
path: playwright-report
retention-days: 14

3
.gitignore vendored
View file

@ -258,6 +258,9 @@ langflow.db
/tmp/*
src/backend/langflow/frontend/
src/backend/base/langflow/frontend/
.docker
scratchpad*
chroma*/*
stuff/*
src/frontend/playwright-report/index.html

View file

@ -6,6 +6,20 @@ setup_poetry:
pipx install poetry
poetry self add poetry-monorepo-dependency-plugin
add:
@echo 'Adding dependencies'
ifdef devel
cd src/backend/base && poetry add --group dev $(devel)
endif
ifdef main
poetry add $(main)
endif
ifdef base
cd src/backend/base && poetry add $(base)
endif
init:
@echo 'Installing backend dependencies'
make install_backend
@ -47,22 +61,47 @@ run_frontend:
tests_frontend:
ifeq ($(UI), true)
cd src/frontend && ./run-tests.sh --ui
cd src/frontend && npx playwright test --ui --project=chromium
else
cd src/frontend && ./run-tests.sh
cd src/frontend && npx playwright test --project=chromium
endif
run_cli:
poetry run langflow run --path src/frontend/build
@echo 'Running the CLI'
@make install_frontend > /dev/null
@echo 'Building the frontend'
@make build_frontend > /dev/null
@echo 'Install backend dependencies'
@make install_backend > /dev/null
ifdef env
poetry run langflow run --path src/frontend/build --host $(host) --port $(port) --env-file $(env)
else
poetry run langflow run --path src/frontend/build --host $(host) --port $(port) --env-file .env
endif
run_cli_debug:
poetry run langflow run --path src/frontend/build --log-level debug
@echo 'Running the CLI in debug mode'
@make install_frontend > /dev/null
@echo 'Building the frontend'
@make build_frontend > /dev/null
@echo 'Install backend dependencies'
@make install_backend > /dev/null
ifdef env
poetry run langflow run --path src/frontend/build --log-level debug --host $(host) --port $(port) --env-file $(env)
else
poetry run langflow run --path src/frontend/build --log-level debug --host $(host) --port $(port) --env-file .env
endif
setup_devcontainer:
make init
make build_frontend
poetry run langflow --path src/frontend/build
setup_env:
@sh ./scripts/setup/update_poetry.sh 1.8.2
@sh ./scripts/setup/setup_env.sh
frontend:
make install_frontend
make run_frontend
@ -72,18 +111,19 @@ frontendc:
make run_frontend
install_backend:
poetry install --extras deploy
poetry run pip install -e src/backend/base/.
@echo 'Installing backend dependencies'
@make setup_env
@poetry install --extras deploy
backend:
make install_backend
@-kill -9 `lsof -t -i:7860`
ifeq ($(login),1)
@echo "Running backend without autologin";
poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser --env-file .env
poetry run uvicorn --factory langflow.main:create_app --host 0.0.0.0 --port 7860 --reload --env-file .env
else
@echo "Running backend with autologin";
LANGFLOW_AUTO_LOGIN=True poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser --env-file .env
LANGFLOW_AUTO_LOGIN=True poetry run uvicorn --factory langflow.main:create_app --host 0.0.0.0 --port 7860 --reload --env-file .env
endif
build_and_run:
@ -98,13 +138,15 @@ build_and_install:
@echo 'Removing dist folder'
rm -rf dist
rm -rf src/backend/base/dist
make build && poetry run pip install dist/*.tar.gz && pip install src/backend/base/dist/*.tar.gz
make build && poetry run pip install dist/*.whl && pip install src/backend/base/dist/*.whl --force-reinstall
build_frontend:
cd src/frontend && CI='' npm run build
cp -r src/frontend/build src/backend/base/langflow/frontend
build:
@echo 'Building the project'
@make setup_env
make build_langflow_base
make build_langflow
@ -127,10 +169,18 @@ else
docker compose $(if $(debug),-f docker-compose.debug.yml) up
endif
lock:
lock_base:
cd src/backend/base && poetry lock
lock_langflow:
poetry lock
lock:
# Run both in parallel
# cd src/backend/base && poetry lock
# poetry lock
@echo 'Locking dependencies'
@make -j2 lock_base lock_langflow
publish_base:
make build_langflow_base
cd src/backend/base && poetry publish

View file

@ -0,0 +1,250 @@
import Admonition from '@theme/Admonition';
# Experimental
Experimental are components that are currently in a beta phase. This means they have undergone initial development and testing but have not yet reached a stable or fully supported status. Users are encouraged to explore these components, provide feedback, and report any issues encountered during their usage.
### Clear Message History Component
This component is designed to clear the message history associated with a specific session ID.
**Beta:** This component is currently in beta.
**Parameters**
- **Session ID:**
- **Display Name:** Session ID
- **Info:** The session ID to clear the message history.
**Usage**
To use this component, provide the session ID for which you want to clear the message history.
---
### Extract Key From Record
This component extracts specified keys from a record.
**Parameters**
- **Record:**
- **Display Name:** Record
- **Info:** The record from which to extract the keys.
- **Keys:**
- **Display Name:** Keys
- **Info:** The keys to extract from the record.
- **Silent Errors:**
- **Display Name:** Silent Errors
- **Info:** If True, errors will not be raised.
- **Advanced:** True
**Usage**
To use this component, provide the record from which you want to extract keys, specify the keys to extract, and optionally set whether to raise errors for missing keys.
---
### Flow as Tool
This component constructs a Tool from a function that runs the loaded Flow.
**Parameters**
- **Flow Name:**
- **Display Name:** Flow Name
- **Info:** The name of the flow to run.
- **Options:** List of available flow names.
- **Real-time Refresh:** True
- **Refresh Button:** True
- **Name:**
- **Display Name:** Name
- **Description:** The name of the tool.
- **Description:**
- **Display Name:** Description
- **Description:** The description of the tool.
- **Return Direct:**
- **Display Name:** Return Direct
- **Description:** Return the result directly from the Tool.
- **Advanced:** True
**Usage**
To use this component, select the desired flow from the available options, provide a name and description for the tool, and specify whether to return the result directly from the tool.
---
### Listen
This component listens for a notification.
**Parameters**
- **Name:**
- **Display Name:** Name
- **Info:** The name of the notification to listen for.
**Usage**
To use this component, specify the name of the notification to listen for.
---
### List Flows
This component lists all available flows.
**Usage**
To use this component, simply call it without any parameters.
---
### Merge Records
**Parameters**
- **Records:**
- **Display Name:** Records
**Usage**
To use this component, provide a list of records to merge.
---
### Notify
This component generates a notification to the Get Notified component.
**Parameters**
- **Name:**
- **Display Name:** Name
- **Info:** The name of the notification.
- **Record:**
- **Display Name:** Record
- **Info:** The record to store.
- **Append:**
- **Display Name:** Append
- **Info:** If True, the record will be appended to the notification.
**Usage**
To use this component, specify the name of the notification, provide an optional record to store, and indicate whether to append the record to the notification.
---
### Run Flow
This component runs a flow.
**Parameters**
- **Input Value:**
- **Display Name:** Input Value
- **Multiline:** True
- **Flow Name:**
- **Display Name:** Flow Name
- **Info:** The name of the flow to run.
- **Options:** List of available flow names.
- **Refresh Button:** True
- **Tweaks:**
- **Display Name:** Tweaks
- **Info:** Tweaks to apply to the flow.
**Usage**
To use this component, provide the input value, specify the flow name to run, and optionally provide tweaks to apply to the flow.
---
### Runnable Executor
This component executes a runnable.
**Parameters**
- **Input Key:**
- **Display Name:** Input Key
- **Info:** The key to use for the input.
- **Inputs:**
- **Display Name:** Inputs
- **Info:** The inputs to pass to the runnable.
- **Runnable:**
- **Display Name:** Runnable
- **Info:** The runnable to execute.
- **Output Key:**
- **Display Name:** Output Key
- **Info:** The key to use for the output.
**Usage**
To use this component, specify the input key, provide the inputs to pass to the runnable, select the runnable to execute, and optionally specify the output key.
---
### SQL Executor
This component executes an SQL query.
**Parameters**
- **Database URL:**
- **Display Name:** Database URL
- **Info:** The URL of the database.
- **Include Columns:**
- **Display Name:** Include Columns
- **Info:** Include columns in the result.
- **Passthrough:**
- **Display Name:** Passthrough
- **Info:** If an error occurs, return the query instead of raising an exception.
- **Add Error:**
- **Display Name:** Add Error
- **Info:** Add the error to the result.
**Usage**
To use this component, provide the SQL query, specify the database URL, and optionally configure include columns, passthrough, and add error settings.
---
### SubFlow
This component dynamically generates a component from a flow. The output is a list of records with keys 'result' and 'message'.
**Parameters**
- **Input Value:**
- **Display Name:** Input Value
- **Multiline:** True
- **Flow Name:**
- **Display Name:** Flow Name
- **Info:** The name of the flow to run.
- **Options:** List of available flow names.
- **Real Time Refresh:** True
- **Refresh Button:** True
- **Tweaks:**
- **Display Name:** Tweaks
- **Info:** Tweaks to apply to the flow.
**Usage**
To use this component, specify the flow name and provide any necessary tweaks to apply to the flow.

View file

@ -0,0 +1,173 @@
import Admonition from '@theme/Admonition';
# Helpers
### Custom Component
This component serves as a template for creating your own custom components.
**Params**
- **Display Name:** Parameter
**Usage**
To use this component, provide the required parameter as specified.
Learn more about [Custom Component](http://docs.langflow.org/components/custom).
---
### Documents to Records
This component converts documents to records.
**Params**
- **Documents:**
- **Display Name:** Documents
**Usage**
To use this component, provide a list of documents to be converted into records.
---
### Unique ID Generator
This component generates a unique ID.
**Params**
- **Value:**
- **Display Name:** Value
- **Real Time Refresh:** True
**Usage**
To use this component, simply retrieve the generated unique ID from the provided value parameter.
---
### Message History
This component is used to retrieve stored messages from the message history.
**Params**
- **Sender Type:**
- **Display Name:** Sender Type
- **Options:** Machine, User, Machine and User
- **Sender Name:**
- **Display Name:** Sender Name
- **Number of Messages:**
- **Display Name:** Number of Messages
- **Info:** Number of messages to retrieve.
- **Session ID:**
- **Display Name:** Session ID
- **Info:** Session ID of the chat history.
- **Input Types:** Text
**Usage**
To use this component, configure the parameters as needed to retrieve messages from the message history.
---
### Python Function
**Params**
- **Code:**
- **Display Name:** Code
- **Info:** The code for the function.
- **Show:** True
**Usage**
To use this component, provide the Python code for the function you want to define.
---
### Records to Text
This component converts records into a single piece of text using a template.
**Params**
- **Records:**
- **Display Name:** Records
- **Info:** The records to convert to text.
- **Template:**
- **Display Name:** Template
- **Info:** The template to use for formatting the records. It can contain the keys `{text}`, `{data}` or any other key in the Record.
**Usage**
To use this component, provide the records you want to convert to text along with a template for formatting.
---
### SearchApi
This component provides access to the real-time search engine results API.
**Params**
- **Engine:**
- **Display Name:** Engine
- **Info:** The search engine to use.
- **Parameters:**
- **Display Name:** Parameters
- **Info:** The parameters to send with the request.
- **API Key:**
- **Display Name:** API Key
- **Info:** The API key to use SearchApi.
- **Required:** True
- **Password:** True
Learn more about [SearchApi Documentation](https://www.searchapi.io/docs/google).
---
### Text to Record
This component enables the creation of a record from text data.
**Params**
- **Data:**
- **Display Name:** Data
- **Info:** The data to convert to a record.
- **Input Types:** Text
**Usage**
To use this component, provide the text data to convert into a record.
---
### Update Record
This component updates a record with new data.
**Params**
- **Record:**
- **Display Name:** Record
- **Info:** The record to update.
- **New Data:**
- **Display Name:** New Data
- **Info:** The new data to update the record with.
- **Input Types:** Text
**Usage**
To use this component, provide the record to be updated along with the new data.

View file

@ -2,7 +2,7 @@ import Admonition from '@theme/Admonition';
# Inputs
### ChatInput
### Chat Input
This component is designed to get user input from the chat.
@ -22,7 +22,7 @@ This component is designed to get user input from the chat.
</p>
</Admonition>
### TextInput
### Text Input
This component is designed for simple text input, allowing users to pass textual data to subsequent components in the workflow. It's particularly useful for scenarios where a brief user input is required to initiate or influence the flow.

View file

@ -0,0 +1,464 @@
import Admonition from '@theme/Admonition';
# Models
<Admonition type="caution" icon="🚧" title="ZONE UNDER CONSTRUCTION">
<p>
We appreciate your understanding as we polish our documentation – it may contain some rough edges. Share your feedback or report issues to help us improve! 🛠️📝
</p>
</Admonition>
### AmazonBedrock
This component facilitates the generation of text using the LLM (Large Language Model) model from Amazon Bedrock.
**Params**
- **Input Value:** Specifies the input text for text generation.
- **System Message (Optional):** A system message to pass to the model.
- **Model ID (Optional):** Specifies the model ID to be used for text generation. Defaults to _`"anthropic.claude-instant-v1"`_. Available options include:
- _`"ai21.j2-grande-instruct"`_
- _`"ai21.j2-jumbo-instruct"`_
- _`"ai21.j2-mid"`_
- _`"ai21.j2-mid-v1"`_
- _`"ai21.j2-ultra"`_
- _`"ai21.j2-ultra-v1"`_
- _`"anthropic.claude-instant-v1"`_
- _`"anthropic.claude-v1"`_
- _`"anthropic.claude-v2"`_
- _`"cohere.command-text-v14"`_
- **Credentials Profile Name (Optional):** Specifies the name of the credentials profile.
- **Region Name (Optional):** Specifies the region name.
- **Model Kwargs (Optional):** Additional keyword arguments for the model.
- **Endpoint URL (Optional):** Specifies the endpoint URL.
- **Streaming (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **Cache (Optional):** Specifies whether to cache the response.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
<Admonition type="note" title="Note">
<p>
Ensure that necessary credentials are provided to connect to the Amazon Bedrock API. If connection fails, a ValueError will be raised.
</p>
</Admonition>
---
### AnthropicLLM
This component allows the generation of text using Anthropic Chat&Completion large language models.
**Params**
- **Model Name:** Specifies the name of the Anthropic model to be used for text generation. Available options include:
- _`"claude-2.1"`_
- _`"claude-2.0"`_
- _`"claude-instant-1.2"`_
- _`"claude-instant-1"`_
- **Anthropic API Key:** Your Anthropic API key.
- **Max Tokens (Optional):** Specifies the maximum number of tokens to generate. Defaults to _`256`_.
- **Temperature (Optional):** Specifies the sampling temperature. Defaults to _`0.7`_.
- **API Endpoint (Optional):** Specifies the endpoint of the Anthropic API. Defaults to _`"https://api.anthropic.com"`_ if not specified.
- **Input Value:** Specifies the input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
For detailed documentation and integration guides, please refer to the [Anthropic Component Documentation](https://python.langchain.com/docs/integrations/chat/anthropic).
---
### AzureChatOpenAI
This component allows the generation of text using the LLM (Large Language Model) model from Azure OpenAI.
**Params**
- **Model Name:** Specifies the name of the Azure OpenAI model to be used for text generation. Available options include:
- _`"gpt-35-turbo"`_
- _`"gpt-35-turbo-16k"`_
- _`"gpt-35-turbo-instruct"`_
- _`"gpt-4"`_
- _`"gpt-4-32k"`_
- _`"gpt-4-vision"`_
- **Azure Endpoint:** Your Azure endpoint, including the resource. Example: `https://example-resource.azure.openai.com/`.
- **Deployment Name:** Specifies the name of the deployment.
- **API Version:** Specifies the version of the Azure OpenAI API to be used. Available options include:
- _`"2023-03-15-preview"`_
- _`"2023-05-15"`_
- _`"2023-06-01-preview"`_
- _`"2023-07-01-preview"`_
- _`"2023-08-01-preview"`_
- _`"2023-09-01-preview"`_
- _`"2023-12-01-preview"`_
- **API Key:** Your Azure OpenAI API key.
- **Temperature (Optional):** Specifies the sampling temperature. Defaults to _`0.7`_.
- **Max Tokens (Optional):** Specifies the maximum number of tokens to generate. Defaults to _`1000`_.
- **Input Value:** Specifies the input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
For detailed documentation and integration guides, please refer to the [Azure OpenAI Component Documentation](https://python.langchain.com/docs/integrations/llms/azure_openai).
---
### QianfanChatEndpoint
This component facilitates the generation of text using Baidu Qianfan chat models.
**Params**
- **Model Name:** Specifies the name of the Qianfan chat model to be used for text generation. Available options include:
- _`"ERNIE-Bot"`_
- _`"ERNIE-Bot-turbo"`_
- _`"BLOOMZ-7B"`_
- _`"Llama-2-7b-chat"`_
- _`"Llama-2-13b-chat"`_
- _`"Llama-2-70b-chat"`_
- _`"Qianfan-BLOOMZ-7B-compressed"`_
- _`"Qianfan-Chinese-Llama-2-7B"`_
- _`"ChatGLM2-6B-32K"`_
- _`"AquilaChat-7B"`_
- **Qianfan Ak:** Your Baidu Qianfan access key, obtainable from [here](https://cloud.baidu.com/product/wenxinworkshop).
- **Qianfan Sk:** Your Baidu Qianfan secret key, obtainable from [here](https://cloud.baidu.com/product/wenxinworkshop).
- **Top p (Optional):** Model parameter. Specifies the top-p value. Only supported in ERNIE-Bot and ERNIE-Bot-turbo models. Defaults to _`0.8`_.
- **Temperature (Optional):** Model parameter. Specifies the sampling temperature. Only supported in ERNIE-Bot and ERNIE-Bot-turbo models. Defaults to _`0.95`_.
- **Penalty Score (Optional):** Model parameter. Specifies the penalty score. Only supported in ERNIE-Bot and ERNIE-Bot-turbo models. Defaults to _`1.0`_.
- **Endpoint (Optional):** Endpoint of the Qianfan LLM, required if custom model is used.
- **Input Value:** Specifies the input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
---
### Cohere
This component enables text generation using Cohere large language models.
**Params**
- **Cohere API Key:** Your Cohere API key.
- **Max Tokens (Optional):** Specifies the maximum number of tokens to generate. Defaults to _`256`_.
- **Temperature (Optional):** Specifies the sampling temperature. Defaults to _`0.75`_.
- **Input Value:** Specifies the input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
---
### CTransformers
This component allows the generation of text using CTransformers large language models.
**Params**
- **Model:** Specifies the CTransformers model to be used for text generation.
- **Model File (Optional):** Path to the model file if using a custom model. Should be a _.bin_ file.
- **Model Type:** Specifies the type of the CTransformers model.
- **Config (Optional):** Additional configuration parameters for the model. It should be provided as a JSON object.
Defaults to:
`{"top_k":40,"top_p":0.95,"temperature":0.8,"repetition_penalty":1.1,"last_n_tokens":64,"seed":-1,"max_new_tokens":256,"stop":"","stream":"False","reset":"True","batch_size":8,"threads":-1,"context_length":-1,"gpu_layers":0}`.
- **Input Value:** Specifies the input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
---
### Google Generative AI
This component enables text generation using Google Generative AI.
**Params**
- **Google API Key:** Your Google API key to use for the Google Generative AI.
- **Model:** The name of the model to use. Supported examples are _`"gemini-pro"`_ and _`"gemini-pro-vision"`_.
- **Max Output Tokens (Optional):** The maximum number of tokens to generate.
- **Temperature:** Run inference with this temperature. Must be in the closed interval [0.0, 1.0].
- **Top K (Optional):** Decode using top-k sampling: consider the set of top_k most probable tokens. Must be positive.
- **Top P (Optional):** The maximum cumulative probability of tokens to consider when sampling.
- **N (Optional):** Number of chat completions to generate for each prompt. Note that the API may not return the full n completions if duplicates are generated.
- **Input Value:** The input to the model.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
---
### Hugging Face API
This component facilitates text generation using LLM models from the Hugging Face Inference API.
**Params**
- **Endpoint URL:** The URL of the Hugging Face Inference API endpoint. Should be provided along with necessary authentication credentials.
- **Task:** Specifies the task for text generation. Options include _`"text2text-generation"`_, _`"text-generation"`_, and _`"summarization"`_.
- **API Token:** The API token required for authentication with the Hugging Face Hub.
- **Model Keyword Arguments (Optional):** Additional keyword arguments for the model. Should be provided as a Python dictionary.
- **Input Value:** The input text for text generation.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** A system message to pass to the model.
---
### LlamaCpp
The `LlamaCpp` is a component for generating text using the llama.cpp model.
**Params**
- **Model Path:** The path to the llama.cpp model file. This should be provided as a file type input.
- **Input Value:** The input text for text generation.
- **Grammar (Optional):** The grammar for text generation.
- **Cache (Optional):** Specifies whether to cache the generated text.
- **Client (Optional):** The client to use for text generation.
- **Echo (Optional):** Specifies whether to echo the generated text. Defaults to _`False`_.
- **F16 KV:** Specifies whether to use F16 key-value pairs. Defaults to _`True`_.
- **Grammar Path (Optional):** The path to the grammar file.
- **Last N Tokens Size (Optional):** The size of the last N tokens. Defaults to _`64`_.
- **Logits All:** Specifies whether to include logits for all tokens. Defaults to _`False`_.
- **Logprobs (Optional):** The log probabilities for text generation.
- **Lora Base (Optional):** The base URL for Lora.
- **Lora Path (Optional):** The path for Lora.
- **Max Tokens (Optional):** The maximum number of tokens to generate. Defaults to _`256`_.
- **Metadata (Optional):** Additional metadata for the model.
- **Model Kwargs:** Additional keyword arguments for the model. Should be provided as a Python dictionary.
- **N Batch (Optional):** The batch size. Defaults to _`8`_.
- **N Ctx:** The context size. Defaults to _`512`_.
- **N GPU Layers (Optional):** The number of GPU layers.
- **N Parts:** The number of parts.
- **N Threads (Optional):** The number of threads. Defaults to _`1`_.
- **Repeat Penalty (Optional):** The repeat penalty for text generation. Defaults to _`1.1`_.
- **Rope Freq Base:** The base frequency for rope.
- **Rope Freq Scale:** The scale frequency for rope.
- **Seed:** The seed for random generation.
- **Stop (Optional):** The stop words for text generation.
- **Streaming:** Specifies whether to stream the response from the model. Defaults to _`True`_.
- **Suffix (Optional):** The suffix for text generation.
- **Tags (Optional):** The tags for text generation.
- **Temperature (Optional):** The temperature for text generation. Defaults to _`0.8`_.
- **Top K (Optional):** The top K tokens to consider for text generation. Defaults to _`40`_.
- **Top P (Optional):** The top P probability threshold for text generation. Defaults to _`0.95`_.
- **Use Mlock:** Specifies whether to use Mlock. Defaults to _`False`_.
- **Use Mmap (Optional):** Specifies whether to use Mmap. Defaults to _`True`_.
- **Verbose:** Specifies whether to enable verbose mode. Defaults to _`True`_.
- **Vocab Only:** Specifies whether to include vocabulary only.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
For more information, please refer to the [documentation](https://python.langchain.com/docs/modules/model_io/models/llms/integrations/llamacpp).
---
### ChatOllama
This component facilitates text generation using the Local LLM model for chat with Ollama.
**Params**
- **Base URL:** The endpoint of the Ollama API. Defaults to 'http://localhost:11434' if not specified.
- **Model Name:** The name of the model to use. Refer to [https://ollama.ai/library](https://ollama.ai/library) for more models.
- **Input Value:** The input text for text generation.
- **Mirostat:** Enable/disable Mirostat sampling for controlling perplexity.
- **Mirostat Eta (Optional):** The learning rate for the Mirostat algorithm. (Default: 0.1)
- **Mirostat Tau (Optional):** Controls the balance between coherence and diversity of the output. (Default: 5.0)
- **Repeat Last N (Optional):** How far back the model looks to prevent repetition. (Default: 64, 0 = disabled, -1 = num_ctx)
- **Verbose (Optional):** Whether to print out response text.
- **Cache (Optional):** Enable or disable caching. Defaults to _`False`_.
- **Context Window Size (Optional):** Size of the context window for generating tokens. (Default: 2048)
- **Number of GPUs (Optional):** Number of GPUs to use for computation. (Default: 1 on macOS, 0 to disable)
- **Format (Optional):** Specify the format of the output (e.g., json).
- **Metadata (Optional):** Metadata to add to the run trace.
- **Number of Threads (Optional):** Number of threads to use during computation. (Default: detected for optimal performance)
- **Repeat Penalty (Optional):** Penalty for repetitions in generated text. (Default: 1.1)
- **Stop Tokens (Optional):** List of tokens to signal the model to stop generating text.
- **System (Optional):** System to use for generating text.
- **Tags (Optional):** Tags to add to the run trace.
- **Temperature (Optional):** Controls the creativity of model responses. Defaults to _`0.8`_.
- **Template (Optional):** Template to use for generating text.
- **TFS Z (Optional):** Tail free sampling value. (Default: 1)
- **Timeout (Optional):** Timeout for the request stream.
- **Top K (Optional):** Limits token selection to top K. (Default: 40)
- **Top P (Optional):** Works together with top-k. (Default: 0.9)
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** System message to pass to the model.
---
### OpenAIModel
This component facilitates text generation using OpenAI's models.
**Params**
- **Input Value:** The input text for text generation.
- **Max Tokens (Optional):** The maximum number of tokens to generate. Defaults to _`256`_.
- **Model Kwargs (Optional):** Additional keyword arguments for the model. Should be provided as a nested dictionary.
- **Model Name (Optional):** The name of the model to use. Defaults to _`gpt-4-1106-preview`_. Supported options include: _`gpt-4-turbo-preview`_, _`gpt-4-0125-preview`_, _`gpt-4-1106-preview`_, _`gpt-4-vision-preview`_, _`gpt-3.5-turbo-0125`_, _`gpt-3.5-turbo-1106`_.
- **OpenAI API Base (Optional):** The base URL of the OpenAI API. Defaults to _`https://api.openai.com/v1`_.
- **OpenAI API Key (Optional):** The API key for accessing the OpenAI API.
- **Temperature:** Controls the creativity of model responses. Defaults to _`0.7`_.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** System message to pass to the model.
---
### ChatVertexAI
The `ChatVertexAI` is a component for generating text using Vertex AI Chat large language models API.
**Params**
- **Input Value:** The input text for text generation.
- **Credentials:** The JSON file containing the credentials for accessing the Vertex AI Chat API.
- **Project:** The name of the project associated with the Vertex AI Chat API.
- **Examples (Optional):** List of examples to provide context for text generation.
- **Location:** The location of the Vertex AI Chat API service. Defaults to _`us-central1`_.
- **Max Output Tokens:** The maximum number of tokens to generate. Defaults to _`128`_.
- **Model Name:** The name of the model to use. Defaults to _`chat-bison`_.
- **Temperature:** Controls the creativity of model responses. Defaults to _`0.0`_.
- **Top K:** Limits token selection to top K. Defaults to _`40`_.
- **Top P:** Works together with top-k. Defaults to _`0.95`_.
- **Verbose:** Whether to print out response text. Defaults to _`False`_.
- **Stream (Optional):** Specifies whether to stream the response from the model. Defaults to _`False`_.
- **System Message (Optional):** System message to pass to the model.

View file

@ -21,7 +21,7 @@ The `PromptTemplate` component allows users to create prompts and define variabl
<Admonition type="info">
Once a variable is defined in the prompt template, it becomes a component
input of its own. Check out [Prompt
Customization](../docs/guidelines/prompt-customization.mdx) to learn more.
Customization](../guidelines/prompt-customization) to learn more.
</Admonition>
- **template:** Template used to format an individual request.

View file

@ -6,4 +6,640 @@ import Admonition from '@theme/Admonition';
<p>
We appreciate your understanding as we polish our documentation – it may contain some rough edges. Share your feedback or report issues to help us improve! 🛠️📝
</p>
</Admonition>
</Admonition>
### AstraDB
The `AstraDB` is a component for initializing an AstraDB Vector Store from Records. It facilitates the creation of AstraDB-based vector indexes for efficient document storage and retrieval.
**Params**
- **Input:** The input documents or records.
- **Embedding:** The embedding model used by AstraDB.
- **Collection Name:** The name of the collection in AstraDB.
- **Token:** The token for AstraDB.
- **API Endpoint:** The API endpoint for AstraDB.
- **Namespace:** The namespace in AstraDB.
- **Metric:** The metric to use in AstraDB.
- **Batch Size:** The batch size for AstraDB.
- **Bulk Insert Batch Concurrency:** The bulk insert batch concurrency for AstraDB.
- **Bulk Insert Overwrite Concurrency:** The bulk insert overwrite concurrency for AstraDB.
- **Bulk Delete Concurrency:** The bulk delete concurrency for AstraDB.
- **Setup Mode:** The setup mode for the vector store.
- **Pre Delete Collection:** Pre delete collection.
- **Metadata Indexing Include:** Metadata indexing include.
- **Metadata Indexing Exclude:** Metadata indexing exclude.
- **Collection Indexing Policy:** Collection indexing policy.
<Admonition type="note" title="Note">
<p>
Ensure that the required AstraDB token and API endpoint are properly configured.
</p>
</Admonition>
---
### AstraDB Search
The `AstraDBSearch` is a component for searching an existing AstraDB Vector Store for similar documents. It extends the functionality of the `AstraDB` component to provide efficient document retrieval based on similarity metrics.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Embedding:** The embedding model used by AstraDB.
- **Collection Name:** The name of the collection in AstraDB.
- **Token:** The token for AstraDB.
- **API Endpoint:** The API endpoint for AstraDB.
- **Namespace:** The namespace in AstraDB.
- **Metric:** The metric to use in AstraDB.
- **Batch Size:** The batch size for AstraDB.
- **Bulk Insert Batch Concurrency:** The bulk insert batch concurrency for AstraDB.
- **Bulk Insert Overwrite Concurrency:** The bulk insert overwrite concurrency for AstraDB.
- **Bulk Delete Concurrency:** The bulk delete concurrency for AstraDB.
- **Setup Mode:** The setup mode for the vector store.
- **Pre Delete Collection:** Pre delete collection.
- **Metadata Indexing Include:** Metadata indexing include.
- **Metadata Indexing Exclude:** Metadata indexing exclude.
- **Collection Indexing Policy:** Collection indexing policy.
---
### Chroma
The `Chroma` is a component designed for implementing a Vector Store using Chroma. This component allows users to utilize Chroma for efficient vector storage and retrieval within their language processing workflows.
**Params**
- **Collection Name:** The name of the collection.
- **Persist Directory:** The directory to persist the Vector Store to.
- **Server CORS Allow Origins (Optional):** The CORS allow origins for the Chroma server.
- **Server Host (Optional):** The host for the Chroma server.
- **Server Port (Optional):** The port for the Chroma server.
- **Server gRPC Port (Optional):** The gRPC port for the Chroma server.
- **Server SSL Enabled (Optional):** Whether to enable SSL for the Chroma server.
- **Input:** Input data for creating the Vector Store.
- **Embedding:** The embeddings to use for the Vector Store.
For detailed documentation and integration guides, please refer to the [Chroma Component Documentation](https://python.langchain.com/docs/integrations/vectorstores/chroma).
---
### Chroma Search
The `ChromaSearch` is a component designed for searching a Chroma collection for similar documents. This component integrates with Chroma to facilitate efficient document retrieval based on similarity metrics.
**Params**
- **Input:** The input text to search for similar documents.
- **Search Type:** The type of search to perform ("Similarity" or "MMR").
- **Collection Name:** The name of the Chroma collection.
- **Index Directory:** The directory where the Chroma index is stored.
- **Embedding:** The embedding model used to vectorize inputs (make sure to use the same as the index).
- **Server CORS Allow Origins (Optional):** The CORS allow origins for the Chroma server.
- **Server Host (Optional):** The host for the Chroma server.
- **Server Port (Optional):** The port for the Chroma server.
- **Server gRPC Port (Optional):** The gRPC port for the Chroma server.
- **Server SSL Enabled (Optional):** Whether SSL is enabled for the Chroma server.
---
### FAISS
The `FAISS` is a component designed for ingesting documents into a FAISS Vector Store. It facilitates efficient document indexing and retrieval using the FAISS library.
**Params**
- **Embedding:** The embedding model used to vectorize inputs.
- **Input:** The input documents to ingest into the FAISS Vector Store.
- **Folder Path:** The path to save the FAISS index. It will be relative to where Langflow is running.
- **Index Name:** The name of the FAISS index.
For detailed documentation and integration guides, please refer to the [FAISS Component Documentation](https://faiss.ai/index.html).
---
### FAISS Search
The `FAISSSearch` is a component for searching a FAISS Vector Store for similar documents. It enables efficient document retrieval based on similarity metrics using FAISS.
**Params**
- **Embedding:** The embedding model used by the FAISS Vector Store.
- **Folder Path:** The path from which to load the FAISS index. It will be relative to where Langflow is running.
- **Input:** The input value to search for similar documents.
- **Index Name:** The name of the FAISS index.
---
### MongoDB Atlas
The `MongoDBAtlas` is a component used to construct a MongoDB Atlas Vector Search vector store from Records. It facilitates the creation of MongoDB Atlas-based vector stores for efficient document storage and retrieval.
**Params**
- **Embedding:** The embedding model used by the MongoDB Atlas Vector Search.
- **Input:** The input documents or records.
- **Collection Name:** The name of the collection in the MongoDB Atlas database.
- **Database Name:** The name of the database in MongoDB Atlas.
- **Index Name:** The name of the index in MongoDB Atlas.
- **MongoDB Atlas Cluster URI:** The URI of the MongoDB Atlas cluster.
- **Search Kwargs:** Additional search arguments for MongoDB Atlas.
<Admonition type="note" title="Note">
<p>
Ensure that pymongo is installed to use MongoDB Atlas Vector Store.
</p>
</Admonition>
---
### MongoDB Atlas Search
The `MongoDBAtlasSearch` is a component for searching a MongoDB Atlas Vector Store for similar documents. It extends the functionality of the MongoDBAtlasComponent to provide efficient document retrieval based on similarity metrics.
**Params**
- **Search Type:** The type of search to perform. Options: "Similarity", "MMR".
- **Input:** The input value to search for.
- **Embedding:** The embedding model used by the MongoDB Atlas Vector Store.
- **Collection Name:** The name of the collection in the MongoDB Atlas database.
- **Database Name:** The name of the database in MongoDB Atlas.
- **Index Name:** The name of the index in MongoDB Atlas.
- **MongoDB Atlas Cluster URI:** The URI of the MongoDB Atlas cluster.
- **Search Kwargs:** Additional search arguments for MongoDB Atlas.
---
### PGVector
The `PGVector` is a component for implementing a Vector Store using PostgreSQL. It allows users to store and retrieve vectors efficiently within a PostgreSQL database.
**Params**
- **Input:** The input value to use for the Vector Store.
- **Embedding:** The embedding model used by the Vector Store.
- **PostgreSQL Server Connection String:** The URL for the PostgreSQL server.
- **Table:** The name of the table in the PostgreSQL database.
For detailed documentation and integration guides, please refer to the [PGVector Component Documentation](https://python.langchain.com/docs/integrations/vectorstores/pgvector).
<Admonition type="note" title="Note">
<p>
Ensure that the required PostgreSQL server is accessible and properly configured.
</p>
</Admonition>
---
### PGVector Search
The `PGVectorSearch` is a component for searching a PGVector Store for similar documents. It extends the functionality of the PGVectorComponent to provide efficient document retrieval based on similarity metrics.
**Params**
- **Input:** The input value to search for.
- **Embedding:** The embedding model used by the Vector Store.
- **PostgreSQL Server Connection String:** The URL for the PostgreSQL server.
- **Table:** The name of the table in the PostgreSQL database.
- **Search Type:** The type of search to perform (e.g., "Similarity", "MMR").
---
### Pinecone
The `Pinecone` is a component used to construct a Pinecone wrapper from Records. It facilitates the creation of Pinecone-based vector indexes for efficient document storage and retrieval.
**Params**
- **Input:** The input documents or records.
- **Embedding:** The embedding model used by Pinecone.
- **Index Name:** The name of the index in Pinecone.
- **Namespace:** The namespace in Pinecone.
- **Pinecone API Key:** The API key for Pinecone.
- **Pinecone Environment:** The environment for Pinecone.
- **Search Kwargs:** Additional search keyword arguments for Pinecone.
- **Pool Threads:** The number of threads to use for Pinecone.
<Admonition type="note" title="Note">
<p>
Ensure that the required Pinecone API key and environment are properly configured.
</p>
</Admonition>
---
### Pinecone Search
The `PineconeSearch` is a component used to search a Pinecone Vector Store for similar documents. It extends the functionality of the `PineconeComponent` to provide efficient document retrieval based on similarity metrics.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Embedding:** The embedding model used by Pinecone.
- **Index Name:** The name of the index in Pinecone.
- **Namespace:** The namespace in Pinecone.
- **Pinecone API Key:** The API key for Pinecone.
- **Pinecone Environment:** The environment for Pinecone.
- **Search Kwargs:** Additional search keyword arguments for Pinecone.
- **Pool Threads:** The number of threads to use for Pinecone.
---
### Qdrant
The `Qdrant` is a component used to construct a Qdrant wrapper from a list of texts. It allows for efficient similarity search and retrieval operations based on the provided embeddings.
**Params**
- **Input:** The input documents or records.
- **Embedding:** The embedding model used by Qdrant.
- **API Key:** The API key for Qdrant (password field).
- **Collection Name:** The name of the collection in Qdrant.
- **Content Payload Key:** The key for the content payload in the documents (advanced).
- **Distance Function:** The distance function to use in Qdrant (advanced).
- **gRPC Port:** The gRPC port for Qdrant (advanced).
- **Host:** The host for Qdrant (advanced).
- **HTTPS:** Enable HTTPS for Qdrant (advanced).
- **Location:** The location for Qdrant (advanced).
- **Metadata Payload Key:** The key for the metadata payload in the documents (advanced).
- **Path:** The path for Qdrant (advanced).
- **Port:** The port for Qdrant (advanced).
- **Prefer gRPC:** Prefer gRPC for Qdrant (advanced).
- **Prefix:** The prefix for Qdrant (advanced).
- **Search Kwargs:** Additional search keyword arguments for Qdrant (advanced).
- **Timeout:** The timeout for Qdrant (advanced).
- **URL:** The URL for Qdrant (advanced).
---
### Qdrant Search
The `QdrantSearch` is a component used to search a Qdrant Vector Store for similar documents. It extends the functionality of the `QdrantComponent` to provide efficient document retrieval based on similarity metrics.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Embedding:** The embedding model used by Qdrant.
- **API Key:** The API key for Qdrant (password field).
- **Collection Name:** The name of the collection in Qdrant.
- **Content Payload Key:** The key for the content payload in the documents (advanced).
- **Distance Function:** The distance function to use in Qdrant (advanced).
- **gRPC Port:** The gRPC port for Qdrant (advanced).
- **Host:** The host for Qdrant (advanced).
- **HTTPS:** Enable HTTPS for Qdrant (advanced).
- **Location:** The location for Qdrant (advanced).
- **Metadata Payload Key:** The key for the metadata payload in the documents (advanced).
- **Path:** The path for Qdrant (advanced).
- **Port:** The port for Qdrant (advanced).
- **Prefer gRPC:** Prefer gRPC for Qdrant (advanced).
- **Prefix:** The prefix for Qdrant (advanced).
- **Search Kwargs:** Additional search keyword arguments for Qdrant (advanced).
- **Timeout:** The timeout for Qdrant (advanced).
- **URL:** The URL for Qdrant (advanced).
---
### Redis
The `Redis` is a component for implementing a Vector Store using Redis. It provides functionality to store and retrieve vectors efficiently from a Redis database.
**Params**
- **Index Name:** The name of the index in Redis (default: your_index).
- **Input:** The input data to build the Redis Vector Store (input types: Document, Record).
- **Embedding:** The embedding model used by Redis.
- **Schema:** The schema file (.yaml) to define the structure of the documents (optional).
- **Redis Server Connection String:** The connection string for the Redis server.
- **Redis Index:** The name of the Redis index (optional).
For detailed documentation, please refer to the [Redis Documentation](https://python.langchain.com/docs/integrations/vectorstores/redis).
<Admonition type="note" title="Note">
<p>
Ensure that the required Redis server connection URL and index name are properly configured. If no documents are provided, a schema must be provided.
</p>
</Admonition>
---
### Redis Search
The `RedisSearch` is a component for searching a Redis Vector Store for similar documents.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Index Name:** The name of the index in Redis (default: your_index).
- **Embedding:** The embedding model used by Redis.
- **Schema:** The schema file (.yaml) to define the structure of the documents (optional).
- **Redis Server Connection String:** The connection string for the Redis server.
- **Redis Index:** The name of the Redis index (optional).
---
### Supabase
The `Supabase` is a component for initializing a Supabase Vector Store from texts and embeddings.
**Params**
- **Input:** The input documents or records.
- **Embedding:** The embedding model used by Supabase.
- **Query Name:** The name of the query (optional).
- **Search Kwargs:** Additional search keyword arguments for Supabase (advanced).
- **Supabase Service Key:** The service key for Supabase.
- **Supabase URL:** The URL for the Supabase instance.
- **Table Name:** The name of the table in Supabase (advanced).
<Admonition type="note" title="Note">
<p>
Ensure that the required Supabase service key, Supabase URL, and table name are properly configured.
</p>
</Admonition>
---
### Supabase Search
The `SupabaseSearch` is a component for searching a Supabase Vector Store for similar documents.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Embedding:** The embedding model used by Supabase.
- **Query Name:** The name of the query (optional).
- **Search Kwargs:** Additional search keyword arguments for Supabase (advanced).
- **Supabase Service Key:** The service key for Supabase.
- **Supabase URL:** The URL for the Supabase instance.
- **Table Name:** The name of the table in Supabase (advanced).
---
### Vectara
The `Vectara` is a component for implementing a Vector Store using Vectara.
**Params**
- **Vectara Customer ID:** The customer ID for Vectara.
- **Vectara Corpus ID:** The corpus ID for Vectara.
- **Vectara API Key:** The API key for Vectara.
- **Files Url:** The URL(s) of the file(s) to be used for initializing the Vectara Vector Store (optional).
- **Input:** The input data to be upserted to the corpus (optional).
For detailed documentation and integration guides, please refer to the [Vectara Component Documentation](https://python.langchain.com/docs/integrations/vectorstores/vectara).
<Admonition type="note" title="Note">
<p>
If `inputs` are provided, they will be upserted to the corpus. If `files_url` are provided, Vectara will process the files from the URLs.
</p>
</Admonition>
---
### Vectara Search
The `VectaraSearch` is a component for searching a Vectara Vector Store for similar documents.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Vectara Customer ID:** The customer ID for Vectara.
- **Vectara Corpus ID:** The corpus ID for Vectara.
- **Vectara API Key:** The API key for Vectara.
- **Files Url:** The URL(s) of the file(s) to be used for initializing the Vectara Vector Store (optional).
---
### Weaviate
The `Weaviate` is a component for implementing a Vector Store using Weaviate.
**Params**
- **Weaviate URL:** The URL of the Weaviate instance (default: http://localhost:8080).
- **Search By Text:** Boolean indicating whether to search by text (default: False).
- **API Key:** The API key for authentication (optional).
- **Index name:** The name of the index in Weaviate (optional).
- **Text Key:** The key used to extract text from documents (default: "text").
- **Input:** The input document or record.
- **Embedding:** The embedding model used by Weaviate.
- **Attributes:** Additional attributes to consider during indexing (optional).
For detailed documentation and integration guides, please refer to the [Weaviate Component Documentation](https://python.langchain.com/docs/integrations/vectorstores/weaviate).
<Admonition type="note" title="Note">
<p>
Before using the Weaviate Vector Store component, ensure that you have a Weaviate instance running and accessible at the specified URL. Additionally, make sure to provide the correct API key for authentication if required. Adjust the index name, text key, and attributes according to your dataset and indexing requirements. Finally, ensure that the provided embeddings are compatible with Weaviate's requirements.
</p>
</Admonition>
---
### Weaviate Search
The `WeaviateSearch` component facilitates searching a Weaviate Vector Store for similar documents.
**Params**
- **Search Type:** The type of search to perform (e.g., Similarity, MMR).
- **Input Value:** The input value to search for.
- **Weaviate URL:** The URL of the Weaviate instance (default: http://localhost:8080).
- **Search By Text:** Boolean indicating whether to search by text (default: False).
- **API Key:** The API key for authentication (optional).
- **Index name:** The name of the index in Weaviate (optional).
- **Text Key:** The key used to extract text from documents (default: "text").
- **Embedding:** The embedding model used by Weaviate.
- **Attributes:** Additional attributes to consider during indexing (optional).

View file

@ -3,8 +3,6 @@ description: Custom Components
hide_table_of_contents: true
---
import ZoomableImage from "/src/theme/ZoomableImage.js";
import Admonition from "@theme/Admonition";
# FlowRunner Component
@ -365,6 +363,8 @@ Done! This is what our script and custom component looks like:
}}
/>
</div>import ZoomableImage from "/src/theme/ZoomableImage.js";
</div>
import ZoomableImage from "/src/theme/ZoomableImage.js";
import Admonition from "@theme/Admonition";

View file

@ -1,8 +1,3 @@
import ThemedImage from "@theme/ThemedImage";
import useBaseUrl from "@docusaurus/useBaseUrl";
import ZoomableImage from "/src/theme/ZoomableImage.js";
import ReactPlayer from "react-player";
import Admonition from "@theme/Admonition";
# Features
@ -66,9 +61,11 @@ The example below shows a Python script making a POST request to a local API end
style={{ marginBottom: "20px", display: "flex", justifyContent: "center" }}
>
<ReactPlayer playing controls url="/videos/langflow_api.mp4" />
</div>import ThemedImage from "@theme/ThemedImage";
</div>
import ThemedImage from "@theme/ThemedImage";
import useBaseUrl from "@docusaurus/useBaseUrl";
import ZoomableImage from "/src/theme/ZoomableImage.js";
import ReactPlayer from "react-player";
import Admonition from "@theme/Admonition";

View file

@ -1,7 +0,0 @@
import ThemedImage from "@theme/ThemedImage";
import useBaseUrl from "@docusaurus/useBaseUrl";
import ZoomableImage from "/src/theme/ZoomableImage.js";
import ReactPlayer from "react-player";
Now, we need to explain what are the permissions the superuser gets. Once logged in, they can activate new users,
edit them,

View file

@ -0,0 +1,44 @@
import Admonition from '@theme/Admonition';
# Compatibility with Previous Versions
## TLDR;
- You'll need to add a few components to your flow to make it compatible with the new version of Langflow.
- Add a Runnable Executor, connect it to the last component (a Chain or an Agent) in your flow, and connect a Chat Input and a Chat Output to the Runnable Executor. This should work *most of the time*.
- You might also need to update the Chain or Agent component to the latest version.
- Most Components will work as they are, but you'll need to add an Input and an Output to your flow.
- You can use the Runnable Executor to run a LangChain runnable (which is the output of many components before 1.0)
- We need your feedback on this, so please let us know how it goes and what you think.
## Introduction
Langflow now works best with a flow that has an Input and an Output and that is mostly what you'll need to add to your existing flows.
Hopefully, you'll find that even though you still can work with your current flows, updating all your components to the new version of Langflow will be worth it.
We've tried to make it as easy as possible for you to adapt your existing flows to work seamlessly in the new version of Langflow.
## How to Adapt Your Existing Flows
The steps to take are few but not always simple. Here's how you can adapt your existing flows to work seamlessly in the new version of Langflow:
<Admonition type="caution">
<p>**Caution:**</p>
<p>While this should work most of the time, it might not work for all flows. You might need to update the Chain or Agent component to the latest version. Please let us know if you encounter any issues.</p>
</Admonition>
1. **Check if your flow ends with a Chain or Agent component**.
- If it does not, it *should* work as it is because it probably was not a chat flow.
2. **Add a Runnable Executor**.
- Add a Runnable Executor to the end of your flow.
- Connect the last component (a Chain or an Agent) in your flow to the Runnable Executor.
3. **Add a Chat Input and a Chat Output**.
- Add a Chat Input and a Chat Output to your flow.
- Connect the Chat Input to the Runnable Executor.
- Connect the Chat Output to the Runnable Executor.
{/* Add picture of the flow */}

View file

View file

View file

View file

@ -0,0 +1,36 @@
# Inputs and Outputs
TL;DR: Inputs and Outputs are a category of components that are used to define where data comes in and out of your flow. They also
dynamically change the Interaction Panel and can be renamed to make it easier to build and maintain your flows.
## Introduction
Langflow 1.0 introduces new categories of components called Inputs and Outputs. They are used to make it easier to understand and interact with your flows.
Let's start with what they have in common:
- Components in these categories connect to components that have Text or Record inputs or outputs. Some can connect to both but you have to pick what type of data you want to output or input.
- They can be renamed to help you identify them more easily in the Interaction Panel and while using the API.
- They dynamically change the Interaction Panel to make it easier to understand and interact with your flows.
Native Langflow Components were created to be powerful tools that work around Langflow's features. They are designed to be easy to use and understand, and to help you build your flows faster.
Let's dive into Inputs and Outputs.
## Inputs
Inputs are components that are used to define where data comes into your flow. They can be used to receive data from the user, from a database, or from any other source that can be converted to Text or Record.
The difference between Chat Input and other Input components is the format of the output, the number of configurable fields, and the way they are displayed in the Interaction Panel.
Chat Input components can output Text or Record. When you want to pass the sender name, or sender to the next component, you can use the Record output, and when you want to pass the message only you can use the Text output. This is useful when saving the message to a database or a memory system like Zep.
You can find out more about it and the other Inputs [here](../components/inputs).
## Outputs
Outputs are components that are used to define where data comes out of your flow. They can be used to send data to the user, to the Interaction Panel, or to define how the data will be displayed in the Interaction Panel.
The Chat Output works similarly to the Chat Input but does not have a field that allows for written input. It is used as an Output definition and can be used to send data to the user.
You can find out more about it and the other Outputs [here](../components/outputs).

View file

View file

View file

View file

@ -0,0 +1 @@
# A New Customization and Control

View file

@ -0,0 +1 @@
# Debugging Reimagined

View file

@ -0,0 +1,124 @@
# Migrating to Langflow 1.0: A Guide
Langflow 1.0 is a significant update that brings many exciting changes and improvements to the platform. This guide will walk you through the key differences and help you migrate your existing projects to the new version.
If you have any questions or need assistance during the migration process, please don't hesitate to reach out to in our [Discord](https://discord.gg/wZSWQaukgJ) or [GitHub](https://github.com/logspace-ai/langflow/issues) community.
We have a special channel
## TLDR;
- Inputs and Outputs of Components have changed
- The composition model has been replaced with a flow of data
- Continued support for LangChain and new support for multiple frameworks
- Redesigned sidebar and customizable interaction panel
- New Native Categories and Components
- Improved user experience with Text and Record modes
- CustomComponent for all components
- Compatibility with previous versions using Runnable Executor
- Multiple flows in the canvas
- Improved component status
- Ability to connect Output components to any other Component
- Rename and edit component descriptions
- Pass tweaks and inputs in the API using Display Name
- Global Variables for Text Fields
- Experimental components like SubFlow and Flow as Tool
- Experimental State Management system with Notify and Listen components
## Inputs and Outputs of Components
Langflow 1.0 introduces adds the concept of Inputs and Outputs to flows, allowing clear definition of the data flow between components. Discover how to use Inputs and Outputs to pass data between components and create more dynamic flows.
[Learn more about Inputs and Outputs of Components](../guides/inputs-and-outputs)
## From Composition to Freedom
Even though composition is still possible in Langflow 1.0, the new standard is getting data moving through the flow. This allows for more flexibility and control over the data flow in your projects. Check out how to use this in new and existing projects.
[Learn more about the Flow of Data](../guides/flow-of-data)
## Continued Support for LangChain and Multiple Frameworks
Langflow 1.0 continues to support LangChain while also introducing support for multiple frameworks. This is another important boon that adding the paradigm of data flow brings to the table. Find out how to leverage the power of different frameworks in your projects.
[Learn more about Supported Frameworks](../guides/supported-frameworks)
## Sidebar Redesign and Customizable Interaction Panel
We've expanded on the chat experience by creating a customizable interaction panel that allows you to design a panel that fits your needs and interact with it. The sidebar has also been redesigned to provide a more intuitive and user-friendly experience. Explore the new sidebar and interaction panel features to enhance your workflow.
[Learn more about some of the UI updates](../guides/sidebar-and-interaction-panel)
## New Native Categories and Components
Langflow 1.0 introduces many new native categories, including Inputs, Outputs, Helpers, Experimental, Models, and more. Discover the new components available, such as Chat Input, Prompt, Files, API Request, and others.
[Learn more about New Categories and Components](../guides/new-categories-and-components)
## New Way of Using Langflow: Text and Record (and more to come)
With the introduction of Text and Record types connections between Components are more intuitive and easier to understand. This is the first step in a series of improvements to the way you interact with Langflow. Learn how to use Text, and Record and how they help you build better flows.
[Learn more about Text and Record](../guides/text-and-record)
## CustomComponent for All Components
Almost all components in Langflow 1.0 are now CustomComponents, allowing you to check and modify the code of each component. Discover how to leverage this feature to customize your components to your specific needs.
[Learn more about CustomComponent](../guides/custom-component)
## Compatibility with Previous Versions
To use flows built in previous versions of Langflow, you can utilize the experimental component Runnable Executor along with an Input and Output. **We'd love your feedback on this**. Learn how to adapt your existing flows to work seamlessly in the new version of Langflow.
[Learn more about Compatibility with Previous Versions](../guides/compatibility)
## Multiple Flows in the Canvas
Langflow 1.0 allows you to have more than one flow in the canvas and run them separately. Discover how to create and manage multiple flows within a single project.
[Learn more about Multiple Flows](../guides/multiple-flows)
## Improved Component Status
Each component now displays its status more clearly, allowing you to quickly identify any issues or errors. Explore how to use the new component status feature to troubleshoot and optimize your flows.
[Learn more about Component Status](../guides/component-status-and-data-passing)
## Connecting Output Components
You can now connect Output components to any other component (that has a Text output), providing a better understanding of the data flow. Explore the possibilities of connecting Output components and how it enhances your flow's functionality.
[Learn more about Connecting Output Components](../guides/connecting-output-components)
## Renaming and Editing Component Descriptions
Langflow 1.0 allows you to rename and edit the description of each component, making it easier to understand and interact with the flow. Learn how to customize your component names and descriptions for improved clarity.
[Learn more about Renaming and Editing Components](../guides/renaming-and-editing-components)
## Passing Tweaks and Inputs in the API
Things got a whole lot easier. You can now pass tweaks and inputs in the API by referencing the Display Name of the component. Discover how to leverage this feature to dynamically control your flow's behavior.
[Learn more about Passing Tweaks and Inputs](../guides/passing-tweaks-and-inputs)
## Global Variables for Text Fields
Global Variables can be used in any Text Field across your projects. Learn how to define and utilize Global Variables to streamline your workflow.
[Learn more about Global Variables](../guides/global-variables)
## Experimental Components
Explore the experimental components available in Langflow 1.0, such as SubFlow, which allows you to load a flow as a component dynamically, and Flow as Tool, which enables you to use a flow as a tool for an Agent.
[Learn more about Experimental Components](../guides/experimental-components)
## Experimental State Management System
We are experimenting with a State Management system for flows that allows components to trigger other components and pass messages between them using the Notify and Listen components. Discover how to leverage this system to create more dynamic and interactive flows.
[Learn more about State Management](../guides/state-management)
We hope this guide helps you navigate the changes and improvements in Langflow 1.0. If you have any questions or need further assistance, please don't hesitate to reach out to us in our [Discord](https://discord.gg/wZSWQaukgJ).

View file

@ -0,0 +1 @@
# Simplification Through Standardization

427
docs/package-lock.json generated
View file

@ -10,10 +10,10 @@
"dependencies": {
"@babel/preset-react": "^7.22.3",
"@code-hike/mdx": "^0.9.0",
"@docusaurus/core": "3.0.1",
"@docusaurus/plugin-ideal-image": "^3.0.1",
"@docusaurus/preset-classic": "3.0.1",
"@docusaurus/theme-classic": "^3.0.1",
"@docusaurus/core": "^3.1.1",
"@docusaurus/plugin-ideal-image": "^3.1.1",
"@docusaurus/preset-classic": "^3.1.1",
"@docusaurus/theme-classic": "^3.1.1",
"@docusaurus/theme-search-algolia": "^3.0.1",
"@mdx-js/react": "^2.3.0",
"@mendable/search": "^0.0.154",
@ -2069,9 +2069,9 @@
}
},
"node_modules/@docusaurus/core": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/core/-/core-3.0.1.tgz",
"integrity": "sha512-CXrLpOnW+dJdSv8M5FAJ3JBwXtL6mhUWxFA8aS0ozK6jBG/wgxERk5uvH28fCeFxOGbAT9v1e9dOMo1X2IEVhQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/core/-/core-3.1.1.tgz",
"integrity": "sha512-2nQfKFcf+MLEM7JXsXwQxPOmQAR6ytKMZVSx7tVi9HEm9WtfwBH1fp6bn8Gj4zLUhjWKCLoysQ9/Wm+EZCQ4yQ==",
"dependencies": {
"@babel/core": "^7.23.3",
"@babel/generator": "^7.23.3",
@ -2083,13 +2083,13 @@
"@babel/runtime": "^7.22.6",
"@babel/runtime-corejs3": "^7.22.6",
"@babel/traverse": "^7.22.8",
"@docusaurus/cssnano-preset": "3.0.1",
"@docusaurus/logger": "3.0.1",
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/cssnano-preset": "3.1.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/react-loadable": "5.5.2",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-common": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-common": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@slorber/static-site-generator-webpack-plugin": "^4.0.7",
"@svgr/webpack": "^6.5.1",
"autoprefixer": "^10.4.14",
@ -2249,9 +2249,9 @@
"integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A=="
},
"node_modules/@docusaurus/cssnano-preset": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/cssnano-preset/-/cssnano-preset-3.0.1.tgz",
"integrity": "sha512-wjuXzkHMW+ig4BD6Ya1Yevx9UJadO4smNZCEljqBoQfIQrQskTswBs7lZ8InHP7mCt273a/y/rm36EZhqJhknQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/cssnano-preset/-/cssnano-preset-3.1.1.tgz",
"integrity": "sha512-LnoIDjJWbirdbVZDMq+4hwmrTl2yHDnBf9MLG9qyExeAE3ac35s4yUhJI8yyTCdixzNfKit4cbXblzzqMu4+8g==",
"dependencies": {
"cssnano-preset-advanced": "^5.3.10",
"postcss": "^8.4.26",
@ -2263,9 +2263,9 @@
}
},
"node_modules/@docusaurus/logger": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/logger/-/logger-3.0.1.tgz",
"integrity": "sha512-I5L6Nk8OJzkVA91O2uftmo71LBSxe1vmOn9AMR6JRCzYeEBrqneWMH02AqMvjJ2NpMiviO+t0CyPjyYV7nxCWQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/logger/-/logger-3.1.1.tgz",
"integrity": "sha512-BjkNDpQzewcTnST8trx4idSoAla6zZ3w22NqM/UMcFtvYJgmoE4layuTzlfql3VFPNuivvj7BOExa/+21y4X2Q==",
"dependencies": {
"chalk": "^4.1.2",
"tslib": "^2.6.0"
@ -2339,11 +2339,11 @@
}
},
"node_modules/@docusaurus/lqip-loader": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/lqip-loader/-/lqip-loader-3.0.1.tgz",
"integrity": "sha512-hFSu8ltYo0ZnWBWmjMhSprOr6nNKG01YdMDxH/hahBfyaNDCkZU4o7mQNgUW845lvYdp6bhjyW31WJwBjOnLqw==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/lqip-loader/-/lqip-loader-3.1.1.tgz",
"integrity": "sha512-s06lySAX5ghCiQe0+/GaMWcVvgkBQ6U8p182fW+JbdjxABS8ecx2in2AQJbvrwKNgiMjOhsXiaE6BmbQAmT6nw==",
"dependencies": {
"@docusaurus/logger": "3.0.1",
"@docusaurus/logger": "3.1.1",
"file-loader": "^6.2.0",
"lodash": "^4.17.21",
"sharp": "^0.32.3",
@ -2354,15 +2354,15 @@
}
},
"node_modules/@docusaurus/mdx-loader": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/mdx-loader/-/mdx-loader-3.0.1.tgz",
"integrity": "sha512-ldnTmvnvlrONUq45oKESrpy+lXtbnTcTsFkOTIDswe5xx5iWJjt6eSa0f99ZaWlnm24mlojcIGoUWNCS53qVlQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/mdx-loader/-/mdx-loader-3.1.1.tgz",
"integrity": "sha512-xN2IccH9+sv7TmxwsDJNS97BHdmlqWwho+kIVY4tcCXkp+k4QuzvWBeunIMzeayY4Fu13A6sAjHGv5qm72KyGA==",
"dependencies": {
"@babel/parser": "^7.22.7",
"@babel/traverse": "^7.22.8",
"@docusaurus/logger": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@mdx-js/mdx": "^3.0.0",
"@slorber/remark-comment": "^1.0.0",
"escape-html": "^1.0.3",
@ -2434,17 +2434,17 @@
}
},
"node_modules/@docusaurus/plugin-content-blog": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-blog/-/plugin-content-blog-3.0.1.tgz",
"integrity": "sha512-cLOvtvAyaMQFLI8vm4j26svg3ktxMPSXpuUJ7EERKoGbfpJSsgtowNHcRsaBVmfuCsRSk1HZ/yHBsUkTmHFEsg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-blog/-/plugin-content-blog-3.1.1.tgz",
"integrity": "sha512-ew/3VtVoG3emoAKmoZl7oKe1zdFOsI0NbcHS26kIxt2Z8vcXKCUgK9jJJrz0TbOipyETPhqwq4nbitrY3baibg==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/logger": "3.0.1",
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-common": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-common": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"cheerio": "^1.0.0-rc.12",
"feed": "^4.2.2",
"fs-extra": "^11.1.1",
@ -2465,17 +2465,17 @@
}
},
"node_modules/@docusaurus/plugin-content-docs": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.0.1.tgz",
"integrity": "sha512-dRfAOA5Ivo+sdzzJGXEu33yAtvGg8dlZkvt/NEJ7nwi1F2j4LEdsxtfX2GKeETB2fP6XoGNSQnFXqa2NYGrHFg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-docs/-/plugin-content-docs-3.1.1.tgz",
"integrity": "sha512-lhFq4E874zw0UOH7ujzxnCayOyAt0f9YPVYSb9ohxrdCM8B4szxitUw9rIX4V9JLLHVoqIJb6k+lJJ1jrcGJ0A==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/logger": "3.0.1",
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/module-type-aliases": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/module-type-aliases": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@types/react-router-config": "^5.0.7",
"combine-promises": "^1.1.0",
"fs-extra": "^11.1.1",
@ -2494,12 +2494,12 @@
}
},
"node_modules/@docusaurus/plugin-content-docs/node_modules/@docusaurus/module-type-aliases": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.0.1.tgz",
"integrity": "sha512-DEHpeqUDsLynl3AhQQiO7AbC7/z/lBra34jTcdYuvp9eGm01pfH1wTVq8YqWZq6Jyx0BgcVl/VJqtE9StRd9Ag==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.1.1.tgz",
"integrity": "sha512-xBJyx0TMfAfVZ9ZeIOb1awdXgR4YJMocIEzTps91rq+hJDFJgJaylDtmoRhUxkwuYmNK1GJpW95b7DLztSBJ3A==",
"dependencies": {
"@docusaurus/react-loadable": "5.5.2",
"@docusaurus/types": "3.0.1",
"@docusaurus/types": "3.1.1",
"@types/history": "^4.7.11",
"@types/react": "*",
"@types/react-router-config": "*",
@ -2513,15 +2513,15 @@
}
},
"node_modules/@docusaurus/plugin-content-pages": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-pages/-/plugin-content-pages-3.0.1.tgz",
"integrity": "sha512-oP7PoYizKAXyEttcvVzfX3OoBIXEmXTMzCdfmC4oSwjG4SPcJsRge3mmI6O8jcZBgUPjIzXD21bVGWEE1iu8gg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-content-pages/-/plugin-content-pages-3.1.1.tgz",
"integrity": "sha512-NQHncNRAJbyLtgTim9GlEnNYsFhuCxaCNkMwikuxLTiGIPH7r/jpb7O3f3jUMYMebZZZrDq5S7om9a6rvB/YCA==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"fs-extra": "^11.1.1",
"tslib": "^2.6.0",
"webpack": "^5.88.1"
@ -2535,13 +2535,13 @@
}
},
"node_modules/@docusaurus/plugin-debug": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-debug/-/plugin-debug-3.0.1.tgz",
"integrity": "sha512-09dxZMdATky4qdsZGzhzlUvvC+ilQ2hKbYF+wez+cM2mGo4qHbv8+qKXqxq0CQZyimwlAOWQLoSozIXU0g0i7g==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-debug/-/plugin-debug-3.1.1.tgz",
"integrity": "sha512-xWeMkueM9wE/8LVvl4+Qf1WqwXmreMjI5Kgr7GYCDoJ8zu4kD+KaMhrh7py7MNM38IFvU1RfrGKacCEe2DRRfQ==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"fs-extra": "^11.1.1",
"react-json-view-lite": "^1.2.0",
"tslib": "^2.6.0"
@ -2555,13 +2555,13 @@
}
},
"node_modules/@docusaurus/plugin-google-analytics": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-analytics/-/plugin-google-analytics-3.0.1.tgz",
"integrity": "sha512-jwseSz1E+g9rXQwDdr0ZdYNjn8leZBnKPjjQhMBEiwDoenL3JYFcNW0+p0sWoVF/f2z5t7HkKA+cYObrUh18gg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-analytics/-/plugin-google-analytics-3.1.1.tgz",
"integrity": "sha512-+q2UpWTqVi8GdlLoSlD5bS/YpxW+QMoBwrPrUH/NpvpuOi0Of7MTotsQf9JWd3hymZxl2uu1o3PIrbpxfeDFDQ==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"tslib": "^2.6.0"
},
"engines": {
@ -2573,13 +2573,13 @@
}
},
"node_modules/@docusaurus/plugin-google-gtag": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-gtag/-/plugin-google-gtag-3.0.1.tgz",
"integrity": "sha512-UFTDvXniAWrajsulKUJ1DB6qplui1BlKLQZjX4F7qS/qfJ+qkKqSkhJ/F4VuGQ2JYeZstYb+KaUzUzvaPK1aRQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-gtag/-/plugin-google-gtag-3.1.1.tgz",
"integrity": "sha512-0mMPiBBlQ5LFHTtjxuvt/6yzh8v7OxLi3CbeEsxXZpUzcKO/GC7UA1VOWUoBeQzQL508J12HTAlR3IBU9OofSw==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@types/gtag.js": "^0.0.12",
"tslib": "^2.6.0"
},
@ -2592,13 +2592,13 @@
}
},
"node_modules/@docusaurus/plugin-google-tag-manager": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-tag-manager/-/plugin-google-tag-manager-3.0.1.tgz",
"integrity": "sha512-IPFvuz83aFuheZcWpTlAdiiX1RqWIHM+OH8wS66JgwAKOiQMR3+nLywGjkLV4bp52x7nCnwhNk1rE85Cpy/CIw==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-google-tag-manager/-/plugin-google-tag-manager-3.1.1.tgz",
"integrity": "sha512-d07bsrMLdDIryDtY17DgqYUbjkswZQr8cLWl4tzXrt5OR/T/zxC1SYKajzB3fd87zTu5W5klV5GmUwcNSMXQXA==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"tslib": "^2.6.0"
},
"engines": {
@ -2610,16 +2610,16 @@
}
},
"node_modules/@docusaurus/plugin-ideal-image": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-ideal-image/-/plugin-ideal-image-3.0.1.tgz",
"integrity": "sha512-IvAUpEIz6v1/fVz6UTdQY12pYIE5geNFtsuKpsULpMaotwYf3Gs7acXjQog4qquKkc65yV5zuvMj8BZMHEwLyQ==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-ideal-image/-/plugin-ideal-image-3.1.1.tgz",
"integrity": "sha512-FYce5eV5/fWO4qIG8sKYdK3MTwusdxQML/M62IiltUNM/cqFkDrty1d+H+/I2PYX1s7AOoL3YomdJNP4vra/Tg==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/lqip-loader": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/lqip-loader": "3.1.1",
"@docusaurus/responsive-loader": "^1.7.0",
"@docusaurus/theme-translations": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/theme-translations": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@slorber/react-ideal-image": "^0.0.12",
"react-waypoint": "^10.3.0",
"sharp": "^0.32.3",
@ -2641,16 +2641,16 @@
}
},
"node_modules/@docusaurus/plugin-sitemap": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-sitemap/-/plugin-sitemap-3.0.1.tgz",
"integrity": "sha512-xARiWnjtVvoEniZudlCq5T9ifnhCu/GAZ5nA7XgyLfPcNpHQa241HZdsTlLtVcecEVVdllevBKOp7qknBBaMGw==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/plugin-sitemap/-/plugin-sitemap-3.1.1.tgz",
"integrity": "sha512-iJ4hCaMmDaUqRv131XJdt/C/jJQx8UreDWTRqZKtNydvZVh/o4yXGRRFOplea1D9b/zpwL1Y+ZDwX7xMhIOTmg==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/logger": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-common": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-common": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"fs-extra": "^11.1.1",
"sitemap": "^7.1.1",
"tslib": "^2.6.0"
@ -2664,23 +2664,23 @@
}
},
"node_modules/@docusaurus/preset-classic": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/preset-classic/-/preset-classic-3.0.1.tgz",
"integrity": "sha512-il9m9xZKKjoXn6h0cRcdnt6wce0Pv1y5t4xk2Wx7zBGhKG1idu4IFHtikHlD0QPuZ9fizpXspXcTzjL5FXc1Gw==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/preset-classic/-/preset-classic-3.1.1.tgz",
"integrity": "sha512-jG4ys/hWYf69iaN/xOmF+3kjs4Nnz1Ay3CjFLDtYa8KdxbmUhArA9HmP26ru5N0wbVWhY+6kmpYhTJpez5wTyg==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/plugin-content-blog": "3.0.1",
"@docusaurus/plugin-content-docs": "3.0.1",
"@docusaurus/plugin-content-pages": "3.0.1",
"@docusaurus/plugin-debug": "3.0.1",
"@docusaurus/plugin-google-analytics": "3.0.1",
"@docusaurus/plugin-google-gtag": "3.0.1",
"@docusaurus/plugin-google-tag-manager": "3.0.1",
"@docusaurus/plugin-sitemap": "3.0.1",
"@docusaurus/theme-classic": "3.0.1",
"@docusaurus/theme-common": "3.0.1",
"@docusaurus/theme-search-algolia": "3.0.1",
"@docusaurus/types": "3.0.1"
"@docusaurus/core": "3.1.1",
"@docusaurus/plugin-content-blog": "3.1.1",
"@docusaurus/plugin-content-docs": "3.1.1",
"@docusaurus/plugin-content-pages": "3.1.1",
"@docusaurus/plugin-debug": "3.1.1",
"@docusaurus/plugin-google-analytics": "3.1.1",
"@docusaurus/plugin-google-gtag": "3.1.1",
"@docusaurus/plugin-google-tag-manager": "3.1.1",
"@docusaurus/plugin-sitemap": "3.1.1",
"@docusaurus/theme-classic": "3.1.1",
"@docusaurus/theme-common": "3.1.1",
"@docusaurus/theme-search-algolia": "3.1.1",
"@docusaurus/types": "3.1.1"
},
"engines": {
"node": ">=18.0"
@ -2726,22 +2726,22 @@
}
},
"node_modules/@docusaurus/theme-classic": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-classic/-/theme-classic-3.0.1.tgz",
"integrity": "sha512-XD1FRXaJiDlmYaiHHdm27PNhhPboUah9rqIH0lMpBt5kYtsGjJzhqa27KuZvHLzOP2OEpqd2+GZ5b6YPq7Q05Q==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-classic/-/theme-classic-3.1.1.tgz",
"integrity": "sha512-GiPE/jbWM8Qv1A14lk6s9fhc0LhPEQ00eIczRO4QL2nAQJZXkjPG6zaVx+1cZxPFWbAsqSjKe2lqkwF3fGkQ7Q==",
"dependencies": {
"@docusaurus/core": "3.0.1",
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/module-type-aliases": "3.0.1",
"@docusaurus/plugin-content-blog": "3.0.1",
"@docusaurus/plugin-content-docs": "3.0.1",
"@docusaurus/plugin-content-pages": "3.0.1",
"@docusaurus/theme-common": "3.0.1",
"@docusaurus/theme-translations": "3.0.1",
"@docusaurus/types": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-common": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/module-type-aliases": "3.1.1",
"@docusaurus/plugin-content-blog": "3.1.1",
"@docusaurus/plugin-content-docs": "3.1.1",
"@docusaurus/plugin-content-pages": "3.1.1",
"@docusaurus/theme-common": "3.1.1",
"@docusaurus/theme-translations": "3.1.1",
"@docusaurus/types": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-common": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"@mdx-js/react": "^3.0.0",
"clsx": "^2.0.0",
"copy-text-to-clipboard": "^3.2.0",
@ -2765,12 +2765,12 @@
}
},
"node_modules/@docusaurus/theme-classic/node_modules/@docusaurus/module-type-aliases": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.0.1.tgz",
"integrity": "sha512-DEHpeqUDsLynl3AhQQiO7AbC7/z/lBra34jTcdYuvp9eGm01pfH1wTVq8YqWZq6Jyx0BgcVl/VJqtE9StRd9Ag==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.1.1.tgz",
"integrity": "sha512-xBJyx0TMfAfVZ9ZeIOb1awdXgR4YJMocIEzTps91rq+hJDFJgJaylDtmoRhUxkwuYmNK1GJpW95b7DLztSBJ3A==",
"dependencies": {
"@docusaurus/react-loadable": "5.5.2",
"@docusaurus/types": "3.0.1",
"@docusaurus/types": "3.1.1",
"@types/history": "^4.7.11",
"@types/react": "*",
"@types/react-router-config": "*",
@ -2784,9 +2784,9 @@
}
},
"node_modules/@docusaurus/theme-classic/node_modules/@mdx-js/react": {
"version": "3.0.0",
"resolved": "https://registry.npmjs.org/@mdx-js/react/-/react-3.0.0.tgz",
"integrity": "sha512-nDctevR9KyYFyV+m+/+S4cpzCWHqj+iHDHq3QrsWezcC+B17uZdIWgCguESUkwFhM3n/56KxWVE3V6EokrmONQ==",
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@mdx-js/react/-/react-3.0.1.tgz",
"integrity": "sha512-9ZrPIU4MGf6et1m1ov3zKf+q9+deetI51zprKB1D/z3NOb+rUxxtEl3mCjW5wTGh6VhRdwPueh1oRzi6ezkA8A==",
"dependencies": {
"@types/mdx": "^2.0.0"
},
@ -2800,9 +2800,9 @@
}
},
"node_modules/@docusaurus/theme-classic/node_modules/clsx": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/clsx/-/clsx-2.0.0.tgz",
"integrity": "sha512-rQ1+kcj+ttHG0MKVGBUXwayCCF1oh39BF5COIpRzuCEv8Mwjv0XucrI2ExNTOn9IlLifGClWQcU9BrZORvtw6Q==",
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.0.tgz",
"integrity": "sha512-m3iNNWpd9rl3jvvcBnu70ylMdrXt8Vlq4HYadnU5fwcOtvkSQWPmj7amUcDT2qYI7risszBjI5AUIUox9D16pg==",
"engines": {
"node": ">=6"
}
@ -2820,17 +2820,17 @@
}
},
"node_modules/@docusaurus/theme-common": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-common/-/theme-common-3.0.1.tgz",
"integrity": "sha512-cr9TOWXuIOL0PUfuXv6L5lPlTgaphKP+22NdVBOYah5jSq5XAAulJTjfe+IfLsEG4L7lJttLbhW7LXDFSAI7Ag==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-common/-/theme-common-3.1.1.tgz",
"integrity": "sha512-38urZfeMhN70YaXkwIGXmcUcv2CEYK/2l4b05GkJPrbEbgpsIZM3Xc+Js2ehBGGZmfZq8GjjQ5RNQYG+MYzCYg==",
"dependencies": {
"@docusaurus/mdx-loader": "3.0.1",
"@docusaurus/module-type-aliases": "3.0.1",
"@docusaurus/plugin-content-blog": "3.0.1",
"@docusaurus/plugin-content-docs": "3.0.1",
"@docusaurus/plugin-content-pages": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-common": "3.0.1",
"@docusaurus/mdx-loader": "3.1.1",
"@docusaurus/module-type-aliases": "3.1.1",
"@docusaurus/plugin-content-blog": "3.1.1",
"@docusaurus/plugin-content-docs": "3.1.1",
"@docusaurus/plugin-content-pages": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-common": "3.1.1",
"@types/history": "^4.7.11",
"@types/react": "*",
"@types/react-router-config": "*",
@ -2849,12 +2849,12 @@
}
},
"node_modules/@docusaurus/theme-common/node_modules/@docusaurus/module-type-aliases": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.0.1.tgz",
"integrity": "sha512-DEHpeqUDsLynl3AhQQiO7AbC7/z/lBra34jTcdYuvp9eGm01pfH1wTVq8YqWZq6Jyx0BgcVl/VJqtE9StRd9Ag==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/module-type-aliases/-/module-type-aliases-3.1.1.tgz",
"integrity": "sha512-xBJyx0TMfAfVZ9ZeIOb1awdXgR4YJMocIEzTps91rq+hJDFJgJaylDtmoRhUxkwuYmNK1GJpW95b7DLztSBJ3A==",
"dependencies": {
"@docusaurus/react-loadable": "5.5.2",
"@docusaurus/types": "3.0.1",
"@docusaurus/types": "3.1.1",
"@types/history": "^4.7.11",
"@types/react": "*",
"@types/react-router-config": "*",
@ -2868,9 +2868,9 @@
}
},
"node_modules/@docusaurus/theme-common/node_modules/clsx": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/clsx/-/clsx-2.0.0.tgz",
"integrity": "sha512-rQ1+kcj+ttHG0MKVGBUXwayCCF1oh39BF5COIpRzuCEv8Mwjv0XucrI2ExNTOn9IlLifGClWQcU9BrZORvtw6Q==",
"version": "2.1.0",
"resolved": "https://registry.npmjs.org/clsx/-/clsx-2.1.0.tgz",
"integrity": "sha512-m3iNNWpd9rl3jvvcBnu70ylMdrXt8Vlq4HYadnU5fwcOtvkSQWPmj7amUcDT2qYI7risszBjI5AUIUox9D16pg==",
"engines": {
"node": ">=6"
}
@ -2888,18 +2888,18 @@
}
},
"node_modules/@docusaurus/theme-search-algolia": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-search-algolia/-/theme-search-algolia-3.0.1.tgz",
"integrity": "sha512-DDiPc0/xmKSEdwFkXNf1/vH1SzJPzuJBar8kMcBbDAZk/SAmo/4lf6GU2drou4Ae60lN2waix+jYWTWcJRahSA==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-search-algolia/-/theme-search-algolia-3.1.1.tgz",
"integrity": "sha512-tBH9VY5EpRctVdaAhT+b1BY8y5dyHVZGFXyCHgTrvcXQy5CV4q7serEX7U3SveNT9zksmchPyct6i1sFDC4Z5g==",
"dependencies": {
"@docsearch/react": "^3.5.2",
"@docusaurus/core": "3.0.1",
"@docusaurus/logger": "3.0.1",
"@docusaurus/plugin-content-docs": "3.0.1",
"@docusaurus/theme-common": "3.0.1",
"@docusaurus/theme-translations": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/utils-validation": "3.0.1",
"@docusaurus/core": "3.1.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/plugin-content-docs": "3.1.1",
"@docusaurus/theme-common": "3.1.1",
"@docusaurus/theme-translations": "3.1.1",
"@docusaurus/utils": "3.1.1",
"@docusaurus/utils-validation": "3.1.1",
"algoliasearch": "^4.18.0",
"algoliasearch-helper": "^3.13.3",
"clsx": "^2.0.0",
@ -2926,9 +2926,9 @@
}
},
"node_modules/@docusaurus/theme-translations": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-translations/-/theme-translations-3.0.1.tgz",
"integrity": "sha512-6UrbpzCTN6NIJnAtZ6Ne9492vmPVX+7Fsz4kmp+yor3KQwA1+MCzQP7ItDNkP38UmVLnvB/cYk/IvehCUqS3dg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/theme-translations/-/theme-translations-3.1.1.tgz",
"integrity": "sha512-xvWQFwjxHphpJq5fgk37FXCDdAa2o+r7FX8IpMg+bGZBNXyWBu3MjZ+G4+eUVNpDhVinTc+j6ucL0Ain5KCGrg==",
"dependencies": {
"fs-extra": "^11.1.1",
"tslib": "^2.6.0"
@ -2938,10 +2938,11 @@
}
},
"node_modules/@docusaurus/types": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/types/-/types-3.0.1.tgz",
"integrity": "sha512-plyX2iU1tcUsF46uQ01pAd4JhexR7n0iiQ5MSnBFX6M6NSJgDYdru/i1/YNPKOnQHBoXGLHv0dNT6OAlDWNjrg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/types/-/types-3.1.1.tgz",
"integrity": "sha512-grBqOLnubUecgKFXN9q3uit2HFbCxTWX4Fam3ZFbMN0sWX9wOcDoA7lwdX/8AmeL20Oc4kQvWVgNrsT8bKRvzg==",
"dependencies": {
"@mdx-js/mdx": "^3.0.0",
"@types/history": "^4.7.11",
"@types/react": "*",
"commander": "^5.1.0",
@ -2957,11 +2958,11 @@
}
},
"node_modules/@docusaurus/utils": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils/-/utils-3.0.1.tgz",
"integrity": "sha512-TwZ33Am0q4IIbvjhUOs+zpjtD/mXNmLmEgeTGuRq01QzulLHuPhaBTTAC/DHu6kFx3wDgmgpAlaRuCHfTcXv8g==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils/-/utils-3.1.1.tgz",
"integrity": "sha512-ZJfJa5cJQtRYtqijsPEnAZoduW6sjAQ7ZCWSZavLcV10Fw0Z3gSaPKA/B4micvj2afRZ4gZxT7KfYqe5H8Cetg==",
"dependencies": {
"@docusaurus/logger": "3.0.1",
"@docusaurus/logger": "3.1.1",
"@svgr/webpack": "^6.5.1",
"escape-string-regexp": "^4.0.0",
"file-loader": "^6.2.0",
@ -2992,9 +2993,9 @@
}
},
"node_modules/@docusaurus/utils-common": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils-common/-/utils-common-3.0.1.tgz",
"integrity": "sha512-W0AxD6w6T8g6bNro8nBRWf7PeZ/nn7geEWM335qHU2DDDjHuV4UZjgUGP1AQsdcSikPrlIqTJJbKzer1lRSlIg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils-common/-/utils-common-3.1.1.tgz",
"integrity": "sha512-eGne3olsIoNfPug5ixjepZAIxeYFzHHnor55Wb2P57jNbtVaFvij/T+MS8U0dtZRFi50QU+UPmRrXdVUM8uyMg==",
"dependencies": {
"tslib": "^2.6.0"
},
@ -3011,12 +3012,12 @@
}
},
"node_modules/@docusaurus/utils-validation": {
"version": "3.0.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils-validation/-/utils-validation-3.0.1.tgz",
"integrity": "sha512-ujTnqSfyGQ7/4iZdB4RRuHKY/Nwm58IIb+41s5tCXOv/MBU2wGAjOHq3U+AEyJ8aKQcHbxvTKJaRchNHYUVUQg==",
"version": "3.1.1",
"resolved": "https://registry.npmjs.org/@docusaurus/utils-validation/-/utils-validation-3.1.1.tgz",
"integrity": "sha512-KlY4P9YVDnwL+nExvlIpu79abfEv6ZCHuOX4ZQ+gtip+Wxj0daccdReIWWtqxM/Fb5Cz1nQvUCc7VEtT8IBUAA==",
"dependencies": {
"@docusaurus/logger": "3.0.1",
"@docusaurus/utils": "3.0.1",
"@docusaurus/logger": "3.1.1",
"@docusaurus/utils": "3.1.1",
"joi": "^17.9.2",
"js-yaml": "^4.1.0",
"tslib": "^2.6.0"
@ -4928,12 +4929,12 @@
"dev": true
},
"node_modules/body-parser": {
"version": "1.20.1",
"resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.1.tgz",
"integrity": "sha512-jWi7abTbYwajOytWCQc37VulmWiRae5RyTpaCyDcS5/lMdtwSz5lOpDE67srw/HYe35f1z3fDQw+3txg7gNtWw==",
"version": "1.20.2",
"resolved": "https://registry.npmjs.org/body-parser/-/body-parser-1.20.2.tgz",
"integrity": "sha512-ml9pReCu3M61kGlqoTm2umSXTlRTuGTx0bfYj+uIUKKYycG5NtSbeetV3faSU6R7ajOPw0g/J1PvK4qNy7s5bA==",
"dependencies": {
"bytes": "3.1.2",
"content-type": "~1.0.4",
"content-type": "~1.0.5",
"debug": "2.6.9",
"depd": "2.0.0",
"destroy": "1.2.0",
@ -4941,7 +4942,7 @@
"iconv-lite": "0.4.24",
"on-finished": "2.4.1",
"qs": "6.11.0",
"raw-body": "2.5.1",
"raw-body": "2.5.2",
"type-is": "~1.6.18",
"unpipe": "1.0.0"
},
@ -6124,9 +6125,9 @@
"integrity": "sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg=="
},
"node_modules/cookie": {
"version": "0.5.0",
"resolved": "https://registry.npmjs.org/cookie/-/cookie-0.5.0.tgz",
"integrity": "sha512-YZ3GUyn/o8gfKJlnlX7g7xq4gyO6OSuhGPKaaGssGB2qgDUS0gPgtTvoyZLTt9Ab6dC4hfc9dV5arkvc/OCmrw==",
"version": "0.6.0",
"resolved": "https://registry.npmjs.org/cookie/-/cookie-0.6.0.tgz",
"integrity": "sha512-U71cyTamuh1CRNCfpGY6to28lxvNwPG4Guz/EVjgf3Jmzv0vlDp1atT9eS5dDjMYHucpHbWns6Lwf3BKz6svdw==",
"engines": {
"node": ">= 0.6"
}
@ -9620,16 +9621,16 @@
}
},
"node_modules/express": {
"version": "4.18.2",
"resolved": "https://registry.npmjs.org/express/-/express-4.18.2.tgz",
"integrity": "sha512-5/PsL6iGPdfQ/lKM1UuielYgv3BUoJfz1aUwU9vHZ+J7gyvwdQXFEBIEIaxeGf0GIcreATNyBExtalisDbuMqQ==",
"version": "4.19.2",
"resolved": "https://registry.npmjs.org/express/-/express-4.19.2.tgz",
"integrity": "sha512-5T6nhjsT+EOMzuck8JjBHARTHfMht0POzlA60WV2pMD3gyXw2LZnZ+ueGdNxG+0calOJcWKbpFcuzLZ91YWq9Q==",
"dependencies": {
"accepts": "~1.3.8",
"array-flatten": "1.1.1",
"body-parser": "1.20.1",
"body-parser": "1.20.2",
"content-disposition": "0.5.4",
"content-type": "~1.0.4",
"cookie": "0.5.0",
"cookie": "0.6.0",
"cookie-signature": "1.0.6",
"debug": "2.6.9",
"depd": "2.0.0",
@ -10005,9 +10006,9 @@
}
},
"node_modules/follow-redirects": {
"version": "1.15.3",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz",
"integrity": "sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q==",
"version": "1.15.6",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz",
"integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==",
"funding": [
{
"type": "individual",
@ -11688,9 +11689,9 @@
}
},
"node_modules/ip": {
"version": "2.0.0",
"resolved": "https://registry.npmjs.org/ip/-/ip-2.0.0.tgz",
"integrity": "sha512-WKa+XuLG1A1R0UWhl2+1XQSi+fZWMsYKffMZTTYsiZaUD8k2yDAj5atimTUD2TZkyCkNEeYE5NhFZmupOGtjYQ==",
"version": "2.0.1",
"resolved": "https://registry.npmjs.org/ip/-/ip-2.0.1.tgz",
"integrity": "sha512-lJUL9imLTNi1ZfXT+DU6rBBdbiKGBuay9B6xGSPVjUeQwaH1RIGqef8RZkUtHioLmSNpPR5M4HVKJGm1j8FWVQ==",
"dev": true
},
"node_modules/ipaddr.js": {
@ -17476,9 +17477,9 @@
}
},
"node_modules/raw-body": {
"version": "2.5.1",
"resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.1.tgz",
"integrity": "sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==",
"version": "2.5.2",
"resolved": "https://registry.npmjs.org/raw-body/-/raw-body-2.5.2.tgz",
"integrity": "sha512-8zGqypfENjCIqGhgXToC8aB2r7YrBX+AQAfIPs/Mlk+BtPTztOvTS01NRW/3Eh60J+a48lt8qsCzirQ6loCVfA==",
"dependencies": {
"bytes": "3.1.2",
"http-errors": "2.0.0",
@ -22018,9 +22019,9 @@
}
},
"node_modules/webpack-dev-middleware": {
"version": "5.3.3",
"resolved": "https://registry.npmjs.org/webpack-dev-middleware/-/webpack-dev-middleware-5.3.3.tgz",
"integrity": "sha512-hj5CYrY0bZLB+eTO+x/j67Pkrquiy7kWepMHmUMoPsmcUaeEnQJqFzHJOyxgWlq746/wUuA64p9ta34Kyb01pA==",
"version": "5.3.4",
"resolved": "https://registry.npmjs.org/webpack-dev-middleware/-/webpack-dev-middleware-5.3.4.tgz",
"integrity": "sha512-BVdTqhhs+0IfoeAf7EoH5WE+exCmqGerHfDM0IL096Px60Tq2Mn9MAbnaGUe6HiMa41KMCYF19gyzZmBcq/o4Q==",
"dependencies": {
"colorette": "^2.0.10",
"memfs": "^3.4.3",

View file

@ -16,10 +16,10 @@
"dependencies": {
"@babel/preset-react": "^7.22.3",
"@code-hike/mdx": "^0.9.0",
"@docusaurus/core": "3.0.1",
"@docusaurus/plugin-ideal-image": "^3.0.1",
"@docusaurus/preset-classic": "3.0.1",
"@docusaurus/theme-classic": "^3.0.1",
"@docusaurus/core": "^3.1.1",
"@docusaurus/plugin-ideal-image": "^3.1.1",
"@docusaurus/preset-classic": "^3.1.1",
"@docusaurus/theme-classic": "^3.1.1",
"@docusaurus/theme-search-algolia": "^3.0.1",
"@mdx-js/react": "^2.3.0",
"@mendable/search": "^0.0.154",
@ -69,4 +69,4 @@
"engines": {
"node": ">=16.14"
}
}
}

View file

@ -11,6 +11,40 @@ module.exports = {
"getting-started/creating-flows",
],
},
{
type: "category",
label: "What's New",
collapsed: false,
items: [
"whats-new/migrating-to-one-point-zero",
"whats-new/customization-control",
"whats-new/debugging-reimagined",
"whats-new/simplification-standardization",
],
},
{
type: "category",
label: "Migration Guides",
collapsed: false,
items: [
"migration/inputs-and-outputs",
"migration/flow-of-data",
"migration/supported-frameworks",
"migration/sidebar-and-interaction-panel",
"migration/new-categories-and-components",
"migration/text-and-record",
"migration/custom-component",
"migration/compatibility",
"migration/multiple-flows",
"migration/component-status-and-data-passing",
"migration/connecting-output-components",
"migration/renaming-and-editing-components",
"migration/passing-tweaks-and-inputs",
"migration/global-variables",
"migration/experimental-components",
"migration/state-management",
],
},
{
type: "category",
label: "Guidelines",
@ -66,18 +100,25 @@ module.exports = {
"guides/loading_document",
"guides/chatprompttemplate_guide",
"guides/langfuse_integration",
"guides/inputs-and-outputs",
"guides/flow-of-data",
"guides/supported-frameworks",
"guides/sidebar-and-interaction-panel",
"guides/new-categories-and-components",
"guides/text-and-record",
"guides/custom-component",
"guides/compatibility",
"guides/multiple-flows",
"guides/component-status-and-data-passing",
"guides/connecting-output-components",
"guides/renaming-and-editing-components",
"guides/passing-tweaks-and-inputs",
"guides/global-variables",
"guides/experimental-components",
"guides/state-management",
"guides/run-flow",
],
},
// {
// type: 'category',
// label: 'Components',
// collapsed: false,
// items: [
// 'components/agents', 'components/chains', 'components/loaders', 'components/embeddings', 'components/llms',
// 'components/memories', 'components/prompts','components/text-splitters', 'components/toolkits', 'components/tools',
// 'components/utilities', 'components/vector-stores', 'components/wrappers',
// ],
// },
{
type: "category",
label: "Examples",

42
poetry.lock generated
View file

@ -435,17 +435,17 @@ files = [
[[package]]
name = "boto3"
version = "1.34.70"
version = "1.34.71"
description = "The AWS SDK for Python"
optional = false
python-versions = ">=3.8"
files = [
{file = "boto3-1.34.70-py3-none-any.whl", hash = "sha256:8d7902e2c0c62837457ba18146e3feaf1dec62018617edc5c0336b65b305b682"},
{file = "boto3-1.34.70.tar.gz", hash = "sha256:54150a52eb93028b8e09df00319e8dcb68be7459333d5da00d706d75ba5130d6"},
{file = "boto3-1.34.71-py3-none-any.whl", hash = "sha256:7ce8c9a50af2f8a159a0dd86b40011d8dfdaba35005a118e51cd3ac72dc630f1"},
{file = "boto3-1.34.71.tar.gz", hash = "sha256:d786e7fbe3c4152866199786468a625dc77b9f27294cd7ad4f63cd2e0c927287"},
]
[package.dependencies]
botocore = ">=1.34.70,<1.35.0"
botocore = ">=1.34.71,<1.35.0"
jmespath = ">=0.7.1,<2.0.0"
s3transfer = ">=0.10.0,<0.11.0"
@ -454,13 +454,13 @@ crt = ["botocore[crt] (>=1.21.0,<2.0a0)"]
[[package]]
name = "botocore"
version = "1.34.70"
version = "1.34.71"
description = "Low-level, data-driven core of boto 3."
optional = false
python-versions = ">=3.8"
files = [
{file = "botocore-1.34.70-py3-none-any.whl", hash = "sha256:c86944114e85c8a8d5da06fb84f2609ed3bd23cd2fc06b30250bef7e37e8c589"},
{file = "botocore-1.34.70.tar.gz", hash = "sha256:fa03d4972cd57d505e6c0eb5d7c7a1caeb7dd49e84f963f7ebeca41fe8ab736e"},
{file = "botocore-1.34.71-py3-none-any.whl", hash = "sha256:3bc9e23aee73fe6f097823d61f79a8877790436038101a83fa96c7593e8109f8"},
{file = "botocore-1.34.71.tar.gz", hash = "sha256:c58f9ed71af2ea53d24146187130541222d7de8c27eb87d23f15457e7b83d88b"},
]
[package.dependencies]
@ -2950,6 +2950,16 @@ files = [
{file = "hpack-4.0.0.tar.gz", hash = "sha256:fc41de0c63e687ebffde81187a948221294896f6bdc0ae2312708df339430095"},
]
[[package]]
name = "html2text"
version = "2024.2.26"
description = "Turn HTML into equivalent Markdown-structured text."
optional = false
python-versions = ">=3.8"
files = [
{file = "html2text-2024.2.26.tar.gz", hash = "sha256:05f8e367d15aaabc96415376776cdd11afd5127a77fce6e36afc60c563ca2c32"},
]
[[package]]
name = "httpcore"
version = "1.0.4"
@ -3873,7 +3883,7 @@ name = "langflow-base"
version = "0.0.11"
description = "A Python package with a built-in web application"
optional = false
python-versions = ">=3.9,<3.12"
python-versions = ">=3.10,<3.12"
files = []
develop = true
@ -3881,14 +3891,25 @@ develop = true
alembic = "^1.13.0"
bcrypt = "4.0.1"
cachetools = "^5.3.1"
chromadb = "^0.4.24"
docstring-parser = "^0.15"
duckdb = "^0.9.2"
fastapi = "^0.109.0"
gunicorn = "^21.2.0"
httpx = "^0.25"
jq = {version = "^1.7.0", markers = "sys_platform != \"win32\""}
langchain = "~0.1.0"
langchain-anthropic = "^0.1.4"
langchain-astradb = "^0.1.0"
langchain-experimental = "*"
loguru = "^0.7.1"
multiprocess = "^0.70.14"
opentelemetry-api = "^1.23.0"
opentelemetry-exporter-otlp = "^1.23.0"
opentelemetry-instrumentation-asgi = "^0.44b0"
opentelemetry-instrumentation-fastapi = "^0.44b0"
opentelemetry-instrumentation-httpx = "^0.44b0"
opentelemetry-sdk = "^1.23.0"
orjson = "3.9.15"
pandas = "2.2.0"
passlib = "^1.7.4"
@ -3896,8 +3917,11 @@ pillow = "^10.2.0"
platformdirs = "^4.2.0"
pydantic = "^2.5.0"
pydantic-settings = "^2.1.0"
pypdf = "^4.1.0"
python-docx = "^1.1.0"
python-jose = "^3.3.0"
python-multipart = "^0.0.7"
python-socketio = "^5.11.0"
rich = "^13.7.0"
sqlmodel = "^0.0.14"
typer = "^0.9.0"
@ -10175,4 +10199,4 @@ local = ["ctransformers", "llama-cpp-python", "sentence-transformers"]
[metadata]
lock-version = "2.0"
python-versions = ">=3.10,<3.12"
content-hash = "d627cedabc4e480f2ae0d8def9120bf7222a52ae64890486eb7844eca8b34e2a"
content-hash = "bbdd60e5b07fe4ad4759dc69ddcf83fdedf133825835e03b74c50018da803c6b"

View file

@ -30,16 +30,13 @@ enable = true
[tool.poetry.dependencies]
python = ">=3.10,<3.12"
langflow-base = { path = "./src/backend/base", develop = true }
duckdb = "^0.9.2"
beautifulsoup4 = "^4.12.2"
google-search-results = "^2.4.1"
google-api-python-client = "^2.118.0"
openai = "^1.12.0"
chromadb = "^0.4.23"
huggingface-hub = { version = "^0.20.0", extras = ["inference"] }
llama-cpp-python = { version = "~0.2.0", optional = true }
networkx = "^3.1"
pypdf = "^4.0.0"
pysrt = "^1.1.2"
fake-useragent = "^1.4.0"
psycopg2-binary = "^2.9.6"
@ -51,7 +48,6 @@ sentence-transformers = { version = "^2.3.1", optional = true }
ctransformers = { version = "^0.2.10", optional = true }
cohere = "^4.47.0"
faiss-cpu = "^1.7.4"
anthropic = "^0.21.0"
types-cachetools = "^5.3.0.5"
pinecone-client = "^3.0.3"
pymongo = "^4.6.0"
@ -64,8 +60,6 @@ celery = { extras = ["redis"], version = "^5.3.6", optional = true }
redis = { version = "^5.0.1", optional = true }
flower = { version = "^2.0.0", optional = true }
metaphor-python = "^0.1.11"
pydantic = "^2.5.0"
pydantic-settings = "^2.1.0"
zep-python = "*"
pywin32 = { version = "^306", markers = "sys_platform == 'win32'" }
langfuse = "^2.9.0"
@ -73,7 +67,6 @@ metal-sdk = "^2.5.0"
markupsafe = "^2.1.3"
extract-msg = "^0.47.0"
# jq is not available for windows
jq = { version = "^1.6.0", markers = "sys_platform != 'win32'" }
boto3 = "^1.34.0"
numexpr = "^2.8.6"
qianfan = "0.3.5"
@ -82,21 +75,12 @@ pyautogen = "^0.2.0"
langchain-google-genai = "^0.0.6"
elasticsearch = "^8.12.0"
pytube = "^15.0.0"
python-socketio = "^5.11.0"
llama-index = "^0.10.13"
langchain-openai = "^0.0.5"
unstructured = { extras = ["md"], version = "^0.12.4" }
opentelemetry-api = "^1.23.0"
opentelemetry-sdk = "^1.23.0"
opentelemetry-exporter-otlp = "^1.23.0"
opentelemetry-instrumentation-fastapi = "^0.44b0"
opentelemetry-instrumentation-httpx = "^0.44b0"
opentelemetry-instrumentation-asgi = "^0.44b0"
dspy-ai = "^2.4.0"
crewai = "^0.22.5"
langchain-anthropic = "^0.1.4"
python-docx = "^1.1.0"
langchain-astradb = "^0.1.0"
html2text = "^2024.2.26"
[tool.poetry.group.dev.dependencies]
types-redis = "^4.6.0.5"

View file

@ -0,0 +1,9 @@
#!/bin/bash
# Create a .env if it doesn't exist, log all cases
if [ ! -f .env ]; then
echo "Creating .env file"
touch .env
else
echo ".env file already exists"
fi

View file

@ -0,0 +1,33 @@
#!/bin/bash
# Check if version argument is provided
if [ -z "$1" ]
then
echo "No argument supplied. Please provide the Poetry version to check."
exit 1
fi
echo "Checking Poetry version..."
# Check Poetry version
poetry_version=$(poetry --version | awk '{print $3}' | tr -d '()')
echo "Current Poetry version: $poetry_version"
# Compare version
if [[ "$(printf '%s\n' "$1" "$poetry_version" | sort -V | head -n1)" != "$1" ]]; then
echo "Poetry version is lower than $1. Updating..."
# Update Poetry
poetry self update
echo "Poetry updated successfully."
else
echo "Poetry version is $1 or higher. No need to update."
fi
# Check if poetry-monorepo-dependency-plugin is installed
if poetry self show | grep -q "poetry-monorepo-dependency-plugin"; then
echo "poetry-monorepo-dependency-plugin is already installed."
else
echo "Installing poetry-monorepo-dependency-plugin..."
poetry run pip install poetry-monorepo-dependency-plugin
echo "poetry-monorepo-dependency-plugin installed successfully."
fi

View file

@ -7,7 +7,12 @@ from fastapi import APIRouter, BackgroundTasks, Body, Depends, HTTPException
from fastapi.responses import StreamingResponse
from loguru import logger
from langflow.api.utils import build_and_cache_graph, format_elapsed_time, format_exception_message
from langflow.api.utils import (
build_and_cache_graph,
format_elapsed_time,
format_exception_message,
get_top_level_vertices,
)
from langflow.api.v1.schemas import (
InputValueRequest,
ResultDataResponse,
@ -93,7 +98,8 @@ async def get_vertices(
# and return the same structure but only with the ids
run_id = uuid.uuid4()
graph.set_run_id(run_id)
return VerticesOrderResponse(ids=first_layer, run_id=run_id, vertices_to_run=list(graph.vertices_to_run))
vertices_to_run = list(graph.vertices_to_run) + get_top_level_vertices(graph, graph.vertices_to_run)
return VerticesOrderResponse(ids=first_layer, run_id=run_id, vertices_to_run=vertices_to_run)
except Exception as exc:
logger.error(f"Error checking build status: {exc}")

View file

@ -35,10 +35,10 @@ class LCModelComponent(CustomComponent):
self, runnable: BaseChatModel, stream: bool, input_value: str, system_message: Optional[str] = None
):
messages = []
if input_value:
messages.append(HumanMessage(input_value))
if system_message:
messages.append(SystemMessage(system_message))
if input_value:
messages.append(HumanMessage(input_value))
if stream:
result = runnable.stream(messages)
else:

View file

@ -2,9 +2,9 @@ from langflow.interface.custom.custom_component import CustomComponent
from langflow.schema import Record
class GetNotifiedComponent(CustomComponent):
display_name = "Get Notified"
description = "A component to get notified by Notify component."
class ListenComponent(CustomComponent):
display_name = "Listen"
description = "A component to listen for a notification."
beta: bool = True
def build_config(self):

View file

@ -22,6 +22,7 @@ class RunnableExecComponent(CustomComponent):
"runnable": {
"display_name": "Runnable",
"info": "The runnable to execute.",
"input_types": ["Chain", "AgentExecutor", "Agent", "Runnable"],
},
"output_key": {
"display_name": "Output Key",
@ -31,9 +32,9 @@ class RunnableExecComponent(CustomComponent):
def build(
self,
input_key: str,
input_value: Text,
runnable: Runnable,
input_key: str = "input",
output_key: str = "output",
) -> Text:
result = runnable.invoke({input_key: input_value})

View file

@ -1,6 +1,6 @@
from .ClearMessageHistory import ClearMessageHistoryComponent
from .ExtractDataFromRecord import ExtractKeyFromRecordComponent
from .GetNotified import GetNotifiedComponent
from .Listen import GetNotifiedComponent
from .ListFlows import ListFlowsComponent
from .MergeRecords import MergeRecordsComponent
from .Notify import NotifyComponent

View file

@ -10,6 +10,8 @@ from langflow.schema import Record
class AstraDBVectorStoreComponent(CustomComponent):
display_name = "AstraDB Vector Store"
description = "Builds or loads an AstraDB Vector Store"
icon = "AstraDB"
field_order = ["token", "api_endpoint", "collection_name", "inputs", "embedding"]
def build_config(self):
return {

View file

@ -9,6 +9,8 @@ from langflow.schema import Record
class AstraDBSearchComponent(AstraDBVectorStoreComponent, LCVectorStoreComponent):
display_name = "AstraDB Search"
description = "Searches an existing AstraDB Vector Store"
icon = "AstraDB"
field_order = ["token", "api_endpoint", "collection_name", "input_value", "embedding"]
def build_config(self):
return {

View file

@ -797,7 +797,7 @@
"list": false,
"show": true,
"multiline": true,
"value": "from typing import Optional\n\nfrom langchain_openai import ChatOpenAI\n\nfrom langflow.components.models.base.model import LCModelComponent\nfrom langflow.field_typing import NestedDict, Text\n\n\nclass OpenAIModelComponent(LCModelComponent):\n display_name = \"OpenAI\"\n description = \"Generates text using OpenAI's models.\"\n icon = \"OpenAI\"\n\n def build_config(self):\n return {\n \"input_value\": {\"display_name\": \"Input\"},\n \"max_tokens\": {\n \"display_name\": \"Max Tokens\",\n \"advanced\": False,\n \"required\": False,\n },\n \"model_kwargs\": {\n \"display_name\": \"Model Kwargs\",\n \"advanced\": True,\n \"required\": False,\n },\n \"model_name\": {\n \"display_name\": \"Model Name\",\n \"advanced\": False,\n \"required\": False,\n \"options\": [\n \"gpt-4-turbo-preview\",\n \"gpt-4-0125-preview\",\n \"gpt-4-1106-preview\",\n \"gpt-4-vision-preview\",\n \"gpt-3.5-turbo-0125\",\n \"gpt-3.5-turbo-1106\",\n ],\n },\n \"openai_api_base\": {\n \"display_name\": \"OpenAI API Base\",\n \"advanced\": False,\n \"required\": False,\n \"info\": (\n \"The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\\n\\n\"\n \"You can change this to use other APIs like JinaChat, LocalAI and Prem.\"\n ),\n },\n \"openai_api_key\": {\n \"display_name\": \"OpenAI API Key\",\n \"advanced\": False,\n \"required\": False,\n \"password\": True,\n },\n \"temperature\": {\n \"display_name\": \"Temperature\",\n \"advanced\": False,\n \"required\": False,\n \"value\": 0.7,\n },\n \"stream\": {\n \"display_name\": \"Stream\",\n \"info\": \"Stream the response from the model.\",\n },\n }\n\n def build(\n self,\n input_value: Text,\n max_tokens: Optional[int] = 256,\n model_kwargs: NestedDict = {},\n model_name: str = \"gpt-4-1106-preview\",\n openai_api_base: Optional[str] = None,\n openai_api_key: Optional[str] = None,\n temperature: float = 0.7,\n stream: bool = False,\n ) -> Text:\n if not openai_api_base:\n openai_api_base = \"https://api.openai.com/v1\"\n output = ChatOpenAI(\n max_tokens=max_tokens,\n model_kwargs=model_kwargs,\n model=model_name,\n base_url=openai_api_base,\n api_key=openai_api_key,\n temperature=temperature,\n )\n\n return self.get_result(output=output, stream=stream, input_value=input_value)\n",
"value": "from typing import Optional\n\nfrom langchain_openai import ChatOpenAI\n\nfrom langflow.base.models.model import LCModelComponent\nfrom langflow.field_typing import NestedDict, Text\n\n\nclass OpenAIModelComponent(LCModelComponent):\n display_name = \"OpenAI\"\n description = \"Generates text using OpenAI's models.\"\n icon = \"OpenAI\"\n\n def build_config(self):\n return {\n \"input_value\": {\"display_name\": \"Input\"},\n \"max_tokens\": {\n \"display_name\": \"Max Tokens\",\n \"advanced\": False,\n \"required\": False,\n },\n \"model_kwargs\": {\n \"display_name\": \"Model Kwargs\",\n \"advanced\": True,\n \"required\": False,\n },\n \"model_name\": {\n \"display_name\": \"Model Name\",\n \"advanced\": False,\n \"required\": False,\n \"options\": [\n \"gpt-4-turbo-preview\",\n \"gpt-4-0125-preview\",\n \"gpt-4-1106-preview\",\n \"gpt-4-vision-preview\",\n \"gpt-3.5-turbo-0125\",\n \"gpt-3.5-turbo-1106\",\n ],\n },\n \"openai_api_base\": {\n \"display_name\": \"OpenAI API Base\",\n \"advanced\": False,\n \"required\": False,\n \"info\": (\n \"The base URL of the OpenAI API. Defaults to https://api.openai.com/v1.\\n\\n\"\n \"You can change this to use other APIs like JinaChat, LocalAI and Prem.\"\n ),\n },\n \"openai_api_key\": {\n \"display_name\": \"OpenAI API Key\",\n \"advanced\": False,\n \"required\": False,\n \"password\": True,\n },\n \"temperature\": {\n \"display_name\": \"Temperature\",\n \"advanced\": False,\n \"required\": False,\n \"value\": 0.7,\n },\n \"stream\": {\n \"display_name\": \"Stream\",\n \"info\": \"Stream the response from the model.\",\n },\n }\n\n def build(\n self,\n input_value: Text,\n max_tokens: Optional[int] = 256,\n model_kwargs: NestedDict = {},\n model_name: str = \"gpt-4-1106-preview\",\n openai_api_base: Optional[str] = None,\n openai_api_key: Optional[str] = None,\n temperature: float = 0.7,\n stream: bool = False,\n ) -> Text:\n if not openai_api_base:\n openai_api_base = \"https://api.openai.com/v1\"\n output = ChatOpenAI(\n max_tokens=max_tokens,\n model_kwargs=model_kwargs,\n model=model_name,\n base_url=openai_api_base,\n api_key=openai_api_key,\n temperature=temperature,\n )\n\n return self.get_result(output=output, stream=stream, input_value=input_value)\n",
"fileTypes": [],
"file_path": "",
"password": false,

View file

@ -34,6 +34,10 @@ class Component:
if key == "user_id":
setattr(self, "_user_id", value)
else:
if key == "code" and "from langflow import CustomComponent" in value:
value = value.replace(
"from langflow import CustomComponent", "from langflow.custom import CustomComponent"
)
setattr(self, key, value)
def __setattr__(self, key, value):

View file

@ -106,7 +106,9 @@ def initialize_session_service():
Initialize the session manager.
"""
from langflow.services.cache import factory as cache_factory
from langflow.services.session import factory as session_service_factory # type: ignore
from langflow.services.session import (
factory as session_service_factory,
) # type: ignore
initialize_settings_service()

View file

@ -157,6 +157,9 @@ def create_class(code, class_name):
if not hasattr(ast, "TypeIgnore"):
ast.TypeIgnore = create_type_ignore_class()
# Replace from langflow import CustomComponent with from langflow.custom import CustomComponent
code = code.replace("from langflow import CustomComponent", "from langflow.custom import CustomComponent")
module = ast.parse(code)
exec_globals = prepare_global_scope(code, module)

File diff suppressed because it is too large Load diff

View file

@ -25,8 +25,7 @@ documentation = "https://docs.langflow.org"
langflow-base = "langflow.__main__:main"
[tool.poetry.dependencies]
python = ">=3.9,<3.12"
python = ">=3.10,<3.12"
fastapi = "^0.109.0"
httpx = "^0.25"
uvicorn = "^0.27.0"
@ -52,6 +51,21 @@ docstring-parser = "^0.15"
python-jose = "^3.3.0"
pandas = "2.2.0"
multiprocess = "^0.70.14"
opentelemetry-api = "^1.23.0"
opentelemetry-sdk = "^1.23.0"
opentelemetry-exporter-otlp = "^1.23.0"
opentelemetry-instrumentation-fastapi = "^0.44b0"
opentelemetry-instrumentation-httpx = "^0.44b0"
opentelemetry-instrumentation-asgi = "^0.44b0"
duckdb = "^0.9.2"
python-socketio = "^5.11.0"
python-docx = "^1.1.0"
jq = { version = "^1.7.0", markers = "sys_platform != 'win32'" }
pypdf = "^4.1.0"
chromadb = "^0.4.24"
langchain-anthropic = "^0.1.4"
langchain-astradb = "^0.1.0"
[tool.poetry.group.dev.dependencies]
pytest-asyncio = "^0.21.1"

View file

@ -0,0 +1,70 @@
from typing import List, Union
from langchain.agents import AgentExecutor, BaseMultiActionAgent, BaseSingleActionAgent
from langflow import CustomComponent
from langflow.field_typing import BaseMemory, Text, Tool
class LCAgentComponent(CustomComponent):
def build_config(self):
return {
"lc": {
"display_name": "LangChain",
"info": "The LangChain to interact with.",
},
"handle_parsing_errors": {
"display_name": "Handle Parsing Errors",
"info": "If True, the agent will handle parsing errors. If False, the agent will raise an error.",
"advanced": True,
},
"output_key": {
"display_name": "Output Key",
"info": "The key to use to get the output from the agent.",
"advanced": True,
},
"memory": {
"display_name": "Memory",
"info": "Memory to use for the agent.",
},
"tools": {
"display_name": "Tools",
"info": "Tools the agent can use.",
},
"input_value": {
"display_name": "Input",
"info": "Input text to pass to the agent.",
},
}
async def run_agent(
self,
agent: Union[BaseSingleActionAgent, BaseMultiActionAgent, AgentExecutor],
inputs: str,
input_variables: list[str],
tools: List[Tool],
memory: BaseMemory = None,
handle_parsing_errors: bool = True,
output_key: str = "output",
) -> Text:
if isinstance(agent, AgentExecutor):
runnable = agent
else:
runnable = AgentExecutor.from_agent_and_tools(
agent=agent, tools=tools, verbose=True, memory=memory, handle_parsing_errors=handle_parsing_errors
)
input_dict = {"input": inputs}
for var in input_variables:
if var not in ["agent_scratchpad", "input"]:
input_dict[var] = ""
result = await runnable.ainvoke(input_dict)
self.status = result
if output_key in result:
return result.get(output_key)
elif "output" not in result:
if output_key != "output":
raise ValueError(f"Output key not found in result. Tried '{output_key}' and 'output'.")
else:
raise ValueError("Output key not found in result. Tried 'output'.")
return result.get("output")

View file

@ -0,0 +1,3 @@
from .model import LCModelComponent
__all__ = ["LCModelComponent"]

View file

@ -0,0 +1,48 @@
from typing import Optional
from langchain_core.language_models.chat_models import BaseChatModel
from langchain_core.language_models.llms import LLM
from langchain_core.messages import HumanMessage, SystemMessage
from langflow import CustomComponent
class LCModelComponent(CustomComponent):
display_name: str = "Model Name"
description: str = "Model Description"
def get_result(self, runnable: LLM, stream: bool, input_value: str):
"""
Retrieves the result from the output of a Runnable object.
Args:
output (Runnable): The output object to retrieve the result from.
stream (bool): Indicates whether to use streaming or invocation mode.
input_value (str): The input value to pass to the output object.
Returns:
The result obtained from the output object.
"""
if stream:
result = runnable.stream(input_value)
else:
message = runnable.invoke(input_value)
result = message.content if hasattr(message, "content") else message
self.status = result
return result
def get_chat_result(
self, runnable: BaseChatModel, stream: bool, input_value: str, system_message: Optional[str] = None
):
messages = []
if input_value:
messages.append(HumanMessage(input_value))
if system_message:
messages.append(SystemMessage(system_message))
if stream:
result = runnable.stream(messages)
else:
message = runnable.invoke(messages)
result = message.content
self.status = result
return result

View file

@ -0,0 +1,85 @@
from typing import Any, List, Optional, Text
from langchain_core.tools import StructuredTool
from loguru import logger
from langflow import CustomComponent
from langflow.field_typing import Tool
from langflow.graph.graph.base import Graph
from langflow.helpers.flow import build_function_and_schema
from langflow.schema.dotdict import dotdict
class FlowToolComponent(CustomComponent):
display_name = "Flow as Tool"
description = "Construct a Tool from a function that runs the loaded Flow."
field_order = ["flow_name", "name", "description", "return_direct"]
def get_flow_names(self) -> List[str]:
flow_records = self.list_flows()
return [flow_record.data["name"] for flow_record in flow_records]
def get_flow(self, flow_name: str) -> Optional[Text]:
"""
Retrieves a flow by its name.
Args:
flow_name (str): The name of the flow to retrieve.
Returns:
Optional[Text]: The flow record if found, None otherwise.
"""
flow_records = self.list_flows()
for flow_record in flow_records:
if flow_record.data["name"] == flow_name:
return flow_record
return None
def update_build_config(self, build_config: dotdict, field_value: Any, field_name: str | None = None):
logger.debug(f"Updating build config with field value {field_value} and field name {field_name}")
if field_name == "flow_name":
build_config["flow_name"]["options"] = self.get_flow_names()
return build_config
def build_config(self):
return {
"flow_name": {
"display_name": "Flow Name",
"info": "The name of the flow to run.",
"options": [],
"real_time_refresh": True,
"refresh_button": True,
},
"name": {
"display_name": "Name",
"description": "The name of the tool.",
},
"description": {
"display_name": "Description",
"description": "The description of the tool.",
},
"return_direct": {
"display_name": "Return Direct",
"description": "Return the result directly from the Tool.",
"advanced": True,
},
}
async def build(self, flow_name: str, name: str, description: str, return_direct: bool = False) -> Tool:
flow_record = self.get_flow(flow_name)
if not flow_record:
raise ValueError("Flow not found.")
graph = Graph.from_payload(flow_record.data["data"])
dynamic_flow_function, schema = build_function_and_schema(flow_record, graph)
tool = StructuredTool.from_function(
coroutine=dynamic_flow_function,
name=name,
description=description,
return_direct=return_direct,
args_schema=schema,
)
description_repr = repr(tool.description).strip("'")
args_str = "\n".join([f"- {arg_name}: {arg_data['description']}" for arg_name, arg_data in tool.args.items()])
self.status = f"{description_repr}\nArguments:\n{args_str}"
return tool

View file

@ -0,0 +1,37 @@
from langchain_community.tools.searchapi import SearchAPIRun
from langchain_community.utilities.searchapi import SearchApiAPIWrapper
from langflow import CustomComponent
from langflow.field_typing import Tool
class SearchApiToolComponent(CustomComponent):
display_name: str = "SearchApi Tool"
description: str = "Real-time search engine results API."
documentation: str = "https://www.searchapi.io/docs/google"
field_config = {
"engine": {
"display_name": "Engine",
"field_type": "str",
"info": "The search engine to use.",
},
"api_key": {
"display_name": "API Key",
"field_type": "str",
"required": True,
"password": True,
"info": "The API key to use SearchApi.",
},
}
def build(
self,
engine: str,
api_key: str,
) -> Tool:
search_api_wrapper = SearchApiAPIWrapper(engine=engine, searchapi_api_key=api_key)
tool = SearchAPIRun(api_wrapper=search_api_wrapper)
self.status = tool
return tool

View file

@ -1,27 +0,0 @@
name: Playwright Tests
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
jobs:
test:
timeout-minutes: 60
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: 18
- name: Install dependencies
run: npm ci
- name: Install Playwright Browsers
run: npx playwright install --with-deps
- name: Run Playwright tests
run: npx playwright test
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: playwright-report/
retention-days: 30

View file

@ -5770,9 +5770,9 @@
}
},
"node_modules/follow-redirects": {
"version": "1.15.5",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.5.tgz",
"integrity": "sha512-vSFWUON1B+yAw1VN4xMfxgn5fTUiaOzAJCKBwIIgT/+7CuGy9+r+5gITvP62j3RmaD5Ph65UaERdOSRGUzZtgw==",
"version": "1.15.6",
"resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.6.tgz",
"integrity": "sha512-wWN62YITEaOpSK584EZXJafH1AGpO8RVgElfkuXbTOrPX4fIfOyEpW/CsiNd8JdYrAoOvafRTOEnvsO++qCqFA==",
"funding": [
{
"type": "individual",
@ -7079,9 +7079,9 @@
}
},
"node_modules/katex": {
"version": "0.16.9",
"resolved": "https://registry.npmjs.org/katex/-/katex-0.16.9.tgz",
"integrity": "sha512-fsSYjWS0EEOwvy81j3vRA8TEAhQhKiqO+FQaKWp0m39qwOzHVBgAUBIXWj1pB+O2W3fIpNa6Y9KSKCVbfPhyAQ==",
"version": "0.16.10",
"resolved": "https://registry.npmjs.org/katex/-/katex-0.16.10.tgz",
"integrity": "sha512-ZiqaC04tp2O5utMsl2TEZTXxa6WSC4yo0fv5ML++D3QZv/vx2Mct0mTlRx3O+uUkjfuAgOkzsCmq5MiUEsDDdA==",
"funding": [
"https://opencollective.com/katex",
"https://github.com/sponsors/katex"

View file

@ -1,15 +0,0 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
</head>
<body>
<ul>
<li>
<a href="./e2e/index.html">e2e report</a>
</li>
</ul>
</body>
</html>

View file

@ -12,7 +12,7 @@ import { defineConfig, devices } from "@playwright/test";
export default defineConfig({
testDir: "./tests",
/* Run tests in files in parallel */
fullyParallel: false,
fullyParallel: true,
/* Fail the build on CI if you accidentally left test.only in the source code. */
forbidOnly: !!process.env.CI,
/* Retry on CI only */
@ -20,18 +20,22 @@ export default defineConfig({
/* Opt out of parallel tests on CI. */
workers: process.env.CI ? 2 : undefined,
/* Reporter to use. See https://playwright.dev/docs/test-reporters */
reporter: [
["html", { open: "never", outputFolder: "playwright-report/test-results" }],
],
timeout: 120 * 1000,
// reporter: [
// ["html", { open: "never", outputFolder: "playwright-report/test-results" }],
// ],
reporter: process.env.CI ? "blob" : "html",
/* Shared settings for all the projects below. See https://playwright.dev/docs/api/class-testoptions. */
use: {
/* Base URL to use in actions like `await page.goto('/')`. */
// baseURL: "http://127.0.0.1:3000",
baseURL: "http://localhost:3000/",
/* Collect trace when retrying the failed test. See https://playwright.dev/docs/trace-viewer */
trace: "on-first-retry",
},
globalTeardown: require.resolve("./tests/globalTeardown.ts"),
/* Configure projects for major browsers */
projects: [
{
@ -48,39 +52,28 @@ export default defineConfig({
// name: "webkit",
// use: { ...devices["Desktop Safari"] },
// },
/* Test against mobile viewports. */
// {
// name: 'Mobile Chrome',
// use: { ...devices['Pixel 5'] },
// },
// {
// name: 'Mobile Safari',
// use: { ...devices['iPhone 12'] },
// },
/* Test against branded browsers. */
// {
// name: 'Microsoft Edge',
// use: { ...devices['Desktop Edge'], channel: 'msedge' },
// },
// {
// name: 'Google Chrome',
// use: { ...devices['Desktop Chrome'], channel: 'chrome' },
// },
],
/* Run your local dev server before starting the tests */
// webServer: [
// {
// command: "npm run backend",
// reuseExistingServer: !process.env.CI,
// timeout: 120 * 1000,
// },
// {
// command: "npm run start",
// url: "http://127.0.0.1:3000",
// reuseExistingServer: !process.env.CI,
// },
// ],
webServer: [
{
command:
"poetry run uvicorn --factory langflow.main:create_app --host 127.0.0.1 --port 7860",
port: 7860,
env: {
LANGFLOW_DATABASE_URL: "sqlite:///./temp",
LANGFLOW_AUTO_LOGIN: "true",
},
stdout: "ignore",
reuseExistingServer: !process.env.CI,
timeout: 120 * 1000,
},
{
command: "npm start",
port: 3000,
env: {
VITE_PROXY_TARGET: "http://127.0.0.1:7860",
},
},
],
});

View file

@ -3,6 +3,17 @@
# Default value for the --ui flag
ui=false
# Absolute path to the project root directory
PROJECT_ROOT="../../"
# Check if necessary commands are available
for cmd in npx poetry fuser; do
if ! command -v $cmd &> /dev/null; then
echo "Error: Required command '$cmd' is not installed. Aborting."
exit 1
fi
done
# Parse command-line arguments
while [[ $# -gt 0 ]]; do
key="$1"
@ -23,54 +34,85 @@ done
terminate_process_by_port() {
port="$1"
echo "Terminating process on port: $port"
fuser -k -n tcp "$port" # Forcefully terminate processes using the specified port
echo "Process terminated."
if ! fuser -k -n tcp "$port"; then
echo "Failed to terminate process on port $port. Please check manually."
else
echo "Process terminated."
fi
}
delete_temp() {
cd ../../
echo "Deleting temp database"
rm temp
echo "Temp database deleted."
if cd "$PROJECT_ROOT"; then
echo "Deleting temp database"
rm -f temp && echo "Temp database deleted." || echo "Failed to delete temp database."
else
echo "Failed to navigate to project root for cleanup."
fi
}
# Trap signals to ensure cleanup on script termination
trap 'terminate_process_by_port 7860; terminate_process_by_port 3000; delete_temp' EXIT
# install playwright if there is not installed yet
npx playwright install
# Ensure the script is executed from the project root directory
if ! cd "$PROJECT_ROOT"; then
echo "Error: Failed to navigate to project root directory. Aborting."
exit 1
fi
# Navigate to the project root directory (where the Makefile is located)
cd ../../
# Install playwright if not installed yet
if ! npx playwright install; then
echo "Error: Failed to install Playwright. Aborting."
exit 1
fi
# Start the frontend using 'make frontend' in the background
make frontend &
# Start the frontend
make frontend > /dev/null 2>&1 &
# Give some time for the frontend to start (adjust sleep duration as needed)
# Adjust sleep duration as needed
sleep 10
#install backend
poetry install --extras deploy
# Install backend dependencies
if ! poetry install; then
echo "Error: Failed to install backend dependencies. Aborting."
exit 1
fi
# Start the backend using 'make backend' in the background
LANGFLOW_DATABASE_URL=sqlite:///./temp LANGFLOW_AUTO_LOGIN=True poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser --env-file .env &
# Give some time for the backend to start (adjust sleep duration as needed)
# Start the backend
LANGFLOW_DATABASE_URL=sqlite:///./temp LANGFLOW_AUTO_LOGIN=True poetry run langflow run --backend-only --port 7860 --host 0.0.0.0 --no-open-browser > /dev/null 2>&1 &
backend_pid=$! # Capture PID of the backend process
# Adjust sleep duration as needed
sleep 25
# Navigate to the test directory
cd src/frontend
# Run Playwright tests with or without UI based on the --ui flag
if [ "$ui" = true ]; then
PLAYWRIGHT_HTML_REPORT=playwright-report/e2e npx playwright test tests/end-to-end --ui --project=chromium
else
PLAYWRIGHT_HTML_REPORT=playwright-report/e2e npx playwright test tests/end-to-end --project=chromium
if ! cd src/frontend; then
echo "Error: Failed to navigate to test directory. Aborting."
kill $backend_pid # Terminate the backend process if navigation fails
echo "Backend process terminated."
exit 1
fi
npx playwright show-report
# Check if backend is running
if ! lsof -i :7860; then
echo "Error: Backend is not running. Aborting."
exit 1
fi
# After the tests are finished, you can add cleanup or teardown logic here if needed
# Run Playwright tests
if [ "$ui" = true ]; then
TEST_COMMAND="npx playwright test tests/end-to-end --ui --project=chromium"
else
TEST_COMMAND="npx playwright test tests/end-to-end --project=chromium"
fi
# The trap will automatically terminate processes by port on script exit
if ! PLAYWRIGHT_HTML_REPORT=playwright-report/e2e $TEST_COMMAND; then
echo "Error: Playwright tests failed. Aborting."
exit 1
fi
if [ "$ui" = true ]; then
echo "Opening Playwright report..."
npx playwright show-report
fi
trap 'terminate_process_by_port 7860; terminate_process_by_port 3000; delete_temp; kill $backend_pid 2>/dev/null' EXIT

View file

@ -129,7 +129,7 @@ export default function IOView({
</div>
</BaseModal.Header>
<BaseModal.Content>
<div className="flex h-full flex-col overflow-hidden">
<div className="flex h-full flex-col ">
<div className="flex-max-width mt-2 h-full">
{selectedTab !== 0 && (
<div

View file

@ -50,7 +50,7 @@ export default function FlowToolbar({ flow }: ChatType): JSX.Element {
<button
disabled={!hasApiKey || !validApiKey || !hasStore}
className={classNames(
"relative inline-flex h-full w-full items-center justify-center gap-[4px] bg-muted px-5 py-3 text-sm font-semibold text-foreground transition-all duration-500 ease-in-out hover:bg-background hover:bg-hover ",
"relative inline-flex h-full w-full items-center justify-center gap-[4px] bg-muted px-5 py-3 text-sm font-semibold text-foreground transition-all duration-150 ease-in-out hover:bg-background hover:bg-hover ",
!hasApiKey || !validApiKey || !hasStore
? " button-disable text-muted-foreground "
: ""
@ -93,7 +93,7 @@ export default function FlowToolbar({ flow }: ChatType): JSX.Element {
<div className="flex h-full w-full gap-1 rounded-sm text-medium-indigo transition-all">
{hasIO ? (
<IOView open={open} setOpen={setOpen} disable={!hasIO}>
<div className="relative inline-flex w-full items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-medium-indigo transition-all transition-all duration-500 ease-in-out ease-in-out hover:bg-hover">
<div className="relative inline-flex w-full items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-medium-indigo transition-all transition-all duration-150 ease-in-out ease-in-out hover:bg-hover">
<ForwardedIconComponent
name="Zap"
className={"message-button-icon h-5 w-5 transition-all"}
@ -103,7 +103,7 @@ export default function FlowToolbar({ flow }: ChatType): JSX.Element {
</IOView>
) : (
<div
className={`relative inline-flex w-full cursor-not-allowed items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-muted-foreground transition-all duration-500 ease-in-out ease-in-out`}
className={`relative inline-flex w-full cursor-not-allowed items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-muted-foreground transition-all duration-150 ease-in-out ease-in-out`}
>
<ForwardedIconComponent
name="Zap"
@ -123,7 +123,7 @@ export default function FlowToolbar({ flow }: ChatType): JSX.Element {
<ApiModal flow={currentFlow}>
<div
className={classNames(
"relative inline-flex w-full items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-foreground transition-all duration-500 ease-in-out hover:bg-hover"
"relative inline-flex w-full items-center justify-center gap-1 px-5 py-3 text-sm font-semibold text-foreground transition-all duration-150 ease-in-out hover:bg-hover"
)}
>
<ForwardedIconComponent

View file

@ -0,0 +1,16 @@
const AstraSVG = (props) => (
<svg width="96" height="96" viewBox="12 33 72 29" fill="none" xmlns="http://www.w3.org/2000/svg" {...props}>
<g clip-path="url(#clip0_702_1449)">
{/* <rect width="96" height="96" rx="6" fill="white"/> */}
<path d="M38.0469 33H12V62.1892H38.0469L44.5902 57.1406V38.0485L38.0469 33ZM17.0478 38.0485H39.5424V57.1459H17.0478V38.0485Z" fill="black"/>
<path d="M82.0705 38.2605V33.3243H58.2546L51.788 38.2605V45.038L58.2546 49.9742H79.0107V56.9286H53.076V61.8648H77.5334L84 56.9286V49.9742L77.5334 45.038H56.7772V38.2605H82.0705Z" fill="black"/>
</g>
<defs>
<clipPath id="clip0_702_1449">
<rect width="96" height="96" fill="white"/>
</clipPath>
</defs>
</svg>
);
export default AstraSVG;

View file

@ -0,0 +1,12 @@
<svg width="96" height="96" viewBox="0 0 96 96" fill="none" xmlns="http://www.w3.org/2000/svg">
<g clip-path="url(#clip0_702_1449)">
<rect width="96" height="96" rx="6" fill="white"/>
<path d="M38.0469 33H12V62.1892H38.0469L44.5902 57.1406V38.0485L38.0469 33ZM17.0478 38.0485H39.5424V57.1459H17.0478V38.0485Z" fill="black"/>
<path d="M82.0705 38.2605V33.3243H58.2546L51.788 38.2605V45.038L58.2546 49.9742H79.0107V56.9286H53.076V61.8648H77.5334L84 56.9286V49.9742L77.5334 45.038H56.7772V38.2605H82.0705Z" fill="black"/>
</g>
<defs>
<clipPath id="clip0_702_1449">
<rect width="96" height="96" fill="white"/>
</clipPath>
</defs>
</svg>

After

Width:  |  Height:  |  Size: 645 B

View file

@ -0,0 +1,9 @@
import React, { forwardRef } from "react";
import AstraSVG from "./AstraDB";
export const AstraDBIcon = forwardRef<
SVGSVGElement,
React.PropsWithChildren<{}>
>((props, ref) => {
return <AstraSVG ref={ref} {...props} />;
});

View file

@ -138,6 +138,7 @@ import { FaApple, FaGithub } from "react-icons/fa";
import { AWSIcon } from "../icons/AWS";
import { AirbyteIcon } from "../icons/Airbyte";
import { AnthropicIcon } from "../icons/Anthropic";
import { AstraDBIcon } from "../icons/AstraDB";
import { AzureIcon } from "../icons/Azure";
import { BingIcon } from "../icons/Bing";
import { BotMessageSquareIcon } from "../icons/BotMessageSquare";
@ -311,6 +312,7 @@ export const nodeIconsLucide: iconsType = {
Amazon: AWSIcon,
Anthropic: AnthropicIcon,
ChatAnthropic: AnthropicIcon,
AstraDB: AstraDBIcon,
BingSearchAPIWrapper: BingIcon,
BingSearchRun: BingIcon,
Cohere: CohereIcon,

View file

@ -1,28 +1,28 @@
import { test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(16000);
test.setTimeout(140000);
// await page.waitForTimeout(16000);
// test.setTimeout(140000);
});
test.describe("Auto_login tests", () => {
test("auto_login sign in", async ({ page }) => {
await page.goto("http:localhost:3000/");
await page.goto("/");
await page.locator('//*[@id="new-project-btn"]').click();
});
test("auto_login block_admin", async ({ page }) => {
await page.goto("http:localhost:3000/");
await page.goto("/");
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(5000);
await page.goto("http:localhost:3000/login");
await page.goto("/login");
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(5000);
await page.goto("http:localhost:3000/admin");
await page.goto("/admin");
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(5000);
await page.goto("http:localhost:3000/admin/login");
await page.goto("/admin/login");
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(5000);
});

View file

@ -1,11 +1,20 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
<<<<<<< HEAD
await page.waitForTimeout(1000);
test.setTimeout(120000);
});
test("CodeAreaModalComponent", async ({ page }) => {
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
// await page.waitForTimeout(2000);
// test.setTimeout(120000);
});
test("CodeAreaModalComponent", async ({ page }) => {
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,13 +1,13 @@
import { expect, test } from "@playwright/test";
import { readFileSync } from "fs";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(3000);
test.setTimeout(120000);
// await page.waitForTimeout(3000);
// test.setTimeout(120000);
});
test.describe("drag and drop test", () => {
/// <reference lib="dom"/>
test("drop collection", async ({ page }) => {
await page.goto("http:localhost:3000/");
await page.goto("/");
await page.locator("span").filter({ hasText: "My Collection" }).isVisible();
// Read your file into a buffer.
const jsonContent = readFileSync(

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(4000);
test.setTimeout(120000);
// await page.waitForTimeout(4000);
// test.setTimeout(120000);
});
test("dropDownComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);
@ -195,4 +200,66 @@ test("dropDownComponent", async ({ page }) => {
if (value !== "ai21.j2-ultra-v1") {
expect(false).toBeTruthy();
}
await page.getByTestId("code-button-modal").click();
await page
.locator("#CodeEditor div")
.filter({ hasText: "from typing import" })
.nth(1)
.click();
await page.locator("textarea").press("Control+a");
const emptyOptionsCode = `from typing import Optional
from langchain.llms.base import BaseLLM
from langchain_community.llms.bedrock import Bedrock
from langflow.interface.custom.custom_component import CustomComponent
class AmazonBedrockComponent(CustomComponent):
display_name: str = "Amazon Bedrock"
description: str = "LLM model from Amazon Bedrock."
icon = "Amazon"
def build_config(self):
return {
"model_id": {
"display_name": "Model Id",
"options": [],
},
"credentials_profile_name": {"display_name": "Credentials Profile Name"},
"streaming": {"display_name": "Streaming", "field_type": "bool"},
"endpoint_url": {"display_name": "Endpoint URL"},
"region_name": {"display_name": "Region Name"},
"model_kwargs": {"display_name": "Model Kwargs"},
"cache": {"display_name": "Cache"},
"code": {"advanced": True},
}
def build(
self,
model_id: str = "anthropic.claude-instant-v1",
credentials_profile_name: Optional[str] = None,
region_name: Optional[str] = None,
model_kwargs: Optional[dict] = None,
endpoint_url: Optional[str] = None,
streaming: bool = False,
cache: Optional[bool] = None,
) -> BaseLLM:
try:
output = Bedrock(
credentials_profile_name=credentials_profile_name,
model_id=model_id,
region_name=region_name,
model_kwargs=model_kwargs,
endpoint_url=endpoint_url,
streaming=streaming,
cache=cache,
) # type: ignore
except Exception as e:
raise ValueError("Could not connect to AmazonBedrock API.") from e
return output
`;
await page.locator("textarea").fill(emptyOptionsCode);
await page.getByRole("button", { name: "Check & Save" }).click();
await page.getByText("No parameters are available for display.").isVisible();
});

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(5000);
test.setTimeout(120000);
// await page.waitForTimeout(5000);
// test.setTimeout(120000);
});
test("FloatComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,18 +1,23 @@
import { Page, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(6000);
test.setTimeout(120000);
// await page.waitForTimeout(6000);
// test.setTimeout(120000);
});
test.describe("Flow Page tests", () => {
async function goToFlowPage(page: Page) {
await page.goto("http://localhost:3000/");
await page.goto("/");
await page.getByRole("button", { name: "New Project" }).click();
}
test("save", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,13 +1,13 @@
import { expect, test } from "@playwright/test";
import { readFileSync } from "fs";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(7000);
test.setTimeout(120000);
// await page.waitForTimeout(7000);
// test.setTimeout(120000);
});
test.describe("group node test", () => {
/// <reference lib="dom"/>
test("group and ungroup updating values", async ({ page }) => {
await page.goto("http:localhost:3000/");
await page.goto("/");
await page.locator('//*[@id="new-project-btn"]').click();
await page.getByTestId("blank-flow").click();

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(8000);
test.setTimeout(120000);
// await page.waitForTimeout(8000);
// test.setTimeout(120000);
});
test("InputComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);
@ -120,7 +125,7 @@ test("InputComponent", async ({ page }) => {
await page.getByTestId("input-collection_name-edit").click();
await page
.getByTestId("input-collection_name-edit")
.fill("NEW_collection_name_test_123123123!@#$&*(&%$@");
.fill("NEW_collection_name_test_123123123!@#$&*(&%$@ÇÇÇÀõe");
await page.locator('//*[@id="saveChangesBtn"]').click();
@ -143,7 +148,7 @@ test("InputComponent", async ({ page }) => {
let value = await page.getByTestId("input-collection_name").inputValue();
if (value != "NEW_collection_name_test_123123123!@#$&*(&%$@") {
if (value != "NEW_collection_name_test_123123123!@#$&*(&%$@ÇÇÇÀõe") {
expect(false).toBeTruthy();
}
}

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(9000);
test.setTimeout(120000);
// await page.waitForTimeout(9000);
// test.setTimeout(120000);
});
test("IntComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(20000);
test.setTimeout(120000);
// await page.waitForTimeout(20000);
// test.setTimeout(120000);
});
test("KeypairListComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,8 +1,8 @@
import { expect, test } from "@playwright/test";
import uaParser from "ua-parser-js";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(11000);
test.setTimeout(120000);
// await page.waitForTimeout(11000);
// test.setTimeout(120000);
});
test("LangflowShortcuts", async ({ page }) => {
const getUA = await page.evaluate(() => navigator.userAgent);
@ -13,7 +13,7 @@ test("LangflowShortcuts", async ({ page }) => {
control = "Meta";
}
await page.goto("http://localhost:3000/");
await page.goto("/");
await page.waitForTimeout(1000);
await page.locator('//*[@id="new-project-btn"]').click();

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(12000);
test.setTimeout(120000);
// await page.waitForTimeout(12000);
// test.setTimeout(120000);
});
test("NestedComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(13000);
test.setTimeout(120000);
// await page.waitForTimeout(13000);
// test.setTimeout(120000);
});
test("PromptTemplateComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -1,8 +1,8 @@
import { Page, expect, test } from "@playwright/test";
import { readFileSync } from "fs";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(14000);
test.setTimeout(120000);
// await page.waitForTimeout(14000);
// test.setTimeout(120000);
});
test.describe("save component tests", () => {
async function saveComponent(page: Page, pattern: RegExp, n: number) {
@ -14,7 +14,7 @@ test.describe("save component tests", () => {
/// <reference lib="dom"/>
test("save group component tests", async ({ page }) => {
await page.goto("http:localhost:3000/");
await page.goto("/");
await page.locator('//*[@id="new-project-btn"]').click();
await page.getByTestId("blank-flow").click();

View file

@ -1,11 +1,16 @@
import { expect, test } from "@playwright/test";
test.beforeEach(async ({ page }) => {
await page.waitForTimeout(15000);
test.setTimeout(120000);
// await page.waitForTimeout(15000);
// test.setTimeout(120000);
});
test("ToggleComponent", async ({ page }) => {
<<<<<<< HEAD
await page.goto("http://localhost:3000/");
await page.waitForTimeout(1000);
=======
await page.goto("/");
await page.waitForTimeout(2000);
>>>>>>> zustand/io/migration
await page.locator('//*[@id="new-project-btn"]').click();
await page.waitForTimeout(1000);

View file

@ -0,0 +1,25 @@
// tests/globalTeardown.ts
import fs from "fs";
import path from "path";
export default async () => {
try {
console.log("Removing the temp database");
// Check if the file exists in the path
// this file is in src/frontend/tests/globalTeardown.ts
// temp is in src/frontend/temp
const tempDbPath = path.join(__dirname, "..", "temp");
console.log("tempDbPath", tempDbPath);
// Remove the temp database
fs.rmSync(tempDbPath);
// Check if the file is removed
if (!fs.existsSync(tempDbPath)) {
console.log("Successfully removed the temp database");
} else {
console.error("Error while removing the temp database");
}
} catch (error) {
console.error("Error while removing the temp database:", error);
}
};