Default

AWS Certified AI Practitioner Domain 2: AWS AI Services Deep Dive

Domain 2, “AI/ML Services and Solutions,” is the largest domain in the AWS Certified AI Practitioner exam, accounting for 35% of the total score. This domain tests your knowledge of AWS’s comprehensive AI and ML service offerings, when to use each service, and how they integrate together.

In this post, we’ll explore each major AWS AI service in detail with practical examples, use cases, and implementation considerations that will help you not just pass the exam, but apply these services effectively in real-world scenarios.

Amazon SageMaker: The ML Platform

Amazon SageMaker is AWS’s comprehensive machine learning platform that enables you to build, train, and deploy ML models at scale. Think of it as your complete ML workshop.

Key Components

SageMaker Studio

An integrated development environment (IDE) for ML development.

Features:

  • Jupyter notebooks with pre-configured ML environments
  • Visual pipeline builder for drag-and-drop workflows
  • Experiment tracking and model versioning
  • Built-in algorithms and pre-trained models

Real-world Example: A data scientist building a customer churn prediction model can:

  1. Launch a Studio notebook instance
  2. Explore and visualize customer data
  3. Train multiple models with different algorithms
  4. Compare model performance in experiment tracking
  5. Deploy the best model as an endpoint

SageMaker Autopilot

Automated machine learning that handles the entire ML pipeline automatically.

How it works:

  1. Upload your dataset
  2. Specify the target column
  3. Autopilot automatically:
    • Analyzes data and handles missing values
    • Tries multiple algorithms (linear regression, XGBoost, etc.)
    • Performs hyperparameter tuning
    • Selects the best model

Use Case Example: A marketing team with customer data wants to predict which customers will buy a new product. Instead of hiring an ML engineer, they use Autopilot to automatically build and deploy a prediction model.

SageMaker Ground Truth

Managed data labeling service for creating high-quality training datasets.

Features:

  • Human workforce for complex labeling tasks
  • Automated labeling using pre-trained models
  • Quality assurance through consensus mechanisms
  • Integration with custom labeling workflows

Practical Example: An autonomous vehicle company needs to label thousands of images for object detection. Ground Truth provides a workforce to accurately label cars, pedestrians, traffic signs, etc., with quality checks to ensure consistency.

SageMaker Model Registry

Central repository for managing ML model versions and metadata.

Benefits:

  • Version control for models
  • Model approval workflows
  • Metadata tracking (performance metrics, training data used)
  • Integration with CI/CD pipelines

Real-world Scenario: A financial services company maintains multiple versions of their fraud detection model. The registry tracks which version is in production, when it was trained, and its performance metrics.

SageMaker Pricing Considerations

  • Studio instances: Pay for compute time when notebooks are running
  • Training jobs: Pay for compute resources used during training
  • Hosting endpoints: Pay for inference requests
  • Free tier: Limited hours for getting started

Computer Vision Services

Amazon Rekognition

Image and video analysis service that can identify objects, people, text, and activities.

Core Capabilities

Object and Scene Detection

  • Identifies thousands of objects (cars, buildings, food, etc.)
  • Scene classification (indoor, outdoor, beach, etc.)
  • Confidence scores for each detection

Example Use Case: Retail inventory management

// Detect products on store shelves
const rekognition = new AWS.Rekognition();
const params = {
  Image: {
    S3Object: {
      Bucket: "store-images",
      Name: "aisle-5.jpg",
    },
  },
};

rekognition.detectLabels(params, (err, data) => {
  if (data.Labels) {
    data.Labels.forEach((label) => {
      console.log(`${label.Name}: ${label.Confidence}% confidence`);
      // Output: "Cereal Box: 95.2%", "Milk Carton: 87.1%"
    });
  }
});

Facial Analysis

  • Facial recognition and verification
  • Emotion detection (happy, sad, angry, etc.)
  • Age estimation and gender identification
  • Facial landmarks (eyes, nose, mouth positions)

Security Example: Airport security system

  • Compares faces against watchlists
  • Verifies passenger identity against boarding pass photos
  • Detects suspicious behavior through emotion analysis

Text Detection (OCR)

  • Extracts text from images and videos
  • Supports multiple languages
  • Handles various fonts and layouts

Document Processing Example: Digitizing paper forms

