ModelPricing

org.llm4s.model.ModelPricing
See theModelPricing companion object
case class ModelPricing(inputCostPerToken: Option[Double], outputCostPerToken: Option[Double], cacheCreationInputTokenCost: Option[Double], cacheReadInputTokenCost: Option[Double], inputCostPerTokenBatches: Option[Double], outputCostPerTokenBatches: Option[Double], inputCostPerTokenPriority: Option[Double], outputCostPerTokenPriority: Option[Double], outputCostPerReasoningToken: Option[Double], inputCostPerAudioToken: Option[Double], outputCostPerAudioToken: Option[Double], inputCostPerImage: Option[Double], outputCostPerImage: Option[Double], inputCostPerPixel: Option[Double], outputCostPerPixel: Option[Double])

Detailed pricing information for a model.

Attributes

Companion
object
Graph
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all

Members list

Value members

Concrete methods

def estimateCost(inputTokens: Int, outputTokens: Int): Option[Double]

Estimate the cost of a completion given token counts.

Estimate the cost of a completion given token counts.

Value parameters

inputTokens

Number of input tokens

outputTokens

Number of output tokens

Attributes

Returns

Estimated cost in dollars

Inherited methods

def productElementNames: Iterator[String]

Attributes

Inherited from:
Product
def productIterator: Iterator[Any]

Attributes

Inherited from:
Product