Skip to Content
실무로 통하는 LLM 애플리케이션 설계
book

실무로 통하는 LLM 애플리케이션 설계

by 수하스 파이, 박조은
October 2025
Intermediate
424 pages
10h 19m
Korean
Hanbit Media, Inc.
Content preview from 실무로 통하는 LLM 애플리케이션 설계
288
2
LLM 활용하기
9.4
디코딩 가속화 기법
자기회귀 모델은 한 번에 하나의 토큰만 생성합니다. 각 토큰은 전체 입력과 이전에 생성된 토
큰들의 함수로 계산되므로 현재 토큰이 생성되기 전에는 다음 토큰을 생성할 수 없는 순차적인
제약이 존재합니다. 이러한 제약을 극복할 수 있을까요? 최근에는 이를 해결하고자
스페큘러티
디코딩
speculative
decoding
병렬
디코딩
parallel
decoding
같은 다양한 기법이 개발되었습니다. 이 기
술들을 자세히 살펴보겠습니다.
9.4.1
스페큘러티브 디코딩
스페큘러티브 디코딩
15
의 기본 개념은 단순합니다. 먼저, 초안 모델
draft
model
이라는 작고 빠른
모델이 여러 개의 후속 토큰 후보를 생성합니다. 그 후, 더 큰 메인 모델이 이 후보 토큰들의 조
건부 확률을 한꺼번에 계산해 수용할 토큰과 폐기할 토큰을 판단합니다. 더 많은 후보 토큰이
수용될수록 초안 모델의 품질이 높다는 의미입니다.
[그림
9
-
3
]은 스페큘러티브 디코딩이 실제로 어떻게 작동하는지를 보여줍니다.
초안 모델
(소형 )
메인 모델
(대형 )
로그 가능도
계산
토큰 폐기
최종 출력
입력 프롬프트
K
개의 후보
토큰 생성
토큰
수용
토큰
거부
재생성
그림
9-3
실제 스페큘러티브 디코딩
스페큘러티브 디코딩에서 중요한 두 가지 지표는 다음과 같습니다.
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

What Successful Project Managers Do

What Successful Project Managers Do

W. Scott Cameron, Jeffrey S. Russell, Edward J. Hoffman, Alexander Laufer
How to Overcome a Power Deficit

How to Overcome a Power Deficit

Cyril Bouquet, Jean-Louis Barsoux
Relational Power Is the New Currency of Hybrid Work

Relational Power Is the New Currency of Hybrid Work

Lebene Soga, Yemisi Bolade-Ogunfodun, Nazrul Islam, Joseph Amankwah-Amoah

Publisher Resources

ISBN: 9791169214384