Skip to content

Widgets

Add Widget to Dashboard
client.evaluationDashboards.widgets.create(stringdashboardID, WidgetCreateParams { title, type, config, query } body, RequestOptionsoptions?): EvaluationDashboardWidgetWithResult { id, account_id, created_at, 6 more }
POST/v5/evaluation-dashboards/{dashboard_id}/widgets
Update Dashboard Widget
client.evaluationDashboards.widgets.update(stringwidgetID, WidgetUpdateParams { dashboard_id, config, query, title } params, RequestOptionsoptions?): EvaluationDashboardWidgetWithResult { id, account_id, created_at, 6 more }
PATCH/v5/evaluation-dashboards/{dashboard_id}/widgets/{widget_id}
Remove Widget from Dashboard
client.evaluationDashboards.widgets.remove(stringwidgetID, WidgetRemoveParams { dashboard_id } params, RequestOptionsoptions?): void
DELETE/v5/evaluation-dashboards/{dashboard_id}/widgets/{widget_id}
ModelsExpand Collapse
EvaluationDashboardWidget { id, account_id, created_at, 6 more }
id: string

Unique identifier of the widget

account_id: string

Account that owns this widget

created_at: string

When the widget was created

formatdate-time
title: string

Widget title

Widget type

One of the following:
"bar"
"histogram"
"donut"
"scatter"
"metric"
"table"
"markdown"
"heading"
"timeseries"
archived_at?: string

When the widget was archived (soft-deleted)

formatdate-time
config?: Record<string, unknown>

Chart-specific display configuration

object?: "evaluation_dashboard_widget"
query?: SeriesQuery { select, evaluation_ids, filter, 4 more } | MetricQuery { select, evaluation_ids, filter, latest_only }

Structured query AST for metric computation (SeriesQuery or MetricQuery)

One of the following:
SeriesQuery { select, evaluation_ids, filter, 4 more }

Query that returns a series of records (used for table/bar/histogram/donut/scatter widgets).

Used for widget types: table, bar, histogram, donut, scatter. Returns: {“type”: “series”, “data”: […]}

Example SQL equivalent: SELECT category, AVG(score) as avg_score, COUNT(*) as count FROM evaluation_items WHERE score > 0.5 AND category = ‘test’ GROUP BY category ORDER BY avg_score DESC LIMIT 100

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
groupBy?: Array<string>

Columns to group by

latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

limit?: number

Max rows to return

minimum1
orderBy?: Array<OrderBy>

Sort order

column: string

Column name to sort by

direction?: "ASC" | "DESC"

Sort direction

One of the following:
"ASC"
"DESC"
source?: string

Column source: ‘data’ or ‘task_result_cache’

MetricQuery { select, evaluation_ids, filter, latest_only }

Query that returns a single metric value (used for metric widgets).

Used for widget type: metric. Enforces exactly 1 aggregation in select. Returns: {“type”: “metric”, “data”: …}

Example SQL equivalent: SELECT AVG(score) as average_score FROM evaluation_items

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

EvaluationDashboardWidgetResult { id, account_id, computation_status, 10 more }
id: string

Unique identifier of the widget result

account_id: string

Account that owns this widget result

computation_status: "pending" | "completed" | "failed"

Status of the computation

One of the following:
"pending"
"completed"
"failed"
created_at: string

When the widget result was created

formatdate-time
widget_id: string

Unique identifier of the widget

computation_job_id?: string

Temporal workflow ID or job ID for async computation tracking

computed_at?: string

Timestamp when computation completed successfully

formatdate-time
computed_result?: Record<string, unknown>

Cached computation results

error_message?: string

Error message if computation failed

evaluation_group_id?: string

FK to evaluation_groups. Null if result is for a single evaluation.

evaluation_id?: string

FK to evaluations. Null if result is for an evaluation group.

object?: "evaluation_dashboard_widget_result"
widget?: EvaluationDashboardWidget { id, account_id, created_at, 6 more }

Widget that this result is for

id: string

Unique identifier of the widget

account_id: string

Account that owns this widget

created_at: string

When the widget was created

formatdate-time
title: string

Widget title

Widget type

One of the following:
"bar"
"histogram"
"donut"
"scatter"
"metric"
"table"
"markdown"
"heading"
"timeseries"
archived_at?: string

When the widget was archived (soft-deleted)

formatdate-time
config?: Record<string, unknown>

Chart-specific display configuration

object?: "evaluation_dashboard_widget"
query?: SeriesQuery { select, evaluation_ids, filter, 4 more } | MetricQuery { select, evaluation_ids, filter, latest_only }

