omni_dev/claude/
ai_client.rs1use anyhow::Result;
4use std::future::Future;
5use std::pin::Pin;
6
7#[derive(Clone, Debug)]
9pub struct AiClientMetadata {
10 pub provider: String,
12 pub model: String,
14 pub max_context_length: usize,
16 pub max_response_length: usize,
18}
19
20pub trait AiClient: Send + Sync {
22 fn send_request<'a>(
24 &'a self,
25 system_prompt: &'a str,
26 user_prompt: &'a str,
27 ) -> Pin<Box<dyn Future<Output = Result<String>> + Send + 'a>>;
28
29 fn get_metadata(&self) -> AiClientMetadata;
31}