Property TopNSigma
- Namespace
- LMKit.TextGeneration.Sampling
- Assembly
- LM-Kit.NET.dll
TopNSigma
Gets or sets the Top-nσ threshold used to filter candidate tokens based on their pre-softmax logits.
Tokens are retained only if their logits are within TopNSigma * σ of the maximum logit. A higher threshold (e.g., 5) includes a broader set of tokens (even those with higher noise), while a lower threshold (e.g., 1) focuses on tokens that are very close to the top candidate.
Acceptable values are in the range [0, 5], where setting this value to 0 disables the Top-nσ filtering. The default value is 1.
public float TopNSigma { get; set; }