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

Lora syncer docs #320

Merged
merged 13 commits into from
Feb 14, 2025
Merged

Lora syncer docs #320

merged 13 commits into from
Feb 14, 2025

Conversation

coolkp
Copy link
Contributor

@coolkp coolkp commented Feb 11, 2025

Fixes issue #303 .

  • Add a make file to lora syncer and a cloud build file to automatically create and publish the image
  • Update the guide to incorporate the lora syncer

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Feb 11, 2025
@k8s-ci-robot k8s-ci-robot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Feb 11, 2025
@k8s-ci-robot
Copy link
Contributor

Hi @coolkp. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Feb 11, 2025
Copy link

netlify bot commented Feb 11, 2025

Deploy Preview for gateway-api-inference-extension ready!

Name Link
🔨 Latest commit 277125c
🔍 Latest deploy log https://app.netlify.com/sites/gateway-api-inference-extension/deploys/67afb18c7477390008ee1b6d
😎 Deploy Preview https://deploy-preview-320--gateway-api-inference-extension.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Feb 12, 2025
@ahg-g
Copy link
Contributor

ahg-g commented Feb 12, 2025

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Feb 12, 2025
@ahg-g
Copy link
Contributor

ahg-g commented Feb 12, 2025

I don't think you uploaded the guide

@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Feb 12, 2025
@coolkp coolkp force-pushed the lora-syncer-docs branch 2 times, most recently from e16a3ee to 9efc096 Compare February 12, 2025 16:22
Comment on lines 46 to 57
- "sql-lora=/adapters/hub/models--yard1--llama-2-7b-sql-lora-test/snapshots/0dfa347e8877a4d4ed19ee56c140fa518470028c/"
- "tweet-summary=/adapters/hub/models--vineetsharma--qlora-adapter-Llama-2-7b-hf-TweetSumm/snapshots/796337d8e866318c59e38f16416e3ecd11fe5403"
- 'sql-lora-0=/adapters/yard1/llama-2-7b-sql-lora-test_0'
- 'sql-lora-1=/adapters/yard1/llama-2-7b-sql-lora-test_1'
- 'sql-lora-2=/adapters/yard1/llama-2-7b-sql-lora-test_2'
- 'sql-lora-3=/adapters/yard1/llama-2-7b-sql-lora-test_3'
- 'sql-lora-4=/adapters/yard1/llama-2-7b-sql-lora-test_4'
- 'tweet-summary-0=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_0'
- 'tweet-summary-1=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_1'
- 'tweet-summary-2=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_2'
- 'tweet-summary-3=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_3'
- 'tweet-summary-4=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_4'
Copy link
Contributor

@ahg-g ahg-g Feb 12, 2025

Choose a reason for hiding this comment

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

I would remove those and leave the two that the inferenceModel.yaml have, tweet-summary-0 and tweet-summary-1:

  • 'tweet-summary-0=vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm'
  • 'tweet-summary-1=vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm'

Comment on lines 168 to 153
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v1
source: yard1/llama-2-7b-sql-lora-test
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v3
source: yard1/llama-2-7b-sql-lora-test
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v4
source: yard1/llama-2-7b-sql-lora-test
Copy link
Contributor

Choose a reason for hiding this comment

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

keep only tweet-summary-0 and 1:
- base-model: meta-llama/Llama-2-7b-hf
id: tweet-summary-0
source: vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm
- base-model: meta-llama/Llama-2-7b-hf
id: tweet-summary-1
source: vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm

Copy link
Contributor

Choose a reason for hiding this comment

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

need to align this with https://github.com/kubernetes-sigs/gateway-api-inference-extension/blob/main/pkg/manifests/inferencemodel.yaml, so only keep the ones I mentioned in the comment above

@coolkp coolkp force-pushed the lora-syncer-docs branch 2 times, most recently from 8435721 to 310c5a8 Compare February 13, 2025 19:37
ensureExist:
models:
- id: chatbot-v2
source: gs://[TEAM-A-MODELS-BUCKET]/chatbot-v2
Copy link
Contributor

Choose a reason for hiding this comment

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

need to update those, lets only work with hugging face adapters, otherwise it will be hard to run through the guide

- '{"name": "tweet-summary-3", "path": "vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm", "base_model_name": "llama-2"}'
- '{"name": "tweet-summary-4", "path": "vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm", "base_model_name": "llama-2"}'
- '{"name": "sql-lora", "path": "yard1/llama-2-7b-sql-lora-test", "base_model_name": "llama-2"}'
- '{"name": "tweet-summary", "path": "vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm", "base_model_name": "llama-2"}'
Copy link
Contributor

Choose a reason for hiding this comment

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

Lets only keep tweet-summary-0 and tweet-summary-1, and in the guide we show how we add tweet-summary-2 by modifying the inferenceModel they already created.

Comment on lines 168 to 153
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v1
source: yard1/llama-2-7b-sql-lora-test
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v3
source: yard1/llama-2-7b-sql-lora-test
- base-model: meta-llama/Llama-2-7b-hf
id: sql-lora-v4
source: yard1/llama-2-7b-sql-lora-test
Copy link
Contributor

Choose a reason for hiding this comment

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

need to align this with https://github.com/kubernetes-sigs/gateway-api-inference-extension/blob/main/pkg/manifests/inferencemodel.yaml, so only keep the ones I mentioned in the comment above

Comment on lines 35 to 38
- id: tweet-summary-v1
source: tweet-summary-1=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_1
- id: tweet-summary-v2
source: tweet-summary-2=/adapters/vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm_2
Copy link
Contributor

Choose a reason for hiding this comment

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

needs to be tweet-summary-0, tweet-summary-1 (existing) and a new tweet-summary-2

Copy link
Contributor

Choose a reason for hiding this comment

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

also, to update the configmap, we can instruct the user to:

kubectl edit dynamic-lora-config

@k8s-ci-robot k8s-ci-robot added needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Feb 13, 2025
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. labels Feb 13, 2025
Comment on lines +24 to +44
```yaml
apiVersion: v1
kind: ConfigMap
metadata:
name: dynamic-lora-config
data:
configmap.yaml: |
vLLMLoRAConfig:
name: sql-loras-llama
port: 8000
ensureExist:
models:
- base-model: meta-llama/Llama-2-7b-hf
id: tweet-summary-0
source: vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm
- base-model: meta-llama/Llama-2-7b-hf
id: tweet-summary-1
source: vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm
- base-model: meta-llama/Llama-2-7b-hf
id: tweet-summary-2
source: vineetsharma/qlora-adapter-Llama-2-7b-hf-TweetSumm
Copy link
Contributor

Choose a reason for hiding this comment

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

need to close this with ```, I couldn't make a suggestion to fix that.

@ahg-g
Copy link
Contributor

ahg-g commented Feb 14, 2025

/lgtm
/approve

This is great, thanks!

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Feb 14, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: ahg-g, coolkp

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 /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 14, 2025
@k8s-ci-robot k8s-ci-robot merged commit 88c20f1 into kubernetes-sigs:main Feb 14, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants