AI-901
Deep Dive
NLP allows machines to understand, interpret, and generate human language. The AI-901 evaluates both the fundamental concepts and the specific Azure services for each NLP task.
Contents
NLP (Natural Language Processing) is the field of AI that lets machines understand, interpret, and generate human text and speech. Unlike structured data (tables, numbers), natural language is ambiguous, contextual, and highly variable.
🧠
Understanding (NLU)
Understanding the meaning of text or speech: what did the user mean?
✍️
Generation (NLG)
Producing coherent text: summaries, responses, translations.
💬
Interaction (NLI)
Two-way dialogue: chatbots, voice assistants.
Raw text goes through stages before being analyzed:
Text input
Raw text: review, email, tweet, document.
Tokenization
Splits the text into units (tokens): words, subwords, or characters.
Normalization
Lowercasing, punctuation removal, stopwords, stemming/lemmatization.
Feature extraction
Representing text as numeric vectors (TF-IDF, word embeddings, BERT).
Model / NLP task
Applying the trained model for the specific task (classification, NER, etc.).
Structured output
Result: label, entities, translation, generated response.
Splitting text into minimal units called tokens. Can be at word, subword, or character level.
// Input
"The cat sleeps."
// Word tokens
["The", "cat", "sleeps", "."]
// Subword tokens (BPE)
["The", "▁cat", "▁sle", "eps", "."]
For the exam
Modern LLMs use subword tokenization. "ChatGPT" can be several tokens. The context limit is measured in tokens, not words.
Stopwords
Frequent words without relevant semantic meaning: "the", "a", "of", "and". They are removed in tasks like search.
Stemming
Reduces words to their root by cutting suffixes: "running" → "runn". Fast but imprecise.
Lemmatization
Reduces to the base form (lemma) with grammatical context: "running" → "run". More precise than stemming.
Lowercase / normalization
Unifying uppercase/lowercase, removing accents, special characters to reduce variability.
Determines whether a text expresses a positive, negative, or neutral opinion. It can also identify sentiment by aspect (opinion about specific aspects).
Practical example
"Shipping was fast but the product arrived damaged." → positive on shipping, negative on product.
Exam trap
Sentiment Analysis detects OPINION, not emotion. To detect specific emotions (anger, joy) you use emotion analysis, a different subset.
In Azure: Azure AI Language → Sentiment Analysis. Returns scores (0-1) for positive/negative/neutral and opinion mining by aspect.
Identifies and classifies named entities in text: people, organizations, places, dates, quantities, events, products.
Practical example
"Microsoft announced on May 14 in Seattle that Azure surpassed $50B in revenue." → Microsoft (ORG), May 14 (DATE), Seattle (LOC), $50B (MONEY).
Exam trap
NER identifies entities in unstructured text. It is NOT the same as extracting fields from documents (that's Document Intelligence).
In Azure: Azure AI Language → Named Entity Recognition. Also available: Entity Linking (links entities to Wikipedia/Bing).
Identifies the main concepts and topics of a text, extracting the most relevant phrases without classifying them as entities.
Practical example
"Customer service was excellent and delivery arrived earlier than expected." → key phrases: "customer service", "excellent", "delivery", "earlier than expected".
Exam trap
Key Phrase Extraction ≠ NER. Key phrases are important topics/concepts; NER are entities with a specific type (person, place, date). A topic summary uses key phrases; identifying named people uses NER.
In Azure: Azure AI Language → Key Phrase Extraction. Automatically supports multiple languages.
Identifies the language a text is written in and returns an ISO code (e.g., "es" for Spanish) along with a confidence score.
Practical example
"Bonjour, comment allez-vous?" → fr (French), confidence: 0.99.
Exam trap
Language Detection ≠ Translation. It only identifies the language; to translate you use Azure Translator. It's typically used as the first step in multilingual pipelines.
In Azure: Azure AI Language → Language Detection. Also integrated into Translator as an automatic step.
Assigns one or more predefined categories to a text. It's one of the most common NLP tasks in production.
Each text receives exactly one category. Example: technical support → categories "Billing", "Bug", "Feature request".
A text can belong to multiple categories simultaneously. Example: news article → ["Technology", "Business", "AI"].
Typical use cases
In Azure: Azure AI Language → Custom Text Classification. Lets you train with your own labels without ML experience.
Neural machine translation (NMT)
Modern translation models use transformers that translate considering the full context of the sentence, not word by word. They produce translations that are much more fluent and precise than earlier statistical approaches.
Automatic language detection
You don't need to specify the source language. The model detects it automatically before translating.
Transliteration
Converts text between writing systems without translating the meaning: Arabic → Latin characters for pronunciation.
Exam trap
Azure Translator ≠ Azure Language Service. Translator is only for translation. Language Service does sentiment, NER, key phrases, etc.
In Azure: Azure Translator — supports 100+ languages, real-time translation, Custom Translator for domain-specific terminology.
Speech-to-Text (STT)
Converts spoken audio into written text. Also known as Automatic Speech Recognition (ASR).
Text-to-Speech (TTS)
Converts written text into synthesized speech. Modern models generate neural voice that's nearly indistinguishable from human speech.
Exam trap: Speech Translation
Azure Speech Service includes Speech Translation: STT + Translation + TTS in a single call. This is different from calling the Translator API separately. The question may specify real-time voice translation — the answer is Azure Speech Service, not Azure Translator.
In Azure: Azure AI Speech — unifies STT, TTS, Speech Translation, Speaker Recognition, and Custom Keyword in one service.
❓ Do Key Phrase Extraction and NER do the same thing?
No. Key Phrase Extraction identifies the most important topics/concepts of the text (without a specific type). NER identifies entities with a concrete category: person, organization, place, date. Use NER when you need to know WHAT TYPE of entity it is; use Key Phrases when you only need the main topics.
❓ Does sentiment analysis detect emotions?
Not exactly. Sentiment Analysis classifies opinion (positive/negative/neutral). Detecting specific emotions (anger, surprise, fear) is a different, more granular task. For the exam: if the question talks about "positive/negative" → Sentiment Analysis; if it talks about specific emotions → look for Emotion Detection.
❓ Does Azure Translator do text analysis?
No. Azure Translator only translates between languages. For sentiment, NER, key phrases, or classification, you use Azure AI Language Service. They are separate services with different purposes.
❓ Are Speech-to-Text and Language Detection the same thing?
No. STT converts audio into text. Language Detection identifies the language of already-written text. For audio in an unknown language: first STT (audio → text), then Language Detection (text → identified language).
Did you get this topic?
Test what you just learned
A company receives thousands of support tickets a day in multiple languages. They want to: (1) automatically identify the language of each ticket, (2) extract the name of the product mentioned, and (3) determine whether the customer is frustrated or satisfied. Which combination of NLP tasks is needed?
Put what you learned to the test with original AI-901 exam questions.
Start AI-901 mock examUnlimited mock exams with the Pro plan
Log in to track your progress.