calculate_cost

calculate_cost(
    input_tokens: int,
    output_tokens: int,
    model_id: str
) -> float

Calculate the cost of the completion using the Bedrock pricing.

Parameters:
NameDescription
input_tokensType: int
output_tokensType: int
model_idType: str