chore: fmt.Errorf(static) → errors.New

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Claude 2026-02-24 16:28:27 +00:00
parent 421d0c42ff
commit 9f6dd9d4eb
No known key found for this signature in database
GPG key ID: AF404715446AEB41

View file

@ -4,6 +4,7 @@ package metal
import (
"context"
"errors"
"fmt"
"iter"
"slices"
@ -256,7 +257,7 @@ func (m *Model) Generate(ctx context.Context, prompt string, cfg GenerateConfig)
func (m *Model) InspectAttention(ctx context.Context, prompt string) (*AttentionResult, error) {
tokens := m.tokenizer.Encode(prompt)
if len(tokens) == 0 {
return nil, fmt.Errorf("empty prompt after tokenisation")
return nil, errors.New("empty prompt after tokenisation")
}
caches := m.newCaches()