mirror of
https://github.com/langgenius/dify-docs.git
synced 2026-03-26 13:18:34 +07:00
Add content related to the human input node (#667)
* draft * revise based on hands-on testing * modify based on feedback * add zh and ja translation * Update tip for referencing text output variable Clarify the default behavior of the reasoning model output. * Add translation note Added a note about AI translation accuracy and referenced the English version for discrepancies. * Update human-input.mdx with translation note Add a note about AI translation accuracy and reference to the English version. * Apply suggestion from @Copilot Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * Update wording for clarity on model output display --------- Co-authored-by: Riskey <riskey47@dify.ai> Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
15
docs.json
15
docs.json
@@ -59,9 +59,9 @@
|
||||
"en/use-dify/nodes/answer",
|
||||
"en/use-dify/nodes/output",
|
||||
"en/use-dify/nodes/agent",
|
||||
"en/use-dify/nodes/tools",
|
||||
"en/use-dify/nodes/question-classifier",
|
||||
"en/use-dify/nodes/ifelse",
|
||||
"en/use-dify/nodes/human-input",
|
||||
"en/use-dify/nodes/iteration",
|
||||
"en/use-dify/nodes/loop",
|
||||
"en/use-dify/nodes/code",
|
||||
@@ -71,7 +71,8 @@
|
||||
"en/use-dify/nodes/variable-assigner",
|
||||
"en/use-dify/nodes/parameter-extractor",
|
||||
"en/use-dify/nodes/http-request",
|
||||
"en/use-dify/nodes/list-operator"
|
||||
"en/use-dify/nodes/list-operator",
|
||||
"en/use-dify/nodes/tools"
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -444,9 +445,9 @@
|
||||
"zh/use-dify/nodes/answer",
|
||||
"zh/use-dify/nodes/output",
|
||||
"zh/use-dify/nodes/agent",
|
||||
"zh/use-dify/nodes/tools",
|
||||
"zh/use-dify/nodes/question-classifier",
|
||||
"zh/use-dify/nodes/ifelse",
|
||||
"zh/use-dify/nodes/human-input",
|
||||
"zh/use-dify/nodes/iteration",
|
||||
"zh/use-dify/nodes/loop",
|
||||
"zh/use-dify/nodes/code",
|
||||
@@ -456,7 +457,8 @@
|
||||
"zh/use-dify/nodes/variable-assigner",
|
||||
"zh/use-dify/nodes/parameter-extractor",
|
||||
"zh/use-dify/nodes/http-request",
|
||||
"zh/use-dify/nodes/list-operator"
|
||||
"zh/use-dify/nodes/list-operator",
|
||||
"zh/use-dify/nodes/tools"
|
||||
]
|
||||
},
|
||||
{
|
||||
@@ -829,9 +831,9 @@
|
||||
"ja/use-dify/nodes/answer",
|
||||
"ja/use-dify/nodes/output",
|
||||
"ja/use-dify/nodes/agent",
|
||||
"ja/use-dify/nodes/tools",
|
||||
"ja/use-dify/nodes/question-classifier",
|
||||
"ja/use-dify/nodes/ifelse",
|
||||
"ja/use-dify/nodes/human-input",
|
||||
"ja/use-dify/nodes/iteration",
|
||||
"ja/use-dify/nodes/loop",
|
||||
"ja/use-dify/nodes/code",
|
||||
@@ -841,7 +843,8 @@
|
||||
"ja/use-dify/nodes/variable-assigner",
|
||||
"ja/use-dify/nodes/parameter-extractor",
|
||||
"ja/use-dify/nodes/http-request",
|
||||
"ja/use-dify/nodes/list-operator"
|
||||
"ja/use-dify/nodes/list-operator",
|
||||
"ja/use-dify/nodes/tools"
|
||||
]
|
||||
},
|
||||
{
|
||||
|
||||
79
en/use-dify/nodes/human-input.mdx
Normal file
79
en/use-dify/nodes/human-input.mdx
Normal file
@@ -0,0 +1,79 @@
|
||||
---
|
||||
title: Human Input
|
||||
description: Pause workflows to request human input, review, or decisions
|
||||
icon: user-magnifying-glass
|
||||
---
|
||||
|
||||
The Human Input node pauses workflows at key points to request human input before execution continues.
|
||||
|
||||
When execution reaches this node, a customizable request form is delivered through specific channels. Recipients can provide input, review data, and choose from predefined decisions that determine how the workflow proceeds.
|
||||
|
||||
By embedding human judgement directly where it matters, you can **balance automated efficiency with human oversight**.
|
||||
|
||||
<Frame caption="Request Form Example"><img src="/images/human_input_request_form_example.png" alt="Request Form Example" /></Frame>
|
||||
|
||||
## Configuration
|
||||
|
||||
Configure the following to define how the node requests and processes human input:
|
||||
|
||||
- **Delivery method**: How the request form reaches recipients.
|
||||
|
||||
- **Form content**: What information recipients will see and what they can input.
|
||||
|
||||
- **User action**: What decisions recipients can make and how the workflow proceeds accordingly.
|
||||
|
||||
- **Timeout strategy**: How long to wait and what happens if no recipient responds.
|
||||
|
||||
### Delivery Method
|
||||
|
||||
Choose the channel through which the request is delivered. Currently available methods:
|
||||
|
||||
- **Web app**: Displays the request form directly in the web app interface for the current user to respond.
|
||||
|
||||
- **Email**: Sends an email containing the request link to one or more recipients.
|
||||
|
||||
<Note>
|
||||
The request closes after the first response regardless of delivery method.
|
||||
</Note>
|
||||
|
||||
### Form Content
|
||||
|
||||
Customize what appears in the request form:
|
||||
|
||||
- **Format and structure with Markdown**
|
||||
|
||||
Use headings, lists, bold text, links, and other Markdown elements to present information clearly.
|
||||
|
||||
- **Display dynamic data with variables**
|
||||
|
||||
Reference workflow variables to show dynamic content, such as AI-generated text for review or any needed contextual information from upstream nodes.
|
||||
|
||||
<Tip>
|
||||
If you reference the `text` output variable from a reasoning model, the form will display the model's thinking process along with the final answer by default.
|
||||
|
||||
To show only the answer, toggle on **Enable Reasoning Tag Separation** for the corresponding LLM node.
|
||||
</Tip>
|
||||
|
||||
- **Collect input with input fields**
|
||||
|
||||
Input fields can start empty or pre-filled with variables (e.g., LLM output to refine) or static text (e.g., example or default values) that recipients can edit.
|
||||
|
||||
Each input field becomes a variable for downstream use. For instance, pass edited content for further processing or send feedback to an LLM for regeneration.
|
||||
|
||||
### User Action
|
||||
|
||||
Define the decision buttons that recipients can click. Each button routes the workflow to a different execution path.
|
||||
|
||||
For example, a `Post` branch might lead to nodes that trigger content publishing, while a `Regenerate` branch might loop back to an LLM node to revise the content.
|
||||
|
||||
<Tip>
|
||||
Use preset button styles to visually distinguish actions.
|
||||
|
||||
For example, use a prominent style for key actions like `Approve` and a subtler one for secondary options.
|
||||
</Tip>
|
||||
|
||||
### Timeout Strategy
|
||||
|
||||
Configure how long to wait for a response before the request expires.
|
||||
|
||||
If no recipient responds within the set time, the workflow automatically ends unless you define a fallback branch to handle the timeout—for example, send a notification or retry the request.
|
||||
BIN
images/human_input_request_form_example.png
Normal file
BIN
images/human_input_request_form_example.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 378 KiB |
81
ja/use-dify/nodes/human-input.mdx
Normal file
81
ja/use-dify/nodes/human-input.mdx
Normal file
@@ -0,0 +1,81 @@
|
||||
---
|
||||
title: 人的介入
|
||||
description: ワークフローを一時停止して、人間の入力、レビュー、または意思決定を要求します
|
||||
icon: user-magnifying-glass
|
||||
---
|
||||
|
||||
<Note> ⚠️ このドキュメントはAIによって自動翻訳されています。不正確な部分がある場合は、[英語版](/en/use-dify/nodes/human-input)を参照してください。</Note>
|
||||
|
||||
**人的介入ノード**は、ワークフローを主要なポイントで一時停止し、実行を継続する前に人間による入力を要求します。
|
||||
|
||||
実行がこのノードに到達すると、カスタマイズ可能なリクエストフォームが特定のチャネルを通じて配信されます。受信者は、入力の提供、データの確認、およびワークフローの進行方法を決定する事前に定義された選択肢からの選択を行うことができます。
|
||||
|
||||
重要な場面に人間の判断を直接組み込むことで、**自動化による効率性と人間による監視のバランス**をとることができます。
|
||||
|
||||
<Frame caption="リクエストフォームの例"><img src="/images/human_input_request_form_example.png" alt="リクエストフォームの例" /></Frame>
|
||||
|
||||
## 設定
|
||||
|
||||
ノードがどのように人間の入力を要求し処理するかを定義するために、以下を設定します:
|
||||
|
||||
- **配信方法**: リクエストフォームがどのように受信者に届くか。
|
||||
|
||||
- **フォーム内容**: 受信者に表示される情報と、受信者が入力できる内容。
|
||||
|
||||
- **ユーザーアクション**: 受信者が行える決定と、それに応じたワークフローの進行方法。
|
||||
|
||||
- **タイムアウト戦略**: 待機時間と、受信者が応答しなかった場合の処理。
|
||||
|
||||
### 配信方法
|
||||
|
||||
リクエストを配信するチャネルを選択します。現在利用可能な方法は以下の通りです:
|
||||
|
||||
- **Webアプリ**: 現在のユーザーが応答できるように、Webアプリのインターフェースに直接リクエストフォームを表示します。
|
||||
|
||||
- **メール**: リクエストリンクを含むメールを1人または複数の受信者に送信します。
|
||||
|
||||
<Note>
|
||||
配信方法に関わらず、最初の応答があった時点でリクエストはクローズされます。
|
||||
</Note>
|
||||
|
||||
### フォーム内容
|
||||
|
||||
リクエストフォームに表示される内容をカスタマイズします:
|
||||
|
||||
- **Markdownによるフォーマットと構造化**
|
||||
|
||||
見出し、リスト、太字、リンクなどのMarkdown要素を使用して、情報を明確に提示します。
|
||||
|
||||
- **変数による動的データの表示**
|
||||
|
||||
ワークフロー変数を参照して、レビュー用のAI生成テキストや上流ノードからの必要なコンテキスト情報などの動的コンテンツを表示します。
|
||||
|
||||
<Tip>
|
||||
推論モデルからの `text` 出力変数を参照する場合、フォームには最終的な回答とともにモデルの思考プロセスが表示されます。
|
||||
|
||||
回答のみを表示するには、対応するLLMノードで **推論タグの分離を有効にする(Enable Reasoning Tag Separation)** をオンにしてください。
|
||||
</Tip>
|
||||
|
||||
- **入力フィールドによる入力の収集**
|
||||
|
||||
入力フィールドは、空の状態から始めることも、受信者が編集できるように変数(例:修正するLLMの出力)や静的テキスト(例:例やデフォルト値)を事前に入れておくことも可能です。
|
||||
|
||||
各入力フィールドは、下流で使用するための変数となります。例えば、編集されたコンテンツをさらなる処理のために渡したり、再生成のためにLLMにフィードバックを送信したりできます。
|
||||
|
||||
### ユーザーアクション
|
||||
|
||||
受信者がクリックできる決定ボタンを定義します。各ボタンは、ワークフローを異なる実行パスにルーティングします。
|
||||
|
||||
例えば、`投稿` ブランチはコンテンツの公開をトリガーするノードにつながり、`再生成` ブランチはコンテンツを修正するためにLLMノードにループバックするような構成が可能です。
|
||||
|
||||
<Tip>
|
||||
プリセットのボタンスタイルを使用して、アクションを視覚的に区別します。
|
||||
|
||||
例えば、`承認` のような重要なアクションには目立つスタイルを使用し、二次的なオプションには控えめなスタイルを使用します。
|
||||
</Tip>
|
||||
|
||||
### タイムアウト戦略
|
||||
|
||||
リクエストが期限切れになるまで応答を待機する時間を設定します。
|
||||
|
||||
設定時間内に受信者が応答しなかった場合、タイムアウトを処理するためのフォールバックブランチ(例:通知の送信やリクエストの再試行)を定義していない限り、ワークフローは自動的に終了します。
|
||||
81
zh/use-dify/nodes/human-input.mdx
Normal file
81
zh/use-dify/nodes/human-input.mdx
Normal file
@@ -0,0 +1,81 @@
|
||||
---
|
||||
title: 人工介入
|
||||
description: 暂停工作流以请求人工输入、审核或决策
|
||||
icon: user-magnifying-glass
|
||||
---
|
||||
|
||||
<Note> ⚠️ 本文档由 AI 自动翻译。如有任何不准确之处,请参考[英文原版](/en/use-dify/nodes/human-input)。</Note>
|
||||
|
||||
人工介入节点会在关键点暂停工作流,在继续执行前请求人工输入。
|
||||
|
||||
当执行到达此节点时,系统会通过特定渠道发送可自定义的请求表单。接收人可以提供输入、审核数据,并从预定义的决策中进行选择,这些决策将决定工作流后续如何进行。
|
||||
|
||||
通过在关键环节直接嵌入人工判断,你可以在**自动化效率与人工监督之间取得平衡**。
|
||||
|
||||
<Frame caption="请求表单示例"><img src="/images/human_input_request_form_example.png" alt="请求表单示例" /></Frame>
|
||||
|
||||
## 配置
|
||||
|
||||
配置以下内容以定义该节点如何请求和处理人工输入:
|
||||
|
||||
- **发送方式**:请求表单如何送达接收人。
|
||||
|
||||
- **表单内容**:接收人将看到什么信息以及他们可以输入什么。
|
||||
|
||||
- **用户动作**:接收人可以做出哪些决策,以及工作流相应如何进行。
|
||||
|
||||
- **超时策略**:等待多久以及如果无人响应会发生什么。
|
||||
|
||||
### 发送方式
|
||||
|
||||
选择发送请求的渠道。当前可用的方式:
|
||||
|
||||
- **Web 应用**:直接在 Web 应用界面中显示请求表单,供当前用户响应。
|
||||
|
||||
- **邮件**:向一位或多位接收人发送包含请求链接的电子邮件。
|
||||
|
||||
<Note>
|
||||
无论采用何种发送方式,请求将在收到第一个响应后关闭。
|
||||
</Note>
|
||||
|
||||
### 表单内容
|
||||
|
||||
自定义请求表单中显示的内容:
|
||||
|
||||
- **使用 Markdown 格式化结构**
|
||||
|
||||
使用标题、列表、粗体文本、链接和其他 Markdown 元素清晰地呈现信息。
|
||||
|
||||
- **使用变量显示动态数据**
|
||||
|
||||
引用工作流变量以显示动态内容,例如供审核的 AI 生成文本或上游节点所需的任何上下文信息。
|
||||
|
||||
<Tip>
|
||||
如果你引用推理模型的 `text` 输出变量,表单将默认显示模型的思维过程以及最终答案。
|
||||
|
||||
要仅显示答案,请为相应的 LLM 节点开启 **思维链分离渲染**(Enable Reasoning Tag Separation)。
|
||||
</Tip>
|
||||
|
||||
- **使用输入字段收集输入**
|
||||
|
||||
输入字段可以是空的,也可以预填变量(例如,需优化的 LLM 输出)或静态文本(例如,示例或默认值),接收人可以对其进行编辑。
|
||||
|
||||
每个输入字段都会成为供下游使用的变量。例如,将编辑后的内容传递给后续处理,或将反馈发送给 LLM 进行重新生成。
|
||||
|
||||
### 用户动作
|
||||
|
||||
定义接收人可以点击的决策按钮。每个按钮将工作流路由到不同的执行路径。
|
||||
|
||||
例如,`发布` 分支可能会通向触发内容发布的节点,而 `重新生成` 分支可能会循环回 LLM 节点以修改内容。
|
||||
|
||||
<Tip>
|
||||
使用预设按钮样式在视觉上区分动作。
|
||||
|
||||
例如,对 `批准` 等关键动作使用醒目的样式,对次要选项使用较淡的样式。
|
||||
</Tip>
|
||||
|
||||
### 超时策略
|
||||
|
||||
配置在请求过期前等待响应的时间。
|
||||
|
||||
如果在设定时间内没有接收人响应,工作流将自动结束,除非你定义了一个后备分支来处理超时——例如,发送通知或重试请求。
|
||||
Reference in New Issue
Block a user