Scripts

for external scripts that run outside of Mnemosyne to help prepare cards

Use HTML to edit flash cards

Type: 
Plugin
Compatibility: 
Mnemosyne 1.x +
Status: 
Testing
Author: 
tyfj
Source: 

None

Description: 

HTML for flash card
===================

Use HTML as file format to edit flash cards. Then use a Python
script to convert it to "tab separated Q&A for each line, that MNEMOSYNE can
import". For the file MNEMOSYNE can import, see:
http://mnemosyne-proj.org/help/importing.php

File Format
-----------

The following is a frame for one flash card. Of course an HTML file can
contain more than one flash card.

>DIV CLASS="flashcard">
<DIV CLASS="front">
The question is ... made up of lot html tags in any html file format
</DIV>
<DIV CLASS="back">
The answers is ... this html contents, it has many html tags ...
</DIV>
</DIV>

Put the contents of "Question" into the "DIV" with ``CLASS="front"``.
Put the contents of "Answer" into the "DIV" with ``CLASS="back"``. One "DIV"
with CLASS="flashcard" will contains only one flash card.

Note, beside and inside the above structure, you can use any HTML tag as
MNEMOSYNE accepts it.

You can edit it as a real HTML file, as long as you put each card inside:

Usage
-----

After you create the HTML file, use the following command to convert it to what
MNEMOSYNE can import:

./html2cvs html_flash_card.html

Read/Edit HTML will be easy, comparing to edit "plain text files where each
line contains a question/answer pair separated by a tab". Because lot's tools
help we do HTML editing.

Example from a real file
------------------------


<!-- This is an example HTML flash card file : -->
<DIV CLASS="flashcard">
<DIV CLASS="front">
Mnemosyn Importing cards <br />
Plain text and Microsoft Office (Word and Excel)
</DIV>

<DIV CLASS="back">
Mnemosyne can import plain text files where each line contains a
question/answer pair separated by a tab. So e.g. if you have such a list
in Word, save it as plain text (*.txt), choose 'other encoding - Unicode
(UTF-8)' if your data contains foreign characters, and then you get a file
which you can import in Mnemosyne if you choose the 'Text with tab
separated Q/A' format.
<p> The same goes for Excel using 'save as', 'tab delimited (txt)'. However,
Excel's unicode text format is not the standard UTF-8, so this only works
for latin characters.
</p>
</DIV>
</DIV>

<DIV CLASS="flashcard">
<DIV CLASS="front">
Mnemosyn Importing cards <br />
OpenOffice Calc
</DIV>
<DIV CLASS="back">
Choose File-> Save as and select csv as the format. Then click on the box
that says edit filter options and choose utf-8 as the character set, tab
as the field delimiter, and clear as the text delimiter. It works
perfectly with unicode (a major advantage over Excel!).
</DIV>
</DIV>

Install
-------

To use it, make a directory, put the zip file in, unzip it,
the following cmd is for linux (ubuntu) as example:

mkdir /path/to/my_working_dir
cd /path/to/my_working_dir
mv /path/to/html2cvs.zip .
unzip html2cvs.zip

Then you can edit you HTML flash card file (for example: html_flash_card.html)
in the /path/to/my_working_dir/, after that, use this:

./html2cvs html_flash_card.html

You can then import the file: html_flash_card.html.tab.txt
It's all, hope it can help.

Mnemosyne Parser to review cards on PSP/DS/iPhone/iPod/Mobile phone/Camera

Type: 
Plugin
Compatibility: 
Mnemosyne 1.1.1 +
Status: 
Testing
Author: 
Val Antonini
Source: 

A work in progress by Myself. For feature/change requests please visit: http://mnemosyneparser.blogspot.com/

I will be happy to add functionality when I have a chance.

Description: 

This is a work in progress. Please visit http://mnemosyneparser.blogspot.com/ for the latest information/version.

Useful for reviewing cards on portable devices such as PSP/DS/iPhone/iPod/Mobile phone/Camera

Reads a mnemosyne XML export and creates a series of images of the cards content.

Orders the cards by a field of your choice (easiness, grade, retention reps, grade & easiness, grade & retention reps). It then essentially creates a question card (.jpg) with a numerical filename exactly 1 less than the answer card (also
a .jpg). You just view pictures in order on any device that can display jpg's sequentley in order of filename.

After your Mnemosyne repitions, you recreate the cards (the new gradings assigned my mnemosyne essentially shuffle the deck each day), load them onto your portable device and view them when you have time to kill.

Application does not support grading.

Written in C# (.Net 3.0) and tested only on Windows platform.

EDIT: Applied fix for stupid devices that believe 02 is bigger than 012. (Never sort file names in this way. Stupid, stupid, stupid)

SuperMemo Text to Mnemosyne XML (a way to preserve sound and images from SuperMemo course)

Type: 
Plugin
Compatibility: 
Mnemosyne 1.1 +
Status: 
Incomplete
Author: 
Marcin Kasperski
Source: 

Importing SpeedUp! to Mnemosyne

Description: 

Converting SuperMemo "text" export to Mnemosyne XML format.
I used this script to successfully import Advanced English SpeedUp!
and Proficiency with sound (detailed article in Polish).

SuperMemo "text" format handled here:

Begin Element #1
Source=Y:\SuperMemo\AdvEngSpeedUp\systems\SPEEDUP!
Parent=0
ParentTitle=
Begin ElementInfo #1
Title=Speed Up!
Type=Topic
Status=Dismissed
FirstGrade=6
(...)

The script handles file paths remapping but does not handle learning data import (it could be added easily - see script sources and note "TODO: learning data" - I just did not need it)

Get flashcards from flashcardexchange.com

