Class MiniMaxBlock
java.lang.Object
smile.llm.model.minimax.MiniMaxBlock
One MiniMax-M3 decoder block: pre-norm, GQA/MSA attention, residual, post-norm,
dense FFN or MoE, residual. Norms use the Gemma
1 + weight convention.-
Constructor Summary
ConstructorsConstructorDescriptionMiniMaxBlock(int layerId, MiniMaxModelArgs args) Constructor.MiniMaxBlock(int layerId, MiniMaxModelArgs args, MiniMaxShard shard, TensorParallelGroup group) Expert-parallel constructor. -
Method Summary
-
Constructor Details
-
MiniMaxBlock
Constructor.- Parameters:
layerId- decoder layer index.args- model hyperparameters.
-
MiniMaxBlock
public MiniMaxBlock(int layerId, MiniMaxModelArgs args, MiniMaxShard shard, TensorParallelGroup group) Expert-parallel constructor.- Parameters:
layerId- decoder layer index.args- model hyperparameters.shard- this rank's slice of the routed experts.group- all-reduce group (needed whenshard.size() > 1).
-
-
Method Details
-
layerId
public int layerId()Returns the decoder layer index.- Returns:
- layer index.
-
selfAttn
-
mlp
-
moe
-
forward
-