fix: correct lora_alpha value in Chapter 12 LoRA configuration#114
Open
octo-patch wants to merge 1 commit into
Open
fix: correct lora_alpha value in Chapter 12 LoRA configuration#114octo-patch wants to merge 1 commit into
octo-patch wants to merge 1 commit into
Conversation
…andsOnLLM#82) The lora_alpha parameter was set to 32 while r (rank) was set to 64. The recommended practice is to set lora_alpha to approximately twice the value of r (i.e., 128 when r=64), as confirmed by the maintainer. Updated both LoraConfig instances in cells 11 and 26.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #82
Problem
In the Chapter 12 notebook, the
LoraConfigsetsr=64(rank) butlora_alpha=32(scaling). The common recommendation is to setlora_alphato approximately twice the value ofr. Withr=64,lora_alphashould be128, not32. This was confirmed as a typo by the maintainer in the issue thread.Solution
Updated
lora_alphafrom32to128in bothLoraConfiginstances (cells 11 and 26) in the Chapter 12 notebook, aligning the value with the standard LoRA convention (lora_alpha ≈ 2 * r).Testing
Verified the change is applied consistently in both LoRA configuration blocks within the notebook.