NLP solution planning and text processing with Azure AI Language. This is the part of the AI-102 exam where you learn how to make computers understand human language — not just read words, but grasp meaning, tone, and intent. If you get this right, you can build chatbots, analyse customer feedback, and automate document processing, which is exactly what Azure customers pay for and what the exam expects you to explain.
Jump to a section
A simple way to picture NLP Solution Planning and Text Processing with Azure AI Language
You are a delivery manager at a busy e-commerce warehouse. Today, 10 packages arrive, each containing a different type of item. One is a fragile vase, another is a heavy book, a third is a legal document needing a signature, and a fourth is a perishable cake. Your job is not just to throw these boxes onto a truck. You must first plan the route. You pull up the delivery addresses on a digital map. You cluster the packages by neighbourhood: the vase and the cake both go to the same street, so you assign them to the same driver. The legal document needs a signed receipt, so you flag it for special handling. The heavy book goes to a fifth-floor flat with no lift, so you allocate extra time and a hand truck. This planning stage mirrors how you arrange input data before processing it with Azure AI Language.
Once your plan is ready, you actually process each package. You scan its barcode, confirm the address, apply the right handling instructions, and move it to the correct staging area. This execution stage is the text processing: cleaning the text, detecting the language, recognising key phrases, identifying the sentiment, and extracting the entities. If the package is labelled in Chinese but your driver only speaks English, you need a translator — that is analogous to Azure AI Language's translation capability. Every package gets handled correctly because you took the time to plan the routing and processing rules beforehand. Without that planning, you would be shoving cake boxes under heavy books and losing signatures. In NLP, solution planning is the route map; text processing is the delivery itself.
Natural Language Processing, or NLP, is a branch of artificial intelligence that gives computers the ability to read, understand, and derive meaning from human language. Azure AI Language is the set of tools Microsoft provides inside the Azure cloud platform to do exactly that without you needing to build the AI from scratch. Think of it as a pre-trained language brain you can rent by the second.
Before you start processing any text, you need a plan. This is the 'solution planning' part. You need to ask: what problem am I solving? Am I trying to sort emails into spam and not-spam? Am I trying to extract customer names from a thousand PDF invoices? Or am I trying to figure out if a product review is happy or angry? Each of these goals uses a different feature of Azure AI Language. The exam wants you to know which feature fits which job.
The main features of Azure AI Language are:
Language detection: This tells you what language the text is written in, for example English, Spanish, or Mandarin Chinese. It supports over 100 languages.
Key phrase extraction: This pulls out the most important words or phrases from a document. For a review that says "The camera battery lasts all day but the screen is too small," it would return "camera battery" and "screen."
Sentiment analysis: This reads the emotional tone — positive, negative, neutral, or mixed. A customer email that says "I love my new phone" scores high positivity. One that says "Your service is awful" scores high negativity.
Named entity recognition (NER): This finds specific things in the text such as people, organisations, locations, dates, and quantities. For "Satya Nadella works at Microsoft in Redmond," it identifies Satya Nadella as a person, Microsoft as an organisation, and Redmond as a location.
Entity linking: This goes a step further — it takes the identified entity and connects it to a knowledge base, like Wikipedia, so you know which "Paris" is meant (the city in France, not the celebrity).
Personally Identifiable Information (PII) detection: This finds sensitive data like credit card numbers, social security numbers, or passport numbers so you can redact or mask them before sharing documents.
Text summarisation: This creates a short summary of a long document. It can be extractive (picking the most important sentences) or abstractive (writing new sentences that capture the gist).
Custom text classification: This lets you train the AI to recognise your own categories, like "urgent query" vs "general feedback", using your own labelled examples.
Conversational language understanding (CLU): This is for building bots that hold a conversation. It identifies the user's intent — for example, the user wants to book a flight — and extracts the relevant information like the departure city and date.
All of these features are accessed through one unified endpoint — a single web address you call with your code. You send in text, and you get back structured JSON data — think of JSON as a neat table of facts rather than a messy blob of words.
Why does this all matter? Before Azure AI Language, a company that wanted to analyse customer emails had to hire a team of data scientists, train custom machine learning models for months, and spend tens of thousands of pounds. Now, with a few lines of code and a free-tier Azure subscription, a single developer can perform the same task in minutes. Azure AI Language replaces the expensive, slow, custom-built solution with a scalable, pay-as-you-go cloud service.
You also need to understand the difference between pre-built and custom models. Pre-built models are ready to use straight away. They work for common tasks like general sentiment analysis and standard entity recognition. Custom models require you to provide your own labelled data — examples of text along with the correct answer — which Azure AI Language uses to train a tailored model. Custom models are more accurate for specialised domains like medical records or legal contracts, but they require more work upfront.
Finally, you need to know about responsible AI. Azure AI Language includes content filtering to block offensive or harmful language. It also publishes transparency notes that explain how the models work, what their limitations are, and what data they were trained on. Microsoft expects you to use these tools ethically, and the exam will ask about fairness, reliability, and privacy. For example, sentiment analysis may be less accurate for dialects or slang, and you need to acknowledge that limitation when building your solution.
Identify the business need
Ask what problem you are solving. Are you scanning customer emails for complaints, extracting invoice numbers from PDFs, or building a multi-lingual chatbot? The answer determines which Azure AI Language features you need.
Choose pre-built or custom model
For standard tasks like general sentiment analysis or detecting common entities, use the pre-built model. For specialised domains like medical records legal contracts, or for classifying text into your own categories, use a custom model trained with your own labelled data.
Create the Azure resource
In the Azure portal, create an Azure AI Language resource. Select your region, choose the Free tier for testing or Standard for production, and note the endpoint URL and key. This resource is the single access point for all features.
Send text via API or Language Studio
Call the unified endpoint by sending a JSON payload containing your documents. Each document needs a unique ID and the text content. You can use the client libraries in Python, C#, or JavaScript, or test directly in Language Studio.
Parse the structured response
The API returns a JSON object with the results. For example, language detection returns the language name and confidence score. Sentiment analysis returns per-sentence and overall scores. Parse this structured data and store it in a database or feed it into a dashboard.
Iterate and refine
Test the results against real data. If accuracy is low, consider adding a custom model, cleaning up your input text, or switching to a more specific feature like Entity Linking instead of plain NER.
Imagine you work for a large hotel chain called 'StayWell Hotels'. The company receives over 10,000 guest feedback emails every week from properties in 15 different countries. The CEO wants a weekly dashboard showing which hotels are getting the most complaints and what topics guests are praising or criticising. You have been asked to build a system that processes these emails automatically.
Here is exactly what you do step by step as an IT professional:
First, you plan the solution. You identify the data source: the emails are stored in a shared folder on Azure Blob Storage, which is Microsoft's cloud file storage service. You decide which Azure AI Language features you need. You need language detection because emails come in English, Spanish, French, and Japanese. You need sentiment analysis to separate praise from complaints. You need key phrase extraction to identify specific topics like 'room cleanliness' or 'breakfast buffet'. You also need named entity recognition to pull out hotel names, dates, and guest names.
Second, you create an Azure AI Language resource in the Azure portal. This is as simple as clicking 'Create', selecting your region, and choosing the 'Free' or 'Standard' pricing tier. The portal gives you an endpoint URL and a key — a secret password that your code sends along with every request so Azure knows who you are and bills you correctly.
Third, you write a script — typically in Python or C# — that reads each email from Blob Storage, sends the text to the Azure AI Language endpoint, and saves the returned JSON results into a database like Azure Cosmos DB. The script processes one email at a time or in batches of up to five documents at once.
Fourth, you build the dashboard using Power BI, which is Microsoft's business analytics tool. The database tables feed into Power BI, and you create live charts showing sentiment trends over time and a word cloud of the most frequent key phrases. You also set up an alert: if any hotel's negative sentiment score drops below 0.2 (where 0 is most negative), an email is automatically sent to the hotel manager.
Fifth, you test the solution. You run it against 100 historical emails that have already been read by a human, and you compare the AI's results with the human's assessment. You find that the AI mislabels sarcastic comments like "Great, another broken hairdryer" as positive because of the word 'Great'. You adjust the solution by adding a custom sentiment model trained on your own hotel feedback data, which improves accuracy.
Finally, you deploy the system to production. You set up a scheduled job using Azure Logic Apps — a service that runs your code on a timer — to process new emails every night at 2 a.m. You monitor costs using Azure Cost Management, and you set up error logging so you can see if any requests fail.
In this real scenario, the AI-102 tasks you perform are literally the exam objectives: you planned the NLP solution, chose the right pre-built features, handled text processing in batches, dealt with language diversity, and refined the model for a specific business need. The exam tests whether you can make exactly these decisions.
The AI-102 exam devotes a significant portion of objective 2.1 to testing your knowledge of which Azure AI Language feature to use for a given scenario. The most common question type is a case study or multiple-choice scenario where you are presented with a business requirement — for example, 'A company needs to extract the names of all vendors mentioned in invoices' — and you must select the correct feature, which in this case is Named Entity Recognition.
Here are the specific concepts the exam loves to test:
Pre-built vs custom models: The exam will ask whether a task can be solved with the out-of-the-box pre-built model or requires a custom-trained model. For standard sentiment analysis on general text, the pre-built model is correct. For classifying legal contracts into 'Confidential', 'Draft', and 'Final', you need a custom text classification model.
Entity linking vs NER: The exam frequently presents a trick where the scenario requires disambiguating entities. If the text mentions 'Amazon', does it mean the company or the rainforest? Entity linking provides the answer by connecting to a knowledge base; plain NER does not.
Multi-language support: If a scenario involves processing text in German and Italian, the correct answer is that Azure AI Language supports these languages natively, and you do not need to deploy separate resources per language. However, the exam also tests that some features, such as custom conversational language understanding, require you to specify the language during training.
Sentiment analysis details: The exam will test that sentiment analysis returns three scores — positive, neutral, and negative — that add up to 1.0. It may also ask about mixed sentiment, which occurs when a document contains both strongly positive and strongly negative statements.
PII detection: Scenarios involving compliance with GDPR or HIPAA will test whether you choose PII detection to find and redact data like credit card numbers, social security numbers, and email addresses. The exam expects you to know that PII detection can be run as a standalone feature or as part of the broader text analytics pipeline.
Batch vs single-document processing: The exam will ask about the maximum batch size. You can process up to ten documents per request for features like language detection and key phrase extraction, but for some custom tasks the limits differ. Remember: the 'documents' in a batch are not files — they are individual text blocks, each up to 5,120 characters.
The unified endpoint: The exam will test that all Azure AI Language features are accessible through a single endpoint, which is different from older Azure services where each feature had its own separate endpoint. This is a key architectural point Microsoft added in the latest service version.
Authentication: The exam expects you to know that there are two ways to authenticate to the Azure AI Language endpoint: a key (a simple string sent in the request header) and Microsoft Entra ID (formerly Azure Active Directory) authentication for more secure environments.
Content filtering: Expect a question about responsible AI. The exam wants you to know that Azure AI Language includes built-in content filtering that can reject offensive input. You cannot turn this off. If your scenario involves profanity detection, you should use the content filtering feature, not build your own.
Cost and scalability: The exam may present a scenario where the free tier (5,000 text records per month) is insufficient. The correct answer is to upgrade to the Standard tier, which bills per thousand text records processed. There is no need to buy a separate server or manage infrastructure — it automatically scales.
A common trap is the question where a candidate confuses 'Key Phrase Extraction' with 'Named Entity Recognition'. The exam will describe extracting 'the main point of a news article', which is key phrases, versus 'the names of all the companies mentioned in the article', which is NER. Another trap is selecting 'Text Summarisation' when the scenario simply asks for the most important words — summarisation produces sentences, not keywords.
To pass this objective, memorise which feature maps to which business problem. Practise with real text samples and run them through the Azure portal's built-in Language Studio tool, which lets you test features without writing code. The exam heavily rewards hands-on familiarity.
Azure AI Language provides pre-built NLP features including language detection, key phrase extraction, sentiment analysis, and named entity recognition through a single unified endpoint.
Named Entity Recognition (NER) identifies entities like people and organisations, but Entity Linking is the separate feature that connects those entities to a knowledge base.
Sentiment analysis returns a score between 0 and 1 for positive, negative, and neutral sentiment, and the three scores for each document always add up to 1.
You can process up to ten documents per batch request, with each document being a text block of up to 5,120 characters.
Pre-built models work immediately for general tasks in over 100 languages, but custom models require you to provide your own labelled training data.
Content filtering is built in and cannot be disabled — Azure AI Language will reject abusive or offensive input automatically.
Authentication to the Azure AI Language endpoint can use either a simple key or Microsoft Entra ID for more secure, role-based access.
You can test all Azure AI Language features in the Azure portal's Language Studio without writing any code.
These come up on the exam all the time. Here's how to tell them apart.
Named Entity Recognition (NER)
Identifies entities like persons, organisations, and locations in text.
Does not connect entities to an external knowledge base.
Returns the entity type and position in the text.
Example: 'Paris' is tagged as a Location.
Entity Linking
Identifies entities and links them to a knowledge base like DBpedia or Wikipedia.
Provides a URL and ID for each linked entity.
Disambiguates when multiple entities share the same name.
Example: 'Paris' is linked to 'Paris, France' with a Wikipedia URL.
Pre-built Model
Ready to use with zero training data.
Covers general language patterns across 100+ languages.
Lower accuracy for specialised domains like medical or legal.
No upfront effort required.
Custom Model
Requires you to provide labelled examples for training.
Trained for your specific domain, e.g., extracting drug names from clinical notes.
Higher accuracy for tailored use cases.
Requires time and expertise to create a labelled dataset.
Sentiment Analysis (Pre-built)
Scores text as positive, negative, neutral, or mixed.
Uses a fixed general-purpose model.
Cannot be tuned for specific emotions like frustration or excitement.
Sentiment Analysis (Custom)
Trained on your own labelled data to recognise sentiment in your specific domain.
Can capture domain-specific language, e.g., 'wicked fast' as positive in gaming but negative in formal contexts.
Provides finer granularity, e.g., detecting specific emotions.
Single Document Processing
Sends one document per API request.
Simpler to implement and debug.
Higher overhead if processing many documents.
Batch Processing
Sends up to ten documents in a single request.
More efficient for bulk processing.
Reduces the number of API calls and overall latency.
Mistake
Sentiment analysis tells you the writer's overall emotion like happy or sad.
Correct
Sentiment analysis scores text as positive, negative, neutral, or mixed on a 0 to 1 scale. It does not detect specific emotions like anger, joy, or frustration — that requires a different custom model.
People assume the word 'sentiment' includes specific emotions because that is how humans experience it. The Azure AI Language pre-built model is simpler and only classifies into three broad categories plus confidence scores.
Mistake
Named Entity Recognition (NER) automatically links every found entity to a knowledge base like Wikipedia.
Correct
NER only identifies entities such as persons, organisations, and locations. To link those entities to a knowledge base, you must use the separate Entity Linking feature. The exam tests this distinction directly.
The terms sound similar and both involve entities. Beginners assume the more common feature (NER) includes the more advanced feature (linking). The exam sets traps by describing a linking scenario and listing NER as a wrong answer.
Mistake
You must train a custom model for each new language you want to process.
Correct
The pre-built models support over 100 languages out of the box. You only need a custom model if you want to recognise specialised entities or perform classifications unique to your business domain, regardless of language.
People assume AI models are language-specific because many younger language models require per-language training. Microsoft pre-trained a single multi-lingual model, so the effort is already done.
Mistake
Azure AI Language can understand context and sarcasm perfectly.
Correct
Pre-built models have limited understanding of context and often misinterpret sarcasm, irony, and culturally specific expressions. The service is designed for factual text analysis, not human-level reading comprehension.
Marketing language and demos sometimes show impressive results, leading beginners to overestimate the AI's capabilities. The exam expects you to recognise these limitations and plan accordingly.
Mistake
You must write code to use Azure AI Language features.
Correct
You can test all features interactively in the Azure portal's Language Studio without writing a single line of code. You can also call the features using REST APIs from any programming language.
Many beginners come from non-developer backgrounds and assume all cloud AI requires programming. The exam includes questions about using the studio to prototype, so knowing this broadens your understanding.
Reveal each answer, then mark whether you got it right. Score 60%+ to unlock the next chapter.
Azure AI Language is the new name for the text analytics part of what was previously called Azure Cognitive Services. Think of Cognitive Services as the old family name and Azure AI Language as the specific child focused on NLP.
No, Azure AI Language processes plain text. To handle PDFs, you must first extract the text using a tool like Azure Form Recogniser, or use a PDF library in your code, and then pass the extracted text to Azure AI Language.
Sentiment analysis is available for over 90 languages, but accuracy varies. English, French, German, Spanish, Italian, and Japanese have the highest accuracy because they have larger training datasets.
No. Azure AI Language includes built-in content filtering that automatically detects and blocks abusive or offensive language. You cannot disable this filter. For custom profanity detection, you would use a custom text classification model.
The API will truncate the text to the character limit. For longer documents, you must split them into smaller chunks before sending, or use the document summarisation feature which handles larger inputs.
No. Azure AI Language provides specialised pre-built NLP models for specific tasks like entity extraction and sentiment analysis. Azure OpenAI Service gives you access to large generative models like GPT-4 that can understand and generate free-form text. They solve different problems.
You've finished NLP Solution Planning and Text Processing with Azure AI Language. Continue through the AI-102 study guide to build a complete picture of the exam.
Done with this chapter?