-
-
Notifications
You must be signed in to change notification settings - Fork 11.8k
[Feature] Add offline FastAPI documentation support for air-gapped environments #30184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
[Feature] Add offline FastAPI documentation support for air-gapped environments #30184
Conversation
…vironments - Add --enable-offline-docs CLI flag - Use fastapi-offline for air-gapped environments when enabled - Add fastapi-offline as optional dependency - Fallback to standard FastAPI if package not installed Fixes vllm-project#29847 Signed-off-by: rickychen-infinirc <ricky.chen@infinirc.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code Review
This pull request adds support for offline FastAPI documentation by integrating the fastapi-offline package. The changes are well-implemented, introducing an optional dependency and a CLI flag to enable the feature. My review includes one high-severity suggestion to improve the warning message for when the optional dependency is not installed, ensuring users are guided to install it correctly via the package extra.
|
👋 Hi! Thank you for contributing to the vLLM project. 💬 Join our developer Slack at https://slack.vllm.ai to discuss your PR in #pr-reviews, coordinate on features in #feat- channels, or join special interest groups in #sig- channels. Just a reminder: PRs would not trigger full CI run by default. Instead, it would only run You ask your reviewers to trigger select CI tests on top of Once the PR is approved and ready to go, your PR reviewer(s) can run CI to test the changes comprehensively before merging. To run CI, PR reviewers can either: Add If you have any questions, please reach out to us on Slack at https://slack.vllm.ai. 🚀 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Codex has been enabled to automatically 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 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
- Update install instruction to use vllm[offline] - Remove optional-dependencies from dynamic fields Signed-off-by: rickychen-infinirc <ricky.chen@infinirc.com>
Summary
This PR adds support for offline FastAPI documentation (
/docs) in air-gapped environments by integrating thefastapi-offlinepackage.When used on an air-gapped system, FastAPI documentation route (
/docs) is not accessible because it requires pulling static content from the internet. This route is very useful because it is both documentation and a simple way to send requests to the server, easing integration of vLLM into systems.This PR adds the
--enable-offline-docsCLI flag which usesfastapi-offlineto bundle static assets locally.Fixes #29847
Changes
--enable-offline-docsCLI flag toFrontendArgsfastapi-offlinefor air-gapped environments when enabledfastapi-offlineas optional dependency inpyproject.toml