class Llama::Sampler

Defined in:

llama/sampler.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(vocab_size : Int32, temperature : Float32, topp : Float32, rng_state : UInt64) #

[View source]

Instance Method Detail

def rng_state : UInt64 #

[View source]
def rng_state=(rng_state : UInt64) #

[View source]
def sample(logits : Array(Float32)) : Int32 #

[View source]
def temperature : Float32 #

[View source]
def temperature=(temperature : Float32) #

[View source]
def topp : Float32 #

[View source]
def topp=(topp : Float32) #

[View source]
def vocab_size : Int32 #

[View source]
def vocab_size=(vocab_size : Int32) #

[View source]