Skip to main content

Crate everruns_model_profiles

Crate everruns_model_profiles 

Source
Expand description

Moved. everruns-model-profiles is now part of everruns-contracts, in the Everruns ecosystem. This deprecated shim receives no further updates and leaves the workspace after one migration release.

Replace everruns_model_profiles:: with everruns_contracts::model_profile_data::.

use everruns_contracts::model_profile_data::get_model_profile;
let profile = get_model_profile("anthropic", "claude-sonnet-5").expect("known model");
assert_eq!(profile.family, "claude-sonnet-5");

Modules§

profiles

Structs§

CostTier
A pricing tier that activates above a context token threshold. For example, OpenAI charges higher rates for prompts exceeding 200K tokens.
ModelCost
Cost information for the model (per million tokens)
ModelLimits
Token limits for the model
ModelModalities
Model modalities for input and output
ModelProfileEntry
A canonical registry identity and its capability/pricing profile.
ReasoningEffortConfig
Reasoning effort configuration for a model
ReasoningEffortValue
Named reasoning effort value for UI display
SpeedConfig
Speed configuration for a model
SpeedValue
Named speed value for UI display
VerbosityConfig
Verbosity configuration for a model
VerbosityValue
Named verbosity value for UI display

Enums§

Modality
Modality type (text, image, audio, video)
ModelVendor
Vendor / brand that authored a model. Independent of the provider type that serves it (the same model may be offered by several providers or gateways). Primarily drives UI iconography.
ReasoningEffort
Reasoning effort level for models that support it
ServiceKind
A typed service a provider driver can offer (see knowledge/foundations/providers.md).
Speed
Speed level for models that expose a latency/price service tier. Wire values map 1:1 to the OpenAI service_tier request parameter: flex (slower, cheaper), default (standard), priority (faster, premium), fast (OpenAI’s current name for priority; the API accepts both), and ultrafast (premium speed tier, model-gated). auto is deliberately not offered — omitting the field preserves the provider’s default routing.
Verbosity
Verbosity level for models that support output-length control. Wire values map 1:1 to the OpenAI verbosity request parameter: low (terse), medium (balanced, provider default), high (comprehensive). Independent of ReasoningEffort, which tunes the amount of reasoning rather than the length of the final answer.

Constants§

CLEAR_AT_PARAMETER
Model-profile parameter for message expiry.
MID_CONVERSATION_SYSTEM_PARAMETER
Model-profile parameter for messages-array system roles.

Functions§

all_profile_entries
Enumerate canonical registry entries once each, in registry order. Profiles are provider-independent, as in super::get_model_profile_by_key. This is the curated registry, not the entire models.dev catalog; aliases and dated ids do not produce extra entries. Order is not a recommendation ranking.
all_profiles
Enumerate every canonical profile in registry order, without provider masking. Use all_profile_entries when model ids or service kinds are needed.
estimate_cost_usd
Estimate the USD cost of a generation from the model’s static price-table profile, discounting cached-read tokens at the model’s cache_read rate. Returns None when there is no profile or no cost data for the model — callers then have no estimate to record and fall back accordingly.
estimate_cost_usd_for_speed
estimate_cost_usd priced at the service tier that served the request.
get_model_profile
Get a model profile by matching provider_type and model_id. Returns None if the id is not in the registry or is not offered under the given provider type.
get_model_profile_by_key
Look up a profile by its stable key ("{vendor}/{canonical_id}").
get_model_profile_key
Stable public profile key: "{vendor}/{canonical_id}" (knowledge/foundations/providers.md).
get_model_service_kind
Which provider service a model belongs to. Unknown models default to ServiceKind::Chat.
get_model_vendor
Get the vendor/brand for a model id, or None if it is not in the registry (or not offered under the given provider type).
profile_entries_for_provider
Enumerate canonical entries offered under a provider wire id, in registry order, with the same capability masking as get_model_profile. Unknown provider ids return an empty list. Registry coverage is not live availability.
profiles_for_provider
Enumerate profiles for a provider wire id, applying lookup’s capability masks. Unknown provider ids return an empty list. Use profile_entries_for_provider when model ids or service kinds are needed.
selected_profiles
Enumerate the curated selection. Today the registry is itself the selection, so this is identical to all_profiles; no independent preset list exists.
selected_profiles_for_provider
Enumerate the curated selection for a provider. Today this is identical to profiles_for_provider, including its provider capability masking.

Type Aliases§

ModelProfileDeprecated
Moved to everruns_contracts::model_profile_data::ModelProfile.