-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Add RWKV LoRA defaults and opt-in test #2810
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
Add RWKV LoRA defaults and opt-in test #2810
Conversation
BenjaminBossan
left a comment
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 adding default target modules for RWKV. I have some comments, please take a look.
README.md
Outdated
| # prints something like: Preheat the oven to 350 degrees and place the cookie dough in a baking dish [...] | ||
| ``` | ||
|
|
||
| > [!NOTE] |
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.
IMO this README entry can be removed, as we generally don't highlight individual models here.
tests/test_rwkv_lora.py
Outdated
| @@ -0,0 +1,49 @@ | |||
| # Copyright 2025-present the HuggingFace Inc. team. | |||
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.
There isn't really a need to add this test here, we don't have tests just to ensure that the default target modules are being set. I did, however, confirm that the test passes locally.
I could see an argument to add it to the general test suite, since RWKV has a different architecture:
peft/tests/test_decoder_models.py
Lines 56 to 66 in 815956b
| PEFT_DECODER_MODELS_TO_TEST = [ | |
| "hf-internal-testing/tiny-random-OPTForCausalLM", | |
| "hf-internal-testing/tiny-random-GPT2LMHeadModel", | |
| "hf-internal-testing/tiny-random-BloomForCausalLM", | |
| "hf-internal-testing/tiny-random-gpt_neo", | |
| "hf-internal-testing/tiny-random-GPTJForCausalLM", | |
| "hf-internal-testing/tiny-random-GPTBigCodeForCausalLM", | |
| "trl-internal-testing/tiny-random-LlamaForCausalLM", | |
| "peft-internal-testing/tiny-dummy-qwen2", | |
| "hf-internal-testing/tiny-random-Gemma3ForCausalLM", | |
| ] |
However, at the moment, the PEFT CI is already stressing the rate limit of HF Hub, so adding yet another model would not be a good idea. I think that if this situation relaxes and if we find that there is a big demand for RWKV finetuning with PEFT, we can consider that option.
|
gentle ping @nirbo |
|
Sorry for the delay, been busy and this slipped my mind. |
|
The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update. |
BenjaminBossan
left a comment
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 adding default target modules for RWKV, LGTM. The failing test is unrelated.
Summary
Testing