All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

Understanding Speculative Sampling: Using Draft Distributions to Match Target Sampling Results

By

teleforce

3mo ago· 2 min readen

Summary

Speculative sampling is a technique that uses a draft sampling distribution to achieve the same results as a target sampling distribution. The method involves using two probability distributions - a target distribution p(x) and a draft distribution q(x) - and implementing a smart rejection mechanism to adjust sampling. This approach down-samples over-sampled tokens and up-samples under-sampled tokens from the draft distribution to match the target distribution's sampling results.

Key quotes

· 4 pulled
The idea of speculative sampling is to use a draft sampling to achieve the same sampling result as the target sampling.
We have a target sampling distribution $p(x)$ and a draft sampling distribution $q(x)$.
The core trick of speculative sampling is to design a smart rejection method to down-sample the over-sampled tokens and up-sample the under-sampled tokens.
If we directly sample from $q(x)$, we will get a sample $x$ that is not from the target distribution $p(x)$.
Snippet from the RSS feed
Speculative Sampling The idea of speculative sampling is to use a draft sampling to achieve the same sampling result as the target sampling. We have a target sampling distribution $p(x)$ and a draft sampling distribution $q(x)$.

You might also wanna read