Input: Scanned insurance claim form
Output: Extracted text fields:
- Policy Number: POL-12345
- Claim Amount: $2,500
- Date of Incident: 2025-10-15
- Description: "Car accident on Highway 101"

Content Moderation

Automatically identifies inappropriate content in images and videos.

Moderation Categories:

  • Explicit content (nudity, violence, etc.)
  • Suggestive content
  • Offensive symbols and gestures
  • Hate symbols

Social Media Example: A platform automatically flags and removes posts containing violent content before they reach users.

Amazon Lookout for Vision

Specialized computer vision service for industrial inspection and quality control.

Key Features:

  • Automated visual inspection of products
  • Defect detection in manufacturing
  • Quality assurance for food processing
  • Anomaly detection in production lines

Manufacturing Example: Circuit board inspection

  • Trains on images of good circuit boards
  • Automatically detects defects like missing components, wrong orientations, or damaged traces
  • Reduces human inspection time by 80%

Natural Language Processing Services

Amazon Comprehend

Text analysis service that extracts insights and relationships from unstructured text.

Core Features

Sentiment Analysis Determines the emotional tone of text (positive, negative, neutral).

Customer Service Example:

Input: "The product arrived damaged and customer service was unhelpful"
Output: {
  "Sentiment": "NEGATIVE",
  "SentimentScore": {
    "Positive": 0.01,
    "Negative": 0.95,
    "Neutral": 0.04,
    "Mixed": 0.00
  }
}

Entity Recognition Identifies people, organizations, locations, dates, and other entities.

News Analysis Example:

Input: "Apple Inc. announced a new iPhone in Cupertino, California on September 15, 2025"
Output: {
  "Entities": [
    {
      "Text": "Apple Inc.",
      "Type": "ORGANIZATION",
      "Confidence": 0.99
    },
    {
      "Text": "Cupertino, California",
      "Type": "LOCATION",
      "Confidence": 0.98
    },
    {
      "Text": "September 15, 2025",
      "Type": "DATE",
      "Confidence": 0.95
    }
  ]
}

Language Detection Identifies the dominant language in text.

Multilingual Support Example:

  • Automatically detects 100+ languages
  • Useful for routing customer support tickets to appropriate teams
  • Content categorization for global platforms

Topic Modeling Discovers themes and topics in large document collections.

Document Organization Example: Research library automatically categorizes academic papers into topics like “Machine Learning,” “Computer Vision,” “Natural Language Processing,” etc.

Amazon Comprehend Medical

Specialized version for healthcare text analysis.

Healthcare Applications:

  • Medical entity extraction (medications, conditions, treatments)
  • Protected Health Information (PHI) detection
  • Clinical trial matching
  • Medical coding and billing assistance

Example: Analyzing doctor’s notes

Input: "Patient prescribed 50mg Lisinopril daily for hypertension"
Output: {
  "Entities": [
    {
      "Text": "Lisinopril",
      "Type": "MEDICATION",
      "Attributes": [{"Type": "DOSAGE", "Text": "50mg"}]
    },
    {
      "Text": "hypertension",
      "Type": "MEDICAL_CONDITION"
    }
  ]
}

Speech and Language Services

Amazon Polly

Text-to-speech service that converts written text into lifelike speech.

Voice Options

  • Standard voices: Cost-effective, natural-sounding speech
  • Neural voices: More human-like, emotional speech (Titan TTS)
  • Long-form voices: Optimized for articles, books, and long content
  • Generative voices: Most natural, conversational speech

Supported Languages: 40+ languages and variants

Speech Synthesis Markup Language (SSML)

Advanced control over speech characteristics:

<speak>
  <prosody rate="slow">I speak slowly</prosody>
  <prosody pitch="high">and with a high pitch</prosody>
  <break time="1s"/>
  <emphasis level="strong">This is very important!</emphasis>
</speak>

Practical Applications:

  • Audiobooks and e-learning content
  • Voice assistants and chatbots
  • Accessibility tools for visually impaired users
  • Automated phone systems and IVR

E-learning Example: Converting educational content to audio format for students who prefer listening over reading.

Amazon Transcribe

Speech-to-text service that converts audio to text.

