rasbt-LLMs-from-scratch/ch07
2025-06-27 19:28:56 -05:00
..
01_main-chapter-code Use test mode arg in ch07 (#713) 2025-06-27 19:28:56 -05:00
02_dataset-utilities fix typos, add codespell pre-commit hook (#264) 2024-07-16 07:07:04 -05:00
03_model-evaluation Uv workflow improvements (#531) 2025-02-16 13:16:51 -06:00
04_preference-tuning-with-dpo Dpo vocab size clarification (#628) 2025-04-18 17:20:56 -05:00
05_dataset-generation Uv workflow improvements (#531) 2025-02-16 13:16:51 -06:00
06_user_interface Add PyPI package (#576) 2025-03-23 19:28:49 -05:00
README.md Update pixi (#661) 2025-06-13 10:50:17 -05:00

Chapter 7: Finetuning to Follow Instructions

 

Main Chapter Code

 

Bonus Materials

  • 02_dataset-utilities contains utility code that can be used for preparing an instruction dataset
  • 03_model-evaluation contains utility code for evaluating instruction responses using a local Llama 3 model and the GPT-4 API
  • 04_preference-tuning-with-dpo implements code for preference finetuning with Direct Preference Optimization (DPO)
  • 05_dataset-generation contains code to generate and improve synthetic datasets for instruction finetuning
  • 06_user_interface implements an interactive user interface to interact with the pretrained LLM


Link to the video