Skip to Content

AI-102: How to Extract Dynamic Airline Names for Travel Chatbots?

Struggling with entity selection in AI-102 exam scenarios? Learn why Pattern.Any entities outperform List/Regex for dynamic airline name extraction in Azure chatbots. Get certified Azure AI Engineer tips for travel agency NLP solutions.

Table of Contents

Question

Your organization, Xerigon Corporation, is developing a chatbot for a travel agency. Customers can use the chatbot to book flights, hotels, and rental cars. When booking a flight, customers often specify their preferred airlines. You need to extract the airline name from the user’s input. Airline names can vary significantly (e.g., “United,” “United Airlines”, “American,” “American Airlines,” “Air Emirates”, “Emirates”).

Which type of entity should you create to capture the airline names in the given scenario?

A. List entity
B. ML (Machine Learned) entity
C. Pattern.Any entity
D. Regex entity

Answer

C. Pattern.Any entity

Explanation

In the given scenario, you would create the Pattern.Any entity. A Pattern.Any entity is ideal for extracting flexible, variable-length information within a specific context. In this case, you can define patterns that identify airline names within utterances such as “I want to fly with Emirates” or “Book a flight on Air France.” The Pattern.Any entity allows you to capture the airline name without needing to predefine all possible values or create complex regular expressions.

You would not create a list entity in the given scenario. A list entity acts like a vocabulary list for your chatbot, teaching it to recognize a specific set of terms and their close variations. You could create a list of common airlines. However, it would be difficult to maintain a comprehensive list of all possible airlines.

You would not create a regex entity in the given scenario. A regex entity uses regular expressions to define patterns for extracting information. You can use regex entities for a predefined sequence or structured text such as credit card or flight numbers. They are not affected by letter cases or cultural variations in the text. They excel at extracting structured information such as codes, IDs, or any data that follows a specific pattern.

You would not create an ML (Machine Learned) entity in the given scenario. An ML entity is trained on labeled examples to recognize and extract information. While ML entities are powerful, they require a significant amount of training data. For a relatively straightforward task like extracting airline names, you would use Pattern.Any entity.

Microsoft Azure AI Engineer Associate AI-102 certification exam practice question and answer (Q&A) dump with detail explanation and reference available free, helpful to pass the Microsoft Azure AI Engineer Associate AI-102 exam and earn Microsoft Azure AI Engineer Associate AI-102 certification.