class

Llama::Sampler::Base

Inherits Reference / Object

Base class for all sampling methods. Sampling is the process of selecting the next token during text generation. This is an abstract class.

Constructors

new(handle : Pointer(LibLlama::LlamaSampler))

Creates a new Sampler instance from a raw pointer.

Note: This constructor is intended for internal use.

Source

Instance methods

to_unsafe

Returns the raw pointer to the underlying llama_sampler structure.

Source