The EASIEST way to finetune LLAMA-v2 on local machine!

preview_player
Показать описание
In this video, I'll show you the easiest, simplest and fastest way to fine tune llama-v2 on your local machine for a custom dataset! You can also use the tutorial to train/finetune any other Large Language Model (LLM). In this tutorial, we will be using autotrain-advanced.

Steps:
Install autotrain-advanced using pip:
- pip install autotrain-advanced

Setup (optional, required on google colab):
- autotrain setup --update-torch

Train:
autotrain llm --train --project_name my-llm --model meta-llama/Llama-2-7b-hf --data_path . --use_peft --use_int4 --learning_rate 2e-4 --train_batch_size 12 --num_train_epochs 3 --trainer sft

Please subscribe and like the video to help me keep motivated to make awesome videos like this one. :)

Follow me on:
Рекомендации по теме
Комментарии
Автор

Anyone comes across this in 2024 (jan ), the command switches with new autotrain version is autotrain llm --train --project-name josh-ops --model --data-path . --use-peft --quantization int4 --lr 2e-4 --train-batch-size 12 --epochs 3 --trainer sft . Great, Video, thanks Abhishek

linuxmanju
Автор

Amazing, tutorials at light speed! Llama 2 was just released! 😮

AICoffeeBreak
Автор

Keeping it this simple is something very few people are able to do. Very well explained.

This can be understood by even a beginner. Atleast the execution if not the intuition behind it. Kudos

andyjax
Автор

That's Awesome, nothing better than this way of training large language model. Super easy ❤

tarungupta
Автор

Appreciate it, and request to continue making such videos🎉

tarungupta
Автор

There is only one thing I want to see. I want to see you using the final result and prove it actually works. Thank you.

YuniYoshi
Автор

Great tutorial! Can you also put up one video teaching on how to merge the fine tuned weights to the base model and do inference? Would like to see an end-to-end course. Thank you!

aaronliruns
Автор

Incredibly helpful video, I appreciate that you took the time to create this! Great stuff

WeDuMedia
Автор

As always very useful and short without wasting anyone's time. Thank you. Just I'm a bit confused about the prompt formatting you have used here - "### Instruction:\n### Input:... etc" while Llama official is "<s>[INST] <<SYS>>{{ system_prompt }}<</SYS>>{{ user_message }} [/INST]" and on TheBloke's page it says "SYSTEM: {system_prompt}\nUSER: {prompt}\nASSISTANT:"

elmuchoconrado
Автор

Deceptive use of the term “fine tuning”. What you’re doing here isn’t fine tuning. It’s “many-shot” learning in the prompt.

alexchow
Автор

The way Abhishek side eyes before stopping the video and resuming is is soo crazy 🤣🤣😅

manishsharma
Автор

Great video! Would be great if in some future vid you could go into depth on the training hyperparameters and perhaps also talk about what size your custom datasets should be.

xthefoetusx
Автор

Thank you Abhishek! This is phenomenal.

charleskarpati
Автор

Thanks for the tutorial! A couple questions for you. Is there an approach you're using to test quality and verity that the training data has influenced the weights in the model sufficiently to learn the new task? And second, can you use the same approach for unstructured training data such as using a large corpus of private data to do domain adaptation?

bryanvann
Автор

Please subscribe and like the video to help me keep motivated to make awesome videos like this one. :)

abhishekkrthakur
Автор

what kind of GPUs do you have? how big was your dataset and how long did it take to train? what is the smallest fine-tuning data set size that would be reasonable?

stevenshaw
Автор

I trained model using autotrain in same way as you suggested and model file is stored.
Now I need to use this model for prediction. Can you shed some light on this as well?

sandeelg_lite
Автор

In my experiment, it not create the [config.json] what am I doing wrong?

amx
Автор

Hi Abhishek, is the auto train using LORA or prompt tuning as the PEFT technique?

ajaytaneja
Автор

Can you make a video for fine tuning in silicon macs ?

dhruvilshah