I cover fine-tuning of language models to return *structured responses*, e.g. to return function calls, json objects or arrays. Lecture notes here: https://colab.research.google.com/drive/1KBBQoaJIWmqoDFW6C-lICGVW-lz2ahtD?usp=sharing
Fine-tuning for tone or style? https://www.youtube.com/watch?v=Nbyz3PRsQgo
*Basic Training Google Colab Notebook (FREE)*
Access the Google Colab script here: https://colab.research.google.com/drive/1uMSS1o_8YOPyG1X_4k6ENEE3kJfBGGhH?usp=sharing
*ADVANCED Training Notebook for Structured Responses (PAID)*
- Includes a prompt loss-mask and stop token for improved performance.
Learn more: https://trelis.com/function-calling/
*Advanced Fine-tuning Repo Access - incl. 5+ advanced notebooks*
Learn more here: https://trelis.com/advanced-fine-tuning-scripts/
1. Fine-tuning for structured responses
2. Supervised fine-tuning (best for training "chat" models)
3. Unsupervised fine-tuning (best for training "base" models)
4. Embeddings generation and usage (alternative to fine-tuning)
*Function Calling Dataset*
- Function calling dataset: https://huggingface.co/datasets/Trelis/function_calling_v3
*Out-of-the-box Llama 2 with Function Calling*
- Llama 70b, 34b (code llama), 13b, 7b: https://huggingface.co/Trelis/Llama-2-70b-chat-hf-function-calling-v2
0:00:00 Understanding Model Size
0:03:56 Quantization
0:09:09 Loading and Setting Up a Training Notebook
0:15:26 Data Setup and Selection
0:15:52 Training Process
0:19:31 Inference and Prediction
0:23:17 Saving and Push the Model to the Hub
0:25:59 ADVANCED Fine-tuning and Attention tutorial