Natural Language Processing


Natural Language Processing

Corey
Welcome in. Today we’re exploring the overlap among data science, human language technology, and natural language processing. Our guide is a talk by Christopher Michael Stewart, whose career has crossed all three areas. He trained in French linguistics, taught at the University of Texas at Arlington, and then moved into industry.

Maria
His industry path is a useful illustration of how varied this work can be. At Nuance, now called Cerence, he was a voice engineer in text-to-speech research and development in Belgium, where he developed Siri voices and worked closely with customers. He later became a senior data scientist at Tata Consultancy Services, building a machine-learning pipeline for Walmart, and at a startup modeling industrial Internet of Things time-series data.

Corey
He now works at Google as a computational linguist. His team works on detecting policy violations at scale, crowdsourcing best practices, and automated data-quality reports. He also makes an important boundary clear: he’s speaking from his own experience, not on behalf of Google.

Maria
And because data science, human language technology, and NLP each contain enough material for an entire career, the talk looks for their shared core rather than trying to cover each field exhaustively. Stewart calls that common thread predicted probability: using data and statistical models, especially machine learning and deep learning, to infer or predict something.

Corey
A probability can describe an event, like a fair coin landing heads, which has probability one-half. A conditional probability asks about an event given some information. So instead of asking only whether an object is a person, we might ask: given sensor readings, historical data, and metadata, how likely is an object in front of a car to be a human?

Maria
The same basic question appears in different forms across these fields. A text-to-speech team might estimate how suitable a speech segment is, given its spectral specifications, duration, focus, and part of speech. An NLP team might estimate whether a tweet contains hate speech, given the text, language, metadata, time, location, and retweet information.

Corey
You don’t need a statistics background to follow the intuition. Think about forecasting rain on Friday. If it’s Monday, you may have one estimate; if it’s Thursday, the new information could change your estimate. Conditional probability is simply a way to express how a prediction depends on what you know.

Maria
Before turning to machine learning, Stewart distinguishes two cultures of statistical modeling, drawing on statistician Leo Breiman’s paper, “Statistical Modeling: The Two Cultures.” In data modeling, researchers collect data and build a mathematical model that they hope reflects some underlying process. They care about the model’s parameters because those may help explain what is happening.

Corey
For example, in a study of language use, a regression model might help researchers ask whether someone’s language background predicts a linguistic behavior, or whether age matters more than another factor. Simpler models are often preferred in this culture because the parameters are meant to be interpreted. This approach is common in causal research and in familiar methods such as t-tests, ANOVAs, and regression.

Maria
Algorithmic modeling has a different priority: prediction. It doesn’t assume that the model’s internal structure reveals the true process generating the data. Instead, the question is whether it predicts well on new cases. Because interpretation and simplicity are not the central goal, researchers may use black-box models, often with large amounts of training data and computing power.

Corey
There’s also an intermediate area called statistical learning. Stewart recommends “An Introduction to Statistical Learning,” by Hastie and Tibshirani, as an accessible bridge. He also mentions “The Elements of Statistical Learning” as a more in-depth book.

Maria
So what does machine learning mean in practical terms? In traditional programming, a person writes the rules: give the program an input, apply instructions, and get an output. With machine learning, you provide inputs and the correct results to a model, and the model produces something that functions like a program for making predictions.

Corey
That process isn’t limited to language. It can be any classification problem: will it rain or not, will someone click a link or not, or, in Stewart’s memorable toy example, is an image a Chihuahua or a muffin? You start with labeled examples—images marked as dogs or muffins—and use them to train a classifier.

Maria
Then you test the classifier on images it hasn’t seen. It might say, “I’m 95 percent sure this is a dog.” Or it might say it’s 55 percent likely to be a dog, even though the picture is actually a muffin. Comparing predictions with the known answers lets you see where the model is right or wrong.

Corey
That feedback is part of improving the system. The important point is that, in this prediction-focused setting, you don’t necessarily need to know whether the classifier is looking for ears, lighting, or some other visual clue. What matters most is how accurately it classifies new images.

Maria
That contrasts with the data-modeling perspective. There, you might care about what the model says about the process that produced the observations. In an algorithmic setting, extra variables can improve prediction—or make it worse. A particular challenge occurs when there are far more variables than observations, as can happen with genetic data.

