Max Tokens
An inference parameter capping the length of the model's response.
The maxTokens inference parameter in Amazon Bedrock tells a model the maximum number of tokens it may generate in a single response. Because foundation models charge for both input and output tokens, a tight value is a direct cost control: a response capped at 200 tokens costs less than one allowed to run to 2,000. The key exam distinction is that max tokens governs output length only, while the context window governs the combined input-plus-output budget. A model can have a large context window yet still produce a short response if max tokens is low. Confusing the two leads to misdiagnosing why a response was truncated versus why a long prompt was rejected.
PlayPrepHQ study notes are written and reviewed against primary exam sources. How we create & review content →