pub enum RecommendError {
Show 17 variants
UserNotFound(Uuid),
ContentNotFound(Uuid),
InsufficientData(String),
InvalidRating(f32),
InvalidSimilarity(f32),
MatrixError(String),
ProfileError(String),
HistoryError(String),
TrendingError(String),
PersonalizationError(String),
DiversityError(String),
RankingError(String),
ExplanationError(String),
IoError(Error),
SerializationError(Error),
RateLimited(String),
Other(String),
}Expand description
Errors that can occur during recommendation operations
Variants§
UserNotFound(Uuid)
User not found
ContentNotFound(Uuid)
Content not found
InsufficientData(String)
Insufficient data for recommendation
InvalidRating(f32)
Invalid rating value
InvalidSimilarity(f32)
Invalid similarity score
MatrixError(String)
Matrix computation error
ProfileError(String)
Profile error
HistoryError(String)
History tracking error
TrendingError(String)
Trending detection error
PersonalizationError(String)
Personalization error
DiversityError(String)
Diversity enforcement error
RankingError(String)
Ranking error
ExplanationError(String)
Explanation generation error
IoError(Error)
IO error
SerializationError(Error)
Serialization error
RateLimited(String)
Request was rate-limited
Other(String)
Generic error
Implementations§
Source§impl RecommendError
impl RecommendError
Sourcepub fn insufficient_data(msg: impl Into<String>) -> Self
pub fn insufficient_data(msg: impl Into<String>) -> Self
Create an insufficient data error
Sourcepub fn matrix_error(msg: impl Into<String>) -> Self
pub fn matrix_error(msg: impl Into<String>) -> Self
Create a matrix error
Sourcepub fn profile_error(msg: impl Into<String>) -> Self
pub fn profile_error(msg: impl Into<String>) -> Self
Create a profile error
Sourcepub fn history_error(msg: impl Into<String>) -> Self
pub fn history_error(msg: impl Into<String>) -> Self
Create a history error
Sourcepub fn trending_error(msg: impl Into<String>) -> Self
pub fn trending_error(msg: impl Into<String>) -> Self
Create a trending error
Sourcepub fn personalization_error(msg: impl Into<String>) -> Self
pub fn personalization_error(msg: impl Into<String>) -> Self
Create a personalization error
Sourcepub fn diversity_error(msg: impl Into<String>) -> Self
pub fn diversity_error(msg: impl Into<String>) -> Self
Create a diversity error
Sourcepub fn ranking_error(msg: impl Into<String>) -> Self
pub fn ranking_error(msg: impl Into<String>) -> Self
Create a ranking error
Sourcepub fn explanation_error(msg: impl Into<String>) -> Self
pub fn explanation_error(msg: impl Into<String>) -> Self
Create an explanation error
Trait Implementations§
Source§impl Debug for RecommendError
impl Debug for RecommendError
Source§impl Display for RecommendError
impl Display for RecommendError
Source§impl Error for RecommendError
impl Error for RecommendError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Source§impl From<Error> for RecommendError
impl From<Error> for RecommendError
Auto Trait Implementations§
impl !RefUnwindSafe for RecommendError
impl !UnwindSafe for RecommendError
impl Freeze for RecommendError
impl Send for RecommendError
impl Sync for RecommendError
impl Unpin for RecommendError
impl UnsafeUnpin for RecommendError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more