Cardation Android flashcards app

Cardation is a flashcard app for Android that's optimized for learning languages. I wrote it because among the many fine Android flashcard apps out there I could not find one that handled the direction -- English-to-foreign vs foreign-to-English -- the way I liked. Of course once I got under way, I introduced other unique and sorta-unique features.

Get Cardation here.

Before I get into screen shots and usage details, I'll explain the main "pedagogical" algorithm, including that dual-direction-handling that made me get started. The algorithm is based on the idea of a "streak". Every word has its streak, and the streak goes up by one every time you get that word right. The next time Cardation quizzes you on that word will be in about 2^streak days (where "^" means "power-of"). So the better you know a word, the less often you'll see it, allowing you to concentrate on the words you don't know so well. That's the basic idea.

As for the direction, i.e. English-to-foreign vs foreign-to-English, here's Cardation's rule: it starts you out in the foreign-to-English direction (because it's easier), but after your streak hits a certain point, the direction switches to English-to-foreign. (I should say, "native-to-foreign", since there's nothing about Cardation that requires you to use English; by "English" I mean simply the language you use to provide yourself with a definition for the foreign word.) But get the wrong answer a few times and the direction will switch back to foreign-to-English.

I'll save the finer streak-related details for later. Now let's go to the screenshots and instructions. Or just download the thing and start using it; there's not much that's unobvious.

Here's the "home" screen:


Gets right down to business, doesn't it? You can "learn" (which means, get quizzed) or "input". For, as indicated above those options, your Hebrew words. What? Hebrew happens to be one of my languages, so it shows up in my screen shot. The brand-new Cardation you'll download actually has no languages at all -- only an option for "New language", which, when tapped (not shown here) prompts you to enter the name of a language you do care about.


To get to this list of all your languages, tap the current language. Notice that one of my languages is "English". That's for cool new words I encounter now and then, and wish to learn. The number indicated as "due" tells you how many cards you'll be quizzed on right now, if you press the "Learn" button.

More options are accessible from the three-dots-thingy at upper right. images/cardation_dropdown_menu.jpg I'll get to them later.


At this point, you'll need some words, but I want to cover the menu options in the order they appear, so let's assume you somehow acquired some words, and you're ready to be quizzed on them. (Or skip ahead to the section on "Input".) Hence the Learn option. A word (in this example the foreign one) is shown. If you think you know what it means, tap the green yes button. If you don't know, tap the red no button. If you know, but you had to think a while, tap the amber meh button. Tapping any one of these buttons reveals the answer (and the quote, if there is one). At that point, tap the yes, no or meh button again. Only this second tap really counts, and it "counts" in the sense that it affects your streak. The streak is actually a pair of numbers (in this case (2,4)), of which the first is your "forward streak", the second your "backwards streak". If you're currently in "forward" mode, i.e. the clue word is the foreign word, then tapping yes increases the forward streak (leaving the backwards streak unaffected).


Notice that the streak is a negative number. If you apply the 2^streak formula from above, the implication is that this word will come up again in one-eighth of a day. But actually that's not what happens. The 2^streak rule applies only to nonnegative streaks. A negative streak means the word will come up Well, not right now, but right after the other words in your current "batch" (which I will define).

That (-3,-3) streak happens to be the streak assigned to a brand-new word. And so after the first press of the green yes button, the streak goes to (-2,-3). If you press green the next time the word comes up, the streak goes to (-1,-3). The next step is of course to (0,-3), but that's a special point because when your forward streak reaches zero, Cardation switches direction on you. It starts quizzing you in the reverse, i.e. English-to-foreign, direction. At that point, if you keep pressing the green button, you whittle down your streak to (0,-2), then (0,-1) and (0,0). Once you're at (0,0), you're finally in the 2^streak regime: that word falls out of your current batch and it won't show up again for one (i.e. 2^0) day.

That covers the green yes button. If you don't know the word and, accordingly, press the red no button, your streak goes down. But it doesn't work quite symmetrically. It works as in the "Snakes and Ladders" game: if your streak is positive -- it could be 5, 6 or even 27 -- pressing the red button drops your streak all the way to -1. That ensures you'll see the word again during your current session. When it comes up again, if you press the green button, the streak goes to zero and the word will next show up in a day's time. But if you still don't remember and press the red button again, your streak drops to -2, and next time to -3. If after that you still can't get it, the streak will not drop further. But something else happens: if you're in backwards mode (English-to-foreign) and you drop to -3, then Cardation sets both streaks to -3 and switches the direction to forward; at this point you've proven that you really need to relearn this word starting with the easier direction.

