Sycophant.Pricing.Component
(sycophant v0.4.2)
Copy Markdown
A single pricing component from LLMDB's pricing model.
Components have a kind that determines their billing unit:
"token"-- per-token rates (input, output, cache, reasoning)"tool"-- per-call rates for built-in tools (web_search, file_search, etc.)"image"-- per-image rates by size/quality"storage"-- per-unit storage rates
Summary
Functions
Converts an LLMDB component map (atom-keyed) into a Component struct.
Reconstructs a Component struct from a serialized map (string-keyed).