AIF-C01 Practice Question 47: Prompt Caching
AWS Certified AI Practitioner (AIF-C01) · Test 5 · question 7 of 10
A legal research assistant built on Amazon Bedrock lets a user upload a 60-page contract and then ask many follow-up questions about it. Every question resends the same system prompt and the full contract, so each response is slow and the input-token bill is high. The team wants to cut latency and input-token costs without changing models or losing any of the contract text. What should it do?
Show answer and explanation
Answer:
Prompt caching is an optional Amazon Bedrock feature for supported models that reduces inference response latency and input token costs. It helps workloads with long, repeated context reused across many queries. AWS's own example is a chatbot where users upload a document and ask questions about it: the document is cached, so later queries don't reprocess it. Static content goes at the start of the prompt, before a cache checkpoint, and cached tokens are billed at the model's lower cache-read rate (option D).
- A is wrong because splitting one contract into knowledge bases changes the architecture to retrieval. The model would see only fragments, which risks losing contract text the answers need. - B is wrong because temperature controls randomness, not length. The expensive part here is the repeated *input*, which temperature doesn't reduce. - C is wrong because fine-tuning on a single uploaded contract is slow and costly, doesn't reliably teach the model its exact wording, and would have to be repeated for every new upload.
Reference: Prompt caching for faster model inference