Having gone through the effects of the green and red buttons, explaining the amber meh button is easy. It reduces your streak by one (thus halving the time to the word's next appearance). In other words, it's an intermediate measure, between "no" and "yes". That's it. You may choose not to ever use the amber button; you don't have to. It's just there to give you a little more control, if you want it.

Below "streak" there is something about "batch". The batch is your current set of cards, the cards Cardation will present to you over and over. Some of these are cards with negative streaks -- new words, or older words you've forgotten. Others could be words you know well -- words with positive streaks -- which just happen to have come up because it's time. For example, a word with a streak of 3 is a word that you pressed yes on eight days ago.

The number "now due" (here shown as 5), is related to the batch. As you work through the words in your batch, they will drop out of the batch, one by one, as you press yes and get their streaks to zero or more. When a word drops out of the batch like that, another word enters the batch to take its place, and that word comes from those "now due". After a while, all your due words will be in your batch, and at that point when a word leaves your batch, there's nothing to replace it, and so your batch will diminish. When it reaches zero, you're done. Until next time.

"Career" shows the number of times you have pressed no, meh, and yes for that word.

To the right of the information about batch size, you see "Cram". Cram mode sort of lets you change Cardation's clock. Set cram to 1 and your "now due" cards will be those that would have come up one day from now. Set cram to, say, 4, and your "now due" cards will be those (possibly a large number) that, under normal circumstances would have come up in 2^4=16 days. I recommend leaving cram at 0, and going outside to play when no more words are due.

And one more thing about streaks and the power-of-two rule: Cardation throws in a little randomness, to spread the "due dates" out a little. So don't expect to see a word in exactly 2^streak days.


Now for the Input option. foobar It's simple: type your foreign word on the first line and your definition (in English or whatever) on the second line. The third line is the "quote" line: it's for an illustrative quote, an etymological note, anything you like, or nothing at all.

The checkbox labeled active indicates if you want Cardation to quiz you in the English-to-foreign direction (after you master the easier foreign-to-English direction of course, as discussed above). Active is checked by default as I've assumed you'd like most of your words to become part of your active (hence the name) vocabulary.

The bottom half of the screen shows a list of the words you already have. As you type in the clue box, that list gets filtered down to just the words that match what you've typed. This way you can know if you already have that word. (Diacritical signs, at least in the Roman, Hebrew and Arabic alphabets, don't count for this purpose.)

The Input screen is how I happen to acquire most of my words; typically I'm reading something, I see a word I don't know, I look it up in a dictionary, and I enter it into Cardation. There's a faster alternative, a way to import an arbitrary number of words wholesale. But I'll cover that when I get to the Restore option because first I have to talk about the format your imported words will need to be in, and that has to do with the Backup option, which also comes later.

Search and Edit

Press the magnifying-glass icon. Type in the search box, or scroll through the list. foobar If you tap on one of these words, you come to a page where you can edit that word as well as its definition, the quote if foobar any, the active checkbox, and the word's streaks. You can also delete a word. To do that, just backspace over the first (i.e. foreign) line, and press "Save".

The icons at upper right are, respectively, for sharing the word with your friends, and for committing your changes.




Backup is, of course, for backing up your cards. I know there are fancy cloud backup solutions in the Android API, but I picked something easier and (as you'll see) more flexible: email. Backup just emails you (as an attachment) a file that has all your words (and their definitions, quotes, streaks and due dates -- everything). In fact, to save time, "backup" backs up everything you have and sends you as many attachments as you have languages.

If you try to open such an attachment in your Android device's email, Cardation offers itself up (alongside, possibly, Adobe Reader and the browser) to do the work. Accept that offer and Cardation will import those words. It will also give you an opportunity to say what should happen in the event of a "conflict", i.e. a word in your backup already exists in your database, and whether you want to restore the configuration along with the words themselves. foobar

And that is the wholesale word-importation feature I mentioned earlier. Obviously, it's a way to restore from your own backups, but it's also a way to import new cards. You just have to get the file format right, but it's pretty simple -- fields delimited by '@'.


Restore works just like the import-from-email method discussed above. Except that instead of working on an email attachment, restore looks for a file on your Android device's storage card. If you know how to work with that card, the location is probably in a directory called /mnt/sdcard/Download/net.trhj.cardation. So if you like, and you know how, you can put files there for Cardation to restore from. But as it happens, Cardation itself writes backup files there every time you do a backup. So you can use restore with no need to get involved with USB cables and adb and such; press restore and Cardation will restore the most recent backup (they're numbered, if you look there) for the current language.


"Delete" removes a language from your device.

Toggle theme

You can switch between the dark theme we've seen to this point, and a light theme. foobar

Hack database

If there were a warranty on this product, using this option would invalidate it! Note the actual sqlite3 db file is one of the attachments that gets emailed out with every backup.

Date-due histogram

