Optimizing low-rank adaptation with decomposed matrices and adaptive rank allocation