Table of Contents

Method DisallowTextChunk

Namespace
LMKit.TextGeneration.Sampling
Assembly
LM-Kit.NET.dll

DisallowTextChunk(string, bool, bool)

Strictly prevents a specific text chunk from appearing during the sampling process associated with this LogitBias instance.

public void DisallowTextChunk(string textChunk, bool ignoreCase = true, bool disableTrimming = false)

Parameters

textChunk string

The text chunk to disallow. This should be a single word from the vocabulary, such as 'cat'.

ignoreCase bool

An optional boolean that specifies whether case must be ignored. The default value is true.

disableTrimming bool

An optional boolean that specifies whether trimming must be ignored. The default value is false.

Remarks

The Vocabulary property of the underlying Model specifies all support text chunks (or token values).