/CourseDump2022

Google Chrome extension to download Memrise courses as csv files

Primary LanguageJavaScript

CourseDump2022

This Google Chrome extension downloads word lists from Memrise courses as .csv spreadsheets along with all the associated audio and video files. It also supports batch download of Memrise courses. The format of the downloaded data is suitable for subsequent import into Anki.

The extension does not download personal study data (although such functionality can be added if requested). It also does not download the words you have marked as "ignored" on Memrise. You might want to unignore them before downloading a course or make a separate clean Memrise account specifically for downloading data from it.

Downloading the Extension

At the top of this page click Code and then Download ZIP (Note, that the Code button might be hidden if your browser window is not wide enough)

Installation

  1. Download the CourseDump2022-main.zip archive and extract CourseDump2022-main folder from it. At this step, you can move the extension folder to any place in your filesystem.
  2. In Google Chrome click the Extensions button Chrome extension icon and then Manage extensions
    (alternatively go to the Main menu `Menu` in the top right corner and click More tools -> Extensions)
  3. Enable Developer mode (top right corner of the page)
    Developer mode off->on
  4. Choose Load unpacked (top left corner of the page) and select the CourseDump2022-main folder extracted in step 1
  5. (optional) Click the Extensions button from step 2 again and pin the extension to the toolbar by clicking the pin button

Downloading a Memrise Course

  1. Make sure you are logged in on Memrise
  2. Navigate to any page belonging to a course you want to download (example-1, example-2)
  3. If you are downloading a course with a lot of media files, make sure you have the option Ask where to save each file before downloading in the Chrome settings (chrome://settings/downloads) disabled
  4. Simply click the extension icon CourseDump2022 icon on the toolbar
    (if you skipped the last installation step, click the Extensions button Chrome extension icon and then `CourseDump2022`)

After that you should see a progress bar at the top, indicating the progress of the extension scanning the course's page:

When the scanning is complete, the bar will start to fill with yellow, as the extension sends the .csv file, course metadata, and media files (if you choose to download them) to Google Chrome download queue. The downloaded files should appear in your downloads directory, in a subfolder named with the course's name and id, as well as the name of the author.

Batch download

  1. Make a list of urls of the Memrise courses to download in the queue.txt file found in the extension folder (make sure to write full urls, including the name of a course after its number – the examples are provided in the file)
  2. Set "batch_download": true (changing settings)
  3. During the batch download the option of downloading media is defined by always_download_media parameter. So set "always_download_media": true to download all media files or "always_download_media": false to download none
  4. Open any Memrise page and make sure you are logged in
  5. Click the extension icon CourseDump2022 icon

Importing into Anki

Simple import without media

  1. In Anki click File and then Import
  2. Navigate to the .csv file created after step 3 of downloading a course
  3. Adjust the import settings:
    1. Indicate the Note Type you want to use in the Type field (if you don't have any particular Note Type in mind, the Basic one will do)
    2. In the Deck field select the Deck you want cards to go into (you can create a new one from this menu by clicking a deck name after the Deck field and then Add)
    3. Check the Field mapping

      By default, the last column in .csv is filled with tags. All the fields from .csv that you don't want to import into Anki can be left out by selecting Change -> Ignore field.

After you click the Import button you should see a message indicating how many notes have been imported:

Anki Import report

You can compare this number against the total number of words in the Memrise course you've been downloading. You can also check out the imported notes after clicking `Close` by going to `Browse` and selecting your deck in the deck list on the left side

Anki Browser Deck list

Full import with media

The overall process is the same as importing without media with two differences:

  1. You need to move all media files from the course ..._media subfolder they have been downloaded into to your Anki's collection.media folder. The default path on different systems is as follows:

    • Windows: %APPDATA%\\Anki2\\[your Anki username]\\collection.media
    • Mac: ~/Library/Application Support/Anki2/[your Anki username]/collection.media (the Library folder is hidden by default, but can be revealed in Finder by holding down the option key while clicking on the Go menu)
    • Linux: ~/.local/share/Anki2/[your Anki username]/collection.media for native installs or ~/.var/app/net.ankiweb.Anki/data/Anki2/[your Anki username]/collection.media for flatpak installs

    Note, that you should move the files themselves, without the subfolder containing them.

  2. In order to facilitate the further editing of cards in Anki, the extension lists media files in the spreadsheets as separate columns. Because of that, you will need a Note Type with more than two fields to be used for step 3.i. of importing. If you don't already have such Note Type in mind (the Basic ones will not suffice in this case), you have two options:

    • Use one of the templates provided by the Extension as a basis for your new Note Type (which you will be able to adjust to your liking at any point). In order to import templates into your Anki double-click the Anki Templates.apkg file found in the CourseDump2022-main folder (or go to File -> Import in Anki and then select the .apkg file). It will create three Note Types for you - Basic (with media), Basic (and reversed card with media), and Basic (reading, writing, and listening) (the difference is in the number and types of questions they've been set up to produce) - any of these three can be used for importing .csv tables with audio and video fields.
      On top of that, importing the Anki Templates.apkg file adds a deck with three example cards to your Anki collection. This deck and the cards can be safely deleted right after if you don't need them.
    • Modify an existing Note Type adding Audio and/or Video fields. To do so:
      1. In Anki go to Tools -> Manage Note Types
      2. Select a Note Type you would like to edit from the list (e.g. the Basic one)
      3. Press Fields then Add buttons, and type a name (e.g. Audio. Repeat the adding for Video and other extra fields as needed).
        You might want to clone the existing Note Type before adding fields though, so as to preserve the original. For that, before step b.: click Add -> select the Note Type from the list to clone -> OK -> enter a new name -> OK -> go to step b. and select the new Note Type.

    You might also want to look at this template to create Anki cards, which look and function similarly to the original Memrise courses.

    For additional information regarding the Note Types editing please refer to this section of Anki manual.

A typical Field mapping for importing with media looks like this:

Settings

The settings for the extension are stored in settings.json file inside the extension root folder. For example, if you want the extension to download media by default without asking every time:

  1. Open settings.json in any text editor
  2. Locate "always_download_media": false and change it to "always_download_media": true
  3. Save the file

The other available settings that can be changed in the same way:

option description
display_anki_help_prompt Setting to false disables the popup which links to this page after the download
batch_download Setting to true enables batch download of Memrise courses
level_tags Setting to false removes column with hierarchical course::level tags from .csv
extra_info Setting to true makes the extension to download additional word data and attributes if present
collapse_columns Setting to false leaves empty columns in the .csv tables, so that the numbering of fields (step 3.iii.) would always be the same: 1 - Learned word, 2 - Definition, 3 - Audio, 4 - Video, 5 - Tags, 6-9 - Extra fields.

Known issues

There is a problem with encoding of a small subset of Unicode characters, which results in media filenames being written with _ where their entries in .csv tables are written with %. If you encounter such a case, the workaround is to replace all % in .csv file with _ in any text editor before importing it into Anki:

Discussion

If you encounter errors, have further questions regarding the extension, or need any help with using the downloaded materials in Anki, please leave a comment in this thread: An alternative to Memrise2Anki