<!--
{
  "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/DataSource/labeledDirectories(at:)",
  "metadataVersion" : "0.1.0",
  "role" : "Case",
  "symbol" : {
    "kind" : "Case",
    "modules" : [
      "Create ML"
    ],
    "preciseIdentifier" : "s:8CreateML16MLTextClassifierV10DataSourceO18labeledDirectoriesyAE10Foundation3URLV_tcAEmF"
  },
  "title" : "MLTextClassifier.DataSource.labeledDirectories(at:)"
}
-->

# MLTextClassifier.DataSource.labeledDirectories(at:)

A root directory of labeled directories for your data set.

```
case labeledDirectories(at: URL)
```

## Discussion

Labeled directories can be used to organize textual inputs. Just
like the data source used with the image classifier, place the
collected text inputs of the same kind in a directory. Name that
directory with the label appropriate for the textual inputs.

---

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)