Skip to content

docs(rust/README): document xAI and Kimi model aliases#3268

Open
nankingjing wants to merge 1 commit into
ultraworkers:mainfrom
nankingjing:docs-model-aliases
Open

docs(rust/README): document xAI and Kimi model aliases#3268
nankingjing wants to merge 1 commit into
ultraworkers:mainfrom
nankingjing:docs-model-aliases

Conversation

@nankingjing

Copy link
Copy Markdown

What

The Model Aliases table in rust/README.md only listed the three Anthropic
aliases (opus, sonnet, haiku), but resolve_model_alias in
rust/crates/api/src/providers/mod.rs also resolves xAI and Kimi aliases. This
PR documents the full alias set, adds a Provider and Auth env var column
so each alias is actionable, and notes that resolution is case-insensitive.

Newly documented aliases (verified against MODEL_REGISTRY / resolve_model_alias):

Alias Resolves To Provider Auth env var
grok, grok-3 grok-3 xAI XAI_API_KEY
grok-mini, grok-3-mini grok-3-mini xAI XAI_API_KEY
grok-2 grok-2 xAI XAI_API_KEY
kimi kimi-k2.5 DashScope (OpenAI-compatible) DASHSCOPE_API_KEY

Why it's correct

Everything added is verifiable in the source, not invented:

  • resolve_model_alias() maps grok/grok-3grok-3, grok-mini/grok-3-mini
    grok-3-mini, grok-2grok-2, and kimikimi-k2.5.
  • MODEL_REGISTRY sets the auth/base-url env vars for each provider:
    xAI → XAI_API_KEY / XAI_BASE_URL, Kimi → DASHSCOPE_API_KEY /
    DASHSCOPE_BASE_URL.
  • Case-insensitivity: resolve_model_alias lowercases input before matching, and
    existing tests assert this (kimi_alias_resolves_to_kimi_k2_5 checks "KIMI",
    resolves_grok_aliases checks the grok family).
  • Provider diagnostics already point users at these aliases (e.g. the hint to
    "use an xAI model alias such as --model grok"), and docs/MODEL_COMPATIBILITY.md
    documents the corresponding request handling — this PR just surfaces the aliases
    where they are listed.

Scope

Docs-only change to rust/README.md. No code or behavior changes. The existing
opus/sonnet/haiku rows are unchanged.

@1716775457damn

Copy link
Copy Markdown

Good catch — the model aliases table was indeed incomplete. Having the full alias set documented alongside the Provider and Auth env var columns makes it much more actionable for users. The case-insensitivity note is also a helpful detail.

@simawulei

simawulei commented Jul 10, 2026 via email

Copy link
Copy Markdown

@nankingjing

Copy link
Copy Markdown
Author

Thanks for the quick review, @1716775457damn! Glad the Provider / Auth-env columns are useful. I noticed a couple of other small doc nits while in there (a broken link and an out-of-date crate count) and have a follow-up PR incoming, kept separate to keep this one focused.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants