Building with Instruction-Tuned LLMs: A Step-by-Step Guide

  Рет қаралды 48,790

DeepLearningAI

DeepLearningAI

Жыл бұрын

Welcome, to the Building with Instruction-Tuned LLMs: A Step-by-Step Guide workshop!
We will be taking questions during the event. Please submit your question or upvote others' here:
app.sli.do/event/erFLUz3s8yWh...
Speakers
Dr. Greg Loughnane, Head of Product & Curriculum at FourthBrain
/ gregloughnane
Chris Alexiuk, is an LLM Instructor at FourthBrain
/ csalexiuk
Let us know how we're doing? We will be giving out discount codes for a selected number of people who fill out the survey:
forms.gle/qzBWfovxPTLPeVRN6
Looking to connect with your peer learners, share projects, and swap advice? Join our AI community:
community.deeplearning.ai/inv...
To learn more about us and signup for future events:
www.deeplearning.ai/events/

Пікірлер: 58
@steveking5858
@steveking5858 Жыл бұрын
Great session. Really helps in starting to understand the key building blocks and considerations required to do model fine-tuning. Great job Chris and Greg - and thanks!
@christopheprotat
@christopheprotat 11 ай бұрын
This is a very very educational content. I found most of all my main questions answered. Fantastic wrap up. Thank you guys
@prizmaweb
@prizmaweb Жыл бұрын
Outstanding! I was looking around for exactly this for the last week.
@fabianaltendorfer11
@fabianaltendorfer11 10 ай бұрын
Love the energy. Thanks for the session!
@chukypedro818
@chukypedro818 Жыл бұрын
Awesome Webinar. Thanks Chris an Greg
@fal57
@fal57 10 ай бұрын
Thank you so much; you've made the idea very simple.
@wangsherpa2801
@wangsherpa2801 Жыл бұрын
Excellent session, thanks!
@archit_singh15
@archit_singh15 6 ай бұрын
such excellent explanations, perfect understanding achieved ! thanks
@RaymonddeLacaze
@RaymonddeLacaze Жыл бұрын
That was an excellent presentation. I feel like I learned a lot. I am frequently disappointed by these 1-hr webinars. I really appreciated the way both of you complemented each other. It was great to get the top-level view and Chris did a great job of walking through the code. He moved understandably a bit fast so it was hard to ingest all the code which is normal, and then I really appreciated Greg giving a recap and the take always of what Chris had demoed. It really helped me retain something constructive the code demo. All in all I think you both did a great job. Thank you for doing this. I would love to get a copy of the slides and the code that was demoed to walk through it at my own pace and try it out. Will you guys be making the slides and code available?
@Deeplearningai
@Deeplearningai Жыл бұрын
We'll be following up with the slides!
@Jyovita1047316
@Jyovita1047316 Жыл бұрын
@@Deeplearningai when?
@productivitylaunchpad
@productivitylaunchpad Жыл бұрын
you can find a link to the slides in the chat around the 45 min mark in the video.
@seyedmohammadseyedmahdi8913
@seyedmohammadseyedmahdi8913 Жыл бұрын
thanks!
@llohannsperanca
@llohannsperanca Жыл бұрын
Dears, great presentation! Thank you very much! I wonder where the material will be available?
@user-pn7jh5xr3n
@user-pn7jh5xr3n Жыл бұрын
magnifico
@membershipyuji
@membershipyuji Жыл бұрын
The session was great and informative. For the 2nd part, I would like to see inference results before fine-tuning as well. The bloomz is instructed-tuned already and might be good at writing marketing email even before feeding 16 examples.
@temp_temp3183
@temp_temp3183 Жыл бұрын
100% agree, it wasn't clear what was the value add with unsupervised training.
@chrisalexiuk
@chrisalexiuk Жыл бұрын
Great question! If you load up the model without the fine-tuning, you will see that it does "fine" on the task - but that it doesn't achieve the same "style" as we're training with the unsupervised fine-tuning. You can imagine it as more of an extension of pre-training - which uses a largely unsupervised process.
@anujanand6
@anujanand6 9 ай бұрын
That was a great presentation! Brief yet clear and to the point! I have a question on the make_inference function - based on the code, both the outputs (the good and bad) seem to be coming from the same fine tuned model. In the inference function, the good outputs are from 'base_model' and bad outputs are from 'model'. But the base_model is the model that was finetuned and pushed to the hub, and later we import that model and store it in the object 'model'. The only difference seems to be that the max_new_tokens is lesser when predicting the bad outputs. Please correct me if I'm wrong. Thanks!
@amortalbeing
@amortalbeing 4 ай бұрын
Thanks a lot. really appreciate it. To what extend quantizing affects the training? or the output of the model in terms of the generation capabilities? does it dumb it down ? does it affect the loss?
@seulkeelee4655
@seulkeelee4655 11 ай бұрын
Thanks for the great session! Only one question... I tried the supervised instruct-tuning exactly the same. After the training is complete, I tried to push the model to the hub. But I got an error message: "NotImplementedError: You are calling `save_pretrained` on a 4-bit converted model. This is currently not supported." But you seemed to have no issue with pushing. Do you have any insight? Any advice? Thank you!
@MS-en7el
@MS-en7el 11 ай бұрын
Hi! Thank you for the valuable content! Although I still have a question. @chrisalexiuk Do I correctly assume that in both cases (instruct tuning and "unsupervised" fine-tuning) the model during the training (tuning) phase actually performs the next token prediction task and calculates loss based on that (as in typical autoregressive training of decoder) ? My point is that in both cases we simply create the text input in different formats (e.g., input combined with response [or target] in the first case) and we pass it through the base model. Is there any crucial "technical" difference underneath in presented cases?
@karrtikiyer1987
@karrtikiyer1987 10 ай бұрын
Thanks for the nice tutorial. How do you create a custom dataset for the second part (single task unsupervised learning)? Say I have bunch of documents, is there some framework or library available to create a single task dataset for unsupervised learning?
@akibulhaque8621
@akibulhaque8621 5 ай бұрын
For the supervised instruction set can i use any model? Like a Lliama 2 base model and train it?
@pec8377
@pec8377 8 ай бұрын
Your first model is repeating itself, does tons of weird things. What would you do in order to correct this ? More steps ? Larger dataset ?
@MrLahcenDZ
@MrLahcenDZ Жыл бұрын
I think there's an error in the formatting_func, it's not example.get("input", "") but example.get("context", "") since the key I assume is context.. so in your case the function will always go to the else part, and all the data will be formatted as only instruction and response, never with a context, or maybe I'm missing something..
@chrisalexiuk
@chrisalexiuk Жыл бұрын
Excellent catch! This is a relic of trying it out on a few different datasets! It should be updated as of now.
@user-bg2yo8uq1k
@user-bg2yo8uq1k 9 ай бұрын
@chris - I wanted to finetune llama model on my mac M1but it seems bitsandbytes does not have package for Apple silicon yet. Any suggestions ?
@androide551
@androide551 Жыл бұрын
wen slides sir?
@fox_trot
@fox_trot Жыл бұрын
Will you guys be making the slides and code available?
@ShyamSunderKumarNITD
@ShyamSunderKumarNITD Жыл бұрын
they have said they will share that in a mail.
@fox_trot
@fox_trot Жыл бұрын
@@ShyamSunderKumarNITD thank you
@jeremiahnwosu4929
@jeremiahnwosu4929 Жыл бұрын
Has this mail been sent?
@ShyamSunderKumarNITD
@ShyamSunderKumarNITD Жыл бұрын
Did not received yet.
@ChiliJ
@ChiliJ Жыл бұрын
If I'm looking to teach the LLM a new programming language, should I go with instruction tuning or fine tuning?
@chrisalexiuk
@chrisalexiuk Жыл бұрын
Fine-tuning will likely have the best results!
@ChiliJ
@ChiliJ Жыл бұрын
@@chrisalexiuk thank you for being responsive. Got to check out your channel as well. Very informative!
@amortalbeing
@amortalbeing 4 ай бұрын
Where are the slides? I want to read the paper suggested at 30:10 . What am I supposed to do ? Thanks a lot in advance
@bhaveshsethi6876
@bhaveshsethi6876 Жыл бұрын
@chris Alexiuk how did you push 4 bit model to hugging face
@weizhili6732
@weizhili6732 Жыл бұрын
I got the same error today: NotImplementedError: You are calling `save_pretrained` on a 4-bit converted model. This is currently not supported
@bhaveshsethi6876
@bhaveshsethi6876 Жыл бұрын
​@@weizhili6732I had searched it it can't be saved and loading the 4 bit require more GPU so go with the same process again and again
@chrisalexiuk
@chrisalexiuk Жыл бұрын
Hey! You'll just want to save and push the adapter - I'll modify the notebook to a format that includes that process. You can expect that to be push tomorrow!
@ashwinrachha1694
@ashwinrachha1694 Жыл бұрын
I tried Intruction-Tuning on a custom dataset and got this error: ValueError: num_samples should be a positive integer value, but got num_samples=0
@chrisalexiuk
@chrisalexiuk Жыл бұрын
This has been corrected in the notebook now, there were some changes to the libraries that cause a few errors.
@ShyamSunderKumarNITD
@ShyamSunderKumarNITD Жыл бұрын
@@chrisalexiuk From where i can access the notebook.
@ashishsharma-fy7ox
@ashishsharma-fy7ox 9 ай бұрын
I get this error when I try to push it hub - NotImplementedError: You are calling `save_pretrained` on a 4-bit converted model. This is currently not supported . Has anyone seen this error ?
@Pouya..
@Pouya.. 2 ай бұрын
are these notebooks available?
@paparaoveeragandham284
@paparaoveeragandham284 Ай бұрын
Look it
@prayagpurohit148
@prayagpurohit148 8 ай бұрын
Hey guys, I come from a non-data-science background and trying to automate a task. I want to automate the task of giving feedback to students. Howver, I am having a hard time coming up the logic for fine tuning. If anyone is interested in helping me out (please do), please reply to this comment. I'll give you more context about the problem if you decide to help me (please do)
@fintech1378
@fintech1378 7 ай бұрын
i finetuned Llama 2 on colab but it says CUDA run out of memory, what is the problem here? cuz video says its possible
@ashishsharma-fy7ox
@ashishsharma-fy7ox 9 ай бұрын
I am using openlm-research/open_llama_7b_v2 . The training starts with loss around 1.26 and after 5K steps , the loss goes down to 1.02 . I am not sure why the numbers are so different from the presentation and model is learning very slowly. Any suggestions ?
@user-rh3cy6xf3v
@user-rh3cy6xf3v Жыл бұрын
@Chris Alexiuk I am getting this WARNING:accelerate.utils.modeling:The model weights are not tied. Please use the `tie_weights` method before using the `infer_auto_device` function.
@chrisalexiuk
@chrisalexiuk Жыл бұрын
On which notebook is this occuring?
@user-rh3cy6xf3v
@user-rh3cy6xf3v Жыл бұрын
@@chrisalexiuk google colab
@chrisalexiuk
@chrisalexiuk Жыл бұрын
@@user-rh3cy6xf3v Is it in the Supervised Fine-tuning notebook?
@user-rh3cy6xf3v
@user-rh3cy6xf3v Жыл бұрын
@@chrisalexiuk yes sir
@chrisalexiuk
@chrisalexiuk Жыл бұрын
@@user-rh3cy6xf3v Hey! Sorry for the late reply, I don't wind up getting notifications on these comments: I didn't encounter this issue - could you send me a copy of your notebook?
Effective Instruction Tuning: Data & Methods
13:17
Shayne Longpre
Рет қаралды 4,6 М.
Finetuning Open-Source LLMs
20:05
Sebastian Raschka
Рет қаралды 28 М.
New Gadgets! Bycycle 4.0 🚲 #shorts
00:14
BongBee Family
Рет қаралды 18 МЛН
$10,000 Every Day You Survive In The Wilderness
26:44
MrBeast
Рет қаралды 137 МЛН
Which one of them is cooler?😎 @potapova_blog
00:45
Filaretiki
Рет қаралды 8 МЛН
The day of the sea 🌊 🤣❤️ #demariki
00:22
Demariki
Рет қаралды 46 МЛН
How ChatGPT is Trained
13:43
Ari Seff
Рет қаралды 517 М.
Fine-tuning Large Language Models (LLMs) | w/ Example Code
28:18
Shaw Talebi
Рет қаралды 251 М.
What is Prompt Tuning?
8:33
IBM Technology
Рет қаралды 171 М.
Prompt Engineering, RAG, and Fine-tuning: Benefits and When to Use
15:21
Fine-tuning LLMs with PEFT and LoRA
15:35
Sam Witteveen
Рет қаралды 113 М.
Understanding 4bit Quantization: QLoRA explained (w/ Colab)
42:06
code_your_own_AI
Рет қаралды 37 М.
Instruction Tuning (Natural Language Processing at UT Austin)
5:50
Greg Durrett
Рет қаралды 2,1 М.
🍁 СЭР ДА СЭР
0:10
Ка12 PRODUCTION
Рет қаралды 2,9 МЛН
Каха ограбил банк
1:00
К-Media
Рет қаралды 3,2 МЛН
Ultra Meme Mashaa 😱😱😱 (Animation Meme) #memeanimation
0:10
Канапе 🍢
0:43
Сан Тан
Рет қаралды 6 МЛН
Разрезанный Человек 🤯
0:31
MovieLuvsky
Рет қаралды 9 МЛН
☺ Неожиданная встреча спустя полгода
0:27
Мария Шортс
Рет қаралды 4,3 МЛН