dify/api/models/workflow.py文件中的数据表

源码位置:dify/api/models/workflow.py

Workflow 表结构

字段英文名 数据类型 字段中文名字 备注
id StringUUID ID UUID生成
tenant_id StringUUID 工作区ID 非空
app_id StringUUID 应用ID 非空
type String 工作流类型 非空
version String 版本 非空
graph Text 工作流画布配置 JSON格式,包含节点和边的配置
features Text 功能 JSON格式
created_by StringUUID 创建者ID 非空
created_at DateTime 创建时间 当前时间
updated_by StringUUID 更新者ID 可选
updated_at DateTime 更新时间 可选

WorkflowRun 表结构

字段英文名 数据类型 字段中文名字 备注
id StringUUID ID UUID生成
tenant_id StringUUID 工作区ID 非空
app_id StringUUID 应用ID 非空
sequence_number Integer 序列号 非空,应用内自增
workflow_id StringUUID 工作流ID 非空
type String 工作流类型 非空
triggered_from String 触发来源 非空
version String 版本 非空
graph Text 工作流画布配置 JSON格式
inputs Text 输入参数 JSON格式
status String 执行状态 非空
outputs Text 输出内容 可选,JSON格式
error Text 错误原因 可选
elapsed_time Float 耗时 非空,默认0
total_tokens Integer 总token数量 非空,默认0
total_steps Integer 总步骤数量 默认0
created_by_role String 创建者角色 非空
created_by StringUUID 创建者ID 非空
created_at DateTime 创建时间 当前时间
finished_at DateTime 结束时间 可选

WorkflowNodeExecution 表结构

字段英文名 数据类型 字段中文名字 备注
id StringUUID ID UUID生成
tenant_id StringUUID 工作区ID 非空
app_id StringUUID 应用ID 非空
workflow_id StringUUID 工作流ID 非空
triggered_from String 触发来源 非空
workflow_run_id StringUUID 工作流运行ID 可选
index Integer 执行序列号 非空
predecessor_node_id String 前置节点ID 可选
node_id String 节点ID 非空
node_type String 节点类型 非空
title String 节点标题 非空
inputs Text 输入参数 JSON格式
process_data Text 处理数据 JSON格式
outputs Text 输出变量 可选,JSON格式
status String 执行状态 非空
error Text 错误原因 可选
elapsed_time Float 耗时 非空,默认0
execution_metadata Text 执行元数据 JSON格式
created_at DateTime 创建时间 当前时间
created_by_role String 创建者角色 非空
created_by StringUUID 创建者ID 非空
finished_at DateTime 结束时间 可选

WorkflowAppLog 表结构

字段英文名 数据类型 字段中文名字 备注
id StringUUID ID UUID生成
tenant_id StringUUID 工作区ID 非空
app_id StringUUID 应用ID 非空
workflow_id StringUUID 工作流ID 非空
workflow_run_id StringUUID 工作流运行ID 非空
created_from String 创建来源 非空
created_by_role String 创建者角色 非空
created_by StringUUID 创建者ID 非空
created_at DateTime 创建时间 当前时间

上述表格详细说明了每个表的字段名称、数据类型、字段中文名称和备注。

相关推荐
Orange_sparkle4 天前
关于dify中http节点下载文件时,文件名不为原始文件名问题解决
人工智能·http·chatgpt·dify
寒冰大叔5 天前
Dify 添加 Google cloud 模型供应商
googlecloud·dify·gemini
TGITCIC5 天前
第1课-通过DIFY实现一个完整的Text2Sql来讲AI原生及Agentic RAG长什么样
text2sql·dify·ai-native·chatbi·rag增强检索·agentic rag
MaybeAI7 天前
Skill 与 Workflow:让自动化更“聪明”的系统架构
人工智能·ai·自动化·workflow·工作流
Alfred king9 天前
Dify chat模型streaming转为文字解决方案
低代码·agent·dify
一马平川的大草原12 天前
基于n8n实现数据库多表数据同步
数据库·数据同步·dify·n8n
菩提树下的杨过13 天前
dify+LLM+echarts打造智能可视化数据分析AI助手
echarts·dify
94甘蓝15 天前
第 12 篇 Dify 入坑记录:database插件连接未关闭
数据库·人工智能·ai·dify·dify插件
天花板之恋16 天前
MutableStateFlow、StateFlow、LiveData在Compose中的运用
kotlin·workflow
Lethehong18 天前
搭建AI智能翻译器:快速部署Dify,接入AiOnly平台GPT-5模型
人工智能·gpt·dify·maas·aionly