Key Features

  • Real-time transcription: Live audio processing
  • Batch transcription: Process recorded audio files
  • Speaker identification: Distinguish between multiple speakers
  • Automatic punctuation: Adds punctuation and formatting
  • Custom vocabulary: Industry-specific terminology

Supported Formats: WAV, MP3, MP4, FLAC, OGG, WebM

Call Center Example:

Audio Input: Customer service call recording
Output: {
  "transcripts": [{
    "transcript": "Hello, I'd like to return this defective product. The screen is cracked and doesn't turn on properly.",
    "confidence": 0.95,
    "speaker": "Caller"
  }, {
    "transcript": "I'm sorry to hear that. Can you provide your order number?",
    "confidence": 0.97,
    "speaker": "Agent"
  }]
}

Advanced Features

  • Medical transcription: Specialized for healthcare conversations
  • Custom language models: Improved accuracy for specific domains
  • Content redaction: Automatically remove sensitive information

Amazon Translate

Language translation service for breaking down language barriers.

Translation Methods

  • Real-time translation: Immediate translation for live conversations
  • Batch translation: Process large volumes of content
  • Custom terminology: Maintain brand consistency across languages

Supported Languages: 75+ languages

E-commerce Example: Global online store automatically translates product descriptions, reviews, and customer communications.

Advanced Features:

  • Formality control: Adjust tone (formal vs. informal)
  • Profanity masking: Filter inappropriate content
  • Parallel data: Custom training for domain-specific translations

Conversational AI Services

Amazon Lex

Build conversational interfaces using voice and text.

Key Components

  • Intents: Actions users want to perform (book flight, check balance)
  • Slots: Parameters needed to fulfill intents (date, destination, amount)
  • Utterances: Sample phrases users might say
  • Fulfillment: Code that executes the intent

Banking Chatbot Example:

Intent: CheckAccountBalance
Sample Utterances:
- "What's my account balance?"
- "How much money do I have?"
- "Check my balance"

Slots:
- AccountType (required): "checking", "savings"

Fulfillment: Query database and return balance

Integration Options

  • Amazon Connect: Build contact center solutions
  • AWS Lambda: Serverless fulfillment functions
  • API Gateway: RESTful API access
  • Mobile apps: iOS and Android SDKs

Real-world Implementation: A retail company builds a chatbot that helps customers:

  • Check order status
  • Request returns
  • Get product recommendations
  • Schedule deliveries

Amazon Kendra

Intelligent search service powered by machine learning.

Key Features

  • Natural language queries: Understands conversational questions
  • Document ranking: Returns most relevant results first
  • Multi-format support: PDFs, HTML, Word documents, FAQs
  • Incremental learning: Improves results over time

Enterprise Search Example: Company knowledge base search

Query: "How do I reset my password?"
Traditional Search: Returns 50 results about passwords
Kendra Search: Returns the specific password reset procedure first

Advanced Capabilities:

  • Custom data sources: Connect to databases, file systems, applications
  • Access control: Secure search results based on user permissions
  • Analytics: Track search patterns and user behavior

Specialized AI Services

Amazon Personalize

Real-time personalization and recommendation engine.

Recommendation Types

  • User-to-item: “Customers who bought X also bought Y”
  • Item-to-item: Similar items based on user behavior
  • Personalized ranking: Reorder lists based on user preferences
  • Next best action: Predict what users will do next

E-commerce Example: Online bookstore recommendations

User browsing history: Mystery novels, crime thrillers
Personalize recommendations:
1. "The Girl with the Dragon Tattoo" (similar to viewed books)
2. "Gone Girl" (popular in mystery genre)
3. "Big Little Lies" (users who liked your books also liked this)

Amazon Forecast

Time series forecasting for business planning.

Use Cases

  • Demand forecasting for inventory management
  • Sales prediction for revenue planning
  • Resource planning (server capacity, staffing)
  • Financial forecasting (budget planning)

Retail Example: Supermarket chain predicts demand for seasonal items

Historical data: Past 2 years of sales data
Forecast horizon: Next 30 days
Output: Predicted daily demand for each product in each store
Result: Optimized inventory levels, reduced waste

Amazon Lookout for Metrics

Anomaly detection in business metrics.

Applications

  • Fraud detection in financial transactions
  • Quality monitoring in manufacturing
  • System performance monitoring
  • Sales anomaly detection

