Class Categorization
- Namespace
- LMKit.TextAnalysis
- Assembly
- LM-Kit.NET.dll
A class designed to handle custom classification of plain text content.
public sealed class Categorization
- Inheritance
-
Categorization
- Inherited Members
Constructors
- Categorization(LM)
Creates an instance of the Categorization class.
Properties
- Confidence
Confidence of the last categorization process, expressed as a floating-point value ranging from 0 to 1. A value closer to 1 indicates higher confidence in the classification accuracy.
- Model
Gets the Model instance associated with this object.
- UseEmbeddingClassifier
Gets or sets a value indicating whether the classifier should utilize embeddings strategy instead of completion. When set to
true
, forces the underlying engine to classify using embeddings.
Methods
- CreateTrainingObject(IList<string>, IList<(string, string)>, int)
Creates an object for fine-tuning a categorization model using provided training data.
- GetBestCategory(IList<string>, string, bool, CancellationToken)
Classifies a given text into one of the predefined categories.
- GetBestCategoryAsync(IList<string>, string, bool, CancellationToken)
Classifies a given text into one of the categories from a predefined list asynchronously.