mirror of
https://github.com/ankitects/anki.git
synced 2025-09-24 16:56:36 -04:00
Update to FSRS-rs v1.3.5 (FSRS-5 model update) && keep three decimals for stability (#3520)
* Update to FSRS-rs v1.3.5 (FSRS-5 model update) * keep three decimals for stability fix https://forums.ankiweb.net/t/fsrs-5-1d-scheduling-and-learning-steps/50242/122?u=l.m.sherlock
This commit is contained in:
parent
507050c876
commit
5caeac530e
4 changed files with 6 additions and 6 deletions
4
Cargo.lock
generated
4
Cargo.lock
generated
|
@ -1860,9 +1860,9 @@ dependencies = [
|
|||
|
||||
[[package]]
|
||||
name = "fsrs"
|
||||
version = "1.3.4"
|
||||
version = "1.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a05b1fdbaa34f9bcd605ad50477eea51b27b3f60f973021bd9ee1b5943169150"
|
||||
checksum = "42155527199b3e7b6ad47e9db849ee25bd5bd436ee17a72ae0a3de646a20021a"
|
||||
dependencies = [
|
||||
"burn",
|
||||
"itertools 0.12.1",
|
||||
|
|
|
@ -35,7 +35,7 @@ git = "https://github.com/ankitects/linkcheck.git"
|
|||
rev = "184b2ca50ed39ca43da13f0b830a463861adb9ca"
|
||||
|
||||
[workspace.dependencies.fsrs]
|
||||
version = "=1.3.4"
|
||||
version = "=1.3.5"
|
||||
# git = "https://github.com/open-spaced-repetition/fsrs-rs.git"
|
||||
# rev = "58ca25ed2bc4bb1dc376208bbcaed7f5a501b941"
|
||||
# path = "../open-spaced-repetition/fsrs-rs"
|
||||
|
|
|
@ -1225,7 +1225,7 @@
|
|||
},
|
||||
{
|
||||
"name": "fsrs",
|
||||
"version": "1.3.4",
|
||||
"version": "1.3.5",
|
||||
"authors": "Open Spaced Repetition",
|
||||
"repository": "https://github.com/open-spaced-repetition/fsrs-rs",
|
||||
"license": "BSD-3-Clause",
|
||||
|
|
|
@ -79,7 +79,7 @@ impl CardData {
|
|||
|
||||
pub(crate) fn convert_to_json(&mut self) -> Result<String> {
|
||||
if let Some(v) = &mut self.fsrs_stability {
|
||||
round_to_places(v, 2)
|
||||
round_to_places(v, 3)
|
||||
}
|
||||
if let Some(v) = &mut self.fsrs_difficulty {
|
||||
round_to_places(v, 3)
|
||||
|
@ -163,7 +163,7 @@ mod test {
|
|||
};
|
||||
assert_eq!(
|
||||
data.convert_to_json().unwrap(),
|
||||
r#"{"s":123.46,"d":1.235,"dr":0.99}"#
|
||||
r#"{"s":123.457,"d":1.235,"dr":0.99}"#
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue