Skip to content

AIP-C01 · Study Guide

← Domain 2: Implementation and Integration

2.4.1 · Lesson 16 of 25

Flexible Model Interaction

The application waits for the model response.

Synchronous

The application waits for the model response.

Client
 ↓
API
 ↓
FM
 ↓
Response
 ↓
Client

Good when the response is expected quickly.

Asynchronous

The application submits work and processes it later.

Client
 ↓
API
 ↓
Queue
 ↓
Worker
 ↓
FM
 ↓
Result

Amazon SQS can support asynchronous processing.

Bedrock APIs

Applications can interact with foundation models through Amazon Bedrock APIs.

The AWS SDK can be used from different programming languages.

Conceptually:

Application
 ↓
AWS SDK
 ↓
Bedrock API
 ↓
Foundation Model

API Gateway Request Validation

API Gateway can validate incoming requests before they reach the backend.

Client
 ↓
API Gateway
 ↓
Validate
 ├── Invalid → Reject
 └── Valid
       ↓
     Backend

This prevents malformed requests from unnecessarily reaching model infrastructure.

Key points

  • Synchronous
  • Asynchronous
  • Bedrock APIs
  • API Gateway Request Validation
  • Client
  • Application

Exam focus

Know when and how to apply Flexible Model Interaction in production GenAI implementations.

View progress