Llama::Sampler::MinP
Inherits Llama::Sampler::Base / Reference / Object
Min-P sampler
The Min-P sampler keeps tokens with probability >= P * max_probability. This is similar to Top-P but uses a minimum probability threshold relative to the most likely token, rather than a cumulative probability threshold.
Example:
sampler = Llama::Sampler::MinP.new(0.05, 1) # Keep tokens with prob >= 5% of max prob