-
Notifications
You must be signed in to change notification settings - Fork 16
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
➕ Install peft for prompt adapter support #124
Conversation
Skipping CI for Draft Pull Request. |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: prashantgupta24 The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/retest |
New changes are detected. LGTM label has been removed. |
Signed-off-by: Prashant Gupta <[email protected]>
Signed-off-by: Prashant Gupta <[email protected]>
@@ -180,6 +180,10 @@ RUN --mount=type=cache,target=/root/.cache/pip \ | |||
--mount=type=cache,target=/root/.cache/uv \ | |||
uv pip install https://github.com/flashinfer-ai/flashinfer/releases/download/v0.1.2/flashinfer-0.1.2+cu121torch2.4-cp311-cp311-linux_x86_64.whl | |||
|
|||
# Install peft for prompt adapter support |
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.
Sorry if I get back to this, but I just realized this is something which is only supported in the adapter, right? In that case this should be a dependency in vllm-tgis-adapter
and not something installed here.
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.
This is something that is needed by vllm explicitly -
vllm/vllm/prompt_adapter/models.py
Line 93 in 7a21f52
from peft.utils import load_peft_weights |
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.
Also see these lines within PromptAdapterConfig
:
Lines 1334 to 1340 in 7a21f52
library_name = 'peft' | |
try: | |
__import__(library_name) | |
except ImportError as e: | |
raise ImportError( | |
f"'{library_name}' is not installed for prompt adapter support." | |
f"Please install it using 'pip install {library_name}'." |
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 can confirm that this is needed to run the upstream unit tests.
Will try to get it merged in upstream https://github.com/vllm-project/vllm/pull/8123/files |
* add memory clean up after every shape and parameter to reduce cache invalidation buffers * small typo * syntax change --------- Co-authored-by: maleksan85 <[email protected]>
For allowing PEFT adapters to be loaded, we will need the
peft
library installed.Upstream PR: vllm-project#8123