Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.
Delete unused types for Mistral non-streaming requests (#38758)
Michael Sloan5f6ae2361f77
diff --git a/crates/mistral/src/mistral.rs b/crates/mistral/src/mistral.rsindex d6f62cfaa07..2e79a8d59f6 100644--- a/crates/mistral/src/mistral.rs+++ b/crates/mistral/src/mistral.rs@@ -267,24 +267,6 @@ pub struct FunctionDefinition {pub parameters: Option<Value>,}-#[derive(Debug, Serialize, Deserialize)]-pub struct CompletionRequest {- pub model: String,- pub prompt: String,- pub max_tokens: u32,- pub temperature: f32,- #[serde(default, skip_serializing_if = "Option::is_none")]- pub prediction: Option<Prediction>,- #[serde(default, skip_serializing_if = "Option::is_none")]- pub rewrite_speculation: Option<bool>,-}--#[derive(Clone, Deserialize, Serialize, Debug)]-#[serde(tag = "type", rename_all = "snake_case")]-pub enum Prediction {- Content { content: String },-}-#[derive(Debug, Serialize, Deserialize)]#[serde(rename_all = "lowercase")]pub enum ToolChoice {@@ -397,21 +379,6 @@ pub struct FunctionContent {pub arguments: String,}-#[derive(Serialize, Deserialize, Debug)]-pub struct CompletionChoice {- pub text: String,-}--#[derive(Serialize, Deserialize, Debug)]-pub struct Response {- pub id: String,- pub object: String,- pub created: u64,- pub model: String,- pub choices: Vec<Choice>,- pub usage: Usage,-}-#[derive(Serialize, Deserialize, Debug)]pub struct Usage {pub prompt_tokens: u64,@@ -419,13 +386,6 @@ pub struct Usage {pub total_tokens: u64,}-#[derive(Serialize, Deserialize, Debug)]-pub struct Choice {- pub index: u32,- pub message: RequestMessage,- pub finish_reason: Option<String>,-}-#[derive(Serialize, Deserialize, Debug)]pub struct StreamResponse {pub id: String,