<!--
{
  "availability" : [
    "iOS: 15.0.0 -",
    "iPadOS: 15.0.0 -",
    "macCatalyst: 15.0.0 -",
    "macOS: 10.14.0 -",
    "visionOS: 1.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CreateML",
  "identifier" : "/documentation/CreateML/MLTextClassifier/ModelAlgorithmType",
  "metadataVersion" : "0.1.0",
  "role" : "Enumeration",
  "symbol" : {
    "kind" : "Enumeration",
    "modules" : [
      "Create ML",
      "CreateML"
    ],
    "preciseIdentifier" : "s:8CreateML16MLTextClassifierV18ModelAlgorithmTypeO"
  },
  "title" : "MLTextClassifier.ModelAlgorithmType"
}
-->

# MLTextClassifier.ModelAlgorithmType

The type of algorithm that a text classifier uses.

```
enum ModelAlgorithmType
```

## Overview

Typically, `maxEnt` is the fastest training algorithm.
If the text classifier’s performance isn’t good enough, consider the `transferLearning` algorithm.

## Topics

### Selecting an algorithm type

[`MLTextClassifier.ModelAlgorithmType.crf(revision:)`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/crf(revision:))

A text classification algorithm that uses a statistical model of transition probabilities between words.

[`MLTextClassifier.ModelAlgorithmType.maxEnt(revision:)`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/maxEnt(revision:))

A text classification algorithm that uses multinomial logistic regression based on the frequencies of words, independent of context.

[`MLTextClassifier.ModelAlgorithmType.transferLearning(_:revision:)`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/transferLearning(_:revision:))

A text classification algorithm that uses transfer learning by leveraging a feature extractor to generate embeddings.

[`MLTextClassifier.FeatureExtractorType`](/documentation/CreateML/MLTextClassifier/FeatureExtractorType)

The text feature extractor type.

### Describing an algorithm type

[`description`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/description)

A text representation of the algorithm type.

[`debugDescription`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/debugDescription)

A text representation of the algorithm type that’s suitable for output
during debugging.

[`playgroundDescription`](/documentation/CreateML/MLTextClassifier/ModelAlgorithmType/playgroundDescription)

A description of the algorithm type shown in a playground.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)