fsrs-rs-python 0.9.2__cp312-cp312-win_arm64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,5 @@
1
+ from .fsrs_rs_python import *
2
+
3
+ __doc__ = fsrs_rs_python.__doc__
4
+ if hasattr(fsrs_rs_python, "__all__"):
5
+ __all__ = fsrs_rs_python.__all__
@@ -0,0 +1,165 @@
1
+ from typing import List, Optional, Sequence
2
+
3
+ class FSRS:
4
+ ...
5
+ def __init__(self, parameters: Sequence[float]) -> None: ...
6
+ def next_states(
7
+ self,
8
+ current_memory_state: Optional[MemoryState],
9
+ desired_retention: float,
10
+ days_elapsed: int,
11
+ ) -> NextStates: ...
12
+ def next_interval(
13
+ self,
14
+ stability: Optional[float],
15
+ desired_retention: float,
16
+ rating: int,
17
+ ) -> float: ...
18
+ def compute_parameters(
19
+ self,
20
+ fsrs_items: Sequence[FSRSItem],
21
+ card_ids: Optional[Sequence[int]] = None,
22
+ enable_short_term: bool = True,
23
+ num_relearning_steps: Optional[int] = None,
24
+ training_config: Optional[TrainingConfig] = None,
25
+ ) -> List[float]: ...
26
+ def benchmark(
27
+ self,
28
+ fsrs_items: Sequence[FSRSItem],
29
+ card_ids: Optional[Sequence[int]] = None,
30
+ enable_short_term: bool = True,
31
+ num_relearning_steps: Optional[int] = None,
32
+ training_config: Optional[TrainingConfig] = None,
33
+ ) -> List[float]: ...
34
+ def memory_state_from_sm2(
35
+ self, ease_factor: float, interval: float, sm2_retention: float
36
+ ) -> MemoryState: ...
37
+ def memory_state(
38
+ self, item: FSRSItem, starting_state: Optional[MemoryState] = None
39
+ ) -> MemoryState: ...
40
+ def memory_state_batch(
41
+ self,
42
+ items: Sequence[FSRSItem],
43
+ starting_states: Optional[Sequence[Optional[MemoryState]]] = None,
44
+ ) -> List[MemoryState]: ...
45
+ def historical_memory_states(
46
+ self, item: FSRSItem, starting_state: Optional[MemoryState] = None
47
+ ) -> List[MemoryState]: ...
48
+ def historical_memory_state_batch(
49
+ self,
50
+ items: Sequence[FSRSItem],
51
+ starting_states: Optional[Sequence[Optional[MemoryState]]] = None,
52
+ ) -> List[List[MemoryState]]: ...
53
+ def evaluate(self, fsrs_items: Sequence[FSRSItem]) -> ModelEvaluation: ...
54
+
55
+ class TrainingConfig:
56
+ num_epochs: int
57
+ batch_size: int
58
+ seed: int
59
+ learning_rate: float
60
+ max_seq_len: int
61
+ gamma: float
62
+ def __init__(
63
+ self,
64
+ num_epochs: int = 5,
65
+ batch_size: int = 512,
66
+ seed: int = 2023,
67
+ learning_rate: float = 4e-2,
68
+ max_seq_len: int = 256,
69
+ gamma: float = 1.0,
70
+ ) -> None: ...
71
+
72
+ class ModelEvaluation:
73
+ log_loss: float
74
+ rmse_bins: float
75
+
76
+ class FSRSItem:
77
+ ...
78
+ reviews: List[FSRSReview]
79
+ def __init__(self, reviews: Sequence[FSRSReview]) -> None: ...
80
+ def long_term_review_cnt(self) -> int: ...
81
+
82
+ class FSRSReview:
83
+ ...
84
+ def __init__(self, rating: int, delta_t: int) -> None: ...
85
+
86
+ class MemoryState:
87
+ def __init__(self, stability: float, difficulty: float) -> None: ...
88
+ stability: float
89
+ difficulty: float
90
+
91
+ class NextStates:
92
+ hard: ItemState
93
+ good: ItemState
94
+ again: ItemState
95
+ easy: ItemState
96
+
97
+ class ItemState:
98
+ memory: MemoryState
99
+ interval: float
100
+
101
+ class SimulationResult:
102
+ memorized_cnt_per_day: list[float]
103
+ review_cnt_per_day: list[int]
104
+ learn_cnt_per_day: list[int]
105
+ cost_per_day: list[float]
106
+ correct_cnt_per_day: list[int]
107
+ average_desired_retention: Optional[float]
108
+ introduced_cnt_per_day: list[int]
109
+
110
+ class SimulatorConfig:
111
+ deck_size: int
112
+ learn_span: int
113
+ max_cost_perday: float
114
+ max_ivl: float
115
+ first_rating_prob: list[float] # List of 4 floats
116
+ review_rating_prob: list[float] # List of 3 floats
117
+ learning_step_transitions: list[list[float]] # 3 rows of 4 floats
118
+ relearning_step_transitions: list[list[float]] # 3 rows of 4 floats
119
+ state_rating_costs: list[list[float]] # 3 rows of 4 floats
120
+ learning_step_count: int
121
+ relearning_step_count: int
122
+ learn_limit: int
123
+ review_limit: int
124
+ new_cards_ignore_review_limit: bool
125
+ suspend_after_lapses: Optional[int] = None
126
+ def __init__(
127
+ self,
128
+ deck_size: int,
129
+ learn_span: int,
130
+ max_cost_perday: float,
131
+ max_ivl: float,
132
+ first_rating_prob: Sequence[float],
133
+ review_rating_prob: Sequence[float],
134
+ learn_limit: int,
135
+ review_limit: int,
136
+ new_cards_ignore_review_limit: bool,
137
+ learning_step_transitions: Sequence[Sequence[float]],
138
+ relearning_step_transitions: Sequence[Sequence[float]],
139
+ state_rating_costs: Sequence[Sequence[float]],
140
+ learning_step_count: int,
141
+ relearning_step_count: int,
142
+ suspend_after_lapses: Optional[int] = None,
143
+ ) -> None: ...
144
+
145
+ def simulate(
146
+ w: Sequence[float],
147
+ desired_retention: float,
148
+ config: Optional[SimulatorConfig] = None,
149
+ seed: Optional[int] = None,
150
+ ) -> SimulationResult: ...
151
+ def default_simulator_config() -> SimulatorConfig: ...
152
+ def evaluate_with_time_series_splits(
153
+ fsrs_items: Sequence[FSRSItem],
154
+ card_ids: Optional[Sequence[int]] = None,
155
+ enable_short_term: bool = True,
156
+ num_relearning_steps: Optional[int] = None,
157
+ training_config: Optional[TrainingConfig] = None,
158
+ ) -> ModelEvaluation: ...
159
+ def filter_outlier(
160
+ dataset_for_initialization: Sequence[FSRSItem],
161
+ trainset: Sequence[FSRSItem],
162
+ ) -> tuple[List[FSRSItem], List[FSRSItem]]: ...
163
+ def check_and_fill_parameters(parameters: Sequence[float]) -> List[float]: ...
164
+
165
+ DEFAULT_PARAMETERS: List[float]
File without changes
@@ -0,0 +1,7 @@
1
+ Metadata-Version: 2.4
2
+ Name: fsrs-rs-python
3
+ Version: 0.9.2
4
+ Classifier: Programming Language :: Rust
5
+ Classifier: Programming Language :: Python :: Implementation :: CPython
6
+ Classifier: Programming Language :: Python :: Implementation :: PyPy
7
+ Requires-Python: >=3.9
@@ -0,0 +1,8 @@
1
+ fsrs_rs_python/__init__.py,sha256=ymPX_Nul6Qj06zEOjvSrJjsd0NYMjgA4WP180L1F34s,139
2
+ fsrs_rs_python/__init__.pyi,sha256=aabn6tyiWDy05RhJlIt2Ysz6DBhriJt5lR0vz2RhoC4,5401
3
+ fsrs_rs_python/fsrs_rs_python.cp312-win_arm64.pyd,sha256=4gsOVA6kOfn9OZNFEUNIuWOOa7qvJND0uYq-njnZIeI,724992
4
+ fsrs_rs_python/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
5
+ fsrs_rs_python-0.9.2.dist-info/METADATA,sha256=iQi8r_7bUId9EqF1NksHSEtBpMxRk-HkOYttqw9b08A,263
6
+ fsrs_rs_python-0.9.2.dist-info/WHEEL,sha256=yQ3R894bY64C-oKws6yqwCFWNwuISt1vMrK0Gto2IMM,97
7
+ fsrs_rs_python-0.9.2.dist-info/sboms/fsrs-rs-python.cyclonedx.json,sha256=xWLTzDvK7jKKa8N3UZW1wz9ooGHIJ3SaIaS4CSuyEBY,75639
8
+ fsrs_rs_python-0.9.2.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: maturin (1.13.3)
3
+ Root-Is-Purelib: false
4
+ Tag: cp312-cp312-win_arm64