Skip to content

PersistentAI API Documentation / @persistentai/fireflow-types / validateDAG

Function: validateDAG()

validateDAG(forward): object

Defined in: packages/fireflow-types/src/flow/execution/planner/graph-analysis.ts:93

Validate that the graph is a DAG (no cycles). Uses Kahn's algorithm.

Parameters

forward

Map<string, string[]>

Returns

object

cycle?

optional cycle: string[]

isDAG

isDAG: boolean

Licensed under BUSL-1.1