Text Analysis: Key Phrases, Entities, Sentiment and Summaries
30-second answer
Text analysis pulls meaning out of text that already exists. The main techniques are key phrase extraction (the main talking points), entity detection (people, places, organisations, dates, plus entity linking and PII detection), sentiment analysis with opinion mining (positive, negative, neutral or mixed, and about what), summarisation (extractive or abstractive) and language detection. In Azure you can use Azure Language in Foundry Tools for fixed, structured output, or prompt a language model for more flexible results.
Simulate it » No Azure account neededExam objective: 1.3.2 Describe common text analysis techniques, including keyword extraction, entity detection, sentiment analysis, and summarization. (Skills measured as of April 15, 2026)
Simulations
Feel it before you read it. No account needed, nothing leaves this page.
Open <strong>Foundry Tools ➜ Azure Language</strong>, pick <strong>Analyze sentiment</strong> and paste a review.
👆 Click the glowing item in the portal to continue
Read the steps as text
- Open Foundry Tools ➜ Azure Language, pick Analyze sentiment and paste a review.
- Sentiment comes per document and per sentence, and opinion mining links each opinion to its target (breakfast ➜ cold).
- Switch capability: key phrases, named entities, PII redaction, language detection and summarization.
- The same calls in Python use the resource endpoint with TextAnalyticsClient.
🧪 Simulation for learning. Screens are simplified versions of the Azure portal; names, prices and IDs are examples. Nothing here touches real Azure.
🖱️ Drag to rotate · scroll or pinch to zoom
Text analysis
A hotel review goes in. Azure Language returns the sentiment (positive, neutral, negative), key phrases, named entities (people, places, dates), PII and a short summary.
🤔 What happens if…
Read this tour as text
- Five workload lanes. Most AI apps fall into a few workloads: generative and agentic AI, text analysis, speech, computer vision and information extraction. Each lane here takes a different kind of input and turns it into something useful.
- Text analysis. A hotel review goes in. Azure Language returns the sentiment (positive, neutral, negative), key phrases, named entities (people, places, dates), PII and a short summary.
- Speech to text. Speech recognition turns spoken audio into text: live captions, call transcripts, voice commands. It can also translate speech into another language as you talk.
- Text to speech. Speech synthesis turns text into natural speech with a neural voice. SSML lets you control speed, pitch and pauses. Think audiobooks, voice assistants and accessibility readers.
- Computer vision. A photo goes in. Vision models return a caption, tags, objects with boxes, and any printed or handwritten text (OCR). A multimodal chat model can also answer questions about the picture.
- Image generation. Image-generation models work the other way round: a text prompt goes in and a brand-new image comes out. Guardrails block harmful requests, and generated images are marked with content credentials.
- Extract from documents. Azure Content Understanding reads an invoice and returns fields you defined (vendor, date, total) with a confidence score for each, so low-confidence values can go to a person.
- Extract from audio and video. The same service handles media: an audio call becomes a transcript with speakers and a summary; a video is split into segments with key frames, descriptions and chapters.
Turn a hotel review into sentiment, key phrases, entities, masked personal data and a summary: first in the portal, then from Python.
🎓 Education-only simulation. Your lab is saved in this browser, so you can leave and continue later.
😟 THE PROBLEM
10,000 hotel reviews arrive each month and nobody reads them.
😊 THE SOLUTION
Text analysis finds the mood, topics, names and private data automatically.
- Is feedback good or bad?✓ Sentiment analysis
- What are people talking about?✓ Key phrase extraction
- Phone numbers in text✓ PII detection
Start with a question
You've got 10,000 customer reviews. How do you find out what people actually think?
Reading them all would take weeks. You’d want to know quickly: are people happy? What are they talking about most? Which products, which cities? Are they complaining about delivery or about the product itself?
That’s text analysis: software reading the text for you and pulling out feelings, topics, names and a short summary.
Explain it like I’m 10
The technical explanation
Text analysis works on text you already have: reviews, emails, chat logs, tickets, transcripts. It doesn’t write anything new (except abstractive summaries). Here’s what each technique gives you, using one review as the example:
“Ordered a Contoso phone from the Mumbai store on 3 March. Screen is gorgeous but the battery barely lasts a day. Call me on 98200 12345.”
| Technique | What it returns | From the example |
|---|---|---|
| Language detection | The language and a confidence score | English |
| Key phrase extraction | Main talking points | “Contoso phone”, “Mumbai store”, “battery”, “screen” |
| Named entity recognition (NER) | Entities with categories | Contoso (Organization), Mumbai (Location), 3 March (DateTime) |
| Entity linking | Which real-world thing an entity is, with a reference link | Mumbai linked to the city’s Wikipedia entry |
| PII detection | Personal data, with a redacted copy of the text | 98200 12345 (Phone number) replaced with asterisks |
| Sentiment analysis | Positive, negative, neutral or mixed, per document and per sentence | Document: mixed |
| Opinion mining | Each opinion and what it’s about | screen: positive (“gorgeous”), battery: negative (“barely lasts”) |
| Summarisation | A shorter version: extractive (picks sentences) or abstractive (rewrites) | “Customer likes the screen but the battery life is poor.” |
Azure Language also includes conversational language understanding, custom question answering and Text Analytics for health, but the exam objective focuses on the techniques above.
Azure Language in Foundry Tools
- Fixed features: sentiment, NER, PII, key phrases, summaries
- Structured JSON output with confidence scores
- Same input gives the same output
- Priced per text record
Prompting a language model
- Any task you can describe in a prompt
- Custom categories and formats
- Several tasks in one call
- Pay per token; output needs checking
Microsoft has announced that key phrase extraction, sentiment analysis, summarisation, entity linking, CLU and custom question answering in Azure Language retire on 31 March 2029, with Foundry models as the replacement. Language detection, PII detection, NER and Text Analytics for health continue.
Architect level Confidence scores and long documents
Every Language result comes with confidence scores between 0 and 1. Use a threshold before acting automatically: for example, only route a ticket to the angry-customer queue when negative sentiment is above 0.8, and send borderline ones to a person. Requests have size limits per document and per call, so long documents are split into chunks. Summaries of long texts use the asynchronous (long-running) operations.
Real-world business scenario
Wide World Foods, a restaurant chain across India
- The problem
- Thousands of reviews and feedback forms came in each week in English and Hindi. Managers only read a handful and missed patterns, and some forms contained customers' phone numbers.
- What they used
- Ran every review through Azure Language: language detection, sentiment with opinion mining, NER for branch names, PII detection to redact phone numbers, and a weekly abstractive summary per branch.
- Why that choice
- The output is structured and scored, so it fed straight into a dashboard. PII redaction let regional managers read feedback without seeing personal data.
- The result
- Managers spotted that one city's branches had slow-service complaints within a week, and fixed staffing before ratings dropped further.
When to use it and when not to
✓ Use it when…
- Analysing large volumes of reviews, tickets, emails or transcripts.
- Redacting personal data before people or other systems see the text.
- Feeding structured results (sentiment, entities) into dashboards or databases.
- Prompting a language model when you need custom categories or several tasks at once.
✕ Think twice when…
- Don't use text analysis to write replies. That's generative AI.
- Don't act automatically on low-confidence results; send them to a person.
- Don't use it to pull specific fields from invoices or forms. Information extraction tools suit that better.
↔ Alternatives to consider
- **A Foundry model with a prompt** for flexible, combined analysis.
- **Azure Content Understanding** to extract defined fields from documents, audio and video.
Test yourself with exercises
5 original practice questions in the AI-901 style. Pick your answers, then check them. You will see why each option is right or wrong. Score 75% or more and this topic is marked complete.
Interview preparation
Say your answer out loud first, then open the model answer. Interviewers care more about your reasoning than the exact words.
Beginner What's the difference between sentiment analysis and opinion mining?
Model answer
Sentiment analysis tells you the overall feeling: "this review is mixed". Opinion mining tells you what each feeling is about: the food was great, the service was slow. So opinion mining is the more detailed, aspect-level view.
Interviewer follows up
What labels does sentiment analysis return?
You
Positive, negative, neutral or mixed, with confidence scores, for the whole document and for each sentence.
Intermediate How is entity linking different from named entity recognition?
Model answer
NER finds an entity and gives it a category, like "Amazon" is an organisation. Entity linking goes further and decides which Amazon: the company or the river, by matching it to a known reference. NER says what kind, linking says which one.
Experienced developer When would you use Azure Language instead of prompting a language model?
Model answer
When I need fixed, predictable output with confidence scores, such as PII redaction or NER feeding a database, or when per-feature pricing works out cheaper at high volume. I'd prompt an LLM when I need flexibility, like custom categories or several tasks combined in one call. Microsoft has also said some Language features retire in March 2029 in favour of Foundry models, so new designs often use models for sentiment and summaries.
Scenario A bank must remove account numbers and phone numbers from chat transcripts before analysts read them. What would you use?
Model answer
PII detection in Azure Language. It finds those values, categorises them and returns a redacted version of the text, so analysts can work with transcripts without seeing personal data.
Quick revision
Key points
- Key phrase extraction finds the main talking points.
- NER finds and categorises entities; entity linking says which real-world thing is meant; PII detection finds personal data to redact.
- Sentiment analysis returns positive, negative, neutral or mixed; opinion mining ties opinions to their targets.
- Extractive summaries pick existing sentences; abstractive summaries write new ones.
- Azure Language in Foundry Tools gives structured output; language models can do the same tasks with prompts.
Important terminology
- Key phrase extraction
- Finds the main talking points in a text, such as "delivery time" or "battery life".
- Named entity recognition (NER)
- Detects and categorises entities in text, such as people, locations, organisations, dates and quantities.
- Entity linking
- Matches an entity to a known reference (such as a Wikipedia entry) to tell apart things with the same name.
- PII detection
- Finds personal information such as phone numbers, email addresses and ID numbers so you can redact it.
- Sentiment analysis
- Labels text as positive, negative, neutral or mixed, with confidence scores per document and per sentence.
- Opinion mining
- Part of sentiment analysis that links each opinion to its target, such as "battery (negative)" and "screen (positive)".
- Extractive summarisation
- Picks the most important sentences from the original text.
- Abstractive summarisation
- Writes a new, shorter summary in its own words.
Common mistakes
- Mixing up key phrases (talking points) with entities (named, categorised things).
- Thinking sentiment analysis only gives one label per document. It also scores each sentence.
- Forgetting that abstractive summaries can include words not in the source.
Exam tips
- "Identify the main talking points" = key phrase extraction.
- "Find people, places, organisations, dates" = named entity recognition.
- "Mask phone numbers and email addresses" = PII detection.
- "Which product feature did customers dislike?" = opinion mining.
Five quick revision questions
-
1.Which technique tells "Paris the city" apart from "Paris the person"?Show
Entity linking.
-
2.What four labels can sentiment analysis return?Show
Positive, negative, neutral and mixed.
-
3.Which summary type writes new sentences?Show
Abstractive summarisation.
-
4.Which Foundry Tool provides text analysis features?Show
Azure Language in Foundry Tools.
-
5.Which technique finds the language a review is written in?Show
Language detection.
Official references
Finished this lesson? Tick it off. Your progress is saved in this browser.
Next up: Speech Recognition and Speech Synthesis
Lesson done? Make it stick with a quick gameSort It, Match the Pairs, Lightning Round and Who Am I? Earn XP and badges.