docs: update docs icons (#12465)

### What problem does this PR solve?

Update icons for docs.
Trailing spaces are auto truncated by the editor, does not affect real
content.

### Type of change

- [x] Documentation Update
This commit is contained in:
Jimmy Ben Klieve
2026-01-07 10:00:09 +08:00
committed by GitHub
parent ca9645f39b
commit 6814ace1aa
88 changed files with 922 additions and 661 deletions

View File

@ -4,5 +4,8 @@
"link": {
"type": "generated-index",
"description": "A complete reference for RAGFlow's agent components."
},
"customProps": {
"categoryIcon": "RagAiAgent"
}
}

View File

@ -1,6 +1,9 @@
---
sidebar_position: 2
slug: /agent_component
sidebar_custom_props: {
categoryIcon: RagAiAgent
}
---
# Agent component
@ -16,7 +19,7 @@ An **Agent** component fine-tunes the LLM and sets its prompt. From v0.20.5 onwa
## Scenarios
An **Agent** component is essential when you need the LLM to assist with summarizing, translating, or controlling various tasks.
An **Agent** component is essential when you need the LLM to assist with summarizing, translating, or controlling various tasks.
## Prerequisites
@ -28,13 +31,13 @@ An **Agent** component is essential when you need the LLM to assist with summari
## Quickstart
### 1. Click on an **Agent** component to show its configuration panel
### 1. Click on an **Agent** component to show its configuration panel
The corresponding configuration panel appears to the right of the canvas. Use this panel to define and fine-tune the **Agent** component's behavior.
### 2. Select your model
Click **Model**, and select a chat model from the dropdown menu.
Click **Model**, and select a chat model from the dropdown menu.
:::tip NOTE
If no model appears, check if your have added a chat model on the **Model providers** page.
@ -55,7 +58,7 @@ In this quickstart, we assume your **Agent** component is used standalone (witho
### 5. Skip Tools and Agent
The **+ Add tools** and **+ Add agent** sections are used *only* when you need to configure your **Agent** component as a planner (with tools or sub-Agents beneath). In this quickstart, we assume your **Agent** component is used standalone (without tools or sub-Agents beneath).
The **+ Add tools** and **+ Add agent** sections are used *only* when you need to configure your **Agent** component as a planner (with tools or sub-Agents beneath). In this quickstart, we assume your **Agent** component is used standalone (without tools or sub-Agents beneath).
### 6. Choose the next component
@ -71,7 +74,7 @@ In this section, we assume your **Agent** will be configured as a planner, with
![](https://raw.githubusercontent.com/infiniflow/ragflow-docs/main/images/mcp_page.jpg)
### 2. Configure your Tavily MCP server
### 2. Configure your Tavily MCP server
Update your MCP server's name, URL (including the API key), server type, and other necessary settings. When configured correctly, the available tools will be displayed.
@ -110,7 +113,7 @@ On the canvas, click the newly-populated Tavily server to view and select its av
Click the dropdown menu of **Model** to show the model configuration window.
- **Model**: The chat model to use.
- **Model**: The chat model to use.
- Ensure you set the chat model correctly on the **Model providers** page.
- You can use different models for different components to increase flexibility or improve overall performance.
- **Creativity**: A shortcut to **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty** settings, indicating the freedom level of the model. From **Improvise**, **Precise**, to **Balance**, each preset configuration corresponds to a unique combination of **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty**.
@ -118,21 +121,21 @@ Click the dropdown menu of **Model** to show the model configuration window.
- **Improvise**: Produces more creative responses.
- **Precise**: (Default) Produces more conservative responses.
- **Balance**: A middle ground between **Improvise** and **Precise**.
- **Temperature**: The randomness level of the model's output.
- **Temperature**: The randomness level of the model's output.
Defaults to 0.1.
- Lower values lead to more deterministic and predictable outputs.
- Higher values lead to more creative and varied outputs.
- A temperature of zero results in the same output for the same prompt.
- **Top P**: Nucleus sampling.
- **Top P**: Nucleus sampling.
- Reduces the likelihood of generating repetitive or unnatural text by setting a threshold *P* and restricting the sampling to tokens with a cumulative probability exceeding *P*.
- Defaults to 0.3.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- A higher **presence penalty** value results in the model being more likely to generate tokens not yet been included in the generated text.
- Defaults to 0.4.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- A higher **frequency penalty** value results in the model being more conservative in its use of repeated tokens.
- Defaults to 0.7.
- **Max tokens**:
- **Max tokens**:
This sets the maximum length of the model's output, measured in the number of tokens (words or pieces of words). It is disabled by default, allowing the model to determine the number of tokens in its responses.
:::tip NOTE
@ -142,7 +145,7 @@ Click the dropdown menu of **Model** to show the model configuration window.
### System prompt
Typically, you use the system prompt to describe the task for the LLM, specify how it should respond, and outline other miscellaneous requirements. We do not plan to elaborate on this topic, as it can be as extensive as prompt engineering. However, please be aware that the system prompt is often used in conjunction with keys (variables), which serve as various data inputs for the LLM.
Typically, you use the system prompt to describe the task for the LLM, specify how it should respond, and outline other miscellaneous requirements. We do not plan to elaborate on this topic, as it can be as extensive as prompt engineering. However, please be aware that the system prompt is often used in conjunction with keys (variables), which serve as various data inputs for the LLM.
An **Agent** component relies on keys (variables) to specify its data inputs. Its immediate upstream component is *not* necessarily its data input, and the arrows in the workflow indicate *only* the processing sequence. Keys in a **Agent** component are used in conjunction with the system prompt to specify data inputs for the LLM. Use a forward slash `/` or the **(x)** button to show the keys to use.
@ -190,11 +193,11 @@ From v0.20.5 onwards, four framework-level prompt blocks are available in the **
The user-defined prompt. Defaults to `sys.query`, the user query. As a general rule, when using the **Agent** component as a standalone module (not as a planner), you usually need to specify the corresponding **Retrieval** components output variable (`formalized_content`) here as part of the input to the LLM.
### Tools
### Tools
You can use an **Agent** component as a collaborator that reasons and reflects with the aid of other tools; for instance, **Retrieval** can serve as one such tool for an **Agent**.
### Agent
### Agent
You use an **Agent** component as a collaborator that reasons and reflects with the aid of subagents or other tools, forming a multi-agent system.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 5
slug: /await_response
sidebar_custom_props: {
categoryIcon: LucideMessageSquareDot
}
---
# Await response component
@ -23,7 +26,7 @@ Whether to show the message defined in the **Message** field.
### Message
The static message to send out.
The static message to send out.
Click **+ Add message** to add message options. When multiple messages are supplied, the **Message** component randomly selects one to send.
@ -31,9 +34,9 @@ Click **+ Add message** to add message options. When multiple messages are suppl
You can define global variables within the **Await response** component, which can be either mandatory or optional. Once set, users will need to provide values for these variables when engaging with the agent. Click **+** to add a global variable, each with the following attributes:
- **Name**: _Required_
A descriptive name providing additional details about the variable.
- **Type**: _Required_
- **Name**: _Required_
A descriptive name providing additional details about the variable.
- **Type**: _Required_
The type of the variable:
- **Single-line text**: Accepts a single line of text without line breaks.
- **Paragraph text**: Accepts multiple lines of text, including line breaks.
@ -41,7 +44,7 @@ You can define global variables within the **Await response** component, which c
- **file upload**: Requires the user to upload one or multiple files.
- **Number**: Accepts a number as input.
- **Boolean**: Requires the user to toggle between on and off.
- **Key**: _Required_
- **Key**: _Required_
The unique variable name.
- **Optional**: A toggle indicating whether the variable is optional.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 1
slug: /begin_component
sidebar_custom_props: {
categoryIcon: LucideHome
}
---
# Begin component
@ -36,9 +39,9 @@ An agent in conversational mode begins with an opening greeting. It is the agent
You can define global variables within the **Begin** component, which can be either mandatory or optional. Once set, users will need to provide values for these variables when engaging with the agent. Click **+ Add variable** to add a global variable, each with the following attributes:
- **Name**: _Required_
A descriptive name providing additional details about the variable.
- **Type**: _Required_
- **Name**: _Required_
A descriptive name providing additional details about the variable.
- **Type**: _Required_
The type of the variable:
- **Single-line text**: Accepts a single line of text without line breaks.
- **Paragraph text**: Accepts multiple lines of text, including line breaks.
@ -46,7 +49,7 @@ You can define global variables within the **Begin** component, which can be eit
- **file upload**: Requires the user to upload one or multiple files.
- **Number**: Accepts a number as input.
- **Boolean**: Requires the user to toggle between on and off.
- **Key**: _Required_
- **Key**: _Required_
The unique variable name.
- **Optional**: A toggle indicating whether the variable is optional.

View File

@ -1,11 +1,14 @@
---
sidebar_position: 8
slug: /categorize_component
sidebar_custom_props: {
categoryIcon: LucideSwatchBook
}
---
# Categorize component
A component that classifies user inputs and applies strategies accordingly.
A component that classifies user inputs and applies strategies accordingly.
---
@ -23,7 +26,7 @@ A **Categorize** component is essential when you need the LLM to help you identi
Select the source for categorization.
The **Categorize** component relies on query variables to specify its data inputs (queries). All global variables defined before the **Categorize** component are available in the dropdown list.
The **Categorize** component relies on query variables to specify its data inputs (queries). All global variables defined before the **Categorize** component are available in the dropdown list.
### Input
@ -31,7 +34,7 @@ The **Categorize** component relies on query variables to specify its data input
The **Categorize** component relies on input variables to specify its data inputs (queries). Click **+ Add variable** in the **Input** section to add the desired input variables. There are two types of input variables: **Reference** and **Text**.
- **Reference**: Uses a component's output or a user input as the data source. You are required to select from the dropdown menu:
- A component ID under **Component Output**, or
- A component ID under **Component Output**, or
- A global variable under **Begin input**, which is defined in the **Begin** component.
- **Text**: Uses fixed text as the query. You are required to enter static text.
@ -39,29 +42,29 @@ The **Categorize** component relies on input variables to specify its data input
Click the dropdown menu of **Model** to show the model configuration window.
- **Model**: The chat model to use.
- **Model**: The chat model to use.
- Ensure you set the chat model correctly on the **Model providers** page.
- You can use different models for different components to increase flexibility or improve overall performance.
- **Creativity**: A shortcut to **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty** settings, indicating the freedom level of the model. From **Improvise**, **Precise**, to **Balance**, each preset configuration corresponds to a unique combination of **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty**.
This parameter has three options:
This parameter has three options:
- **Improvise**: Produces more creative responses.
- **Precise**: (Default) Produces more conservative responses.
- **Balance**: A middle ground between **Improvise** and **Precise**.
- **Temperature**: The randomness level of the model's output.
Defaults to 0.1.
- **Temperature**: The randomness level of the model's output.
Defaults to 0.1.
- Lower values lead to more deterministic and predictable outputs.
- Higher values lead to more creative and varied outputs.
- A temperature of zero results in the same output for the same prompt.
- **Top P**: Nucleus sampling.
- **Top P**: Nucleus sampling.
- Reduces the likelihood of generating repetitive or unnatural text by setting a threshold *P* and restricting the sampling to tokens with a cumulative probability exceeding *P*.
- Defaults to 0.3.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- A higher **presence penalty** value results in the model being more likely to generate tokens not yet been included in the generated text.
- Defaults to 0.4.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- A higher **frequency penalty** value results in the model being more conservative in its use of repeated tokens.
- Defaults to 0.7.
- **Max tokens**:
- **Max tokens**:
This sets the maximum length of the model's output, measured in the number of tokens (words or pieces of words). It is disabled by default, allowing the model to determine the number of tokens in its responses.
:::tip NOTE
@ -81,7 +84,7 @@ This feature is used for multi-turn dialogue *only*. If your **Categorize** comp
### Category name
A **Categorize** component must have at least two categories. This field sets the name of the category. Click **+ Add Item** to include the intended categories.
A **Categorize** component must have at least two categories. This field sets the name of the category. Click **+ Add Item** to include the intended categories.
:::tip NOTE
You will notice that the category name is auto-populated. No worries. Each category is assigned a random name upon creation. Feel free to change it to a name that is understandable to the LLM.
@ -89,7 +92,7 @@ You will notice that the category name is auto-populated. No worries. Each categ
#### Description
Description of this category.
Description of this category.
You can input criteria, situation, or information that may help the LLM determine which inputs belong in this category.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 31
slug: /chunker_title_component
sidebar_custom_props: {
categoryIcon: LucideBlocks
}
---
# Title chunker component
@ -23,7 +26,7 @@ Placing a **Title chunker** after a **Token chunker** is invalid and will cause
### Hierarchy
Specifies the heading level to define chunk boundaries:
Specifies the heading level to define chunk boundaries:
- H1
- H2

View File

@ -1,6 +1,9 @@
---
sidebar_position: 32
slug: /chunker_token_component
sidebar_custom_props: {
categoryIcon: LucideBlocks
}
---
# Token chunker component

View File

@ -1,6 +1,9 @@
---
sidebar_position: 13
slug: /code_component
sidebar_custom_props: {
categoryIcon: LucideCodeXml
}
---
# Code component
@ -33,7 +36,7 @@ If your RAGFlow Sandbox is not working, please be sure to consult the [Troublesh
### 3. (Optional) Install necessary dependencies
If you need to import your own Python or JavaScript packages into Sandbox, please follow the commands provided in the [How to import my own Python or JavaScript packages into Sandbox?](#how-to-import-my-own-python-or-javascript-packages-into-sandbox) section to install the additional dependencies.
If you need to import your own Python or JavaScript packages into Sandbox, please follow the commands provided in the [How to import my own Python or JavaScript packages into Sandbox?](#how-to-import-my-own-python-or-javascript-packages-into-sandbox) section to install the additional dependencies.
### 4. Enable Sandbox-specific settings in RAGFlow
@ -43,11 +46,11 @@ Ensure all Sandbox-specific settings are enabled in **ragflow/docker/.env**.
Any changes to the configuration or environment *require* a full service restart to take effect.
## Configurations
## Configurations
### Input
You can specify multiple input sources for the **Code** component. Click **+ Add variable** in the **Input variables** section to include the desired input variables.
You can specify multiple input sources for the **Code** component. Click **+ Add variable** in the **Input variables** section to include the desired input variables.
### Code
@ -59,7 +62,7 @@ If your code implementation includes defined variables, whether input or output
#### A Python code example
```Python
```Python
def main(arg1: str, arg2: str) -> dict:
return {
"result": arg1 + arg2,
@ -102,7 +105,7 @@ The defined output variable(s) will be auto-populated here.
### `HTTPConnectionPool(host='sandbox-executor-manager', port=9385): Read timed out.`
**Root cause**
**Root cause**
- You did not properly install gVisor and `runsc` was not recognized as a valid Docker runtime.
- You did not pull the required base images for the runners and no runner was started.
@ -144,11 +147,11 @@ docker build -t sandbox-executor-manager:latest ./sandbox/executor_manager
### `HTTPConnectionPool(host='none', port=9385): Max retries exceeded.`
**Root cause**
**Root cause**
`sandbox-executor-manager` is not mapped in `/etc/hosts`.
**Solution**
**Solution**
Add a new entry to `/etc/hosts`:
@ -156,11 +159,11 @@ Add a new entry to `/etc/hosts`:
### `Container pool is busy`
**Root cause**
**Root cause**
All runners are currently in use, executing tasks.
All runners are currently in use, executing tasks.
**Solution**
**Solution**
Please try again shortly or increase the pool size in the configuration to improve availability and reduce waiting times.
@ -205,7 +208,7 @@ To import your JavaScript packages, navigate to `sandbox_base_image/nodejs` and
(ragflow) ➜ ragflow/sandbox main ✓ cd sandbox_base_image/nodejs
(ragflow) ➜ ragflow/sandbox/sandbox_base_image/nodejs main ✓ npm install lodash
(ragflow) ➜ ragflow/sandbox/sandbox_base_image/nodejs main ✓ npm install lodash
(ragflow) ➜ ragflow/sandbox/sandbox_base_image/nodejs main ✓ cd ../.. # go back to sandbox root directory

View File

@ -1,6 +1,9 @@
---
sidebar_position: 25
slug: /execute_sql
sidebar_custom_props: {
categoryIcon: RagSql
}
---
# Execute SQL tool
@ -9,7 +12,7 @@ A tool that execute SQL queries on a specified relational database.
---
The **Execute SQL** tool enables you to connect to a relational database and run SQL queries, whether entered directly or generated by the systems Text2SQL capability via an **Agent** component.
The **Execute SQL** tool enables you to connect to a relational database and run SQL queries, whether entered directly or generated by the systems Text2SQL capability via an **Agent** component.
## Prerequisites

View File

@ -1,11 +1,14 @@
---
sidebar_position: 30
slug: /http_request_component
sidebar_custom_props: {
categoryIcon: RagHTTP
}
---
# HTTP request component
A component that calls remote services.
A component that calls remote services.
---

View File

@ -1,6 +1,9 @@
---
sidebar_position: 40
slug: /indexer_component
sidebar_custom_props: {
categoryIcon: LucideListPlus
}
---
# Indexer component

View File

@ -1,6 +1,9 @@
---
sidebar_position: 7
slug: /iteration_component
sidebar_custom_props: {
categoryIcon: LucideRepeat2
}
---
# Iteration component
@ -9,12 +12,12 @@ A component that splits text input into text segments and iterates a predefined
---
An **Interaction** component can divide text input into text segments and apply its built-in component workflow to each segment.
An **Interaction** component can divide text input into text segments and apply its built-in component workflow to each segment.
## Scenario
An **Iteration** component is essential when a workflow loop is required and the loop count is *not* fixed but depends on number of segments created from the output of specific agent components.
An **Iteration** component is essential when a workflow loop is required and the loop count is *not* fixed but depends on number of segments created from the output of specific agent components.
- If, for instance, you plan to feed several paragraphs into an LLM for content generation, each with its own focus, and feeding them to the LLM all at once could create confusion or contradictions, then you can use an **Iteration** component, which encapsulates a **Generate** component, to repeat the content generation process for each paragraph.
- Another example: If you wish to use the LLM to translate a lengthy paper into a target language without exceeding its token limit, consider using an **Iteration** component, which encapsulates a **Generate** component, to break the paper into smaller pieces and repeat the translation process for each one.
@ -29,12 +32,12 @@ Each **Iteration** component includes an internal **IterationItem** component. T
The **IterationItem** component is visible *only* to the components encapsulated by the current **Iteration** components.
:::
### Build an internal workflow
### Build an internal workflow
You are allowed to pull other components into the **Iteration** component to build an internal workflow, and these "added internal components" are no longer visible to components outside of the current **Iteration** component.
:::danger IMPORTANT
To reference the created text segments from an added internal component, simply add a **Reference** variable that equals **IterationItem** within the **Input** section of that internal component. There is no need to reference the corresponding external component, as the **IterationItem** component manages the loop of the workflow for all created text segments.
To reference the created text segments from an added internal component, simply add a **Reference** variable that equals **IterationItem** within the **Input** section of that internal component. There is no need to reference the corresponding external component, as the **IterationItem** component manages the loop of the workflow for all created text segments.
:::
:::tip NOTE
@ -48,7 +51,7 @@ An added internal component can reference an external component when necessary.
The **Iteration** component uses input variables to specify its data inputs, namely the texts to be segmented. You are allowed to specify multiple input sources for the **Iteration** component. Click **+ Add variable** in the **Input** section to include the desired input variables. There are two types of input variables: **Reference** and **Text**.
- **Reference**: Uses a component's output or a user input as the data source. You are required to select from the dropdown menu:
- A component ID under **Component Output**, or
- A component ID under **Component Output**, or
- A global variable under **Begin input**, which is defined in the **Begin** component.
- **Text**: Uses fixed text as the query. You are required to enter static text.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 4
slug: /message_component
sidebar_custom_props: {
categoryIcon: LucideMessageSquareReply
}
---
# Message component

View File

@ -1,6 +1,9 @@
---
sidebar_position: 30
slug: /parser_component
sidebar_custom_props: {
categoryIcon: LucideFilePlay
}
---
# Parser component
@ -54,12 +57,12 @@ Starting from v0.22.0, RAGFlow includes MinerU (≥ 2.6.3) as an optional PDF p
- `"vlm-mlx-engine"`
- `"vlm-vllm-async-engine"`
- `"vlm-lmdeploy-engine"`.
- `MINERU_SERVER_URL`: (optional) The downstream vLLM HTTP server (e.g., `http://vllm-host:30000`). Applicable when `MINERU_BACKEND` is set to `"vlm-http-client"`.
- `MINERU_SERVER_URL`: (optional) The downstream vLLM HTTP server (e.g., `http://vllm-host:30000`). Applicable when `MINERU_BACKEND` is set to `"vlm-http-client"`.
- `MINERU_OUTPUT_DIR`: (optional) The local directory for holding the outputs of the MinerU API service (zip/JSON) before ingestion.
- `MINERU_DELETE_OUTPUT`: Whether to delete temporary output when a temporary directory is used:
- `1`: Delete.
- `0`: Retain.
3. In the web UI, navigate to your dataset's **Configuration** page and find the **Ingestion pipeline** section:
3. In the web UI, navigate to your dataset's **Configuration** page and find the **Ingestion pipeline** section:
- If you decide to use a chunking method from the **Built-in** dropdown, ensure it supports PDF parsing, then select **MinerU** from the **PDF parser** dropdown.
- If you use a custom ingestion pipeline instead, select **MinerU** in the **PDF parser** section of the **Parser** component.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 3
slug: /retrieval_component
sidebar_custom_props: {
categoryIcon: LucideFolderSearch
}
---
# Retrieval component
@ -21,13 +24,13 @@ Ensure you [have properly configured your target dataset(s)](../../dataset/confi
## Quickstart
### 1. Click on a **Retrieval** component to show its configuration panel
### 1. Click on a **Retrieval** component to show its configuration panel
The corresponding configuration panel appears to the right of the canvas. Use this panel to define and fine-tune the **Retrieval** component's search behavior.
### 2. Input query variable(s)
The **Retrieval** component depends on query variables to specify its queries.
The **Retrieval** component depends on query variables to specify its queries.
:::caution IMPORTANT
- If you use the **Retrieval** component as a standalone workflow module, input query variables in the **Input Variables** text box.
@ -74,7 +77,7 @@ Select the query source for retrieval. Defaults to `sys.query`, which is the def
The **Retrieval** component relies on query variables to specify its queries. All global variables defined before the **Retrieval** component can also be used as queries. Use the `(x)` button or type `/` to show all the available query variables.
### Knowledge bases
### Knowledge bases
Select the dataset(s) to retrieve data from.
@ -110,7 +113,7 @@ Using a rerank model will *significantly* increase the system's response time.
### Empty response
- Set this as a response if no results are retrieved from the dataset(s) for your query, or
- Set this as a response if no results are retrieved from the dataset(s) for your query, or
- Leave this field blank to allow the chat model to improvise when nothing is found.
:::caution WARNING

View File

@ -1,11 +1,14 @@
---
sidebar_position: 6
slug: /switch_component
sidebar_custom_props: {
categoryIcon: LucideSplit
}
---
# Switch component
A component that evaluates whether specified conditions are met and directs the follow of execution accordingly.
A component that evaluates whether specified conditions are met and directs the follow of execution accordingly.
---
@ -13,7 +16,7 @@ A **Switch** component evaluates conditions based on the output of specific comp
## Scenarios
A **Switch** component is essential for condition-based direction of execution flow. While it shares similarities with the [Categorize](./categorize.mdx) component, which is also used in multi-pronged strategies, the key distinction lies in their approach: the evaluation of the **Switch** component is rule-based, whereas the **Categorize** component involves AI and uses an LLM for decision-making.
A **Switch** component is essential for condition-based direction of execution flow. While it shares similarities with the [Categorize](./categorize.mdx) component, which is also used in multi-pronged strategies, the key distinction lies in their approach: the evaluation of the **Switch** component is rule-based, whereas the **Categorize** component involves AI and uses an LLM for decision-making.
## Configurations
@ -39,12 +42,12 @@ When you have added multiple conditions for a specific case, a **Logical operato
- Greater equal
- Less than
- Less equal
- Contains
- Not contains
- Contains
- Not contains
- Starts with
- Ends with
- Is empty
- Not empty
- **Value**: A single value, which can be an integer, float, or string.
- **Value**: A single value, which can be an integer, float, or string.
- Delimiters, multiple values, or expressions are *not* supported.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 15
slug: /text_processing
sidebar_custom_props: {
categoryIcon: LucideType
}
---
# Text processing component
@ -24,7 +27,7 @@ Appears only when you select **Split** as method.
The variable to be split. Type `/` to quickly insert variables.
### Script
### Script
Template for the merge. Appears only when you select **Merge** as method. Type `/` to quickly insert variables.

View File

@ -1,6 +1,9 @@
---
sidebar_position: 37
slug: /transformer_component
sidebar_custom_props: {
categoryIcon: LucideFileStack
}
---
# Transformer component
@ -13,7 +16,7 @@ A **Transformer** component indexes chunks and configures their storage formats
## Scenario
A **Transformer** component is essential when you need the LLM to extract new information, such as keywords, questions, metadata, and summaries, from the original chunks.
A **Transformer** component is essential when you need the LLM to extract new information, such as keywords, questions, metadata, and summaries, from the original chunks.
## Configurations
@ -21,29 +24,29 @@ A **Transformer** component is essential when you need the LLM to extract new in
Click the dropdown menu of **Model** to show the model configuration window.
- **Model**: The chat model to use.
- **Model**: The chat model to use.
- Ensure you set the chat model correctly on the **Model providers** page.
- You can use different models for different components to increase flexibility or improve overall performance.
- **Creativity**: A shortcut to **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty** settings, indicating the freedom level of the model. From **Improvise**, **Precise**, to **Balance**, each preset configuration corresponds to a unique combination of **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty**.
- **Creativity**: A shortcut to **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty** settings, indicating the freedom level of the model. From **Improvise**, **Precise**, to **Balance**, each preset configuration corresponds to a unique combination of **Temperature**, **Top P**, **Presence penalty**, and **Frequency penalty**.
This parameter has three options:
- **Improvise**: Produces more creative responses.
- **Precise**: (Default) Produces more conservative responses.
- **Balance**: A middle ground between **Improvise** and **Precise**.
- **Temperature**: The randomness level of the model's output.
- **Temperature**: The randomness level of the model's output.
Defaults to 0.1.
- Lower values lead to more deterministic and predictable outputs.
- Higher values lead to more creative and varied outputs.
- A temperature of zero results in the same output for the same prompt.
- **Top P**: Nucleus sampling.
- **Top P**: Nucleus sampling.
- Reduces the likelihood of generating repetitive or unnatural text by setting a threshold *P* and restricting the sampling to tokens with a cumulative probability exceeding *P*.
- Defaults to 0.3.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- **Presence penalty**: Encourages the model to include a more diverse range of tokens in the response.
- A higher **presence penalty** value results in the model being more likely to generate tokens not yet been included in the generated text.
- Defaults to 0.4.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- **Frequency penalty**: Discourages the model from repeating the same words or phrases too frequently in the generated text.
- A higher **frequency penalty** value results in the model being more conservative in its use of repeated tokens.
- Defaults to 0.7.
- **Max tokens**:
- **Max tokens**:
This sets the maximum length of the model's output, measured in the number of tokens (words or pieces of words). It is disabled by default, allowing the model to determine the number of tokens in its responses.
:::tip NOTE
@ -62,7 +65,7 @@ Select the type of output to be generated by the LLM:
### System prompt
Typically, you use the system prompt to describe the task for the LLM, specify how it should respond, and outline other miscellaneous requirements. We do not plan to elaborate on this topic, as it can be as extensive as prompt engineering.
Typically, you use the system prompt to describe the task for the LLM, specify how it should respond, and outline other miscellaneous requirements. We do not plan to elaborate on this topic, as it can be as extensive as prompt engineering.
:::tip NOTE
The system prompt here automatically updates to match your selected **Result destination**.