class

MicroGPT::LookaheadModel

Inherits Reference < Object

Constructors

new(model : MiniGPT, n_ahead : Int32 = 2)
Source

Instance methods

extra_heads
Source
generate(start_ids : Array(Int32), max_tokens : Int32, temperature : Float64 = 1.0) : Array(Int32)
Source
masks
Source
model
Source
n_ahead
Source
param_count
Source
train_step(input_ids : Array(Int32), targets : Array(Array(Int32))) : Tuple(Float64, Array(Float64))

Training step with multiple output heads and zebra masks Returns {avg_loss, per_head_losses}

Source