Dify parameter extraction: turn a training request into checked fields
Define fields for a synthetic training request, choose an extraction mode and check status and facts before handoff.
Prepare one request and an available model · Define three parameters from the source meaning · Set instructions and a supported mode
At a glance
Dify Parameter Extractor uses a model to convert unstructured text into parameters for downstream nodes. This task extracts topic, seats and format from a synthetic training request and delivers a definition and acceptance record. Extraction success does not establish factual correctness or a completed booking. Compare fields with the input before handoff. The scope is the current Dify Cloud node page. No login, workflow or model call was performed.
Request-to-parameter checks
Source request
Select the variable containing the request and an available model.
Field extraction
Define names, types, descriptions and required status, then choose a supported mode.
Status and facts
Check
__is_success, then compare each field with the source. Failures stop normal consumption.
Prepare one request and an available model
You need an editable Dify Cloud workflow and a configured model. Put the synthetic text below in a text input you control, then select it in the node’s Input Variable. Writing a variable name in instructions is not the same operation. Choose a model with suitable structured-output capability. The documentation does not certify a model or workspace for this article; select an actually available option. The Chinese input requests training on Python logging diagnostics, with 12 seats and online delivery, and supplies no date.
请整理一条培训需求:主题是 Python 日志排查,需要 12 个名额,形式为线上。没有给日期。
Define three parameters from the source meaning
| Name | Type | Description | Required |
|---|---|---|---|
| topic | string | Training topic stated in the input | Yes |
| seats | number | Explicit seat count; do not infer a number | Yes |
| format | string | online for explicit online format; onsite for explicit in-person format | Yes |
The node supports string, number, boolean, array and object types, with manual definitions or imports from tools. This task defines three fields manually. The two format values are a teaching convention, not a documented enum validator. No date is supplied, so no date field is added. For missing required information, record the actual result rather than assume undocumented completion behavior.
Set instructions and a supported mode
Extract topic, seats, and format from the input text.
Use format values online or onsite only when the input states the format.
Do not infer dates or claim that a booking has been made.
Function Call/Tool Call uses model structured-output features. Prompt-based relies on prompting and may suit models without function calling or cases where prompting works better. Select based on actual support; a visible option does not establish compatibility. This single-input task needs no conversation history. If Memory is enabled later, check that earlier seat counts do not contaminate the current request.
Inspect status, then compare facts
After running in your own debugger, inspect __is_success: the documented values are 1 for success and 0 for failure, with __reason describing failure. Parameters are separate output variables; downstream nodes need not read an extra full JSON string. For the synthetic input, acceptance expects the stated Python logging topic, numeric 12 and online. These are requirements derived from the text, not observed outputs.
| Condition | Action |
|---|---|
| __is_success is 0 | Keep __reason and stop normal consumption |
| Success but fields contradict the input | Fail acceptance; revise instructions or model settings before retry |
| Success and factual match | Deliver checked fields and the record; no booking was made |
| Missing count or format | Record actual behavior rather than supply defaults |
Deliver only checked parameters
This task ends with manual parameter checks. Connecting HTTP, tools or booking actions requires their own documented nodes, conditional branches, types, ranges and permissions. No external write is configured here, so a downstream connection is not described as business success. A number type does not establish a positive integer or a count within capacity; those are business checks.
Retain evidence at the failing step
- An unavailable model or unsupported mode stops extraction; inspect the actual setup rather than fabricate success.
- On failure, retain the source and __reason; do not use error text as topic.
- Missing, mistyped or invented fields fail acceptance even with a success status; keep the comparison and block consumption.
- Any retry policy needs limits and stop conditions. Occasional success after prompt changes does not establish stability.
Verification scope
The official Cloud page was read for inputs, parameters, modes, Memory and outputs. The example and field contract are original teaching materials. No Dify workflow, model or downstream API was run; accuracy, permissions and billing were not tested. Check the installed version before applying Cloud labels to a self-hosted deployment.
Article sources
Original editorial content; official descriptions and checking suggestions are distinguished.