session_define
Define a reactive computed cell using catalog operations. Supports math evaluation, graph parsing, and graph analysis, with live cell references as dependencies.
Instructions
Define a computed cell from a catalog op. args values may be literal JSON or live cell references ({"$cell": "name"}) -- referenced cells become reactive dependencies, so the cell recomputes when they change. Available ops:
math_eval: Evaluate a mallory-math Symbolic expression string over named numeric variables. args: { expr: string, vars?: { name: number | {"$cell": ...} } }. value: number.
graph_parse_edge_list: Parse a
from to [weight]-per-line edge list into a graph value. args: { text: string, directed?: boolean (default true) }. value: graph (opaque; project with session_get_cell).graph_analyze: Structural analysis of a graph cell. args: { graph: graph }. value: { hasCycle, connectedComponents, stronglyConnectedComponents, topologicalOrder, adjacencyMatrix: { matrix, order } }.
graph_bfs: Breadth-first traversal order. args: { graph: graph, start: string }. value: string[].
graph_dfs: Depth-first traversal order. args: { graph: graph, start: string }. value: string[].
graph_dijkstra: Dijkstra shortest-path distances from a start vertex. args: { graph: graph, start: string }. value: [{ vertex, distance }].
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| op | Yes | ||
| args | Yes | ||
| cell | Yes | ||
| sessionId | Yes |