Skip to content

Commit

Permalink
Merge pull request #272 from OpenAccess-AI-Collective/model-revision
Browse files Browse the repository at this point in the history
support for loading a model by git revision
  • Loading branch information
winglian authored Jul 14, 2023
2 parents fb48ad7 + 6130022 commit e1290d5
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/axolotl/utils/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ def load_model(
)

model_kwargs = {}
if cfg.model_revision:
model_kwargs["revision"] = cfg.model_revision
if cfg.adapter == "qlora" and cfg.load_in_4bit:
model_kwargs["quantization_config"] = BitsAndBytesConfig(
load_in_4bit=True,
Expand Down

0 comments on commit e1290d5

Please sign in to comment.