pub enum ModelCapability {
Show 17 variants
Generate,
Embed,
Rerank,
Classify,
Code,
Reasoning,
Summarize,
ToolUse,
MultiToolCall,
Vision,
VideoUnderstanding,
AudioUnderstanding,
Grounding,
SpeechToText,
TextToSpeech,
ImageGeneration,
VideoGeneration,
}Expand description
What a model can do.
Variants§
Generate
Text completion / chat generation
Embed
Vector embeddings
Rerank
Cross-encoder relevance scoring (query + document → relevance score). Qwen3-Reranker is the canonical local implementation.
Classify
Label assignment / classification
Code
Code generation, repair, refactoring
Reasoning
Chain-of-thought, planning, analysis
Summarize
Text condensation
ToolUse
Function/tool calling
MultiToolCall
Multiple tool calls in a single response (parallel tool execution)
Vision
Vision / image understanding
VideoUnderstanding
Video understanding (multi-frame sampling + temporal tokens).
Distinct from Vision so routing can prefer video-trained
models when the caller attaches a video content block.
AudioUnderstanding
Audio understanding (speech + non-speech audio as an input to
a chat/reasoning model). Distinct from SpeechToText which is
the transcription-only task. Gemma 4 E2B/E4B and Gemini do
this; Qwen2.5-VL does not.
Grounding
Visual grounding — structured object-localization output (bounding boxes keyed to object labels) in addition to text.
SpeechToText
Speech recognition / transcription
TextToSpeech
Speech synthesis / text-to-speech
ImageGeneration
Image generation
VideoGeneration
Video generation
Trait Implementations§
Source§impl Clone for ModelCapability
impl Clone for ModelCapability
Source§fn clone(&self) -> ModelCapability
fn clone(&self) -> ModelCapability
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 ModelCapability
impl Debug for ModelCapability
Source§impl<'de> Deserialize<'de> for ModelCapability
impl<'de> Deserialize<'de> for ModelCapability
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Hash for ModelCapability
impl Hash for ModelCapability
Source§impl PartialEq for ModelCapability
impl PartialEq for ModelCapability
Source§fn eq(&self, other: &ModelCapability) -> bool
fn eq(&self, other: &ModelCapability) -> bool
self and other values to be equal, and is used by ==.Source§impl Serialize for ModelCapability
impl Serialize for ModelCapability
impl Copy for ModelCapability
impl Eq for ModelCapability
impl StructuralPartialEq for ModelCapability
Auto Trait Implementations§
impl Freeze for ModelCapability
impl RefUnwindSafe for ModelCapability
impl Send for ModelCapability
impl Sync for ModelCapability
impl Unpin for ModelCapability
impl UnsafeUnpin for ModelCapability
impl UnwindSafe for ModelCapability
Blanket Implementations§
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<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 more