Corey
A familiar linear-regression equation helps connect these ideas. You have a value you want to predict, often called y, and known inputs, the x variables. Each input has a weight, or beta, that contributes to the prediction. In a simple example, you might use one measurement to predict another and find a line of best fit that minimizes the residual sum of squares—the total squared prediction error.

Maria
Machine learning methods can adjust that basic setup. Ridge regression keeps the familiar prediction equation but adds a penalty on large squared coefficients. The parameter lambda controls how strong that penalty is. In the talk’s explanation, this is a straightforward step from ordinary regression toward statistical learning: the model is discouraged from relying too heavily on its inputs.

Corey
Modern production systems can be much more complex, including neural networks and deep-learning models. But Stewart’s point is that the underlying ingredients are recognizable: inputs you know, outcomes you want to predict, weights that connect them, and some way to measure error.

Maria
There’s also a balance to find. A model that barely learns from its training examples may make nearly random predictions. But a model that memorizes those examples may fail on anything new. You want it to learn patterns that generalize beyond its training data. The balance between these problems is called the bias-variance tradeoff.

Corey
Deep learning can be powerful, but it isn’t automatically successful, and it depends heavily on labeled data. That leads to a major practical question: who creates the labels, and how do we know they’re reliable? Linguists can contribute here because they understand language and can help produce or assess language data.

Maria
For people starting out, Stewart recommends building statistical intuition rather than treating modeling as a recipe. Learn the assumptions behind methods, model assessment, and concepts such as normality tests. Don’t simply copy code from Stack Overflow to build a complicated model without understanding what it means.

Corey
He suggests “An Introduction to Statistical Learning” for moving beyond introductory inferential statistics, and “Bayesian Data Analysis” for readers ready for a more advanced step. A useful reminder is that even a very sophisticated model still has inputs, predictions, weights or relationships, and errors that need to be evaluated.

Maria
Now let’s move from the general machine-learning picture to language. Stewart presents an NLP pipeline as an introductory peek, not as state-of-the-art NLP. He uses a passage about Moscow, Ukraine, and Russian speakers to show the kinds of steps a system may need to handle.

Corey
First, the system needs sentence boundaries. A naive rule might treat every period as the end of a sentence, but that fails when periods occur in abbreviations such as “A.D.” or “U.S.A.” A more capable system must predict whether a period marks a sentence ending in context.

Maria
Next comes tokenization: dividing text into units called tokens. Tokens are often words, but they don’t always match the boundaries people intuitively call word boundaries. For example, a tokenizer might separate the possessive ending in “Ukraine’s” into “Ukraine” and “’s.” That choice matters because later steps depend on how the text is divided.

Corey
Then there’s part-of-speech tagging, which assigns labels such as noun or verb to tokens. Stewart cites English part-of-speech tagging as an example of a task that can be highly accurate—around 98 percent in the account he gives—but it is still a prediction task, so mistakes remain possible.

Maria
Syntactic parsing examines how words and phrases relate structurally. Beyond that, entity detection, also called named-entity recognition, identifies and connects references to people, places, and other entities. In the passage, a system might need to recognize that “Moscow” and “it” refer to the same entity.

Corey
These pipeline steps move from relatively low-level text processing toward richer representations of meaning. In current state-of-the-art NLP, deep-learning models are used for many of these predictions. Research scientists and computer engineers often build the models, while linguists contribute domain knowledge, identify recurring errors, and provide annotated data.

Maria
That contribution can be very concrete. If a model repeatedly mishandles possessives, a linguist may notice the pattern and help identify what needs improvement. Linguists’ understanding of how language works helps teams diagnose model failures, even when the linguists themselves aren’t writing the model from scratch.

Corey
And NLP is not a solved problem. Stewart gives the example of asking a digital assistant in Spanish to play a song with a Spanish title, only to have it translate the request instead. The system may be capable of processing language in general but still fail to interpret what the user intended in that situation.

Maria
A more detailed example shows why. Consider: “The police arrested Mayor John Smith yesterday. He was suspected of stealing garden gnomes, the latest breach in a crime wave rocking the sleepy town of Springfield.” A system has to connect “he” with Mayor John Smith and represent relationships among the police, the mayor, and Springfield.

Corey
It also has to make choices about representation. Is “Mayor John Smith” best treated as one entity, or as John Smith plus the role of mayor? Which parts of the representation should be most prominent? Those are questions about how to organize information, not merely how to recognize individual words.

