Skip to content

Commit

Permalink
Update readme
Browse files Browse the repository at this point in the history
  • Loading branch information
EricLBuehler committed Sep 13, 2023
1 parent ba5630b commit 400067a
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ All conversions are done as implemented in HuggingFace's official LoRA implement

Specifically, `candle-lora` is able to convert `Linear`, `Conv1d`, `Conv2d`, and `Embedding` into their respective LoRA counterparts. To improve inference performance, both merging and unmerging LoRA weights are also implemented.

## Ergonomics
Because swapping out and selecting layers is tedious and can be error-prone for medium to large models, I am developing a library that automates the process: [`candle-lora-macro`](https://github.com/EricLBuehler/candle-lora-macro).

## How to use
1) In your model structs, replace any concrete `Linear`, `Conv1d`, `Conv2d`, or `Embedding` types with `Box<dyn ...LayerLike>`. This will allow `candle-lora` to
Expand All @@ -20,7 +18,8 @@ generate new layers that can easily be swapped out without forcing you to redefi
3) Swap out the layers.
4) Enjoy your new LoRA model!

The latter 2 items may be combined into a single macro.
## candle-lora-macro
Because swapping out and selecting layers is tedious and can be error-prone for medium to large models, I am developing a [crate](https://github.com/EricLBuehler/candle-lora-macro) that automates the process.

## Example
```rust
Expand Down

0 comments on commit 400067a

Please sign in to comment.