Structured query AST for metric computation (SeriesQuery or MetricQuery)

One of the following:
SeriesQuery { select, evaluation_ids, filter, 4 more }

Query that returns a series of records (used for table/bar/histogram/donut/scatter widgets).

Used for widget types: table, bar, histogram, donut, scatter. Returns: {“type”: “series”, “data”: […]}

Example SQL equivalent: SELECT category, AVG(score) as avg_score, COUNT(*) as count FROM evaluation_items WHERE score > 0.5 AND category = ‘test’ GROUP BY category ORDER BY avg_score DESC LIMIT 100

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
groupBy?: Array<string>

Columns to group by

latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

limit?: number

Max rows to return

minimum1
orderBy?: Array<OrderBy>

Sort order

column: string

Column name to sort by

direction?: "ASC" | "DESC"

Sort direction

One of the following:
"ASC"
"DESC"
source?: string

Column source: ‘data’ or ‘task_result_cache’

MetricQuery { select, evaluation_ids, filter, latest_only }

Query that returns a single metric value (used for metric widgets).

Used for widget type: metric. Enforces exactly 1 aggregation in select. Returns: {“type”: “metric”, “data”: …}

Example SQL equivalent: SELECT AVG(score) as average_score FROM evaluation_items

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

EvaluationDashboardWidgetResultResponse { id, computation_status, widget_id, 3 more }

Computed result for a widget - used in widget creation response

id: string

Unique identifier of the widget result

computation_status: string

Status: pending, completed, or failed

widget_id: string

Widget ID this result belongs to

computed_at?: string

When computation completed

formatdate-time
computed_result?: Record<string, unknown>

Computed result data. Metric: {type: ‘metric’, data: 42}, Series: {type: ‘series’, data: [{x: ‘A’, y: 10}, …]}

error_message?: string

Error message if computation failed

EvaluationDashboardWidgetWithResult { id, account_id, created_at, 6 more }

Response model for widget creation - includes widget and computed result

id: string

Unique identifier of the widget

account_id: string

Account that owns this widget

created_at: string

When the widget was created

formatdate-time
title: string

Widget title

Widget type

One of the following:
"bar"
"histogram"
"donut"
"scatter"
"metric"
"table"
"markdown"
"heading"
"timeseries"
config?: Record<string, unknown>

Display configuration

object?: "evaluation_widget"
query?: SeriesQuery { select, evaluation_ids, filter, 4 more } | MetricQuery { select, evaluation_ids, filter, latest_only }

Structured query AST for computation (SeriesQuery or MetricQuery)

One of the following:
SeriesQuery { select, evaluation_ids, filter, 4 more }

Query that returns a series of records (used for table/bar/histogram/donut/scatter widgets).

Used for widget types: table, bar, histogram, donut, scatter. Returns: {“type”: “series”, “data”: […]}

Example SQL equivalent: SELECT category, AVG(score) as avg_score, COUNT(*) as count FROM evaluation_items WHERE score > 0.5 AND category = ‘test’ GROUP BY category ORDER BY avg_score DESC LIMIT 100

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
groupBy?: Array<string>

Columns to group by

latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

limit?: number

Max rows to return

minimum1
orderBy?: Array<OrderBy>

Sort order

column: string

Column name to sort by

direction?: "ASC" | "DESC"

Sort direction

One of the following:
"ASC"
"DESC"
source?: string

Column source: ‘data’ or ‘task_result_cache’

MetricQuery { select, evaluation_ids, filter, latest_only }

Query that returns a single metric value (used for metric widgets).

Used for widget type: metric. Enforces exactly 1 aggregation in select. Returns: {“type”: “metric”, “data”: …}

Example SQL equivalent: SELECT AVG(score) as average_score FROM evaluation_items

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

result?: EvaluationDashboardWidgetResultResponse { id, computation_status, widget_id, 3 more }

Computed result for this widget

id: string

Unique identifier of the widget result

computation_status: string

Status: pending, completed, or failed

widget_id: string

Widget ID this result belongs to

computed_at?: string

When computation completed

formatdate-time
computed_result?: Record<string, unknown>

Computed result data. Metric: {type: ‘metric’, data: 42}, Series: {type: ‘series’, data: [{x: ‘A’, y: 10}, …]}

error_message?: string

Error message if computation failed

EvaluationWidgetTypeEnum = "bar" | "histogram" | "donut" | 6 more

Widget types for dashboard visualizations

One of the following:
"bar"
"histogram"
"donut"
"scatter"
"metric"
"table"
"markdown"
"heading"
"timeseries"
Filter { conditions, logicalOperators }

