GareArc
ed222945aa
refactor(telemetry): introduce TelemetryFacade to centralize event emission
...
Migrate from direct TraceQueueManager.add_trace_task calls to TelemetryFacade.emit
with TelemetryEvent abstraction. This reduces CE code invasion by consolidating
telemetry logic in core/telemetry/ with a single guard in ops_trace_manager.py.
2026-02-05 20:15:11 -08:00
GareArc
8ceb1ed96f
feat(telemetry): add input/output token split to enterprise OTEL traces
...
- Add PROMPT_TOKENS and COMPLETION_TOKENS to WorkflowNodeExecutionMetadataKey
- Store prompt/completion tokens in node execution metadata JSON (no schema change)
- Calculate workflow-level token split by summing node executions on-the-fly
- Export gen_ai.usage.input_tokens and output_tokens to enterprise telemetry
- Add semantic convention constants for token attributes
- Maintain backward compatibility (historical data shows null)
BREAKING: None
MIGRATION: None (uses JSON metadata, no schema changes)
2026-02-05 20:12:30 -08:00
GareArc
3461c3a8ef
feat(enterprise): Add OTEL telemetry with slim traces, metrics, and structured logs
...
- Add EnterpriseOtelTrace handler with span emission for workflows and nodes
- Implement minimal-span strategy: slim spans + detailed companion logs
- Add deterministic span/trace IDs for cross-workflow trace correlation
- Add metric collection at 100% accuracy (counters & histograms)
- Add event handlers for app lifecycle and feedback telemetry
- Add cross-workflow trace linking with parent context propagation
- Add OTEL exporter with configurable sampling and privacy controls
- Wire enterprise telemetry into workflow execution pipeline
- Add telemetry configuration in enterprise configs
2026-02-05 20:12:28 -08:00
Asuka Minato
ce2c41bbf5
refactor: port api/controllers/console/datasets/datasets_document.py api/controllers/service_api/app/annotation.py api/core/app/app_config/easy_ui_based_app/agent/manager.py api/core/app/apps/pipeline/pipeline_generator.py api/core/workflow/nodes/knowledge_retrieval/knowledge_retrieval_node.py to match case ( #31832 )
2026-02-02 19:07:30 +09:00
yyh
4f826b4641
refactor(typing): use enum types for workflow status fields ( #31792 )
2026-02-02 09:41:34 +08:00
盐粒 Yanli
b8cb5f5ea2
refactor(typing): Fixup typing A2 - workflow engine & nodes ( #31723 )
...
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Asuka Minato <i@asukaminato.eu.org>
2026-01-31 18:00:56 +09:00
QuantumGhost
90fe9abab7
revert: revert human input relevant code ( #31766 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-30 19:18:49 +08:00
QuantumGhost
03e3acfc71
feat(api): Human Input Node (backend part) ( #31646 )
...
The backend part of the human in the loop (HITL) feature and relevant architecture / workflow engine changes.
Signed-off-by: yihong0618 <zouzou0208@gmail.com>
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: 盐粒 Yanli <yanli@dify.ai>
Co-authored-by: CrabSAMA <40541269+CrabSAMA@users.noreply.github.com>
Co-authored-by: Stephen Zhou <38493346+hyoban@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: yihong <zouzou0208@gmail.com>
Co-authored-by: Joel <iamjoel007@gmail.com>
2026-01-30 10:18:49 +08:00
FFXN
c2473d85dc
feat: Add summary index for knowledge. ( #31625 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: Jyong <76649700+JohnJyong@users.noreply.github.com>
Co-authored-by: zxhlyh <jasonapring2015@outlook.com>
Co-authored-by: Yansong Zhang <916125788@qq.com>
Co-authored-by: hj24 <mambahj24@gmail.com>
Co-authored-by: CodingOnStar <hanxujiang@dify.ai>
Co-authored-by: CodingOnStar <hanxujiang@dify.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-01-29 13:47:35 +08:00
-LAN-
3d414678e3
fix(graph_engine): Cannot run single iteration or loop node ( #31470 )
...
Signed-off-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: Yeuoly <45712896+Yeuoly@users.noreply.github.com>
2026-01-28 01:05:59 +08:00
-LAN-
d76ad15fca
refactor(graph_engine): move observability layer and persistence laye… ( #31620 )
2026-01-28 00:54:21 +08:00
wangxiaolei
e48419937b
feat: chatflow support multimodal ( #31293 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-27 00:24:48 +08:00
Asuka Minato
b9f1d65d4f
refactor: example of refine dict / Mapping ( #31498 )
2026-01-26 10:23:38 +08:00
-LAN-
67eb8c052d
refactor: single-node workflow runner helpers ( #31472 )
2026-01-24 10:27:44 +08:00
-LAN-
c575c34ca6
refactor: Move workflow node factory to app workflow ( #31385 )
...
Signed-off-by: -LAN- <laipz8200@outlook.com>
2026-01-22 18:08:21 +08:00
wangxiaolei
121d301a41
refactor: use session factory instead of call db.session directly ( #31198 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-21 13:43:06 +08:00
wangxiaolei
3b225c01da
refactor: refactor workflow context ( #30607 )
2026-01-19 12:18:51 +08:00
-LAN-
206706987d
refactor(variables): clarify base vs union type naming ( #30634 )
...
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-01-13 23:39:34 +09:00
wangxiaolei
2d53ba8671
fix: fix object value is optional should skip validate ( #30894 )
2026-01-13 15:21:06 +08:00
wangxiaolei
0711dd4159
feat: enhance start node object value check ( #30732 )
2026-01-09 16:13:17 +08:00
QuantumGhost
ae0a26f5b6
revert: "fix: fix assign value stand as default ( #30651 )" ( #30717 )
...
The original fix seems correct on its own. However, for chatflows with multiple answer nodes, the `message_replace` command only preserves the output of the last executed answer node.
2026-01-09 16:08:24 +08:00
-LAN-
7ccf858ce6
fix(workflow): pass correct user_from/invoke_from into graph init ( #30637 )
2026-01-07 21:47:23 +08:00
wangxiaolei
187bfafe8b
fix: fix assign value stand as default ( #30651 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2026-01-07 14:54:11 +08:00
-LAN-
55de731f9c
refactor(api): clarify published RAG pipeline invoke naming ( #30644 )
2026-01-06 23:48:06 +09:00
-LAN-
d12b91a01a
refactor(api): inject sessionmaker into conversation variable updater ( #30609 )
2026-01-06 14:52:59 +08:00
-LAN-
d6e9c3310f
feat: Add conversation variable persistence layer ( #30531 )
2026-01-06 14:05:33 +08:00
-LAN-
6f8bd58e19
feat(graph-engine): make layer runtime state non-null and bound early ( #30552 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2026-01-05 16:43:42 +08:00
-LAN-
a99ac3fe0d
refactor(models): Add mapped type hints to MessageAnnotation ( #27751 )
2026-01-05 15:50:03 +08:00
Shemol
d9cecabe93
fix: release graph_runtime_state reference to prevent memory leak under high load ( #30236 )
...
Signed-off-by: SherlockShemol <shemol@163.com>
2025-12-29 10:35:47 +08:00
lif
542eb04ad8
fix: preserve empty list for FILE_LIST type in base_app_generator ( #29618 )
...
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2025-12-22 21:32:07 +08:00
wangxiaolei
e6545f2727
perf: decrease db query ( #29837 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-18 15:35:52 +08:00
wangxiaolei
dd237f129d
fix: fix json object validate ( #29840 )
2025-12-18 14:46:00 +08:00
-LAN-
2e1efd62e1
revert: "fix(ops): add streaming metrics and LLM span for agent-chat traces" ( #29469 )
2025-12-11 12:53:37 +08:00
Jyong
9affc546c6
Feat/support multimodal embedding ( #29115 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-09 14:41:46 +08:00
heyszt
10b59cd6ba
add service layer OTel Span ( #28582 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-05 21:58:32 +08:00
fang luping
a849411978
fix: treat empty default values for optional file inputs as unset ( #28948 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-05 11:16:18 +08:00
wangxiaolei
102ee7ae13
perf: optimize generate conversation name ( #29131 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-05 10:32:53 +08:00
wangxiaolei
cc6c59b27a
fix: fix db session already begin ( #29160 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-05 09:39:39 +08:00
wangxiaolei
725d6b52a7
feat: start node support json schema ( #29053 )
2025-12-05 01:22:10 +09:00
wangxiaolei
e904c65a9d
perf: decrease heavy db operation ( #29125 )
2025-12-04 16:09:47 +08:00
Yunlu Wen
03357ff1ec
fix: catch error in response converter ( #29056 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-04 11:25:16 +08:00
wangxiaolei
e8f93380d1
Fix validation ( #28985 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
2025-12-02 10:25:52 +08:00
wangxiaolei
d162f7e5ef
feat(api): automatically `NODE_TYPE_CLASSES_MAPPING` generation from node class definitions ( #28525 )
2025-12-01 14:14:19 +08:00
wangxiaolei
1b733abe82
feat: creates logs immediately when workflows start (not at completion) ( #28701 )
2025-11-27 15:22:33 +08:00
XlKsyt
1e23957657
fix(ops): add streaming metrics and LLM span for agent-chat traces ( #28320 )
...
Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
2025-11-26 22:45:20 +08:00
QuantumGhost
1c1f124891
Enhanced GraphEngine Pause Handling ( #28196 )
...
This commit:
1. Convert `pause_reason` to `pause_reasons` in `GraphExecution` and relevant classes. Change the field from a scalar value to a list that can contain multiple `PauseReason` objects, ensuring all pause events are properly captured.
2. Introduce a new `WorkflowPauseReason` model to record reasons associated with a specific `WorkflowPause`.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: -LAN- <laipz8200@outlook.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
2025-11-26 19:59:34 +08:00
Xiu-Lan
abc13ef762
Feat/web workflow improvements ( #27981 )
...
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com>
Co-authored-by: johnny0120 <johnny0120@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
Co-authored-by: Wood <tuiskuwood@outlook.com>
2025-11-25 19:54:40 +08:00
Chen Jiaju
3841e8578f
fix: use default values for optional workflow input variables ( #28546 ) ( #28527 )
...
Co-authored-by: Claude <noreply@anthropic.com>
2025-11-24 10:08:26 +08:00
Asuka Minato
a6c6bcf95c
more typed orm ( #28507 )
2025-11-21 21:45:51 +08:00
Asuka Minato
237bb4595b
more typed orm ( #28494 )
...
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-11-21 16:42:27 +09:00