pub struct Capabilities {Show 80 fields
pub native_tools: bool,
pub message_wire_format: WireDialect,
pub native_tool_wire_format: String,
pub defer_loading: bool,
pub tool_search: Vec<String>,
pub responses_api: bool,
pub hosted_tools: Vec<String>,
pub remote_mcp: bool,
pub conversation_state: bool,
pub compaction: bool,
pub background_mode: bool,
pub batch_api: bool,
pub batch_wire_format: Option<String>,
pub batch_input_mode: Option<String>,
pub batch_discount_percent: Option<u32>,
pub batch_turnaround_hours: Option<u32>,
pub tool_approval_policy: Option<String>,
pub max_tools: Option<u32>,
pub prompt_caching: bool,
pub cache_breakpoint_style: String,
pub vision: bool,
pub audio: bool,
pub pdf: bool,
pub video: bool,
pub files_api_supported: bool,
pub file_upload_wire_format: Option<String>,
pub structured_output: Option<String>,
pub json_schema: Option<String>,
pub prefers_xml_scaffolding: bool,
pub reserved_tool_call_token: bool,
pub prefers_markdown_scaffolding: bool,
pub structured_output_mode: String,
pub supports_assistant_prefill: bool,
pub prefers_role_developer: bool,
pub prefers_xml_tools: bool,
pub thinking_block_style: String,
pub emits_inline_reasoning: bool,
pub thinking_modes: Vec<String>,
pub interleaved_thinking_supported: bool,
pub anthropic_beta_features: Vec<String>,
pub vision_supported: bool,
pub image_url_input_supported: bool,
pub preserve_thinking: bool,
pub server_parser: String,
pub honors_chat_template_kwargs: bool,
pub chat_template_options_field: Option<String>,
pub requires_completion_tokens: bool,
pub chat_completions_unsupported: bool,
pub requires_streaming: bool,
pub reasoning_effort_supported: bool,
pub reasoning_effort_levels: Vec<String>,
pub reasoning_none_supported: bool,
pub max_thinking_budget: Option<i64>,
pub reasoning_disable_supported: bool,
pub reasoning_required_for_tools: bool,
pub reasoning_text_promotable: bool,
pub reasoning_wire_format: Option<String>,
pub seed_supported: bool,
pub top_k_supported: bool,
pub temperature_supported: bool,
pub top_p_supported: bool,
pub frequency_penalty_supported: bool,
pub presence_penalty_supported: bool,
pub allowed_tool_choice_modes: Vec<String>,
pub requires_tool_result_adjacency: bool,
pub supports_parallel_tool_calls: bool,
pub tools_exclude_response_format: bool,
pub recommended_endpoint: Option<String>,
pub text_tool_wire_format_supported: bool,
pub preferred_tool_format: Option<String>,
pub tool_mode_parity: Option<String>,
pub tool_mode_parity_notes: Option<String>,
pub thinking_disable_directive: Option<String>,
pub auto_reasoning_overrides: BTreeMap<String, String>,
pub provider_route_denylist: Vec<String>,
pub openrouter_provider_order: Vec<String>,
pub serving_precision: String,
pub computer_use_style: Option<ComputerUseStyle>,
pub screenshot_scaling: Option<ScreenshotScaling>,
pub safety_ack_flow: bool,
}Expand description
Resolved capabilities for a (provider, model) pair. Unset rule
fields resolve to false / empty / None so callers never have to
unwrap an Option<bool> for what are really boolean gates.
Fields§
§native_tools: bool§message_wire_format: WireDialect§native_tool_wire_format: String§defer_loading: bool§tool_search: Vec<String>§responses_api: bool§hosted_tools: Vec<String>§remote_mcp: bool§conversation_state: bool§compaction: bool§background_mode: bool§batch_api: bool§batch_wire_format: Option<String>§batch_input_mode: Option<String>§batch_discount_percent: Option<u32>§batch_turnaround_hours: Option<u32>§tool_approval_policy: Option<String>§max_tools: Option<u32>§prompt_caching: bool§cache_breakpoint_style: String§vision: bool§audio: bool§pdf: bool§video: bool§files_api_supported: bool§file_upload_wire_format: Option<String>§structured_output: Option<String>§json_schema: Option<String>Legacy mirror for CLI display and older callers.
prefers_xml_scaffolding: bool§reserved_tool_call_token: bool§prefers_markdown_scaffolding: bool§structured_output_mode: String§supports_assistant_prefill: bool§prefers_role_developer: bool§prefers_xml_tools: bool§thinking_block_style: String§emits_inline_reasoning: boolWhether this route emits its reasoning INLINE in the text channel as
<think>...</think> blocks (local Ollama/llama.cpp reasoning models,
Qwen3 via vLLM, Kimi) rather than in a separate provider reasoning
field. When true, the llm_call envelope builder splits those blocks
out of text/prose/visible_text and folds them into the reasoning
channel, mirroring how hosted providers surface a dedicated thinking
field. Derived from thinking_block_style == "inline" — the same
population that represents reasoning as inline <think> in prompt
context is the one that emits it that way in responses.
thinking_modes: Vec<String>§interleaved_thinking_supported: bool§anthropic_beta_features: Vec<String>§vision_supported: bool§image_url_input_supported: bool§preserve_thinking: bool§server_parser: String§honors_chat_template_kwargs: bool§chat_template_options_field: Option<String>§requires_completion_tokens: bool§chat_completions_unsupported: boolTrue when the route is served ONLY by the provider Responses API and
rejects /v1/chat/completions (OpenAI *-codex models). Harn routes
such calls through the Responses provider automatically.
requires_streaming: bool§reasoning_effort_supported: bool§reasoning_effort_levels: Vec<String>§reasoning_none_supported: bool§max_thinking_budget: Option<i64>See ProviderRule::max_thinking_budget. None means the model uses
the provider’s own default ceiling.
reasoning_disable_supported: bool§reasoning_required_for_tools: bool§reasoning_text_promotable: bool§reasoning_wire_format: Option<String>§seed_supported: bool§top_k_supported: bool§temperature_supported: bool§top_p_supported: bool§frequency_penalty_supported: bool§presence_penalty_supported: bool§allowed_tool_choice_modes: Vec<String>§requires_tool_result_adjacency: bool§supports_parallel_tool_calls: bool§tools_exclude_response_format: bool§recommended_endpoint: Option<String>§text_tool_wire_format_supported: bool§preferred_tool_format: Option<String>§tool_mode_parity: Option<String>§tool_mode_parity_notes: Option<String>§thinking_disable_directive: Option<String>§auto_reasoning_overrides: BTreeMap<String, String>Per-task auto-policy reasoning-level overrides for this route.
See ProviderRule::auto_reasoning_overrides.
provider_route_denylist: Vec<String>OpenRouter upstream provider names to exclude from routing for this
row. See ProviderRule::provider_route_denylist. Empty means “no
route restriction”.
openrouter_provider_order: Vec<String>OpenRouter upstream provider names this row is PINNED to (allowlist), in
preference order. See ProviderRule::openrouter_provider_order. Empty
means “no pin” (free OpenRouter routing).
serving_precision: StringServing-quality / precision trust verdict for this route. See
ProviderRule::serving_precision. "unverified" when unset.
computer_use_style: Option<ComputerUseStyle>How the neutral computer tool projects onto this route’s native
computer-use surface. None means the route exposes no computer-use
surface. See ComputerUseStyle.
screenshot_scaling: Option<ScreenshotScaling>Screenshot downscaling policy applied before the image reaches the
model. None means unset. See ScreenshotScaling.
safety_ack_flow: boolWhether this route requires echoing acknowledged safety checks on the
computer-use follow-up turn (OpenAI Responses pending_safety_checks
→ acknowledged_safety_checks). See ProviderRule::safety_ack_flow.
Trait Implementations§
Source§impl Clone for Capabilities
impl Clone for Capabilities
Source§fn clone(&self) -> Capabilities
fn clone(&self) -> Capabilities
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for Capabilities
impl Debug for Capabilities
Source§impl Default for Capabilities
impl Default for Capabilities
impl Eq for Capabilities
Source§impl PartialEq for Capabilities
impl PartialEq for Capabilities
Source§fn eq(&self, other: &Capabilities) -> bool
fn eq(&self, other: &Capabilities) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for Capabilities
Auto Trait Implementations§
impl Freeze for Capabilities
impl RefUnwindSafe for Capabilities
impl Send for Capabilities
impl Sync for Capabilities
impl Unpin for Capabilities
impl UnsafeUnpin for Capabilities
impl UnwindSafe for Capabilities
Blanket Implementations§
Source§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
Source§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Paint for Twhere
T: ?Sized,
impl<T> Paint for Twhere
T: ?Sized,
Source§fn fg(&self, value: Color) -> Painted<&T>
fn fg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the foreground set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like red() and
green(), which have the same functionality but are
pithier.
§Example
Set foreground color to white using fg():
use yansi::{Paint, Color};
painted.fg(Color::White);Set foreground color to white using white().
use yansi::Paint;
painted.white();Source§fn bright_black(&self) -> Painted<&T>
fn bright_black(&self) -> Painted<&T>
Source§fn bright_red(&self) -> Painted<&T>
fn bright_red(&self) -> Painted<&T>
Source§fn bright_green(&self) -> Painted<&T>
fn bright_green(&self) -> Painted<&T>
Source§fn bright_yellow(&self) -> Painted<&T>
fn bright_yellow(&self) -> Painted<&T>
Source§fn bright_blue(&self) -> Painted<&T>
fn bright_blue(&self) -> Painted<&T>
Source§fn bright_magenta(&self) -> Painted<&T>
fn bright_magenta(&self) -> Painted<&T>
Source§fn bright_cyan(&self) -> Painted<&T>
fn bright_cyan(&self) -> Painted<&T>
Source§fn bright_white(&self) -> Painted<&T>
fn bright_white(&self) -> Painted<&T>
Source§fn bg(&self, value: Color) -> Painted<&T>
fn bg(&self, value: Color) -> Painted<&T>
Returns a styled value derived from self with the background set to
value.
This method should be used rarely. Instead, prefer to use color-specific
builder methods like on_red() and
on_green(), which have the same functionality but
are pithier.
§Example
Set background color to red using fg():
use yansi::{Paint, Color};
painted.bg(Color::Red);Set background color to red using on_red().
use yansi::Paint;
painted.on_red();Source§fn on_primary(&self) -> Painted<&T>
fn on_primary(&self) -> Painted<&T>
Source§fn on_magenta(&self) -> Painted<&T>
fn on_magenta(&self) -> Painted<&T>
Source§fn on_bright_black(&self) -> Painted<&T>
fn on_bright_black(&self) -> Painted<&T>
Source§fn on_bright_red(&self) -> Painted<&T>
fn on_bright_red(&self) -> Painted<&T>
Source§fn on_bright_green(&self) -> Painted<&T>
fn on_bright_green(&self) -> Painted<&T>
Source§fn on_bright_yellow(&self) -> Painted<&T>
fn on_bright_yellow(&self) -> Painted<&T>
Source§fn on_bright_blue(&self) -> Painted<&T>
fn on_bright_blue(&self) -> Painted<&T>
Source§fn on_bright_magenta(&self) -> Painted<&T>
fn on_bright_magenta(&self) -> Painted<&T>
Source§fn on_bright_cyan(&self) -> Painted<&T>
fn on_bright_cyan(&self) -> Painted<&T>
Source§fn on_bright_white(&self) -> Painted<&T>
fn on_bright_white(&self) -> Painted<&T>
Source§fn attr(&self, value: Attribute) -> Painted<&T>
fn attr(&self, value: Attribute) -> Painted<&T>
Enables the styling Attribute value.
This method should be used rarely. Instead, prefer to use
attribute-specific builder methods like bold() and
underline(), which have the same functionality
but are pithier.
§Example
Make text bold using attr():
use yansi::{Paint, Attribute};
painted.attr(Attribute::Bold);Make text bold using using bold().
use yansi::Paint;
painted.bold();Source§fn rapid_blink(&self) -> Painted<&T>
fn rapid_blink(&self) -> Painted<&T>
Source§fn quirk(&self, value: Quirk) -> Painted<&T>
fn quirk(&self, value: Quirk) -> Painted<&T>
Enables the yansi Quirk value.
This method should be used rarely. Instead, prefer to use quirk-specific
builder methods like mask() and
wrap(), which have the same functionality but are
pithier.
§Example
Enable wrapping using .quirk():
use yansi::{Paint, Quirk};
painted.quirk(Quirk::Wrap);Enable wrapping using wrap().
use yansi::Paint;
painted.wrap();Source§fn clear(&self) -> Painted<&T>
👎Deprecated since 1.0.1: renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
fn clear(&self) -> Painted<&T>
renamed to resetting() due to conflicts with Vec::clear().
The clear() method will be removed in a future release.
Source§fn whenever(&self, value: Condition) -> Painted<&T>
fn whenever(&self, value: Condition) -> Painted<&T>
Conditionally enable styling based on whether the Condition value
applies. Replaces any previous condition.
See the crate level docs for more details.
§Example
Enable styling painted only when both stdout and stderr are TTYs:
use yansi::{Paint, Condition};
painted.red().on_yellow().whenever(Condition::STDOUTERR_ARE_TTY);