-
-
Notifications
You must be signed in to change notification settings - Fork 7.8k
[Feature] specify model in config.yaml #14855
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
Conversation
👋 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 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 🚀 |
Signed-off-by: weizeng <[email protected]>
tests/test_utils.py
Outdated
def test_model_specification(parser_with_config): | ||
# Test model in CLI takes precedence over config | ||
args = parser_with_config.parse_args([ | ||
'serve', 'cli-model', '--config', './data/test_config_with_model.yaml' |
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.
we should make a fixture factory to get data from tests/data
in tests/conftest.py
?
eventually I think it is good to migrate most test config to that folder
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.
Hi @aarnphm, I moved the test configs fixture to tests/conftest.py, also changed the original data
folder to config
. Please let me know if any other issues. Thanks!
Signed-off-by: weizeng <[email protected]>
Signed-off-by: weizeng <[email protected]>
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.
i have one questions, otherwise it looks good to me.
# EngineArgs expects the model name to be passed as --model. | ||
args.model = args.model_tag | ||
# Check if we have a model specified somewhere | ||
if args.model == EngineArgs.model: # Still has default value |
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.
does this means vllm serve <model_name> --config config.yaml
is allowed?
imo it should be either vllm serve <opts[...]>
or vllm serve --config /path/to/yaml
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.
Good question. My thought is for backward compatibility since vllm serve <model_name> --config config.yaml
is the current conversion. It also aligns with the existing vllm doc: "In case an argument is supplied simultaneously using command line and the config file, the value from the command line will take precedence."
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.
I see, that makes sense then.
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.
The flipping of this condition from !=
to ==
has broken v1-tests
on main
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.
I have reverted the commit, sorry for merging this (V1 test was failing for other reasons on main so I missed this). Please open a new commit that addresses this failure.
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.
Hi all, I have fixed the failure and added more tests for handling --model
error in #15798. Please take a look and let me know if any more issues. Thank you!
This pull request has merge conflicts that must be resolved before it can be |
Signed-off-by: weizeng <[email protected]>
Signed-off-by: weizeng <[email protected]>
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.
Thanks for this QoL improvement!
Signed-off-by: weizeng <[email protected]>
This reverts commit 0fa3970. Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: weizeng <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: weizeng <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: weizeng <[email protected]> Signed-off-by: Louis Ulmer <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]> Signed-off-by: Louis Ulmer <[email protected]>
Signed-off-by: weizeng <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: weizeng <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]>
Signed-off-by: weizeng <[email protected]> Signed-off-by: Mu Huai <[email protected]>
…llm-project#15293) Signed-off-by: DarkLight1337 <[email protected]> Signed-off-by: Mu Huai <[email protected]>
CLOSES #14819
Run CLI:
vllm serve --config config.yaml
with model in yaml.vllm serve SOME_MODEL --config config.yaml
:model_tag
in CLI, takes precedence overmodel
in config file.Tests:
Unit tests:
Integration tests
model
in config fileCreate a test-config.yaml
Run
vllm serve --config test-config.yaml
Can start the server and run benchmark.
model_tag
in CLI, takes precedence overmodel
in config file.Create a test-config.yaml
Run
vllm serve meta-llama/Llama-3.1-8B-Instruct --config test-config.yaml
Can start the server and run benchmark.
model_tag
in CLI andmodel
in config file.