Przeglądaj źródła

fix whitespace removal

Arne Müller 1 rok temu
rodzic
commit
5dc0cff459
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      llm/llama.go

+ 1 - 1
llm/llama.go

@@ -666,7 +666,7 @@ func (llm *llama) Decode(ctx context.Context, tokens []int) (string, error) {
 	}
 
 	// decoded content contains a leading whitespace
-	decoded.Content, _ = strings.CutPrefix(decoded.Content, "")
+	decoded.Content, _ = strings.CutPrefix(decoded.Content, " ")
 
 	return decoded.Content, nil
 }