Skip to Content
핸즈온 LLM
book

핸즈온 LLM

by 제이 알아마르, 마르턴 흐루턴도르스트, 박해선
June 2025
Beginner to intermediate
460 pages
11h 46m
Korean
Hanbit Media, Inc.
Content preview from 핸즈온 LLM
442
3부 언어 모델 훈련 및 미세 튜닝
프롬프트 거부된 생성
참조 모델
(동결)
훈련 가능한 모델
(선호도 튜닝 가능)
토큰 확률 계산
(모델마다 계산)
거부 점수는 토큰 확률을
집계한 것입니다
거부 점수 차이를 계산합니다
그림
12-33
토큰 수준에서 생성 텍스트의 확률로 점수를 계산하여 참조 모델과 훈련 가능 모델 사이의 확률 차이를 최
적화합니다. 승인된 생성도 동일한 과정을 따릅니다.
이 점수를 사용해 승인된 생성을 만드는 데 더 확신하고 거부된 생성을 만드는 데 덜 확신하도
록 훈련 가능 모델의 파라미터를 최적화할 수 있습니다. 논문 저자들은
PPO
에 비해
DPO
훈련 과정에서 더 안정적이고 정확함을 밝혔습니다.
DPO
가 안정적이므로 이를 사용해 인스
트럭션 튜닝된 모델을 선호도 튜닝하는 데 사용하겠습니다.
12.7
DPO
를 사용한 선호도 튜닝
허깅 페이스 도구를 사용하면 선호도 튜닝은 약간의 차이가 있을 뿐 앞서 다룬 지시 기반 튜닝
과 매우 비슷합니다. 여기서도
TinyLlama
를 사용하겠지만 지시 기반으로 튜닝된 버전을 사용
하겠습니다 (
https
://
oreil
.
ly
/
bkVF1
). 이 모델은 완전한 미세 튜닝을 적용한 후
DPO
로 추
가적으로 정렬한 모델입니다. 앞서 지시 기반으로 튜닝한 모델에 비해 이
LLM
은 훨씬 큰 데이
터셋에서 훈련되었습니다.
이 절에서 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

LLMOps

LLMOps

Abi Aryan
딥러닝의 정석(2판)

딥러닝의 정석(2판)

니틴 부두마, 니킬 부두마, 조 파파
FastAPI

FastAPI

Bill Lubanovic

Publisher Resources

ISBN: 9791169213516