120 Commits

Author SHA1 Message Date
Sebastian Raschka
ddbaf0d83e
Use test mode arg in ch07 (#713) 2025-06-27 19:28:56 -05:00
Sebastian Raschka
3dfd7e5f06
Update pixi (#661)
* Llama3 from scratch improvements

* Update HF hub version in pixi.toml

* Update README.md
2025-06-13 10:50:17 -05:00
Greg Gandenberger
7632eb018b
Update ch07.ipynb (#643)
Correct function name
2025-06-13 08:17:10 -05:00
Sebastian Raschka
adaf4faaae
Dpo vocab size clarification (#628)
* Llama3 from scratch improvements

* vocab size should be 50257 not 50256

* restore
2025-04-18 17:20:56 -05:00
casinca
1b242d01a5
Minor DPO fixes (#617)
* minor dpo fixes

* Update dpo-from-scratch.ipynb

metadata diff
2025-04-16 12:56:49 -05:00
Sebastian Raschka
92b308e512
Ch06 and Ch07 videos (#613)
* Ch06 and Ch07 videos

* exclude google scholar from link checking
2025-04-12 14:51:02 -05:00
PRASHANTH REDDY NIMMAKAYALA
74b9f1fcde
fix: typo in ch07.ipynb (#612) 2025-04-12 10:29:53 -05:00
Sebastian Raschka
c21bfe4a23
Add PyPI package (#576)
* Add PyPI package

* fixes

* fixes
2025-03-23 19:28:49 -05:00
Sebastian Raschka
54474fb452
Better instruction eva prompt (#571) 2025-03-15 17:13:15 -05:00
Sebastian Raschka
86b714a5e0
Specify UTF-8 encoding in the json load command explicitely (#557) 2025-03-05 11:46:21 -06:00
Sebastian Raschka
a08d7aaa84
Uv workflow improvements (#531)
* Uv workflow improvements

* Uv workflow improvements

* linter improvements

* pytproject.toml fixes

* pytproject.toml fixes

* pytproject.toml fixes

* pytproject.toml fixes

* pytproject.toml fixes

* pytproject.toml fixes

* windows fixes

* windows fixes

* windows fixes

* windows fixes

* windows fixes

* windows fixes

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix

* win32 fix
2025-02-16 13:16:51 -06:00
Sebastian Raschka
a6cc574605
Upgrade to NumPy 2.0 (#520)
* Upgrade to NumPy 2.0

* bump pytorch

* bump pytorch

* bump pytorch

* bump pytorch

* bump pytorch

* update

* update packages
2025-02-09 06:21:58 -06:00
Sebastian Raschka
9daa7e7511
Fix default argument in ex 7.2 (#506) 2025-01-25 10:46:48 -06:00
Sebastian Raschka
fd8d77a79d
A few cosmetic updates (#504) 2025-01-23 09:38:55 -06:00
Sebastian Raschka
a22d612be6
Bonus material: extending tokenizers (#496)
* Bonus material: extending tokenizers

* small wording update
2025-01-22 09:26:54 -06:00
rasbt
b524afe3da
fix reward margins plot label in dpo nb 2025-01-12 14:04:05 -06:00
Sebastian Raschka
4bfbcd069d
Auto download DPO dataset if not already available in path (#479)
* Auto download DPO dataset if not already available in path

* update tests to account for latest HF transformers release in unit tests

* pep 8
2025-01-12 12:27:28 -06:00
Sebastian Raschka
a48f9c7fe2
adds no-grad context for reference model to DPO (#473) 2025-01-07 20:49:01 -06:00
Sebastian Raschka
2d7ca7ee4b
fix ch07 unit test (#470) 2025-01-05 17:40:57 -06:00
Sebastian Raschka
701090815e
Add backup URL for gpt2 weights (#469)
* Add backup URL for gpt2 weights

* newline
2025-01-05 11:28:09 -06:00
QS
9b95557ba2
typo fixed (#468)
* typo fixed

* only update plot

---------

Co-authored-by: rasbt <mail@sebastianraschka.com>
2025-01-05 09:17:13 -06:00
Sebastian Raschka
f4ed263847
Add "What's next" section (#432)
* Add What's next section

* Delete appendix-D/01_main-chapter-code/appendix-D-Copy2.ipynb

* Delete ch03/01_main-chapter-code/ch03-Copy1.ipynb

* Delete appendix-D/01_main-chapter-code/appendix-D-Copy1.ipynb

* Update ch07.ipynb

* Update ch07.ipynb
2024-11-07 20:12:59 -06:00
Sebastian Raschka
b6c4b2f9f1
Update bonus section formatting (#400) 2024-10-12 10:26:08 -05:00
Sebastian Raschka
76e9a9ec02
Add user interface to ch06 and ch07 (#366)
* Add user interface to ch06 and ch07

* pep8

* fix url
2024-09-21 20:33:00 -05:00
rasbt
6110858d5b
Clarify API usage limits in bonus content 2024-09-15 08:05:04 -05:00
Jinge Wang
4210386cec
Fix 2 typos in 04_preferene-tuning-with-dpo (#356) 2024-09-15 07:36:22 -05:00
rasbt
f1accdf273
clarifications 2024-09-11 20:16:35 -05:00
rasbt
fe2136e7c9
update title 2024-09-10 21:43:32 -05:00
Sebastian Raschka
835ed29dbf
reflection-tuning dataset generation (#349) 2024-09-10 21:42:12 -05:00
rasbt
3760adbd3d
refresh figures 2024-08-27 08:26:40 +02:00
Sebastian Raschka
c443035d56
Note about MPS in ch06 and ch07 (#325) 2024-08-19 08:11:33 -05:00
Sebastian Raschka
9713e70a20
Consistency update in README.md 2024-08-13 07:33:10 -05:00
rasbt
06151a809e
note about logistic sigmoid 2024-08-06 19:48:30 -05:00
rasbt
26df0c474c
note about logistic sigmoid 2024-08-06 19:48:06 -05:00
rasbt
e810f9f004
extend equation description 2024-08-06 19:46:50 -05:00
rasbt
c8090f30ef
add more explanations 2024-08-06 19:45:11 -05:00
rasbt
36fbc7aa74
small figure update 2024-08-05 17:57:16 -05:00
Daniel Kleine
8318d1f002
minor DPO fixes (#298)
* fixed issues, updated .gitignore

* added closing paren

* fixed CEL spelling

* fixed more minor issues

* Update ch07/01_main-chapter-code/ch07.ipynb

* Update ch07/04_preference-tuning-with-dpo/dpo-from-scratch.ipynb

* Update ch07/04_preference-tuning-with-dpo/dpo-from-scratch.ipynb

* Update ch07/04_preference-tuning-with-dpo/dpo-from-scratch.ipynb

---------

Co-authored-by: Sebastian Raschka <mail@sebastianraschka.com>
2024-08-05 08:40:46 -05:00
rasbt
36b9d5e0eb
update model path 2024-08-05 07:36:08 -05:00
rasbt
60aada801b
improve latex rendering in dpo notebook 2024-08-04 09:19:59 -05:00
Sebastian Raschka
52435804eb
Direct Preference Optimization from scratch (#294) 2024-08-04 08:57:36 -05:00
rasbt
a7869ad2bf
Fix 8-billion-parameter spelling 2024-07-28 10:48:56 -05:00
Daniel Kleine
9a3b04f92f
fixed typos and formatting (#291) 2024-07-28 10:04:33 -05:00
rasbt
9eb2e2a5f6
update figure caption 2024-07-27 13:30:18 -05:00
rasbt
c87e4364b7
formatting 2024-07-27 09:51:24 -05:00
Sebastian Raschka
99af403b9f
Generate preference dataset with Llama 3.1 70B (#289) 2024-07-27 09:44:04 -05:00
Sebastian Raschka
08040f024c
Test code in pytorch 2.4 (#285)
* test code in pytorch 2.4

* update
2024-07-24 21:53:41 -05:00
rasbt
46fcde15d8
use utf-8 encoding in json 2024-07-22 07:01:54 -05:00
Sebastian Raschka
8d02cb1cee
Add download help message (#274) 2024-07-19 08:29:29 -05:00
rasbt
be14f06442
explain extra padding token 2024-07-17 07:38:25 -05:00