AI Notes
Master conversational AI. Dialogue systems, intent recognition. NLP 2024.
Introduction
Conversational AI encompasses systems that can engage in natural language dialogue with humans. From simple FAQ chatbots to sophisticated virtual assistants like Siri and Alexa, conversational AI ranges widely in capability and complexity. The goal is to create systems that understand user intent, maintain context across multiple turns, generate appropriate responses, and accomplish tasks through natural language interaction. This is one of the most challenging areas of NLP because it requires integrating understanding, generation, reasoning, and memory.
Types of Conversational Systems
| - Examples | Book flights, order food, schedule meetings |
| - Structure: Intent detection | Slot filling → Action → Response |
| - Examples | Social companionship, entertainment |
| - Challenge | Must be engaging without specific goals |
Task-Oriented Dialogue Architecture
Pipeline Architecture
User: "Book me a flight to London next Tuesday"
│
▼
┌─────────────────────┐
│ NLU (Understanding) │
│ Intent: book_flight │
│ Slots: │
│ destination=London│
│ date=next_Tuesday │
│ origin=??? │
└─────────┬───────────┘
│
▼
┌─────────────────────┐
│ Dialogue Manager │
│ State: need_origin │
│ Policy: ask_origin │
└─────────┬───────────┘
│
▼
┌─────────────────────┐
│ NLG (Generation) │
│ "Where will you be │
│ flying from?" │
└─────────────────────┘
Next turn
User: "From New York"
NLU: slot_fill(origin=New York)
DM: All slots filled → call booking API
NLG: "I found 3 flights from New York to London on Tuesday..."
Intent Classification
| "Book a flight to Paris" | intent: book_flight |
| "What's the weather like?" | intent: get_weather |
| "Cancel my reservation" | intent: cancel_booking |
| "Tell me a joke" | intent: chitchat |
| Model | Fine-tuned BERT classifier |
| Input | User utterance |
| Output | Probability distribution over intents |
| Confidence threshold | If max_prob < 0.6, ask for clarification |
Slot Filling (Named Entity Recognition for Dialogue)
| User | "I need a table for 4 at an Italian restaurant tomorrow at 7pm" |
| party_size | 4 |
| cuisine | Italian |
| date | tomorrow |
| time | 7pm |
| restaurant_name | not specified |
| Required | party_size, date, time |
| Optional | cuisine, restaurant_name, location |
Dialogue State Tracking
Maintaining context across multiple turns
Turn 1: User: "Find me a hotel in Paris"
State: {intent: hotel_search, city: Paris}
Turn 2: User: "Something cheap with wifi"
State: {intent: hotel_search, city: Paris,
price_range: budget, amenities: [wifi]}
Turn 3: User: "Actually, make that London"
State: {intent: hotel_search, city: London, ← updated!
price_range: budget, amenities: [wifi]}
Turn 4: User: "What about restaurants nearby?"
State: {intent: restaurant_search, city: London, ← context preserved
near: hotel_results}
Challenges
- Coreference: "there" refers to previously mentioned city
- Corrections: "Actually..." signals update to previous slot
- Context switching: New intent but preserving relevant context
Large Language Model Approach
| Architecture | Transformer decoder (autoregressive generation) |
| 1. Pre-training | Predict next token on massive text corpus |
| 2. Instruction tuning | Fine-tune on instruction-response pairs |
| 3. RLHF | Reinforcement learning from human feedback |
Evaluation Metrics
Task-oriented
- Task completion rate: % of successfully completed tasks
- Slot accuracy: % of correctly extracted slot values
- Turns to complete: Fewer turns = more efficient
- User satisfaction: Human ratings (1-5)
Open-domain
- Perplexity: How well model predicts responses (lower = better)
- BLEU/ROUGE: N-gram overlap with reference responses
- Human evaluation: Coherence, relevance, engagement
- Sensibleness and Specificity Average (SSA): Google's metric
Summary
Conversational AI combines NLU, dialogue management, and NLG to create systems that interact naturally through language. Task-oriented systems follow structured pipelines for completing specific goals, while open-domain systems aim for engaging general conversation. Modern LLM-based approaches unify these capabilities in a single model, dramatically expanding what conversational AI can accomplish. The field continues to evolve toward more natural, capable, and trustworthy dialogue systems that can serve as genuine assistants in daily life.
Exam Focus
Revise definitions, diagrams, examples, and short-answer points for Conversational AI - Chatbots.
Interview Use
Prepare one clear explanation, one practical example, and one common mistake for this Artificial Intelligence topic.
Search Terms
artificial-intelligence, artificial intelligence, artificial, intelligence, natural, language, processing, conversational
Related Artificial Intelligence Topics