Skip to Content
Practical Artificial Intelligence with Swift
book

Practical Artificial Intelligence with Swift

by Mars Geldard, Jonathon Manning, Paris Buttfield-Addison, Tim Nugent
October 2019
Intermediate to advanced
523 pages
11h 1m
English
O'Reilly Media, Inc.
Content preview from Practical Artificial Intelligence with Swift

Chapter 6. Text and Language

This chapter explores the practical side of implementing text- and language-related AI features in your Swift apps. Taking a top-down approach, we explore five text and language tasks and how to implement them using a variety of AI tools.

Practical AI, Text, and Language

The five text and language tasks that we explore in this chapter are:

Language Identification

Determining what language some text might be in.

Named Entity Recognition

Identifying the elements of text that are people, places, or organizations.

Lemmatization, tagging, tokenization Identifying the lemma of every word in a string, finding the parts of speech (verbs, nouns, and so on), and splitting a string up by words.

Sentiment Analysis

Determining whether some text has a positive or negative sentiment.

Custom Text Classifiers

Another way of classifying text for sentiment, extending Apple’s tools.

Note

In Chapter 8, we also look at generating text. We put that task there because we think it’s more closely related to generating things than it is to text. But really, you’re probably reading the whole book, so it doesn’t matter where it goes.

Images, human movement, and sound might be flashy, but the majority of apps you’ll build in your life will also, or perhaps primarily, deal with text. Humans generate vast amounts of text, and it’s often useful to be able to use a clever machine to figure out what’s going on with text so that you can make decisions or show the user something ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Machine Learning with Swift

Machine Learning with Swift

Alexander Sosnovshchenko

Publisher Resources

ISBN: 9781492044802Errata Page