Expand description
Model registry with capabilities, context windows, and metadata for popular LLMs.
This crate provides a database of known AI models sourced from LiteLLM upstream,
with their capabilities, context window sizes, pricing, and provider information.
§Example
use aither_models::{lookup, Ability};
if let Some(entry) = lookup("gpt-4o") {
assert!(entry.max_input_tokens().unwrap_or(0) > 0);
assert!(entry.has_ability(Ability::Vision));
}Re-exports§
pub use types::ModelEntry;pub use types::ModelMode;pub use types::Pricing;pub use types::Provider;
Modules§
- convert
- Shared conversion logic for
LiteLLMandOpenRouterJSON. - types
- Owned model metadata types sourced from
LiteLLMandOpenRouter.
Structs§
- Model
Registry - A searchable collection of model entries.
Enums§
- Ability
- Represents the capabilities that a language model may support.
- Model
Tier - Capability/cost tier of a model.
Functions§
- all_
models - Get all known models.
- lookup
- Look up a model by ID or alias.
- models_
by_ mode - Get all models matching a mode.
- models_
for_ provider - Get all models for a provider.
- models_
with_ ability - Get all models with a specific ability.
- tier
- Capability/cost tier of a model in the bundled registry.