Skip to content

fix(k8s): the DeepSeek gateway group gets a fallback group #5564

Closed

Description

@dan-petty

Problem Description

The gateway group deepseek-v4.1-flash-1017 has no fallback. When its route fails, the call fails. On 2026-11-13 from about 22:10Z, the gateway logged about 35 litellm.Timeout ... OpenrouterException - A Timeout Occurred lines in 30 minutes, with No fallback model group found for lookup_groups=deepseek-v4.1-flash-1017 (a mid-stream fallback error). Three stage Jobs (#2594, #2713, #3241) failed with HTTP 504 Gateway Timeout.

The group asks OpenRouter for the floor route (the cheapest provider) with fp8 weights and data_collection: deny. The OpenRouter endpoint list at 22:40Z showed the cheapest fp8 endpoint of deepseek/deepseek-v4.1-flash-1017 (0.0784/0.2352 USD per million, the rates of the group) with status -5 and an uptime of 33% in the last 30 minutes.

Proposed Solution & Architectural Design

Owner decision (2026-11-13): "use openrouter deepseek/deepseek-v4.1-flash as a fallback".

  • Add the hosted group deepseek-v4.1-flash to k8s/llm/gateway/config.yaml: openrouter/deepseek/deepseek-v4.1-flash, with no :floor, so that OpenRouter does its own load balance across providers. Keep the same provider filter as the primary group: fp8 weights and data_collection: deny. The privacy control does not change.
  • Set its model_info: window 1,048,576 and the prices. Add the same prices to _HOSTED_GROUP_PRICES (src/devops_cli/ai/spend/pricing.py) and the group to CONST_AI_GATEWAY_HOSTED_MODELS.
  • Add the fallback deepseek-v4.1-flash-1017: [deepseek-v4.1-flash]. This is a hosted group to a hosted group (feat(k8s): fall back from claude-sonnet-5-5 to deepseek-v4.1-flash-1017 #3152), with the same provider (OpenRouter) and the same model family. So the data flow of SECURITY.md item 13 does not change, but its text names one more group and one more fallback.
  • Update SECURITY.md item 13 and the hosted-model text in k8s/README.md.

Acceptance Criteria

  • The gateway config test proves that deepseek-v4.1-flash-1017 falls back to deepseek-v4.1-flash, that the new group is hosted, that its filters hold data_collection: deny and fp8, and that no group that is not hosted falls back to it (devops ci fail-to-pass).
  • tests/ai/spend/test_hosted_group_prices.py passes with the new group (prices equal in both places).
  • After the Argo CD sync and the gateway restart: one call that names deepseek-v4.1-flash answers, and the gateway logs a fallback for a failed deepseek-v4.1-flash-1017 call, or the fallback counter rises.

Related

#3152, #5562 (the stage Job retries a provider timeout), #5527

Activity

  1. added
    source/agent
    type/bug
    scope/k8s
    status/new
    value/high
    effort/medium
    on Nov 13, 2026
  2. dan-petty commented on Nov 13, 2026

    @dan-petty
    OwnerAuthor
    • Priority: P1-High. Production calls are failing with 504 timeouts and three Jobs have already failed due to the missing fallback.
    • Related: feat(k8s): fall back from claude-sonnet-5-5 to deepseek-v4.1-flash-1017 #3152, which asks for a different change. Both add a fallback to the gateway config, but #3152 adds claude-sonnet-5-5 to deepseek-v4.1-flash-1017 while this adds deepseek-v4.1-flash-1017 to deepseek-v4.1-flash.
  3. added
    priority/p1-high
    owner/agent
    on Nov 13, 2026
  4. removed
    owner/agent
    on Nov 13, 2026
  5. added
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 13, 2026
  6. removed
    status/in-review
    on Nov 13, 2026
  7. devops-cli-service commented on Nov 14, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-14 00:14 UTC

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/mediumpriority/p1-highscope/k8ssource/agenttype/bugvalue/high

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions