Estimate one model request's cost in USD from LangChain usage metadata.
LangChain's input_tokens is the full input count, including cache reads and
writes. genai-prices receives that inclusive total plus the cache, modality,
and reasoning details; it subtracts each detail bucket from the total that
contains it before applying rates, so tokens are not double-counted. Only
buckets the matched model actually publishes a rate for are broken out --
forwarding one the catalog does not price leaves those tokens in the ordinary
input or output total rather than pricing them separately.
LangChain provider identifier. An empty value lets
genai-prices infer the provider from model_name.