Alibaba task_status UNKNOWN: map DashScope states to Sume job states

Model Studio reports PENDING, RUNNING, SUCCEEDED, FAILED, CANCELED and UNKNOWN. Sume has five job states and no twin for UNKNOWN. A small map and a rule.

4 min readSume
All posts

Five of Alibaba's six task states map one-to-one onto Sume's five job statuses, and UNKNOWN has no twin. Model Studio's async video API reports task_status as PENDING, RUNNING, SUCCEEDED, FAILED, CANCELED or UNKNOWN. Sume reports queued, processing, completed, failed and canceled, so a ported poll loop needs one extra rule for the sixth value.

The mapping

Alibaba's reference says you start a task with the header X-DashScope-Async: enable, and that the task id and the video URL are valid for 24 hours. The page suggests polling about every 15 seconds. Sume instead hands back a next_poll_after_seconds hint on the status call, and its job id is stored in the job ledger.

Alibaba task_status vs Sume sume_status (Alibaba reference and Sume docs, read 2026-10-07)
DashScope task_statusSume sume_statusTerminal
PENDINGqueuedNo
RUNNINGprocessingNo
SUCCEEDEDcompletedYes
FAILEDfailedYes
CANCELEDcanceledYes
UNKNOWNno equivalentDo not guess

A map with an escape hatch

This is my mapping, not a table either vendor publishes. The needs_attention bucket stands for UNKNOWN or any new value: stop the loop, log the raw status, and look. Never answer an unknown state by resubmitting a paid job.

DASHSCOPE_TO_SUME = {
    "PENDING": "queued", "RUNNING": "processing", "SUCCEEDED": "completed",
    "FAILED": "failed", "CANCELED": "canceled",
}

def sume_state(task_status):
    # UNKNOWN has no Sume twin: treat it as "stop and look", never as "retry the paid call"
    return DASHSCOPE_TO_SUME.get(task_status, "needs_attention")

print([sume_state(s) for s in ("PENDING", "RUNNING", "SUCCEEDED", "UNKNOWN")])

What changes besides the names

Sume has no X-DashScope-Async header; POST /v1/videos is async by design and returns 202 with an id. Wan 3.0 is in Sume's catalog as wan-3.0, with 2 to 30 second clips, so the duration range is not the obstacle.

The expiry is the part to check. Alibaba's task id and URL last 24 hours. Sume's completed job returns Sume-hosted media URLs, and the docs I read do not state a retention window for them, so ask before you build on a long one. Download what you need and store the job id either way.

Sources

Related posts

More in Comparisons

All Comparisons posts

Written by Sume