---
title: "List models available for a task"
method: GET
path: "/v1/tasks/{task}/models"
tags: ["Tasks"]
---

# List models available for a task

`GET /v1/tasks/{task}/models`

## Request

- Base URL: `https://api.genomicintelligence.ai`
- URL: `https://api.genomicintelligence.ai/v1/tasks/{task}/models`
- Auth: none required

List models registered for ``{task}``, plus which one is the default.

``bio_spec.request_max_bp`` is the enforced ceiling — the field to
pre-check a sequence against. ``context_window_bp`` and
``trained_window_bp`` describe what the model scores, not what the route
accepts.

## Path parameters

- `task` 'promoter' | 'splice' | 'enhancer' | 'chromatin' | 'annotation' | 'expression', required: Task identifier. The same value appears as ``meta.task`` on a prediction and as the ``data`` union discriminator. An unrecognised value is ``404 not_found``, not a 422.

## Response `200`

Every model registered for the task, with its ``bio_spec``: organism, capabilities, renderable output formats and the enforced ``request_max_bp`` ceiling. Use it to pick a ``model`` value; the length *minimum* is published once per task, as ``minLength`` on that task's request schema.

- TaskModelsResponse: Success envelope for ``GET /v1/tasks/{task}/models``.
  - `task` string, required: Echo of the requested task.
  - `default_model` string, nullable: Model id used when the request omits ``model``.
  - `models` TaskModelInfo[], required: Every model registered for this task.
    - `id` string, required: Model id — pass as ``model`` in a request body.
    - `name` string, required: Display name.
    - `description` string, required: Short description.
    - `is_default` boolean, required: True for the model used when ``model`` is omitted.
    - `bio_spec` BioSpec: Partner-facing model spec, echoed by ``GET /v1/tasks/{task}/models``. Sourced from ``bio_spec`` in ``api/config/models.yaml``.
      - `sequence_type` string, required: Input alphabet family, e.g. "DNA".
      - `tokenization` string, required: "BPE" or "k-mer".
      - `kmer_k` integer, nullable: k for k-mer tokenizers; null for BPE.
      - `max_tokens` integer, required: Tokenizer output cap per window.
      - `request_max_bp` integer, nullable: Longest ``sequence`` this model accepts, in bp — the admission cap, and the field to pre-check a request against. The matching minimum is published once per task, as ``minLength`` on that task's request schema, not here. Distinct from ``context_window_bp``/``trained_window_bp``, which describe what the model *scores* rather than what the route *accepts*.
      - `context_window_bp` integer, nullable: The model's own input window, in bp. A request **shorter than this is accepted and scored, but against a window padded out to it** — the task's ``minLength`` is admission control, not a statement about regime. Compare your sequence length against this number to know whether the model saw real sequence or padding. Longer input is not a problem: the scanner steps a prediction window at a time and only the final partial window is padded. Null for models that do not slide a window (annotation, expression — see ``trained_window_bp`` for the latter).
      - `trained_window_bp` integer, nullable: The fixed slice, in bp, the server cuts around ``tss_index`` for a model that has one (``g0-expression``: 9198; the model reads the central part of it, roughly 3 kb on each side of the TSS depending on sequence). Not a request bound — a longer submission is cut down to this server-side. Null for models that slide a window across the whole input, and for expression models that read a variable span around the TSS; see ``recommended_flank_bp``.
      - `recommended_flank_bp` integer, nullable: Expression only: how many bp of sequence to fetch on **each** side of the TSS for this model. Supply ``F`` bp of gene-sense (coding-strand) sequence before the TSS and ``F`` bp from the TSS onward, so the TSS is at offset ``F``, and send ``tss_index = F``. In genomic coordinates that is ``[tss - F, tss + F)`` on the plus strand and ``(tss - F, tss + F]``, then reverse-complemented, on the minus strand. Less is accepted down to the task's floor (4,599 bp each side, ``minLength`` 9198) and scored, but a model that reads further than the floor then sees less than it was trained on and its score drifts; the width of ``meta.task_specific_counts.scored_window`` shows how much was read. Equal to the floor for a model with a fixed window (``trained_window_bp``). Null for every other task.
      - `organism` string, required: Organism the model was trained on.
      - `capabilities` string[], required: Model capability tags.
      - `output_formats` string[], required: Renderable output formats for this model.
      - `training_data` string, nullable: Human-readable training-corpus summary.

## Other responses

- `400`: Bad request — e.g. `Prefer: respond-async` combined with a text format.
- `404`: Unknown task, unknown job, or a job owned by another key (`not_found`).
- `409`: Conflict (`conflict`).
- `410`: Async job result expired out of the job store (`job_expired`).
- `413`: Either the 16 MiB request-body hard cap was exceeded (`payload_too_large`, enforced before parsing), or the body is over the endpoint's synchronous-delivery cap (`sync_too_large`; `error.details` carries `{sequence_length, threshold}` — retry the same request with `Prefer: respond-async`).
- `415`: The requested output format is not one this task can render (`unsupported_format`). The message lists the supported formats; the server never silently falls back to JSON.
- `422`: Validation failed (`validation_failed`) — sequence length outside the task's bounds, a non-ACGTN character, an unknown key under `options` (every options object is closed), or a sequence below the *selected task's published `minLength`/`maxLength` bounds.
- `429`: Rate or concurrency cap reached (`too_many_requests`). `Retry-After` and the `RateLimit-*` headers say when to retry.
- `500`: Server error (`internal_error`).
- `503`: Model still loading (`model_loading`), GPU memory exhausted (`insufficient_memory`), or service unavailable. `insufficient_memory` means the card OOM-ed on this request and its cache has been released — it is transient GPU pressure, not a server bug, so `Retry-After` is honest and a bounded retry is the right response.

---

[API](https://skmtc.dev/genomicintelligence/apis/genomic-intelligence-api.md) · [All operations](https://skmtc.dev/genomicintelligence/apis/genomic-intelligence-api/llms.txt) · [OpenAPI document](https://skmtc.dev/genomicintelligence/apis/genomic-intelligence-api/revisions/72436b86d4fe?raw)
