Skip to content

[Rust Frontend] Return model metadata fields in /v1/models#45950

Merged
BugenZhao merged 3 commits into
vllm-project:mainfrom
tahsintunan:rust/models-metadata-parity
Jun 18, 2026
Merged

[Rust Frontend] Return model metadata fields in /v1/models#45950
BugenZhao merged 3 commits into
vllm-project:mainfrom
tahsintunan:rust/models-metadata-parity

Conversation

@tahsintunan

Copy link
Copy Markdown
Contributor

Purpose

The Rust frontend's GET /v1/models returned only id, object, created, and owned_by, dropping the vLLM extension fields the Python frontend includes on each model card. Most visibly, it omitted max_model_len. This brings the Rust /v1/models response into parity with the Python frontend so it stays a drop-in replacement.

This was an unlisted gap (not on the #44280 roadmap); /v1/models itself was already implemented, and the data was already available to the route.

Changes

  • Add root, parent, and max_model_len to the /v1/models model card, plus a real request-time created (it was hardcoded to 0).
  • Fill base-model cards and LoRA adapter cards with the correct per-card values, matching the Python frontend: base cards carry max_model_len and root = model path. LoRA cards carry root = adapter path, parent = base model, and max_model_len = null.
  • List LoRA adapters in load order (the LoRA registry now preserves insertion order), matching Python's insertion-ordered registry.

Notes

  • permission is intentionally omitted. Python emits a permission: [ModelPermission()] array, but modern OpenAI removed permission from its /v1/models schema (the official SDK Model type has no such field). Omitting it keeps the response aligned with the current OpenAI spec.
Signed-off-by: Tahsin Tunan <tahsintunan@gmail.com>
Signed-off-by: Tahsin Tunan <tahsintunan@gmail.com>
@BugenZhao

Copy link
Copy Markdown
Member

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Delightful!

Reviewed commit: fe4e81ecc4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@BugenZhao BugenZhao left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@BugenZhao BugenZhao added the ready ONLY add when PR is ready to merge/full CI is needed label Jun 18, 2026
@BugenZhao BugenZhao enabled auto-merge (squash) June 18, 2026 05:54
@BugenZhao BugenZhao merged commit 7299e65 into vllm-project:main Jun 18, 2026
23 checks passed
@tahsintunan tahsintunan deleted the rust/models-metadata-parity branch June 18, 2026 10:30
djramic pushed a commit to djramic/vllm that referenced this pull request Jun 18, 2026
divineearthly pushed a commit to divineearthly/vllm that referenced this pull request Jun 19, 2026
…ect#45950)

Signed-off-by: Tahsin Tunan <tahsintunan@gmail.com>
Signed-off-by: divineearthly <divineearthly@gmail.com>
xuebwang-amd pushed a commit to xuebwang-amd/vllm that referenced this pull request Jun 21, 2026
tunglinwood pushed a commit to tunglinwood/vllm that referenced this pull request Jun 22, 2026
nkzhenhua pushed a commit to nkzhenhua/vllm that referenced this pull request Jun 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ready ONLY add when PR is ready to merge/full CI is needed rust

2 participants