mirror of
https://github.com/ollama/ollama.git
synced 2025-11-12 10:57:51 +01:00
model: fix issues with spm tokenizer for Gemma 3 (#10081)
This commit is contained in:
@@ -45,7 +45,6 @@ func newTextModel(c ml.Config) *TextModel {
|
||||
|
||||
m := TextModel{
|
||||
SentencePieceModel: model.NewSentencePieceModel(
|
||||
c.String("tokenizer.ggml.pretokenizer", `(?i:'s|'t|'re|'ve|'m|'ll|'d)|[^\r\n\p{L}\p{N}]?\p{L}+|\p{N}{1,3}| ?[^\s\p{L}\p{N}]+[\r\n]*|\s*[\r\n]+|\s+(?!\S)|\s+`),
|
||||
&model.Vocabulary{
|
||||
Values: c.Strings("tokenizer.ggml.tokens"),
|
||||
Scores: c.Floats("tokenizer.ggml.scores"),
|
||||
|
||||
Reference in New Issue
Block a user