stablyai/orca · error · Error

Failed to start download

Error message

Failed to start download

What it means

Fallback error from downloadDictationModel when speech.models.download fails and the host returned no error.message. The download RPC is fire-and-authoritative — failure means the host could not start fetching/extracting the requested model.

Source

Thrown at mobile/src/dictation/mobile-dictation-setup.ts:64

  try {
    return await client.sendRequest('speech.models.list', null)
  } catch (error) {
    if (!(error instanceof LogicalClientCutoverError)) {
      throw error
    }
    // Why: this read can safely repeat on the authenticated replacement; mutation
    // RPCs must still surface cutover so callers never replay unknown commits.
    return client.sendRequest('speech.models.list', null)
  }
}

export async function downloadDictationModel(
  client: Pick<RpcClient, 'sendRequest'>,
  modelId: string
): Promise<void> {
  const response = await client.sendRequest('speech.models.download', { modelId })
  if (!response.ok) {
    throw new Error(response.error?.message || 'Failed to start download')
  }
}

export async function deleteDictationModel(
  client: Pick<RpcClient, 'sendRequest'>,
  modelId: string
): Promise<MobileSpeechSetup> {
  const response = await client.sendRequest('speech.models.delete', { modelId })
  if (!response.ok) {
    throw new Error(response.error?.message || 'Failed to delete model')
  }
  return (response as RpcSuccess).result as MobileSpeechSetup
}

export async function setDictationConfig(
  client: Pick<RpcClient, 'sendRequest'>,
  params: { enabled?: boolean; modelId?: string; dictationMode?: 'toggle' | 'hold' }
): Promise<MobileSpeechSetup> {

View on GitHub (pinned to 1136503c6a)

Solutions

  1. Re-run fetchDictationSetup to confirm modelId still exists in setup.models with status 'available' before retrying the download.
  2. Inspect desktop host logs for the speech.models.download failure cause (disk space, permissions, network).
  3. If a previous download stalled, call deleteDictationModel(modelId) to clear partial state before re-downloading.
  4. Retry once after a short delay — transient CDN/network errors are common.

Example fix

// before
const response = await client.sendRequest('speech.models.download', { modelId })
if (!response.ok) {
  throw new Error(response.error?.message || 'Failed to start download')
}

// after — surface the host code so the UI can distinguish 'already downloading'
if (!response.ok) {
  const code = response.error?.code
  if (code === 'already_downloading') return
  throw new Error(response.error?.message || `Failed to start download${code ? ` (${code})` : ''}`)
}
Defensive patterns

Strategy: try-catch

Validate before calling

// Confirm the model is in the catalog and not already in flight
const setup = await fetchDictationSetup(client)
const model = setup.models.find((m) => m.id === modelId)
if (!model) throw new Error('Unknown model')
if (isModelInFlight(model)) return // already downloading

Type guard

function isDownloadStartError(err: unknown): boolean {
  return err instanceof Error && err.message === 'Failed to start download'
}

Try / catch

try {
  await downloadDictationModel(client, modelId)
} catch (err) {
  if (isDownloadStartError(err)) {
    showDownloadFailedToast(modelId)
    return
  }
  throw err
}

Prevention

When it happens

Trigger: client.sendRequest('speech.models.download', { modelId }) returns {ok:false} with no message; common causes: unknown modelId, host filesystem full, network blocked from the model CDN, model already mid-download with a different status, host lacking write permission to the model directory.

Common situations: User taps download for a model the desktop catalog no longer lists; the host's model cache directory is read-only; the CDN mirror is unreachable from the desktop; a previous extraction left a partial file blocking restart.

Related errors


AI-assisted analysis of stablyai/orca@1136503c6a (2026-08-12). Data as JSON: /api/errors/290de5a8cdb357ce. Report an issue: GitHub.