Skip to content

uni-flow 公开 API(中文注解)


uni-flow 公开 API(中文注解) / WorkflowResult

Interface: WorkflowResult

Defined in: core/types.ts:294

一次 run / resume 结束后的结果摘要。

Properties

completedUnits

completedUnits: string[]

Defined in: core/types.ts:300

已完成的 Unit id 列表。


cost

cost: number

Defined in: core/types.ts:308

累计成本。


duration

duration: number

Defined in: core/types.ts:302

耗时(毫秒)。


messages

messages: WorkflowMessage[]

Defined in: core/types.ts:298

本 run 产生的消息。


runId

runId: string

Defined in: core/types.ts:304

运行 id。


state

state: Record<string, unknown>

Defined in: core/types.ts:296

SharedState 快照(含 output.* 等)。


tokenUsage

tokenUsage: number

Defined in: core/types.ts:306

累计 token。

MIT Licensed