---
title: "Update an evaluation task with either fresh run or edit & re-run logic."
method: PATCH
path: "/tracer/eval-task/update_eval_task/"
tags: ["tracer"]
---

# Update an evaluation task with either fresh run or edit & re-run logic.

`PATCH /tracer/eval-task/update_eval_task/`

## Request

- Base URL: `http://localhost:8000`
- URL: `http://localhost:8000/tracer/eval-task/update_eval_task/`
- Auth: one of:
  - API key in header `X-Api-Key`
  - API key in header `X-Secret-Key`

Fresh Run: Deletes all previous results and starts completely fresh
Edit & Re-run: Preserves existing results and only runs missing evaluations

## Request body

- EvalTaskUpdateRequest
  - `name` string
  - `filters` object, nullable
    - `project_id` string, nullable: Project scope for the evaluation task.
    - `date_range` string[]: Half-open [start, end) ISO timestamps, normalized to UTC.
    - `date_preset` '30m' | '6h' | 'today' | 'yesterday' | '7d' | '30d' | '3m' | '6m' | '12m' | 'custom': Which time-window preset the user chose. The frontend resolves it to date_range at save time; this records the intent so a relative window can be re-anchored on the next save. Never read when building a query — date_range remains authoritative. Absent on tasks predating this field. The enum documents the accepted values; it is not enforced.
    - `created_at` string: Exclusive lower-bound ISO timestamp for legacy task filters, normalized to UTC.
    - `session_id` string[]: Trace session id(s) to constrain the task.
    - `trace_id` string[]: Trace id(s) to constrain linked-source tasks.
    - `span_id` string[]: Observation span id(s) to constrain linked-source tasks.
    - `observation_type` string[]: Observation span type(s), for example llm, tool, or chain.
    - `filters` object[]
      - `column_id` string, required: Column or attribute id to filter on.
      - `property_id` string: Optional stable namespaced Property Registry identity.
      - `display_name` string: Optional UI label for chips and saved views.
      - `source` string: Optional source surface for mixed-source filters, for example traces, datasets, or simulation.
      - `output_type` string: Optional metric output type metadata used by eval and annotation filters.
      - `filter_config` object, required
        - `filter_type` string, required: Canonical field type, for example text, number, boolean, datetime, categorical, thumbs, annotator, array, or map. Legacy json is value-sensitive for SPAN_ATTRIBUTE filters: list values become array and object values become map.
        - `filter_op` string, required: Canonical operator from api_contracts/filter_contract.json, for example equals, not_equals, in, not_in, between, not_between, is_null, or is_not_null.
        - `filter_value` unknown
        - `col_type` string: Column family such as SYSTEM_METRIC, SPAN_ATTRIBUTE, EVAL_METRIC, ANNOTATION, or NORMAL.
        - `attribute_value_types` string[]: Optional storage-family provenance aligned one-for-one with filter_value for mixed SPAN_ATTRIBUTE in/not_in filters. Null entries retain filter_type semantics for manually entered values.
    - `span_attributes_filters` object[]
      - `column_id` string, required: Column or attribute id to filter on.
      - `property_id` string: Optional stable namespaced Property Registry identity.
      - `display_name` string: Optional UI label for chips and saved views.
      - `source` string: Optional source surface for mixed-source filters, for example traces, datasets, or simulation.
      - `output_type` string: Optional metric output type metadata used by eval and annotation filters.
      - `filter_config` object, required
        - `filter_type` string, required: Canonical field type, for example text, number, boolean, datetime, categorical, thumbs, annotator, array, or map. Legacy json is value-sensitive for SPAN_ATTRIBUTE filters: list values become array and object values become map.
        - `filter_op` string, required: Canonical operator from api_contracts/filter_contract.json, for example equals, not_equals, in, not_in, between, not_between, is_null, or is_not_null.
        - `filter_value` unknown
        - `col_type` string: Column family such as SYSTEM_METRIC, SPAN_ATTRIBUTE, EVAL_METRIC, ANNOTATION, or NORMAL.
        - `attribute_value_types` string[]: Optional storage-family provenance aligned one-for-one with filter_value for mixed SPAN_ATTRIBUTE in/not_in filters. Null entries retain filter_type semantics for manually entered values.
  - `sampling_rate` number, nullable
  - `spans_limit` integer, nullable
  - `run_type` 'continuous' | 'historical'
  - `row_type` 'spans' | 'traces' | 'sessions' | 'voiceCalls'
  - `status` 'pending' | 'running' | 'completed' | 'failed' | 'paused' | 'deleted'
  - `evals` string[]
  - `edit_type` 'edit_rerun' | 'fresh_run', required
  - `eval_task_id` string, uuid, required

## Response `200`

OK

- EvalTaskUpdateResponse
  - `status` boolean
  - `result` EvalTaskUpdateResult, required
    - `message` string, required
    - `edit_type` 'edit_rerun' | 'fresh_run', required
    - `task_id` string, uuid, required

## Other responses

- `400`: Bad Request
- `500`: Internal Server Error
- `default`: Default error response

---

[API](https://skmtc.dev/futureagi/apis/future-agi-management-api.md) · [All operations](https://skmtc.dev/futureagi/apis/future-agi-management-api/llms.txt) · [OpenAPI document](https://skmtc.dev/futureagi/apis/future-agi-management-api/revisions/c8684118e142?raw)