Filter clause with conditions connected by logical operators.

Conditions are evaluated left-to-right without precedence (no nesting/parentheses). Example: condition1 AND condition2 OR condition3 evaluates as ((condition1 AND condition2) OR condition3)

Example: { “conditions”: [ {“column”: “score”, “operator”: ”>”, “value”: 0.5}, {“column”: “category”, “operator”: ”=”, “value”: “test”} ], “logicalOperators”: [“AND”] }

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
MetricQuery { select, evaluation_ids, filter, latest_only }

Query that returns a single metric value (used for metric widgets).

Used for widget type: metric. Enforces exactly 1 aggregation in select. Returns: {“type”: “metric”, “data”: …}

Example SQL equivalent: SELECT AVG(score) as average_score FROM evaluation_items

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

SelectItem { expression, alias }

Column in SELECT clause

expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

SeriesQuery { select, evaluation_ids, filter, 4 more }

Query that returns a series of records (used for table/bar/histogram/donut/scatter widgets).

Used for widget types: table, bar, histogram, donut, scatter. Returns: {“type”: “series”, “data”: […]}

Example SQL equivalent: SELECT category, AVG(score) as avg_score, COUNT(*) as count FROM evaluation_items WHERE score > 0.5 AND category = ‘test’ GROUP BY category ORDER BY avg_score DESC LIMIT 100

select: Array<SelectItem { expression, alias } >
expression: Column { column, source, type } | Aggregation { column, function, evaluation_ids, 3 more }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

One of the following:
Column { column, source, type }

Reference to a column from evaluation_items.data

Example: {“type”: “COLUMN”, “column”: “category”}

column: string

Column name from evaluation_items.data

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "COLUMN"
Aggregation { column, function, evaluation_ids, 3 more }

Aggregation function to apply

Examples: {“type”: “AGGREGATION”, “function”: “AVG”, “column”: “score”} {“type”: “AGGREGATION”, “function”: “COUNT”, “column”: ”*”} {“type”: “AGGREGATION”, “function”: “PERCENTILE”, “column”: “score”, “params”: {“percentile”: 95}}

column: string

Column to aggregate, or '' for COUNT()

function: "COUNT" | "SUM" | "AVG" | 7 more

Supported aggregation functions

One of the following:
"COUNT"
"SUM"
"AVG"
"MIN"
"MAX"
"STDDEV"
"VARIANCE"
"PERCENTILE"
"COUNT_DISTINCT"
"PERCENTAGE"
evaluation_ids?: Array<string>

Optional subset of evaluation IDs for per-aggregation filtering in evaluation group dashboards.

params?: Record<string, unknown>

Function parameters (e.g., {‘percentile’: 95} for PERCENTILE, {‘percentage_filters’: Filter} for PERCENTAGE)

source?: string

Column source: ‘data’ or ‘task_result_cache’

type?: "AGGREGATION"
alias?: string

Optional alias for the selected item

evaluation_ids?: Array<string>

Optional subset of evaluation IDs to compute on. Only applicable for evaluation group dashboards. If omitted, computes on all evaluations in the group.

filter?: Filter { conditions, logicalOperators }

Filter conditions (WHERE clause)

conditions: Array<Condition>
column: string

Column name to filter on

operator: "=" | "!=" | ">" | 9 more

Comparison operator

One of the following:
"="
"!="
">"
"<"
">="
"<="
"IN"
"NOT IN"
"LIKE"
"NOT LIKE"
"IS NULL"
"IS NOT NULL"
source?: string

Column source: ‘data’ or ‘task_result_cache’

value?: string | number | boolean | Array<unknown>

Value to compare against. Not required for IS NULL / IS NOT NULL operators.

One of the following:
string
number
boolean
Array<unknown>
logicalOperators?: Array<"AND" | "OR">

Logical operators connecting conditions. Length must be len(conditions) - 1

One of the following:
"AND"
"OR"
groupBy?: Array<string>

Columns to group by

latest_only?: boolean

When True, the widget computes against rows from only the most recent active evaluation in the group (by EvaluationORM.created_at). Only applicable for evaluation group dashboards. Composes with evaluation_ids (latest within the subset). Cannot be combined with per-aggregation evaluation_ids; the use case enforces these rules.

limit?: number

Max rows to return

minimum1
orderBy?: Array<OrderBy>

Sort order

column: string

Column name to sort by

direction?: "ASC" | "DESC"

Sort direction

One of the following:
"ASC"
"DESC"
source?: string

Column source: ‘data’ or ‘task_result_cache’