guide LLM lora

After 500+ LoRAs made, here is the secret

(a reprint of my article posted on reddit)

Well, you wanted it, here it is:

The quality of dataset is 95% of everything. The rest 5% is not to ruin it with bad parameters.

Yeah, I know, GASP! No seriously, folks are searching for secret parameters or secret sauce - but this is the whole deal.

And I mean crystal clean dataset. Yes, I know, thousands of items (maybe tens of thousands), generated or scrubbed from internet, who has time to look at it. I see it in "pro" dataset. Look at some random items, and soon you will spot a garbage - because it was obviously generated or scrubbed and never really checked. What's a few rotten eggs, right? Well, it will spoil the whole bunch as grandma Pam said.

Once I started manually checking the dataset and removing or changing the garbage the quality jumped 10-fold. Yes, it takes a huge amount of time - but no matter of parameters or tricks will fix this, sorry.

The training parameters are there not to ruin it - not make it better, so you don't have to chase the perfect LR 2.5647e-4 it doesn't exist. You kind of aim for the right direction and if dataset is great, most of the time you'll get there.

Some more notes:

Anything else?

Oh, OK, I was talking about LORA for LLM, but it surely applies to SD as well. In fact it's all the same thing (and hence PEFT can be used for both and the same rules apply)