AIF-C01
Deep Dive
According to historical AWS exam patterns, this is the single most-tested topic on the AIF-C01: identifying which of the three customization techniques to use given the scenario presented.
Contents
All three customize how a foundation model responds, but they act at different moments and with very different effort.
Prompt engineering
Changing how you phrase the instruction to the model. Doesn't touch the model or add external data. The lowest effort and the most immediate result.
RAG
Injecting relevant external information into the prompt in real time, retrieved from a knowledge base. Doesn't retrain the model, but requires retrieval infrastructure.
Fine-tuning
Continuing the model's training with your own dataset, adjusting its internal weights. Permanently changes the model's behavior. The highest effort and cost.
| Criterion | Prompt engineering | RAG | Fine-tuning |
|---|---|---|---|
| Effort | Low — immediate | Medium — requires a data pipeline | High — requires a labeled dataset and compute |
| Cost | Minimal (only inference tokens) | Medium (vector storage + inference) | High (training + storage of the tuned model) |
| What problem it solves | The model knows the answer but needs to be guided to phrase it better | The model doesn't have access to private or up-to-date information | The model needs to consistently change its behavior, tone, or domain |
| Requires retraining | No | No | Yes |
| Data updates | Not applicable | Instant (just update the knowledge base) | Requires retraining again |
| Typical example | Asking the model to respond in JSON format or with examples (few-shot) | A chatbot that answers using the company's internal manual | A model that must always speak with the brand's tone and specific legal terminology |
Mnemonic rule for the exam
If the scenario talks about "doesn't know something" → RAG. If it talks about "how it says it / what format / what tone" → prompt engineering. If it talks about "must consistently and repeatably behave differently" → fine-tuning.
Full fine-tuning
All of the model's parameters (weights) are updated during retraining. Requires a lot of compute capacity, a lot of time, and produces a complete copy of the model for each tuned version.
More expensive to train and store, but can achieve the deepest possible tuning.
PEFT (Parameter-Efficient Fine-Tuning)
Only a small subset of additional parameters (or lightweight inserted layers) is trained, keeping the base model's original weights frozen.
Much cheaper and faster to train, requires less data, and produces small artifacts that can be combined with the base model at inference time. It's the preferred approach in most practical use cases with Bedrock.
At a conceptual level, you don't need to know the mathematical details of specific PEFT techniques for the exam — it's enough to understand that PEFT achieves results similar to full fine-tuning with a fraction of the cost and compute, by not retraining the entire model.
Adjust a foundation model with your own examples using fine-tuning in Amazon Bedrock.
+1 more...
"Fine-tuning" is the general term; the exam also names these two specific approaches within that category.
Instruction tuning
Tunes the model with examples formatted as instruction → desired-response pairs (e.g. "summarize this text" → correct summary), so the model learns to follow instructions more precisely and consistently in general, not just on one very narrow task.
Transfer learning
Reuses the knowledge a model already learned on one task or domain to adapt it to another related task, instead of training from scratch. Fine-tuning a foundation model is, in essence, an application of transfer learning: you start from an already-trained model and specialize it with less data and less compute.
This is different from task-specific fine-tuning: here you keep pre-training the base model with a large volume of new, unlabeled data from a specific domain (for example, all of a company's internal technical documents, or medical literature), before applying fine-tuning for a specific task.
The goal is for the model to acquire vocabulary, style, and general domain knowledge, similar to how it was originally pre-trained but focused on that domain — a preceding, complementary step to fine-tuning, not a substitute.
Key difference from fine-tuning
Continuous pre-training uses unlabeled data and aims for the model to "learn the domain" in general. Fine-tuning uses data labeled for a specific task and aims for the model to behave in a specific way on that task.
The quality of fine-tuning depends directly on the quality of the training data used.
Curation
Selecting and cleaning the examples relevant to the task, removing irrelevant, duplicate, or low-quality data.
Governance
Controlling the origin, usage permissions, and traceability of the data used for training, especially if it includes sensitive or customer information.
Dataset size
Enough examples for the model to generalize the desired pattern, without being so large that training becomes unnecessarily expensive.
Labeling
Examples must have the correct answers or labels clearly defined, since the model learns directly from those labels.
Representativeness
The dataset must cover the real variety of cases the model will encounter in production, to avoid biases or blind spots.
RLHF (Reinforcement Learning from Human Feedback)
Instead of only using statically labeled examples, human comparisons and ratings of the model's responses are collected, and reinforcement learning is used to tune the model toward the responses people prefer — key to aligning the model with human preferences (helpfulness, tone, safety).
What it is
When you fine-tune (especially full fine-tuning) with a very specialized, narrow dataset, the model can "forget" general capabilities it had before the tuning — because its weights were strongly readjusted toward the new task, degrading its performance on tasks it wasn't continued to be trained on.
Example: a model intensively tuned only on technical support tickets can become worse at answering general knowledge questions it previously handled well.
How it's mitigated
Use PEFT techniques (which leave the original weights intact), include varied examples in the tuning dataset that preserve general capabilities, and evaluate the tuned model on both the new task and general tasks before deploying it to production.
A bank wants its assistant to always respond citing the current interest rates, which change every week.
The data changes frequently and needs to always be up to date without retraining the model.
An insurer needs the model to correctly understand and use the specific legal terminology of its policies, consistently across thousands of interactions.
A deep, consistent behavior change is needed in the domain, not just occasional information.
A team wants the model's responses to always follow a Markdown table format with specific headers.
This is an output format/style adjustment — solved by giving clear instructions and examples in the prompt, without touching the model or external data.
Did you get this topic?
Test what you just learned
An e-commerce company fine-tuned a foundation model with thousands of examples of fashion product descriptions. After the tuning, they notice the model performs worse on general questions it used to handle correctly. What phenomenon does this describe?
Put what you learned to the test with original AIF-C01 exam questions.
Start AIF-C01 mock examUnlimited mock exams with the Pro plan
Log in to track your progress.