发布

  • [NA] [BE][FE] chore: sync provider model definitions (#6427)

    frostbyte_neo 发布于 2026-04-22 13:06:13 +00:00

    • [NA] [BE][FE] chore: sync provider model definitions

    • fix: sanitize tilde from model identifier names

    The automated sync generated ~ANTHROPIC_CLAUDE_OPUS_LATEST as an
    identifier, but ~ is not valid in Java/TypeScript identifiers.
    Rename to ANTHROPIC_CLAUDE_OPUS_LATEST while keeping the string
    value ~anthropic/claude-opus-latest intact.

    Co-Authored-By: Claude Opus 4.6 (1M context) noreply@anthropic.com

    • fix(sync): strip tilde and leading underscores from generated enum names

    The model_to_enum_name() regex didn't handle ~, so
    ~anthropic/claude-opus-latest produced the invalid identifier
    ~ANTHROPIC_CLAUDE_OPUS_LATEST. Add ~ to the sanitization
    character class and strip any resulting leading underscores.


    Co-authored-by: Andres Cruz andresc@comet.com

    下载附件