Smith::Pricing::Rates
Inherits Struct < Value < Object
US dollars per million tokens.
Constructors
free
Sourcenew(input : Float64, output : Float64, cache_write : Float64 | Nil = nil, cache_read : Float64 | Nil = nil)
Anthropic charges 1.25x the input rate to write the cache and 0.1x to
read it. Both default from input so an override only has to state
the two rates anyone publishes.
Instance methods
cache_read
Sourcecache_write
Sourceinput
Sourceoutput
Source