Showing posts with label anki. Show all posts
Showing posts with label anki. Show all posts

Sunday, 2 September 2012

Finding kanji I haven't studied yet in my main deck



Present in Heisig:

鼠汰闇鼈雛韮

sqlite3 ~/.anki/decks/Japanese.anki 'select * from facts'|sed -E 's/(.)/\1\n/g'|sort|uniq > /tmp/used_kanji && for kanji in `sqlite3 -header ~/.anki/decks/Heisigs\ Remember\ the\ Kanji\ \(RTK\)\ 13.anki 'select value from (select * from cards left join facts on facts.id=cards.factid where type=-1) as t left join fields on t.factid=fields.factid where fieldmodelid=(select id from fieldmodels where name="Kanji")'`; do grep -F $kanji /tmp/used_kanji|tr -d '\n' ; done ; echo; rm /tmp/used_kanji

Any:

汰薤辣鐶闇雛韭韮鼈鼠

sqlite3 -header ~/.anki/decks/Heisigs\ Remember\ the\ Kanji\ \(RTK\)\ 13.anki 'select value from (select * from cards left join facts on facts.id=cards.factid where type!=-1) as t left join fields on t.factid=fields.factid where fieldmodelid=(select id from fieldmodels where name="Kanji")' > /tmp/unlocked_kanji; for kanji in $(sqlite3 ~/.anki/decks/Japanese.anki 'select * from facts'|sed -E 's/(.)/\1\n/g'|sort|uniq|grep -v '*'); do if ! grep -qF "$kanji" /tmp/unlocked_kanji; then echo $kanji; fi ; done |tr -d '\n'; echo; rm /tmp/unlocked_kanji

Obsoletee! Obsoletee! With Anki 2.0!

Sunday, 26 December 2010

Display all the answers to a question in Anki

I finally decided to publish the Anki plugin I've been using for the last few months. It's called "Display all the answers to a question" and it does exactly what its name says, that is, allows you to review decks with some cards containing the same question, but different answers. How does it work? Each time Anki picks a new card to revise, the plugin searches the database for other cards that have the same question and remembers them. When you click the "show answer" button, it shows the answers for all the cards it has found and changes their repetition times accordingly.