ChatFiles
ChatFiles copied to clipboard
解析文件功能开发了吗
It's straightforward, using low-rank approximation, low-rank matrix factorization.
Given a model and its fine-tuning, and a target rank $k$, extract the "best" low-rank approximation to each difference in the model weights, and export as LoRA.
The parameter $k$ can be a constant or can be unique to each matrix, e.g. $k_i$ for $W_i \in \Theta$
To summarize, given $W' - W = \Delta W$, find $\hat{A},\hat{B}$ each with $k$ rows such that the norm $||\hat{A}^T\hat{B} - \Delta W||_2$ is minimized.