Maria
Then there are events and real-world inferences. People understand that being suspected of a crime and being arrested are related, and that suspicion typically comes before arrest. A computer doesn’t automatically know criminal processes; a system needs information or engineering that supports those connections.

Corey
Language also carries subjectivity and figurative meaning. “Suspected” describes an allegation rather than a simple established fact. “A crime wave rocking the town” is metaphorical, and “sleepy town” means quiet or bucolic, not literally a town that needs a nap. Metonymy and other forms of meaning also complicate computational representations.

Maria
So, if you’re a linguist or student wondering how to enter these areas, Stewart’s first advice is to learn independently and find a project you genuinely care about. If a programming course feels dry, connect the learning to a linguistic problem or language you’re interested in. A real question can make technical practice more motivating.

Corey
Open-source projects offer one route. You can inspect a project’s code, make your own copy—often called forking it—work on an improvement, and submit that change back as a pull request. That gives you practice and a concrete contribution you can discuss.

Maria
Side projects, paid internships, and volunteer work can all help you build experience. The project doesn’t have to be glamorous. Finding a problem and fixing it is valuable, and technical projects make it easier to show what you can actually do.

Corey
Keep records of your work. Stewart recommends creating a personal webpage that links to a code repository, with projects clearly explained and their code available. That way, instead of only saying you know Python or statistics, you can point to specific work and describe its impact.

Maria
He also recommends learning new tools, applying for internships, and being thoughtful about data and the models you build. Automate repetitive work: rather than keeping an enormous script with all your research in one place, write reusable functions and unit tests so you can check that those functions behave as intended.

Corey
The principle underneath all of that is: prove it. A course can introduce a skill, but a contribution to a software package or a completed project is evidence that you’ve applied it. A portfolio helps employers understand what you’ve done and what you can bring to a team.

Maria
The talk’s questions and answers add several useful career details. For someone with compositional semantics experience, Stewart suggests the word “ontology” as a bridge to natural language understanding. Ontologies can represent relationships such as a person’s “mom” being referred to later as “her,” which matters for digital assistants.

Corey
He says academic work can absolutely appear alongside side projects on a website. Publications demonstrate that you’ve produced scholarly work, but don’t assume industry interviewers will read every long article. Make it easy for them to see the work and understand what you contributed.

Maria
Python isn’t strictly required for NLP work. Stewart describes it as relatively readable and convenient, while noting that someone who already knows Java can bring that experience too. More broadly, coding isn’t always a formal requirement for a linguist’s role, but being willing to engage with code and engineers is helpful on technical teams.

Corey
For people seeking linguistic annotation work, Stewart mentions vendors such as Appen and Lionbridge as examples of organizations that have sourced annotation work. For introductory learning, he recommends the free, online Natural Language Toolkit book, often called the NLTK book, as well as the statistical-learning book we discussed and an NLP textbook by Jacob Eisenstein.

Maria
On the future of linguists in NLP, he offers a prediction rather than a certainty: as systems move into less familiar and more difficult language territory, linguists’ knowledge of how people use language may become increasingly valuable. That expertise can complement the work of engineers and data scientists.

Corey
He also notes that job titles don’t always map neatly to subject areas. Someone called a data scientist might work on language, while someone in human language technology might be an engineer without much linguistics training. Learning to build models and use data thoughtfully can therefore strengthen a linguist’s prospects across several related fields.

Maria
On speech science specifically, experience with phonetics and speech can be relevant to text-to-speech synthesis and automatic speech recognition. Those roles involve different kinds of technical work from text-focused NLP, and Stewart says it’s difficult to make a simple claim about which area has more jobs.

Corey
Finally, graduate degrees aren’t an absolute requirement for NLP or computational linguistics jobs, but a degree alone isn’t enough either. The key is having the skill set the work requires. Stewart also urges realism about the job market: opportunities follow business needs and market forces, and there may be more people trained in linguistics than there are linguistics-specific jobs.

Maria
That brings the threads together. Data science, human language technology, and NLP all rely on prediction from data, but they also need careful evaluation, useful labels, and a clear understanding of what a model can and cannot tell us. Linguists can help at every stage, from annotation and error analysis to designing better representations of language.

Corey
And for anyone hoping to work in these fields, build your knowledge, choose projects that keep you curious, learn to collaborate with technical teammates, and make your work visible. Don’t just tell people what you’ve studied—show them what you’ve made, what you improved, and what you learned along the way.

Ask anything
We've read this whole study set, so questions about it get the best answers.