Skip to content

ModelCostTier

Base classes

Name Children Inherits
dict
builtins
dict() -> new empty dictionary

⋔ Inheritance diagram

graph TD
  2769327830["toko_types.ModelCostTier"]
  2645524081["builtins.dict"]
  2751680898["builtins.object"]
  2645524081 --> 2769327830
  2751680898 --> 2645524081

🛈 DocStrings

Bases: TypedDict

Prices that apply to a request above a prompt size (LiteLLM's *_above_<N>k_tokens).

Source code in src/tokonomics/toko_types.py
class ModelCostTier(TypedDict, total=False):
    """Prices that apply to a request above a prompt size (LiteLLM's ``*_above_<N>k_tokens``)."""

    input_cost_per_token: Decimal
    output_cost_per_token: Decimal
    cache_read_input_token_cost: Decimal
    cache_creation_input_token_cost: Decimal

:fa-brands-github: Show source on GitHub