wilddom / memrise2anki-extension

An extension for Anki 2 that downloads and converts a course from Memrise into an Anki deck.
ISC License
159 stars 22 forks source link

Import presentation order for never seen levels #44

Closed tomzx closed 7 years ago

tomzx commented 7 years ago

Hello,

It seems that when importing courses, that the things are inserted in Anki in not necessarily the same order you would learn them on the memrise site.

I did a bit of digging around in order to better understand the data that memrise2anki-extension uses in order to hopefully point out a track toward a solution.

It seems that the appropriate presentation order should use the boxes property from the ajax/session endpoint to schedule learning when the thingusers property is empty. Not doing so currently results in a somewhat random scheduling order. Scheduling is well separated between levels, but the ordering within the levels makes it harder to learn things when you're shown the composite word before its base word.

The boxes property is an array with items

{
  "template": "presentation",
  "thing_id": THING_ID,
  "column_a": 1,
  "column_b": 2
}

which appears to follow the order used when displaying the cards in preview mode.

Thus, it seems that given an empty thingusers, the boxes list order should be used in order to create the cards/notes in the proper order to ease learning.

As a side request (if this change is implemented), it would be nice if one could only update the schedule/presentation order of unseen cards/notes through the import mechanism. Otherwise I guess one can delete the whole deck and reimport.

wilddom commented 7 years ago

Could you please manually update the addon from the repo and try the latest changes? The positions will always (there is no option) be imported or updated, but of course already learned cards/notes are left untouched. Does everything work for you as intended?

tomzx commented 7 years ago

@wilddom After a quick test, it seems to work as intended!

Thanks for the prompt update!

Edit: After trying out the decks, it seems that there's some odd scheduling going on. It seems to be ordering the cards just fine, but it interleaves two levels. For instance, here's the Mandarin Chinese 2 course imported into Anki with this change: anki_2017-05-28_22-54-34

In this picture, the display order should be rows 1, 3, 5, 7, 9, etc. which are level 1 words, while 2, 4, 6, 8, etc. are level 2 words. Let me know if you need more details to diagnose this.

wilddom commented 7 years ago

Okay, thanks for testing, I think I know what's going on, but I'll have to take a closer look.

wilddom commented 7 years ago

@tomzx Have another go

tomzx commented 7 years ago

Perfect! Thanks for the followup. :+1: