Skip to main content

Module tables

Module tables 

Source
Expand description

Reusable tabled table widgets for command output.

Pure shaping and rendering: each function turns domain records into a rendered table string. Callers decide where the string is printed, so the row shaping stays testable without a terminal.

Functionsยง

ai_requests_table
artifact_list_table
context_list_table
db_tables_table
execution_steps_table
extract_latency_from_metadata
Pulls the event-type-appropriate latency field out of raw JSON metadata.
format_metadata_value
Formats a trace metadata value for display, giving cost/latency/token keys their unit-aware form.
mcp_tool_calls_table
task_artifacts_table
Renders one row per distinct artifact id, keeping first-seen order.
task_info_table
trace_events_table
Renders trace events with inter-event deltas; empty input yields an empty string.
truncate_cell
Flattens newlines and truncates to max_len, appending ... when cut.