use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct IndexSettingsSimilarityBm25 {
#[serde(rename = "b")]
pub b: f64,
#[serde(rename = "k1")]
pub k_1: f64,
#[serde(rename = "type")]
pub r#type: String,
#[serde(rename = "discount_overlaps")]
pub discount_overlaps: bool,
}
impl IndexSettingsSimilarityBm25 {
pub fn new(
b: f64,
k_1: f64,
r#type: String,
discount_overlaps: bool,
) -> IndexSettingsSimilarityBm25 {
IndexSettingsSimilarityBm25 {
b,
k_1,
r#type,
discount_overlaps,
}
}
}