Let's return to that bargraph visible on the home screen. foobar the graph shows how many words will be due at all future dates. The horizontal axis (whose labels do not, for some reason, show up in the Android emulator I grabbed these screenshots from) is logarithmic.


Cram (on the Learn screen) doesn't go below zero, but if it's already at zero and you long-press the '-' button, you go into a whole different regime, called Decram. Decram is analogous to cram (up to a point). A Cram setting above zero gives you more words. Decram gives you fewer. Say you're coming back to Cardation after an extended "vacation" and the number of words currently due is overwhelming. You could try chipping away at them a few a day, but the problem is that tomorrow your batch will be drawn at random from all the cards due, and the problem with that is you're unlikely to get to review those cards you got wrong today (unless you go through a large number of other cards). Digging yourself out of that hole could thus prove difficult. foobar

Decram solves this problem by resetting your cards' due dates. Using the slider, select a number. This number tells Cardation how many cards you want to "catch up" on today, tomorrow and every subsequent day until you've dug your way out of your backlog. The histogram shows you what your date-due situation would be at that number of cards-per-day...IF you press the floppy-disk (save) icon.

So pressing the save icon actually changes your database (unlike pressing cram buttons on the Learn screen, which only changes an internal clock but otherwise has no effect on the database). So think twice before saving. (But you can restore the status quo ante by clicking your way back to zero and saving again. Or -- always a good practice -- make a backup first.)

Daily load

So what is the expected daily "load"? How many words can you expect to be quizzed on, per day? It's growing but manageable. To take a first stab at this problem, let's assume for simplicity that you never forget, and you introduce w new words per day. Then your load today is the w new words you added today; plus the w new words from yesterday (you got them right yesterday, putting their streak at 0 and their due date therefore one day (2^streak) into the future); the w words you added three days ago (they came up 3 days ago, then 2 days ago at which point their streak went to 1 and their due date was pushed 2 (=2^streak) days ahead); the w words you added 7 days ago; the w words you added 15 days ago; etc. So if you started using Cardation n days ago, your load today is w*log_2(n+1). Say you're a power user and you plan to add a word a day forever. Then your daily load will be nine words after one year, eleven after five years, twelve after ten years, and fifteen after a hundred years.

If you're an eager beaver and plan to add ten new words a day, your load will indeed be ten times higher, and of course 108 (in five years of that) is quite a lot. But it seems unlikely anyone will reach that point; we're talking about knowing 5*365*10=18,250 words! Long before reaching that point, you're an expert at whatever language and unlikely to encounter anything like ten unfamiliar words a day.

All of that assumes you never forget. When you forget a word (i.e. you press the red "No" button), its streak goes to -1. That increases your load. The math gets messy now so instead I programmed up a simulation, which gave me this table.

0% forgotten 5% forgotten 10% forgotten 15% forgotten
365 days 9 9.8 12 15.55
1825 days 11 12.85 17.4 26.75
3650 days 12 14.45 21.6 30.15

Unfortunately, after a couple years of experience, I'm finding that I forget at a higher and higher rate, the longer it's been since I saw a word. You can clearly see this effect from the several date-due histograms shown above. If this becomes your experience too, and you're starting to feel you're spending too much time reviewing words (rather than doing the other things you should be doing if you want to learn a language, like reading and speaking it), you can always resort to decramming.

Frequently-asked questions

Q0. How do you pronounce Cardation?
A0. "Car-DAY-shee-un". Just remember the second 'a' is long.

Q1. Can Cardation use my Android device's speaker to pronounce a word?
A1. No.

Q2. Can Cardation look up a word's meaning and fill that in for me automatically?
A2. No.

Q3. Is there a parental controls feature, to filter out potty-mouth words?
A3. No.

Q4. Can Cardation use my device's accelerometer to detect that I've shaken my phone to indicate that I'd like the order of my words scrambled?
A4. No.

Q5. Is there a version for the iPhone/Pod/Pad family of products? Is there an online Javascript-powered version?
A5. No, nope.

Q5.1. Why don't you upload Cardation to the Google Android app store?
A5.1. Sloth.

Q6. Can we see your source code?
A6. It's at GitHub.

Q7. What are some exciting new features planned for the future?
A7. Here's some of my to-do list.
Q8. How can I merge two decks?
A8. Good question! This comes up when people use Cardation to study for school tests in memory-intensive subjects such as anatomy. Then let's say you have a "language" called Anatomy_master and another called Anatomy_new which you created because you wanted to study for a test and not be bothered with material from old tests but now with the test behind you, you want to warehouse your new body parts with your old body parts, for the final exam, hence Anatomy_master. To merge Anatomy_new into Anatomy_master, make a backup and import the Anatomy_new email attachment into the Anatomy_master "language". And then delete Anatomy_new.