Expand Call-Tree Node
openl_expand_trace_treeLoad one level of a profiling run's call tree on demand to inspect a specific branch; expand any step with sub-calls and page large loops to find performance bottlenecks.
Instructions
Load one level of a profiling run's executed call tree on demand. The tree is lazy: the /stack tree root (a profiling openl_start_trace / openl_resume_trace with includeTree: true) and every node returned here are ONE level deep — each step carries a childrenTotal count instead of nested children. Expand a step whose childrenTotal > 0 by naming its node (uri + instance) and the step's ref; the reply is a TreeChildrenView { children, total } where each child is itself shallow (its own steps' childrenTotal), expanded by calling this tool again. Page a loop's many sub-calls with offset/limit (default 100): when total > offset + children.length the reply sets hasMore: true and nextOffset — call again with that offset to get the next page. A returned node may also carry notRetained — sub-calls that ran but were dropped once the retained tree hit its size limit (report as '+N not retained'). Requires a profiling run (profiling: true retains the tree). To find what's slow use the constant-size profile overview instead; use this to walk one branch's call structure. Valid while the debug session is alive (including after the run completes).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| uri | Yes | Source URI of the node whose step to expand: the root node's `uri` from the /stack `tree` (a profiling openl_start_trace / openl_resume_trace with includeTree: true), or a child node's `uri` from an earlier openl_expand_trace_tree page. | |
| step | Yes | Reference of the step within that node to expand, e.g. 'R1C0' — a step whose `childrenTotal` > 0 (a step with childrenTotal 0 or absent made no sub-calls). | |
| limit | No | How many sub-calls to return per page (backend default 100). Keep it modest — a page of many wide nodes can still be large. | |
| offset | No | Index of the first sub-call to return, for paging a loop's thousands of children (default 0). When the response's total exceeds offset + returned children, call again with offset advanced by the returned count (the reply's nextOffset). | |
| instance | Yes | Zero-based execution index of that node in the run (its `instance`; 0 for the root) — picks the exact loop iteration when the table ran more than once. | |
| projectId | Yes | Project ID returned by backend. Use the exact 'projectId' value from openl_list_projects() response without modification or reformatting. | |
| response_format | No | Response format: 'json' for structured, round-trippable data (default), 'markdown' for human-readable output, 'markdown_concise' for a brief summary (1-2 paragraphs), or 'markdown_detailed' for full details with context | json |