Model: Meta: Llama 3.2 3B Instruct, Context: 20000, Cost: $0.003 per 1M input tokens, $0.006 per 1M output tokens
Note: Calculation is approximate based on public data. Prices may change, check official websites.
Calculate the cost of using the Meta Llama 3.2 3B Instruct model. This model has a context size of 20000 tokens and costs $0.003 per 1 million input tokens and $0.006 per 1 million output tokens.
The formula used for calculation is:
Total Cost = (Number of Input Tokens / 1,000,000) * Input Token Cost + (Number of Output Tokens / 1,000,000) * Output Token Cost
Example: If you use 500,000 input tokens and 200,000 output tokens for 2 requests:
- Input Cost = (500,000 / 1,000,000) * $0.003 * 2 = $0.0015 * 2 = $0.003
- Output Cost = (200,000 / 1,000,000) * $0.006 * 2 = $0.0012 * 2 = $0.0024
- Total Cost = $0.003 + $0.0024 = $0.0054