Guest User

Yomichan Anki integration guide.

a guest
Nov 9th, 2017
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.22 KB | None | 0 0
  1. Yomichan Anki integration guide.
  2.  
  3. This guide assumes you have already installed Yomichan and added the JMdict dictionary to it. If you have not yet done this, see the Yomichan webpage for instructions:
  4. https://foosoft.net/projects/yomichan/
  5.  
  6.  
  7. Yomichan can be set up to automatically create Anki cards from the words which you hover over with it. In order to do this, it is necessary to install Yomichan's companion Anki add-on called AnkiConnect. The installation is no different from that of any other Anki add-on and there is no post-install configuration necessary. See the AnkiConnect page on the Yomichan website for instructions and further details:
  8. https://foosoft.net/projects/anki-connect/
  9.  
  10.  
  11. After you have installed AnkiConnect, you will need to create a deck in Anki to add the words to, assuming you have not done so already. This guide will assume you want to create a deck containing the following information:
  12. The word written in kanji.
  13. The word written in kana.
  14. The word written in kanji, with accompanying furigana.
  15. The definition of the word.
  16. Audio of the word being spoken by a native speaker (if available).
  17.  
  18. We want 5 seperate pieces of information, so this means our deck will need 5 seperate fields to house said information. To get started, we will need to open Anki and click on the "Create Deck" button at the bottom of the window. We will then be presented with a pop-up asking us what we wish to call our deck - I will be using the name "Japanese Vocabulary", but feel free to call it whatever you want.
  19.  
  20. Once the deck has been created, click on it to select it, then press the "Add" button at the top of the screen. This will present us with a pop-up window allowing us to not only add cards to the deck, but also change various things about the deck itself. Our first order of business is creating a new note type to use for our deck. Begin by clicking the button next to the word "Type" (the button itself will most likely say "Basic"), which will open up another pop-up window. From here, our actions will involve clicking more buttons in order to open yet more pop-up windows:
  21. Manage -> Add -> Select "Clone: Basic" and then "OK" -> Type in name (e.g. Yomi) and then click "OK" -> Close -> Select "Yomi" and then click "Choose"
  22.  
  23. Having fun yet? Now it's time to create our new fields and delete the default ones. To begin, click the "Fields..." button to open up yet another pop-up window. Our first order of business is to click the "Add" button in order to create our new fields:
  24. Expression
  25. Meaning
  26. Reading
  27. Furigana
  28. Audio
  29.  
  30. Once done, select the default fields and click "Delete" to get rid of them, then close the pop-up to return to the original "Add" pop-up window. The final thing we need to do in Anki is edit the appearance of the cards themselves. Begin by clicking the "Cards..." button. Here's where things get subjective, but I like to keep my cards simple. If you wish to copy my formatting, then simply add the text below to the relevant sections:
  31.  
  32. ---Front Template---
  33. <div class=expression>{{Expression}}</div>
  34.  
  35.  
  36. ---Styling---
  37. .card {
  38. font-family: TakaoPGothic;
  39. font-size: 20px;
  40. text-align: center;
  41. color: black;
  42. background-color: white;
  43. }
  44.  
  45. .expression {
  46. font-size: 56px;
  47. }
  48.  
  49. .reading {
  50. font-size: 42px;
  51. }
  52.  
  53.  
  54. ---Back Template---
  55. <div class=expression>{{Furigana}}</div>
  56.  
  57. <hr id=answer>
  58.  
  59. <div class=reading>{{Reading}}</div><br>
  60. {{Meaning}}
  61.  
  62. <!--{{Audio}}-->
  63.  
  64.  
  65. For the font I use, see: https://launchpad.net/takao-fonts
  66.  
  67. If you don't want to use my formatting, you're on your own here. Sorry.
  68.  
  69. Once you've got your card formatting how you want it, simply close the window, along with any remaining pop-up windows (making sure to leave Anki itself open!).
  70.  
  71.  
  72. Now that we're done with Anki, we need to make our way over to Yomichan's settings and tick the "Enable Anki integration" checkbox. Upon doing so, a bunch of new options should appear. We are interested in the options in the "Terms" section. First off, under "Deck", we want to select the deck which we just created (Japanese Vocabulary), and under "Model" we want to select the note type which we just created (Yomi). The "Tems" section should now display our newly created fields, so all that's left from here is to assign corresponding "Markers" to them (see the Yomichan webpage for a full list of options: https://foosoft.net/projects/yomichan/#anki-integration).
  73. Expression - {expression}
  74. Meaning - {glossary}
  75. Reading - {reading}
  76. Furigana - {furigana}
  77. Audio - {audio}
  78.  
  79. Alternatively, you can use {glossary-brief} for the Meaning field. {glossary} contains information about the word, such as whether it is a noun, verb, etc. and what dictionary the definition is being taken from. {glossary-brief} contains no other information besides the definitions themselves.
  80.  
  81. Another alternative is using {furigana-plain} instead of {furigana}. {furigana} used HTML ruby text to display the furigana, while {furigana-plain} uses the method of applying furigana provided by the "Japanese Support" Anki addon:
  82. https://ankiweb.net/shared/info/3918629684
  83.  
  84.  
  85. And with that, we're done! To test that you've set everything up properly, try hovering over the following word and clicking the green + button which should now be present in Yomichan's pop-up:
  86. 無為無能
Add Comment
Please, Sign In to add comment