Expand description
AIX Core Library
This is the core library that provides unified abstractions and types for interacting with multiple AI providers. It includes:
- Common types and error handling
- Provider traits and capabilities
- Retry logic with exponential backoff
- Streaming utilities and abstractions
§Example
use aix_core::{AiProvider, ChatRequest, ChatMessage};
let request = ChatRequest::simple("gpt-4", "Hello, world!");
let response = provider.chat(request).await?;
println!("Response: {}", response.content);Re-exports§
pub use error::AixError;pub use error::AixResult;pub use retry::RetryConfig;pub use retry::RetryStrategy;pub use streaming::StreamExt;pub use streaming::TokenStream;pub use traits::AiProvider;pub use traits::AiProviderExt;pub use traits::ModelCapabilities;pub use types::ChatMessage;pub use types::ChatRequest;pub use types::ChatResponse;pub use types::ModelConfig;pub use types::Role;pub use types::StreamChunk;pub use types::Usage;