Package com.tnsai.session.consolidation
Enum Class ForgettingCurve
- All Implemented Interfaces:
Serializable,Comparable<ForgettingCurve>,Constable
Memory decay strategies based on forgetting curves.
Controls how memory importance decays over time when not accessed.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionExponential decay (Ebbinghaus-inspired).Linear decay: score decreases linearly over time.No decay - all memories retain full importance. -
Method Summary
Modifier and TypeMethodDescriptionabstract doubleCalculates the decayed score based on age.static ForgettingCurveReturns the enum constant of this class with the specified name.static ForgettingCurve[]values()Returns an array containing the constants of this enum class, in the order they are declared.Methods inherited from class java.lang.Enum
compareTo, describeConstable, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
-
Enum Constant Details
-
NONE
No decay - all memories retain full importance. -
LINEAR
Linear decay: score decreases linearly over time. -
EXPONENTIAL
Exponential decay (Ebbinghaus-inspired).
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
decay
Calculates the decayed score based on age.- Parameters:
currentScore- Current importance score (0.0 - 1.0)age- How old the memory is- Returns:
- Decayed score
-