LlamaNextTokenScores class
Log-probabilities of the token that would follow a prompt, from
LlamaEngine.scoreNextToken.
They come from a softmax over the model's raw logits at the last prompt position. Sampling settings such as temperature, top-k, penalties and grammar do not apply.
Constructors
-
LlamaNextTokenScores({required List<
LlamaTokenLogprob> candidates, required List<LlamaTokenLogprob> top, required int promptTokens}) - Creates next-token scores.
Properties
-
candidates
→ List<
LlamaTokenLogprob> -
The requested candidate tokens, in request order.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- promptTokens → int
-
Number of tokens the prompt tokenized to.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
top
→ List<
LlamaTokenLogprob> -
The most probable tokens, most probable first.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited