Method GetTokenCandidateByRank
- Namespace
- LMKit.TextGeneration.Events
- Assembly
- LM-Kit.NET.dll
GetTokenCandidateByRank(int)
Retrieves the identifier of a token based on its rank in terms of likelihood of occurrence.
public int GetTokenCandidateByRank(int rankIndex)
Parameters
rankIndex
intThe rank of the token whose identifier is to be retrieved. Must be an integer between 0 and the total number of tokens minus one.
Returns
- int
The identifier of the token at the specified rank.
Exceptions
- ArgumentOutOfRangeException
Thrown when
rankIndex
is outside the valid range.