Starting from iOS 11, Apple introduces a new framework called Vision.
The Vision framework performs face and face landmark detection, text detection, barcode recognition, image registration, and general feature tracking. Vision also allows the use of custom Core ML models for tasks like classification or object detection.
Use the Natural Language framework to perform tasks like language and script identification, tokenization, lemmatization, parts-of-speech tagging, and named entity recognition. You can also use this framework with Create ML to train and deploy custom natural language models.
The NSTextContainer class defines a region in which text is laid out. An NSLayoutManager object uses one or more NSTextContainer objects to determine where to break lines, lay out portions of text, and so on. An NSTextContainer object defines rectangular regions, and you can define exclusion paths inside the text container’s bounding rectangle so that text flows around the exclusion path as it is laid out. You can create subclasses that define regions of nonrectangular shapes, such as circular regions.