E-commerce Example: Detect unusual sales patterns

Normal: 100-200 orders per hour
Anomaly Detected: 500 orders in 5 minutes
Alert: Potential bot attack or flash sale opportunity

Service Integration and Architecture

Common Integration Patterns

Data Lake Architecture

Raw Data (S3) → Data Processing (Glue) → ML Training (SageMaker) → Model Deployment (SageMaker Endpoints)

Real-time Inference Pipeline

User Input → API Gateway → Lambda → SageMaker Endpoint → Response

Batch Processing Workflow

Data Upload → S3 → Event Trigger → Lambda → SageMaker Batch Transform → Results → S3

Cost Optimization Strategies

SageMaker Cost Management

  • Use Spot Instances for training (up to 90% savings)
  • Right-size instances based on workload
  • Use multi-model endpoints for similar models
  • Implement auto-scaling for inference endpoints

Service Selection Based on Scale

  • Small scale: Use managed services (Rekognition, Comprehend)
  • Medium scale: SageMaker for custom models
  • Large scale: Custom distributed training with EC2

Security and Compliance

Data Protection

  • Encryption: Data encrypted at rest and in transit
  • Access control: IAM policies and resource-level permissions
  • VPC support: Private network isolation
  • Audit logging: CloudTrail integration

Compliance Certifications

  • HIPAA: For healthcare workloads (Comprehend Medical)
  • PCI DSS: For payment processing
  • SOC 2: General security and availability
  • GDPR: Data protection and privacy

Exam Preparation: Key Service Comparisons

When to Use Each Service

Vision Tasks:

  • Rekognition: General computer vision (objects, faces, text)
  • Lookout for Vision: Industrial inspection and defect detection

Language Tasks:

  • Comprehend: General NLP (sentiment, entities, topics)
  • Comprehend Medical: Healthcare-specific text analysis
  • Translate: Language translation
  • Polly: Text-to-speech
  • Transcribe: Speech-to-text

Conversational AI:

  • Lex: Build chatbots and voice interfaces
  • Kendra: Intelligent search and Q&A

ML Platform:

  • SageMaker: Complete ML lifecycle management
  • SageMaker Autopilot: Automated ML for non-experts

Common Exam Scenarios

Scenario 1: A company wants to analyze customer feedback from multiple languages. Solution: Use Translate to convert to English, then Comprehend for sentiment analysis.

Scenario 2: A manufacturer needs to inspect product quality automatically. Solution: Use Lookout for Vision to detect defects in production line images.

Scenario 3: A retailer wants personalized product recommendations. Solution: Use Personalize to analyze user behavior and generate recommendations.

Scenario 4: A data scientist needs to build and deploy a custom ML model. Solution: Use SageMaker Studio for development, SageMaker training for model building, and SageMaker hosting for deployment.

Hands-on Practice Recommendations

Free Tier Exploration

  1. Rekognition: Upload images and test object detection
  2. Comprehend: Analyze text samples for sentiment and entities
  3. Polly: Convert text to speech and experiment with voices
  4. Transcribe: Upload audio files and test transcription accuracy

SageMaker Getting Started

  1. Launch SageMaker Studio (free tier available)
  2. Run a built-in algorithm on sample data
  3. Try Autopilot with a simple dataset
  4. Deploy a model endpoint and test inference

Integration Projects

  • Build a chatbot using Lex that integrates with other services
  • Create a document analysis pipeline using multiple services
  • Implement a recommendation system with Personalize

Final Tips for Domain 2 Success

  1. Understand Service Scope: Know what each service does well and its limitations
  2. Cost Awareness: Be familiar with pricing models and optimization strategies
  3. Integration Knowledge: Understand how services work together in solutions
  4. Use Case Recognition: Practice matching business problems to appropriate services
  5. Hands-on Experience: Try services in AWS console to understand their capabilities

Domain 2 is about applying AI services to solve real business problems. Focus on understanding the practical applications and integration patterns rather than just memorizing feature lists.

In our next post, we’ll explore Domain 3: Generative AI, where we’ll dive into foundation models, prompt engineering, and AWS’s generative AI offerings like Amazon Q and Titan.

© . Some rights reserved.

Using the Chirpy theme for Jekyll.