Class: GGUFLoad::SmolLM2Flags
- Inherits:
-
Object
- Object
- GGUFLoad::SmolLM2Flags
- Defined in:
- lib/toy/io/loaders/toy_smollm2_loader.rb
Overview
Detect llama-family GGUF capability flags without instantiating the Ruby Mat-backed model. Returns has_untied_output + has_qkv_bias so the caller can build the FFI cache directly.
Instance Attribute Summary collapse
-
#attn_softcap ⇒ Object
Returns the value of attribute attn_softcap.
-
#embed_scale ⇒ Object
Returns the value of attribute embed_scale.
-
#final_softcap ⇒ Object
Returns the value of attribute final_softcap.
-
#has_post_norms ⇒ Object
Returns the value of attribute has_post_norms.
-
#is_moe ⇒ Object
Returns the value of attribute is_moe.
-
#n_experts ⇒ Object
Returns the value of attribute n_experts.
-
#n_experts_used ⇒ Object
Returns the value of attribute n_experts_used.
-
#qk_norm ⇒ Object
Returns the value of attribute qk_norm.
-
#qk_norm_kind ⇒ Object
Returns the value of attribute qk_norm_kind.
-
#qkv_bias ⇒ Object
Returns the value of attribute qkv_bias.
-
#swa_alternates ⇒ Object
Returns the value of attribute swa_alternates.
-
#swa_window ⇒ Object
Returns the value of attribute swa_window.
-
#untied ⇒ Object
Returns the value of attribute untied.
Instance Method Summary collapse
-
#initialize(untied, qkv_bias, qk_norm, swa_window, is_moe, n_experts, n_experts_used, qk_norm_kind = 0, has_post_norms = false, embed_scale = 1.0, attn_softcap = 0.0, final_softcap = 0.0, swa_alternates = false) ⇒ SmolLM2Flags
constructor
A new instance of SmolLM2Flags.
Constructor Details
#initialize(untied, qkv_bias, qk_norm, swa_window, is_moe, n_experts, n_experts_used, qk_norm_kind = 0, has_post_norms = false, embed_scale = 1.0, attn_softcap = 0.0, final_softcap = 0.0, swa_alternates = false) ⇒ SmolLM2Flags
Returns a new instance of SmolLM2Flags.
156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 156 def initialize(untied, qkv_bias, qk_norm, swa_window, is_moe, n_experts, n_experts_used, qk_norm_kind = 0, has_post_norms = false, = 1.0, attn_softcap = 0.0, final_softcap = 0.0, swa_alternates = false) @untied = untied @qkv_bias = qkv_bias @qk_norm = qk_norm @swa_window = swa_window @is_moe = is_moe @n_experts = n_experts @n_experts_used = n_experts_used @qk_norm_kind = qk_norm_kind @has_post_norms = has_post_norms @embed_scale = @attn_softcap = attn_softcap @final_softcap = final_softcap @swa_alternates = swa_alternates end |
Instance Attribute Details
#attn_softcap ⇒ Object
Returns the value of attribute attn_softcap.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def attn_softcap @attn_softcap end |
#embed_scale ⇒ Object
Returns the value of attribute embed_scale.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def @embed_scale end |
#final_softcap ⇒ Object
Returns the value of attribute final_softcap.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def final_softcap @final_softcap end |
#has_post_norms ⇒ Object
Returns the value of attribute has_post_norms.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def has_post_norms @has_post_norms end |
#is_moe ⇒ Object
Returns the value of attribute is_moe.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def is_moe @is_moe end |
#n_experts ⇒ Object
Returns the value of attribute n_experts.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def n_experts @n_experts end |
#n_experts_used ⇒ Object
Returns the value of attribute n_experts_used.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def n_experts_used @n_experts_used end |
#qk_norm ⇒ Object
Returns the value of attribute qk_norm.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def qk_norm @qk_norm end |
#qk_norm_kind ⇒ Object
Returns the value of attribute qk_norm_kind.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def qk_norm_kind @qk_norm_kind end |
#qkv_bias ⇒ Object
Returns the value of attribute qkv_bias.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def qkv_bias @qkv_bias end |
#swa_alternates ⇒ Object
Returns the value of attribute swa_alternates.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def swa_alternates @swa_alternates end |
#swa_window ⇒ Object
Returns the value of attribute swa_window.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def swa_window @swa_window end |
#untied ⇒ Object
Returns the value of attribute untied.
128 129 130 |
# File 'lib/toy/io/loaders/toy_smollm2_loader.rb', line 128 def untied @untied end |