Module traits

Module traits 

Source
Expand description

Core traits for LLM providers.

This module defines the foundational traits that LLM providers implement, following the Interface Segregation Principle - providers only implement the capabilities they support.

Traitsยง

ChatProvider
Base trait for chat-based LLM providers.
CompletionProvider
Trait for providers that support text completion (non-chat).
EmbeddingProvider
Trait for providers that support text embeddings.
ImageProvider
Optional trait for providers that support image generation.
SpeechToTextProvider
Optional trait for providers that support speech-to-text.
StreamingProvider
Optional trait for providers that support streaming responses.
TextToSpeechProvider
Optional trait for providers that support text-to-speech.
ToolProvider
Optional trait for providers that support tool/function calling.