Skip to content
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

[Core] enable out-of-tree model register #3871

Merged
merged 14 commits into from
Apr 7, 2024

Conversation

youkaichao
Copy link
Member

Usage: add three lines:

from vllm.model_executor.models import ModelRegistry
from your_code import YourModelForCausalLM
ModelRegistry.register_out_of_tree_model("YourModelForCausalLM", YourModelForCausalLM)

@njhill
Copy link
Member

njhill commented Apr 5, 2024

See also: #3820. I guess this registration approach is probably better.

@simon-mo
Copy link
Collaborator

simon-mo commented Apr 5, 2024

anyway to test this in CI?

@youkaichao
Copy link
Member Author

@simon-mo added tests in ci. PTAL.

Copy link
Collaborator

@WoosukKwon WoosukKwon left a comment

Choose a reason for hiding this comment

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

Thanks for the work! Left some comments.

vllm/model_executor/models/__init__.py Show resolved Hide resolved
docs/source/models/adding_model.rst Outdated Show resolved Hide resolved
tests/models/test_oot_registration.py Show resolved Hide resolved
Copy link
Collaborator

@WoosukKwon WoosukKwon left a comment

Choose a reason for hiding this comment

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

Awesome! Thanks for the great work!

@youkaichao youkaichao merged commit 95baec8 into vllm-project:main Apr 7, 2024
35 checks passed
@youkaichao youkaichao deleted the oot_models branch April 7, 2024 00:11
z103cb pushed a commit to z103cb/opendatahub_vllm that referenced this pull request Apr 22, 2024
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.

4 participants