Most of the models which you wish to invoke via AWS Bedrock, GPT, Google, etc, charges per token ( words/ characters )
For example -
A model like Claude is not a computer program that executes instructions. It is a statistical pattern matcher trained on text.
It has no CPU, no memory, no ability to run code. It only predicts the next most likely token based on patterns it saw during training.
But, some AI platforms give the model a sandboxed Python environment to actually execute code. Bedrock does have a Code Interpreter tool in Bedrock Agents — but that's a completely different setup- the overhead of setting it up just to decompress JSON makes zero sense when simply sending clean JSON is trivially easy.
Easy Way To Estimate Your Cost-
Step 1 — Measure your actual prompt size:
- Take your evidence JSON + instructions
- Paste into: https://platform.openai.com/tokenizer
- (OpenAI's tokenizer is close enough for estimation)
- It will tell you exact token count
- Cost = (input_tokens / 1000 × 0.003) + (output_tokens / 1000 × 0.015)
- Cost per case × cases per month = monthly Bedrock bill
- Strip null fields from evidence JSON → fewer tokens
- Shorten field names → fewer tokens
- Drop fields Claude doesn't need → fewer tokens
- System prompt caching → Bedrock charges less for repeated instructions
Comments
Post a Comment