continue tracing impl
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
use std::time::Duration;
|
||||
|
||||
use openrouter_rs::{Message, api::chat::ChatCompletionRequest};
|
||||
use tracing::instrument;
|
||||
|
||||
pub struct ChatResult {
|
||||
pub message: String,
|
||||
@@ -27,6 +28,7 @@ impl OpenRouterClient {
|
||||
})
|
||||
}
|
||||
|
||||
#[instrument(skip(self), err)]
|
||||
pub async fn chat(&self, msg: &str) -> anyhow::Result<ChatResult> {
|
||||
let request = ChatCompletionRequest::builder()
|
||||
.model(&self.model)
|
||||
|
||||
Reference in New Issue
Block a user