Skip to content

Commit

Permalink
Merge pull request axolotl-ai-cloud#272 from OpenAccess-AI-Collective…
Browse files Browse the repository at this point in the history
…/model-revision

support for loading a model by git revision
  • Loading branch information
winglian authored Jul 14, 2023
2 parents e428d5f + b62e8ec commit dd73b6a
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 dd73b6a

Please sign in to comment.