Skip to content

feat(human-input): expose selected action value#35451

Merged
Blackoutta merged 1 commit into
langgenius:mainfrom
Blackoutta:blackoutta/action-value-hitl-output-clean
May 11, 2026
Merged

feat(human-input): expose selected action value#35451
Blackoutta merged 1 commit into
langgenius:mainfrom
Blackoutta:blackoutta/action-value-hitl-output-clean

Conversation

@Blackoutta
Copy link
Copy Markdown
Contributor

@Blackoutta Blackoutta commented Apr 21, 2026

Summary

Implements the Dify-side companion for langgenius/dify#34597.

This PR exposes the selected Human Input action value in preview/editor flows and updates the Human Input UI so the right-hand field is treated as the downstream action value.

Changes

  • add __action_value to Human Input preview submission outputs
  • expose __action_value in Human Input output variable metadata
  • update Human Input editor copy so the right-hand field is presented as Action Value
  • raise the frontend action value limit from 20 to 100 while keeping the action id limit at 20
  • avoid duplicate built-in variable injection by keeping Human Input built-ins in the shared workflow constants
  • update backend and frontend tests

Closes #34597.

image

Dependency

This PR depends on the companion Graphon work:

Verification

uv run --project api --dev pytest ./api/tests/unit_tests/services/test_workflow_service.py -k test_submit_human_input_form_preview_success -q
pnpm exec vp test app/components/workflow/nodes/human-input/components/__tests__/user-action.spec.tsx app/components/workflow/nodes/human-input/__tests__/panel.spec.tsx app/components/workflow/nodes/human-input/__tests__/human-input.spec.tsx app/components/workflow/hooks/__tests__/use-workflow-variables.spec.ts

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented Apr 21, 2026

Pyrefly Diff

base → PR
--- /tmp/pyrefly_base.txt	2026-05-10 10:25:00.471183315 +0000
+++ /tmp/pyrefly_pr.txt	2026-05-10 10:24:48.795055936 +0000
@@ -6210,11 +6210,11 @@
 ERROR `Literal['2']` is not assignable to TypedDict key `limit` with type `int` [bad-typed-dict-key]
    --> tests/unit_tests/services/test_workflow_run_service.py:132:103
 ERROR Missing required key `id` for TypedDict `NodeConfigDict` [bad-typed-dict-key]
-    --> tests/unit_tests/services/test_workflow_service.py:2747:71
+    --> tests/unit_tests/services/test_workflow_service.py:2755:71
 ERROR Missing required key `data` for TypedDict `NodeConfigDict` [bad-typed-dict-key]
-    --> tests/unit_tests/services/test_workflow_service.py:2747:71
+    --> tests/unit_tests/services/test_workflow_service.py:2755:71
 ERROR Argument `dict[str, str | dict[str, str]]` is not assignable to parameter `node_config` with type `NodeConfigDict` in function `services.workflow_service.WorkflowService._build_human_input_node` [bad-argument-type]
-    --> tests/unit_tests/services/test_workflow_service.py:2833:65
+    --> tests/unit_tests/services/test_workflow_service.py:2841:65
 ERROR Argument `Literal['api_key']` is not assignable to parameter `credential_type` with type `CredentialType` in function `services.tools.builtin_tools_manage_service.BuiltinToolManageService.list_builtin_provider_credentials_schema` [bad-argument-type]
   --> tests/unit_tests/services/tools/test_builtin_tools_manage_service.py:91:89
 ERROR Object of class `Mapping` has no attribute `startswith` [missing-attribute]

Copy link
Copy Markdown
Contributor Author

Release-order note for reviewers: this PR depends on the companion Graphon changes in langgenius/graphon#78 / langgenius/graphon#77.

Those Graphon changes need to be merged first, and a Graphon release containing them needs to be published first. Only after Dify can consume that released Graphon version should this PR be merged and included in a Dify release.

In short: merge/release Graphon first, then merge/release this Dify PR.

@Blackoutta Blackoutta self-assigned this Apr 21, 2026
@Blackoutta Blackoutta force-pushed the blackoutta/action-value-hitl-output-clean branch from d3e9508 to 897ae04 Compare May 10, 2026 10:23
@Blackoutta Blackoutta enabled auto-merge May 10, 2026 10:25
@github-actions
Copy link
Copy Markdown
Contributor

Pyrefly Type Coverage

Metric Base PR Delta
Type coverage 0.00% 43.76% +43.76%
Strict coverage 0.00% 43.29% +43.29%
Typed symbols 0 21,998 +21,998
Untyped symbols 0 28,580 +28,580
Modules 0 2547 +2,547

@Blackoutta Blackoutta added this pull request to the merge queue May 11, 2026
@dosubot dosubot Bot added the lgtm This PR has been approved by a maintainer label May 11, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks May 11, 2026
@Blackoutta Blackoutta added this pull request to the merge queue May 11, 2026
Merged via the queue into langgenius:main with commit 0b70eec May 11, 2026
55 of 59 checks passed
@Blackoutta Blackoutta deleted the blackoutta/action-value-hitl-output-clean branch May 11, 2026 02:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🌊 feat:workflow Workflow related stuff. lgtm This PR has been approved by a maintainer size:S This PR changes 10-29 lines, ignoring generated files. web This relates to changes on the web.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Expose selected action value as an output in HITL Human Input(and extend its length as well)

2 participants