Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Front Side of Card Does Not Show Correct Custom Algorithm Intervals #8

Open
SpicyRicecaker opened this issue May 22, 2023 · 2 comments

Comments

@SpicyRicecaker
Copy link

This issue is from an AnkiWeb review. I added some pictures for clarity.

Incorrect Behavior 1 :

When using FSRS4Anki (a custom card scheduling algorithm for Anki) along with this add-on, the front of the card shows intervals from Anki's native algorithm (see Figure 1).

image
Figure 1: Reviewing a Card With FSRS4Anki and Flexible Grading Add-on

Expected Behavior 1:

When using FSRS4Anki along with this add-on, the front of the card should display intervals from FSRS4Anki's custom algorithm (see Figure 2)

image
Figure 2: Reviewing a Card With FSRS4Anki but Without Flexible Grading Add-on

Notes

Once the card is flipped, the backside displays the correct custom intervals (see Figure 3).

image
Figure 3: A Flipped Card With FSRS4Anki and Flexible Grading

Incorrect Behavior 2:

After rating the card, the Last grade (on the top toolbar) displays the custom interval for the previous (see Figure 4). In the particular case of Figure 4, there seems to be some sort of rounding error on the "Last Grade".

image
Figure 4: The "Last Grade" Interval of the Same Flipped Card from Figure 1 and Figure 2

Expected Behavior 2:

The Last Grade should display the same information as the backside of the card (as seen in Figure 3).

@tatsumoto-ren
Copy link
Member

Since we don't recommend FSRS4Anki, and since I don't use it personally, I can't say why the intervals differ. Maybe the custom algorithm doesn't run until the back side is shown. One thing that might point towards this conclusion is that Flexible Grading gets estimated intervals by calling Reviewer._buttonTime() and doesn't calculate anything by itself.

The estimated interval and the final interval differ because Anki randomizes the new interval after a card is answered. The interval shown on the top toolbar (1.6mo) should be correct, but the estimated interval may deviate a bit. Please confirm if that is the case by checking the last review stats (alt+ctrl+i) and comparing the shown intervals.

screenshot-2023-05-22-22-42-06

There may be some difference between what the stats window reports and what the toolbar reports, but I'm assuming that's due to rounding.

@tatsumoto-ren
Copy link
Member

Maybe if we use round() here, we can imitate the rounding anki does.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants