Cost Tracking
TrueFoundry AI Gateway supports two types of cost tracking for models:
- Public Cost: Pre-configured pricing based on provider’s published rates for commonly used models
- Private Cost: Custom pricing that can be manually configured for specialized models or custom rates (e.g. custom pricing contracts with providers) or for fine-tuned models
Public Cost
Add Public Cost
Public cost refers to the pre-configured pricing information available for commonly used models. This is provided on a best-effort basis and may not be available for all models. When you select a model that has public cost enabled:
- The cost per token is automatically populated based on Provider’s published pricing
- Pricing is kept up-to-date with the provider’s official rates
- No manual configuration needed for supported models
This feature simplifies cost management for standard models from providers like OpenAI, Anthropic, and AWS Bedrock.
When adding a model through the + Add Model
form or editing an existing model, you’ll see an option to enable public cost if it’s available for that specific model.
Private Cost
For models where we are not able to support public pricing or you need custom pricing (e.g. custom pricing contracts with providers) or for fine-tuned models:
- You can manually configure cost per token for input and output
- Track costs for private or specialized models
Add Private Cost
To set up private cost:
- When adding a new model, select Private Cost Metrics
- Enter your custom input and output token rates
- Save to apply your custom cost settings
To update private cost for an existing model:
- Click the “Edit” button next to the model
- Select Private Cost Metrics
- Update your custom input and output token rates
- Save to apply the new cost settings
This flexibility allows you to accurately track costs for any model deployment scenario.