Property SamplingMode
SamplingMode
Gets or sets the token sampling strategy for text generation.
public TokenSampling SamplingMode { get; set; }
Property Value
- TokenSampling
The sampling mode. Default is GreedyDecoding for deterministic outputs.
Examples
using var chat = new RagChat(ragEngine, chatModel);
// Use random sampling for more varied responses
chat.SamplingMode = new RandomSampling { Temperature = 0.3f };