removed redundant strings.CutPrefix from Decode

This commit is contained in:
Arne Müller 2023-10-18 22:47:20 +02:00
parent 46b9953f32
commit ce6197a8e0

View file

@ -668,9 +668,6 @@ func (llm *llama) Decode(ctx context.Context, tokens []int) (string, error) {
return "", fmt.Errorf("unmarshal encode response: %w", err)
}
// decoded content contains a leading whitespace
decoded.Content, _ = strings.CutPrefix(decoded.Content, "")
return decoded.Content, nil
}