Brapi Walk Pedigree
brapi_walk_pedigreeWalk germplasm ancestry or descendancy as a deduplicated DAG, with multi-generation traversal, cycle detection, and depth limits. Returns nodes + edges plus traversal stats (depthReached, rootCount, leafCount, cycleCount, deadEndCount).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| alias | No | Connection alias registered via brapi_connect. Omit to read the connection registered under alias `default` — i.e. a prior brapi_connect call that did not specify an alias. Calls that used a non-default alias must pass that same alias here. | |
| maxDepth | No | Max generations to walk per direction (default 3, cap 10). | |
| direction | No | Which direction to walk: ancestors (parents), descendants (progeny), or both. | ancestors |
| loadLimit | No | Cap on rows returned inline. Omit for the deployment default. Rows beyond the cap land in a dataframe; query with brapi_dataframe_query (SQL) instead of paging row-by-row. | |
| germplasmDbIds | Yes | Starting germplasm (1–20 roots). All roots are walked concurrently. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| alias | No | Alias of the registered BrAPI connection the call used. | |
| edges | No | Deduplicated edge list. `relationship: "parent"` means `from` is a parent of `to`; `relationship: "child"` means `from` is a descendant of `to`. | |
| error | No | Present when the call failed. Absent on success. | |
| nodes | No | Deduplicated node list — every germplasm reached by the walk, sorted by depth then DbId. | |
| maxDepth | No | The maximum depth the walk was allowed to reach (echoed from the input). | |
| warnings | No | Advisory messages (capability gaps, per-node expansion failures). | |
| direction | No | The direction the walk expanded (echoed from the input). | |
| leafCount | No | Nodes that have no outgoing edges in the walked direction — terminal in the DAG. | |
| rootCount | No | Number of starting germplasm roots. | |
| truncated | No | True when the walk hit the 1000-node safety cap before exhausting depth. | |
| cycleCount | No | Number of times the walk revisited an already-registered node (cycles broken). | |
| deadEndCount | No | Nodes whose upstream pedigree/progeny lookup failed. | |
| depthReached | No | Deepest BFS level that produced at least one new edge (0 if only roots were walked). | |
| edgesDataframe | No | Canvas dataframe holding the full edge set, present when the walk exceeds loadLimit — edges[] is then a bounded preview. Any edge field that is a reserved SQL word (e.g. `from` → `from_`) is renamed to a SQL-safe identifier; columnLegend maps it back. Query with brapi_dataframe_query (SQL). | |
| nodesDataframe | No | Canvas dataframe holding the full node set, present when the walk exceeds loadLimit — nodes[] is then a bounded preview. Query with brapi_dataframe_query (SQL); JOIN to the edges dataframe on germplasmDbId. |