Skip to content

Commit

Permalink
add serde for Keyword (#465)
Browse files Browse the repository at this point in the history
Co-authored-by: guillaume-be <[email protected]>
  • Loading branch information
oiwn and guillaume-be authored Aug 18, 2024
1 parent 3df3816 commit eabebc6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pipelines/keywords_extraction/pipeline.rs
Original file line number Diff line number Diff line change
Expand Up @@ -31,12 +31,13 @@ use crate::pipelines::sentence_embeddings::{
use crate::{Config, RustBertError};
use regex::Regex;
use rust_tokenizers::Offset;
use serde::{Deserialize, Serialize};
use std::borrow::Cow;
use std::cmp::min;
use std::collections::{HashMap, HashSet};

/// # Keyword generated by a `KeywordExtractionModel`
#[derive(Debug, Clone)]
#[derive(Debug, Clone, Serialize, Deserialize)]
pub struct Keyword {
/// String representation of the keyword
pub text: String,
Expand Down

0 comments on commit eabebc6

Please sign in to comment.