mirror of
https://github.com/likelovewant/ollama-for-amd.git
synced 2025-12-21 22:33:56 +00:00
models: enable deepseek2 (deepseek v3.1 w/ MLA) on the new engine (#13151)
This commit is contained in:
@@ -250,6 +250,7 @@ func (kv KV) OllamaEngineRequired() bool {
|
|||||||
"qwen3", "qwen3moe",
|
"qwen3", "qwen3moe",
|
||||||
"qwen3vl", "qwen3vlmoe",
|
"qwen3vl", "qwen3vlmoe",
|
||||||
"deepseekocr",
|
"deepseekocr",
|
||||||
|
"deepseek2",
|
||||||
}, kv.Architecture())
|
}, kv.Architecture())
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -236,6 +236,11 @@ type Model struct {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func New(c fs.Config) (model.Model, error) {
|
func New(c fs.Config) (model.Model, error) {
|
||||||
|
if c.Uint("attention.key_length_mla") == 0 {
|
||||||
|
// non-MLA models aren't yet supported
|
||||||
|
return nil, model.ErrUnsupportedModel
|
||||||
|
}
|
||||||
|
|
||||||
layers := make([]Layer, c.Uint("block_count"))
|
layers := make([]Layer, c.Uint("block_count"))
|
||||||
|
|
||||||
firstDenseLayerIndex := int(c.Uint("leading_dense_block_count"))
|
firstDenseLayerIndex := int(c.Uint("leading_dense_block_count"))
|
||||||
|
|||||||
Reference in New Issue
Block a user