Type: 
Card Collection
Compatibility: 
Mnemosyne 1.x +
Status: 
Incomplete
Author: 
Adam Raizen
Source: 

Written by me.

Description: 

Simple python script to download a full set of flashcards from the site http://www.flashcardexchange.com. Simply run the script with the flashcard set number that you see in the URL of the set of cards you want. A few additional options are explained in the program's help message.

svgtoquiz

Type: 
Plugin
Compatibility: 
Mnemosyne 1.0.x
Status: 
Complete
Author: 
Timothy Bourke
Source: 

http://www.cse.unsw.edu.au/~tbourke/software/svgtoquiz.html

Description: 

Svgtoquiz generates card sets for memorising details of images, such as states or countries from a map, or the names of bones or muscles from a schematic of the body. It reads an svg file and extracts all path elements whose id attributes match a given regular expression. It highlights each path in turn, by changing the fill colour, and produces image files that Mnemosyne can read. The script also produces an XML file, containing a set of questions and answers linked to the generated graphic files, for import into Mnemosyne. If the id values are not suitable as questions, a separate csv file can be created, in Excel for example, to map each id value to more appropriate text.

Helper for Images, Removing Formatting, Cloze and Microsoft Word [AutoHotkey, Windows]

Type: 
Plugin
Compatibility: 
Mnemosyne 1.0.x
Status: 
Testing
Author: 
irv
Source: 

A continuation from http://sourceforge.net/forum/message.php?msg_id=4956853

If you haven't changed the Word keyboard shortcuts from Ctrl-F9 for New Field and F9 for Update Field, you can use the compiled EXE version if you like and don't want to install AutoHotkey(more info). Otherwise, please feel free to edit the script to your purposes.

Description: 

Download includes both the compiled EXE and the original AutoHotkey script so you may tailor it to your needs.

How to use:

  1. Insert Image: press Ctrl-Shift-I to bring up a Select Image dialog. A Mnemosyne-friendly image tag will be inserted and in Word, the image will be inserted as well.
  2. Cloze: Select text and press RightCtrl-/ (the ? key) and the text will be replaced with ??? and pasted in the next field
  3. Paste plain text: press RightCtrl-V [Fixed June 2, 2008]
  4. Copy to Notepad and Save as UTF-8 (experimental): Press Ctrl-Shift-C

New features June 2, 2008[Download Below]:

  1. Pasting plain text with RightCtrl-V now preserves unicode characters!
  2. In Word templates, row numbers are formatted as hidden text. To import into Mnemosyne, simply select the table and press Ctrl-Shift-C (if you're using the helper script) or copy and paste into Notepad manually. The hidden row numbers won't copy, which I find desirable. Copying a table right into Notepad gives you each column separated by a Tab and each row on a separate line. (NB: No paragraph marks in Word tables!)
  3. New Simple Q&A Table Templates for Word 97-2003 & 2007
  4. Pretty Purple Template is now for Word 2007 only, because the alternating rows don't translate to previous versions of Word well.

New features May 25, 2008 [Download Below]:

  1. Ctrl-Shift-I now copies the image to a folder in your .mnemosyne folder corresponding to your current collection and produces relative img tags to that copy... much better portability!
  2. Other little tweaks

New features May 20, 2008:

  1. Adding an image in Microsoft Word with Ctrl-Shift-I now also includes manual line breaks that are hidden, so copying text (convert from table first, if appropriate!) into Notepad will skip these hidden line breaks so easier importing of a tab-delimited txt file into Mnemosyne
  2. New command: Ctrl-Shift-C copies text and opens a new Notepad document, pastes the text, and prompts you to save it in UTF-8 encoding
  3. Paste plain text: Right Ctrl-V pastes clipboard content without white space or line breaks (sadly, not Unicode-aware)
  4. Right Ctrl-/ for tables: Cuts the selected text, replaces it with "???", tabs to the next field, and pastes

Special Notes:

  1. Please turn off smart quotes AutoFormat as you type in Word; it screws with the img tags for Mnemosyne.
  2. You might have to display Hidden Text in Word for the manual line breaks to work
  3. Saving to a plain text file within Word itself sadly converts the hidden line breaks into real line breaks, which can screw up the file for importing into Mnemosyne

Songs intro

Type: 
Plugin
Compatibility: 
Mnemosyne 1.0.x
Status: 
Complete
Author: 
Luc Tanguay
Description: 

I created a Python program to build a card collection to learn song names.
The program reads all the OGG files, extract 10 seconds from the beginning of the file, then display a card collection in Tab Separated format on the screen.
Ususally you redirect the output to file (ending in .txt) and then import the file into Mnemosyne. You need to specify the category since it is a TSV (not XML).
Requires:
sox : to extract first non-silence 10 seconds from OGG file
Mutagen Python module : to copy and read OGG tags

Timestamp cards (AutoHotkey script)

Type: 
Plugin
Compatibility: 
Mnemosyne 1.0.x
Status: 
Testing
Author: 
irv
Description: 

An AutoHotkey script for adding a timestamp to cards. Please edit the script to suit your purposes.

Alt-Q: move to question field
Alt-A: move to answer field
Shift-Enter: add card with initial grade of 0 and timestamp new card
\:print timestamp

Note: timestamp is enclosed in tags so they show up in the Edit Deck dialog but not during review. Of course, you can edit or change this behavior however you like.

#IfWinActive ahk_class QWidget
!q::ControlFocus, QWidget27, A
!a::ControlFocus, QWidget15, A
+enter::
Send ^0
Sleep 250
gosub timestamp
return
\::
timestamp:
FormatTime, yo,, MMddHHmmss
FormatTime, easy,, ddd
Send <%yo% %easy%>
return
#IfWinActive

Syndicate content