In this blog, i'll show you how you can train/finetune the latest phi-3 model from Microsoft on your macbook pro! You'll need an M1 or M2 mac to do

How to Finetune phi-3 on MacBook Pro

submited by
Style Pass
2024-04-24 22:30:02

In this blog, i'll show you how you can train/finetune the latest phi-3 model from Microsoft on your macbook pro! You'll need an M1 or M2 mac to do this. We will be using AutoTrain Advanced!

Note: autotrain doesnt install pytorch, torchvision etc. So, you need to install it yourself. You can create a conda environment and install these dependencies:

AutoTrain not only offers LLM finetuning but many other tasks such as text classification, image classification, dreambooth lora, etc. But in this blog post, we are looking into LLM finetuning.

The next step is grabbing the data. In this blog I'm going to show you how you can train on your macbook with SFT training and ORPO tuning (the big but small brother of DPO).

you can use AutoTrain's chat-template parameter. We will see it later in this post, but for ORPO training. So, we will cover SFT training using pre-formatted dataset and do ORPO training with chat template.

With AutoTrain, only creating or finding the dataset will be the most time consuming part. Now, when we have the dataset, we can do a SFT training using:

Leave a Comment