Anki is a smart spaced repetition flashcard program
Find a file
Jake Probst c6cb4e4373
load balancer! (#3230)
* start of load balancer

* add configuration options; option to load balance per deck

* formatting

* clippy

* add myself to contributors

* cleanup

* cargo fmt

* copyright header on load_balancer.rs

* remove extra space

* more formatting

* python formatting

* ignore this being None

only doing this cause python has awful lambdas and can't
loop in a meaningful way without doing this

* only calculate notes on each day if we are trying to avoid siblings

* don't fuzz intervals if the load balancer is enabled

* force generator to eval so this actually happens

* load balance instead of fuzzing, rather than in addition to

* use builtin fuzz_bounds rather than reinvent something new

* print some debug info on how its load balancing

* clippy

* more accurately load balance only when we want to fuzz

* incorrectly doublechecking the presence of the load balancer

* more printfs for debugging

* avoid siblings -> disperse siblings

* load balance learning graduating intervals

* load balancer: respect min/max intervals; graduating easy should be at least +1 good

* filter out after-days under minimum interval

* this is an inclusive check

* switch load balancer to caching instead of on the fly calculation

* handle case where load balancer would balance outside of its bounds

* disable lb when unselecting it in preferences

* call load_balancer in StateContext::with_review_fuzz instead of next to

* rebuild load balancer when card queue is rebuilt

* remove now-unused configuration options

* add note option to notetype to enable/disable sibling dispersion

* add options to exclude decks from load balancing

* theres a lint checking that the link actually exists so I guess I'll add the anchor back in later?

* how did I even update this

* move load balancer to cardqueue

* remove per-deck balancing options

* improve determining whether to disperse siblings when load balancing

* don't recalculate notes on days every time

* remove debug code

* remove all configuration; load balancer enabled by default; disperse siblings if bury_reviews is set

* didn't fully remove caring about decks from load balancer sql query

* load balancer should only count cards in the same preset

* fuzz interval if its outside of load balancer's range

* also check minimum when bailing out of load balancer

* cleanup; make tests happy

* experimental weight-based load balance fuzzing

* take into account interval when weighting as it seems to help

* if theres no cards the interval weight is just 1.0

* make load balancer disableable through debug console

* remove debug prints

* typo

* remove debugging print

* explain a bit how load balancer works

* properly balance per preset

* use inclusive range rather than +1

* -1 type cast

* move type hint somewhere less ugly; fix comment typo

* Reuse existing deck list from parent function (dae)

Minor optimisation
2024-08-17 12:50:54 +07:00
.buildkite Bump cargo deny version 2024-07-20 17:59:08 +07:00
.cargo Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
.config Drop workspace-hack in favor of workspace deps 2023-06-23 17:41:31 +10:00
.github/ISSUE_TEMPLATE Move away from Bazel (#2202) 2022-11-27 15:24:20 +10:00
.vscode.dist HMR on Windows (#3144) 2024-04-17 21:23:34 +10:00
build Update to Rust 1.80 2024-08-05 15:37:59 +07:00
cargo Update to FSRS-rs v1.1.4 (#3329) 2024-08-05 15:54:10 +07:00
docs Remove outdated comments in contributing, and mention refactoring 2024-08-10 18:43:11 +07:00
ftl Integrate AnkiHub Sign-in (#3232) 2024-08-17 10:58:23 +07:00
proto load balancer! (#3230) 2024-08-17 12:50:54 +07:00
pylib load balancer! (#3230) 2024-08-17 12:50:54 +07:00
python Bump Python deps 2024-07-06 18:40:37 +07:00
qt Integrate AnkiHub Sign-in (#3232) 2024-08-17 10:58:23 +07:00
rslib load balancer! (#3230) 2024-08-17 12:50:54 +07:00
tools Feat/FSRS-5 (#3298) 2024-07-21 21:02:24 +07:00
ts Added name to contributors list as well as addressed issue #3343. Ran ninja check and the build compiled successfully. (#3345) 2024-08-07 16:15:50 +07:00
.deny.toml Allow Unicode-3 license 2024-07-20 18:07:06 +07:00
.dprint.json Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
.eslintrc.cjs Include error message text on page 2024-06-24 15:35:47 +07:00
.gitattributes try again to improve GitHub's language stats 2021-01-20 13:20:45 +10:00
.gitignore Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
.gitmodules Exclude PyOxidizer from recursive checkout 2023-07-02 18:22:44 +10:00
.isort.cfg Specify Python version for auto-formatters (#3325) 2024-08-04 20:54:14 +07:00
.mypy.ini Use system certificate store (#3050) 2024-03-04 05:48:16 +00:00
.pylintrc Add ability to restore a notetype to its original configuration (#2472) 2023-04-18 14:07:51 +10:00
.ruff.toml Specify Python version for auto-formatters (#3325) 2024-08-04 20:54:14 +07:00
.rustfmt-empty.toml Move away from Bazel (#2202) 2022-11-27 15:24:20 +10:00
.rustfmt.toml Move ascii_percent_encoding into a separate repo 2023-04-12 08:45:23 +10:00
.version Bump version to 24.06.3 2024-06-24 14:55:43 +07:00
Cargo.lock Update to FSRS-rs v1.1.4 (#3329) 2024-08-05 15:54:10 +07:00
Cargo.toml Update to FSRS-rs v1.1.4 (#3329) 2024-08-05 15:54:10 +07:00
check Add a shortcut to auto-format before running checks 2023-07-02 09:59:05 +10:00
CONTRIBUTORS load balancer! (#3230) 2024-08-17 12:50:54 +07:00
LICENSE Replace css_browser_selector with our own implementation (#2854) 2023-11-30 10:57:33 +10:00
ninja Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
package.json Fix remaining accessibility warnings (#3241) 2024-07-10 19:55:08 +07:00
pkgkey.asc add public key for release signing 2018-09-18 10:40:45 +10:00
pyproject.toml Specify Python version for auto-formatters (#3325) 2024-08-04 20:54:14 +07:00
README.md Updated README (#2718) 2023-10-11 14:11:07 +10:00
run Fix webengine remote debugging in Qt6 2023-11-05 12:41:17 +10:00
run.bat HMR on Windows (#3144) 2024-04-17 21:23:34 +10:00
rust-toolchain.toml Bump Rust to 1.80.1 2024-08-17 11:29:36 +07:00
SECURITY.md add SECURITY.md 2021-09-22 22:55:19 +10:00
yarn Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
yarn.bat Switch to SvelteKit (#3077) 2024-03-31 09:16:31 +01:00
yarn.lock Update web deps 2024-07-06 18:40:37 +07:00

Anki

Build status

This repo contains the source code for the computer version of Anki.

About

Anki is a spaced repetition program. Please see the website to learn more.

Getting Started

Anki Betas

If you'd like to try development builds of Anki but don't feel comfortable building the code, please see Anki betas

Developing

For more information on building and developing, please see Development.

Contributing

Want to contribute to Anki? Check out the Contribution Guidelines.

Anki Contributors

CONTRIBUTORS

License

Anki's license: LICENSE