Mila
Deep Neural Network Library
Loading...
Searching...
No Matches
Mila::Dnn::QwenModelConfig Struct Referenceexport

Deployment configuration for Qwen 3.8 language models. More...

Inheritance diagram for Mila::Dnn::QwenModelConfig:
Mila::Dnn::LanguageModelConfig< QwenModelConfig >

Public Member Functions

 QwenModelConfig (dim_t context_length)
 Construct with a required context length.
std::string toString () const
Public Member Functions inherited from Mila::Dnn::LanguageModelConfig< QwenModelConfig >
std::string baseToString () const
 Produce the base fields portion of a toString() summary.
dim_t getContextLength () const noexcept
KvCacheCompression getKvCacheCompression () const noexcept
dim_t getLanguageModelHeadPositions () const noexcept
WeightQuantization getWeightQuantization () const noexcept
QwenModelConfig & withContextLength (dim_t context_length)
 Set the maximum sequence length.
QwenModelConfig & withFP4Quantization ()
 FP4 quantization – FP4 weights, FP8 KV cache.
QwenModelConfig & withFP8Quantization ()
 FP8 quantization – FP8 weights, FP8 KV cache.
QwenModelConfig & withFullPrecision ()
 Full precision – BF16 weights, BF16 KV cache.
QwenModelConfig & withKvCacheCompression (KvCacheCompression kv)
 Set the KV cache compression mode independently.
QwenModelConfig & withLanguageModelHeadPositions (dim_t positions)
 Positions the language-model head evaluates per pass.
QwenModelConfig & withPrecisionPlan ()
 The family's designed per-role allocation, from a pre-quantized artifact.
QwenModelConfig & withWeightQuantization (WeightQuantization wq)
 Set the weight quantization mode independently.

Additional Inherited Members

Protected Attributes inherited from Mila::Dnn::LanguageModelConfig< QwenModelConfig >
dim_t context_length_
KvCacheCompression kv_cache_compression_
dim_t language_model_head_positions_
WeightQuantization weight_quantization_

Detailed Description

Deployment configuration for Qwen 3.8 language models.

Inherits all fluent setters and accessors from LanguageModelConfig<QwenModelConfig>.

Constructor & Destructor Documentation

◆ QwenModelConfig()

Mila::Dnn::QwenModelConfig::QwenModelConfig ( dim_t context_length)
inlineexplicit

Construct with a required context length.

Parameters
context_lengthMaximum sequence length in tokens. Must be > 0.
Exceptions
std::invalid_argumentif context_length is zero.

The documentation for this struct was generated from the following file: