diff --git a/src/api/client.rs b/src/api/client.rs index 8d1f2a3..25b43cf 100644 --- a/src/api/client.rs +++ b/src/api/client.rs @@ -33,4 +33,4 @@ pub async fn request_model( let body = response.text().await?; Ok(body) -} \ No newline at end of file +} diff --git a/src/api/mod.rs b/src/api/mod.rs index e5d5886..1d33131 100644 --- a/src/api/mod.rs +++ b/src/api/mod.rs @@ -1 +1 @@ -pub(crate) mod client; \ No newline at end of file +pub(crate) mod client; diff --git a/src/config.rs b/src/config.rs index fb59c6e..336a74a 100644 --- a/src/config.rs +++ b/src/config.rs @@ -35,4 +35,4 @@ impl Config { Ok(config) } -} \ No newline at end of file +} diff --git a/src/controls/mod.rs b/src/controls/mod.rs index 3429204..fd220da 100644 --- a/src/controls/mod.rs +++ b/src/controls/mod.rs @@ -1,2 +1,2 @@ +pub mod feishu; pub mod summary; -pub mod feishu; \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 0d441d2..195b475 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,7 +1,7 @@ mod api; mod config; -mod models; mod controls; +mod models; #[tokio::main] async fn main() -> Result<(), Box> { diff --git a/src/models/feishu.rs b/src/models/feishu.rs index eeac308..2afc469 100644 --- a/src/models/feishu.rs +++ b/src/models/feishu.rs @@ -1,4 +1,4 @@ #[derive(Debug, serde::Serialize, serde::Deserialize)] pub struct MessageContent { pub text: String, -} \ No newline at end of file +} diff --git a/src/models/mod.rs b/src/models/mod.rs index 9ea564b..69ff53d 100644 --- a/src/models/mod.rs +++ b/src/models/mod.rs @@ -1,3 +1,3 @@ +pub mod feishu; pub mod silicon_cloud; pub mod summary; -pub mod feishu; \ No newline at end of file diff --git a/src/models/silicon_cloud.rs b/src/models/silicon_cloud.rs index dfa27d0..c04db13 100644 --- a/src/models/silicon_cloud.rs +++ b/src/models/silicon_cloud.rs @@ -7,7 +7,7 @@ pub struct Content { pub struct ModelResponse { pub id: String, pub content: Vec, - pub model: String + pub model: String, } impl ModelResponse { @@ -15,4 +15,4 @@ impl ModelResponse { let prase_response: ModelResponse = serde_json::from_str(&response)?; Ok(prase_response) } -} \ No newline at end of file +} diff --git a/src/models/summary.rs b/src/models/summary.rs index e324430..5ea404f 100644 --- a/src/models/summary.rs +++ b/src/models/summary.rs @@ -5,9 +5,6 @@ pub struct Summary { impl Summary { pub fn new(name: String, description: String) -> Self { - Self { - name, - description, - } + Self { name, description } } -} \ No newline at end of file +}