AIF-C01 notes
Fundamentals of ML and AI

AWS Infrastructure and Technologies

Three layers, from most control to most ready-made

The story: You want dinner. You can buy raw ingredients and cook from scratch, buy a ready-made dish from a shop, or order from a restaurant that will cook anything you ask for.

In AI/AWS terms: AWS offers the same three choices:

  • ML frameworks layer, cooking from scratch: Amazon SageMaker AI (the new name for Amazon SageMaker) is a fully managed service to build, train, and deploy your own ML models.
  • AI/ML services layer, ready-made dishes: pre-trained services that need no ML expertise.
  • Generative AI layer, the restaurant: foundation models and tools to build generative AI apps.

For the exam: SageMaker AI is for building your own models. The AI services are pre-trained and need no ML expertise.

The ready-made AI services

The story: Picture a shopping street where each shop does exactly one job, and does it well.

In AI/AWS terms:

The shopServiceUse it to
A reader who tells you what a letter is about and how the writer feelsAmazon ComprehendRun NLP on text: detect language, extract key phrases and entities, analyze sentiment, and organize documents by topic
A translatorAmazon TranslateTranslate text with neural machine translation
A clerk who copies a paper form into a spreadsheet, keeping which answer goes in which boxAmazon TextractExtract text, form fields, and tables from scanned documents (more than plain OCR)
A phone operator who understands what you say and answersAmazon LexBuild chatbots and voice bots (IVR), the technology behind Alexa
A voice actor reading your script aloudAmazon PollyTurn text into lifelike speech
A stenographer typing up a meetingAmazon TranscribeTurn speech into text, in batch or real time, with a timestamp per word
A detective studying photos and CCTVAmazon RekognitionAnalyze images and video: objects, people, text, scenes, faces, and inappropriate content
A librarian who knows every shelf in the companyAmazon KendraRun intelligent enterprise search across many content repositories
A shopkeeper who remembers what you like and suggests thingsAmazon PersonalizeCreate real-time, individualized recommendations from user activity
A toy race car that learns from trial and errorAWS DeepRacerLearn reinforcement learning with a 1/18th scale autonomous race car

Watch the similar pairs: Polly speaks (text to speech), Transcribe listens (speech to text). Textract reads documents, Comprehend understands the meaning of text.

For the exam: Match the job to the service: text to speech is Polly, speech to text is Transcribe, forms and tables from scans is Textract, sentiment is Comprehend, chatbots are Lex, images and video are Rekognition, enterprise search is Kendra, recommendations are Personalize.

The generative AI layer

The story: A big restaurant has a buffet of dishes you can take and adjust, a kitchen with chefs from many famous restaurants behind one counter, a free tasting corner, a personal assistant who knows your company's files, and a helper who sits beside programmers and suggests code.

In AI/AWS terms:

  • The buffet is Amazon SageMaker JumpStart: ready-made solutions and one-click deployment and fine-tuning of popular open-source models.
  • The kitchen with one counter is Amazon Bedrock: fully managed and serverless, with FMs from Amazon and leading AI companies through a single API, which you can customize privately with your data.
  • The tasting corner is PartyRock: an Amazon Bedrock playground for experimenting with generative AI apps.
  • The assistant is Amazon Q: a generative AI assistant for work that uses your company's data.
  • The programmer's helper is Amazon Q Developer: code generation and recommendations inside IDEs.

For the exam: Bedrock = many FMs through one serverless API. JumpStart = one-click open-source models in SageMaker. PartyRock = playground. Q Developer = code help in the IDE.

Why build AI on AWS

The story: Why rent a stall in a well-run food court instead of building your own restaurant? The building, electricity, and cleaning are handled. You pay rent only for the space you use and can open branches anywhere. There are many suppliers in one place. Everything connects to the same payment system. And there's a security team, while you still lock your own cash box.

In AI/AWS terms:

  • Faster development: managed services handle infrastructure, training, and deployment.
  • Scalability and cost: pay-as-you-go pricing and global infrastructure.
  • Model choice: many FMs behind one API in Amazon Bedrock.
  • Integration: AI services connect to the rest of AWS through SDKs and APIs.
  • Security and compliance: the shared responsibility model (AWS secures the building, you secure what you put in it) and compliance programs.

For the exam: AWS benefits: faster development, scalability with pay-as-you-go, model choice, integration, security and compliance.

Cost trade-offs

The story: Running a delivery business: faster delivery and branches in more cities cost more. Keeping spare vans in case one breaks costs more. Motorbikes are faster than bicycles but pricier. A taxi meter charges by distance. Renting a van for the whole month costs more up front but guarantees you always have one. Training your own drivers costs time and money.

In AI/AWS terms:

  • Responsiveness and availability: lower latency and multi-Region deployments cost more.
  • Redundancy and Regional coverage: multiple Availability Zones or Regions add cost.
  • Performance: GPUs and accelerators cost more than CPUs but can be much faster.
  • Token-based pricing: Amazon Bedrock and Amazon Q Developer charge per token processed or generated, like the taxi meter.
  • Provisioned throughput: paying up front for capacity costs more but gives predictable performance, like the monthly van.
  • Custom models: training and fine-tuning add compute and data costs.

For the exam: More speed, availability, and redundancy cost more. Bedrock charges per token. Provisioned throughput buys predictable performance.

On this page