[UserScript] Extra Practice First Official Release!

:tada: Introducing “Extra Practice” Userscript

The official release of my first UserScript, Extra Practice!

About

So my entire focus for the last week or so has been spent developing this script instead of doing my WaniKani reviews (the irony isn’t lost on me). I’ve got so many reviews piling up lol… But at least now I have a cool tool to help practice them!

Extra Practice is a UserScript that lets you create custom practice sessions for radicals and kanji at your current WaniKani level. I built it because I wanted more flexibility in how I study items, especially being able to focus on specific radicals or kanji that were giving me trouble. The idea came from when I was frustrated with the built-in Extra Study feature.

I didn’t want to study a ton of recent items (vocab, kanji, and radicals from however many levels back)… I just wanted to study the kanji and radicals at my current level. This is where my idea for Extra Practice came from.

:sparkles: Features

  • Practice Buttons integrated directly into your dashboard via tools such as TamperMonkey
  • Radical Practice Mode: Select the Radicals you’d like to practice based on meaning
  • Three Practice Modes for Kanji:
    • Standard Practice: Review meanings and readings
    • English → Kanji: Select the correct kanji based on meaning (I’m proud of this one)
    • Combined Practice: Mix of both modes for a comprehensive review
  • Custom selection: of which radicals/kanji to practice
  • Hint system: similar to that of WaniKani
  • Play again: When you’ve reached the end page, you’re given an option to restart the practice with the same items (kanji or radicals) along with the same practice mode (if you’re studying Kanji you have different practice modes)

I tried to make it similar to WaniKani’s approach so that someone can easily understand how to use the UserScript instead of learning something entirely new.

:framed_picture: Screenshots





:wrench: Installation

Prerequisites

Install Links

:rocket: How to Use

  1. Visit your WaniKani dashboard
  2. Look for the new “Practice” buttons next to your Radicals and Kanji progress sections
  3. Click a button to open the selection modal
  4. Choose which items you want to practice
  5. Select your preferred practice mode (if you’re practicing Kanji)
  6. Begin your review session!

:brain: Practice Modes Explained

Standard Practice

Reviews both meanings and readings in a traditional format. For each item you’ll be asked to recall:

  • The meaning of the radical/kanji
  • The reading of the kanji (for kanji only)

English → Kanji (I’m proud of this one, it was a last-minute feature creep item I thought of)

Tests recognition rather than recall. You’ll be shown an English meaning and asked to select the matching kanji from multiple choices. This mode requires at least 4 kanji to be selected.

Combined Practice

Combines both formats for a comprehensive review session. This mode requires at least 4 kanji to be selected, as it creates three question types for each kanji.

:hammer_and_wrench: Technical Notes

  • Sorry, but this UserScript is not mobile-responsive. And mobile responsiveness was not my priority. Honestly, I’m not good at that stuff and I wanted to get this UserScript out and used, so you should not have any problems on Desktop.
  • If you’re an engineer, man… This was an interesting problem! I had to tackle things such as getting the Kanji and Radicals of your current levels, making sure to only get the Radicals and Kanji that are unlocked, and using the readings that you have unlocked. All without using the API. It was a super interesting challenge from an engineering perspective!
  • If there are updates to the UserScript, I’m not really sure how to sync the update with everyone. I’m sure if there’s an update to the UserScript I will post a message here, but I don’t think I have an automatic update set up. I was trying to, but I couldn’t figure out how to sync GreasyFork with GitHub releases to auto-update the script.

:handshake: Contributing

I’m open to suggestions, feature requests, and contributions! While I can’t guarantee I’ll maintain this script, I’m happy to review pull requests and consider improvements.

If you have ideas, find bugs, or want to contribute:

Practice Buttons Not Loading

  • Please try to refresh your page. It may be slow or it may have some of the web page elements it needs to attach to.

Let me know what you think! This is my first WaniKani script, so I’m eager to hear your experiences, suggestions, and bug reports.

Happy studying! Honestly, I really hope you find it fun and useful! This is exciting for me because it’s my first OSS project and one that I can share with the community so I’m really excited to hear everyone’s feedback! I’ll try to get back to any questions if you may have some.

5 Likes

The UI is very impressive. It’s maybe the nicest I’ve ever seen for a WK userscript.


Some initial feedback:

I did a quick review of all the kanji I currently have unlocked. The first thing I noticed was that typos are not accepted like they are in the regular interface.

For 汽 (steam), I made a typo of “stream” which wasn’t accepted. Since “stream” is actually an english word and the meaning of another kanji, I could see why the script might be justified in rejecting that answer.

For 苛 (frustration), I said “frustrating” instead, which I think is usually accepted by the regular interface and self-study quiz (but don’t quote me on that).

After these two actual mistakes, I decided to test things further.

For 繋 (connect), I intentionally misspelled it as “conncet” just to see what would happen. It wasn’t accepted.


I don’t mean to sound so negative though. It’s clear you put a lot of work into this. It’s a very impressive project! :+1:

1 Like

Juniormint,

Thank you so much for your comment! I honestly really appreciate the feedback!

As for the typos and how WaniKani offers some leniency, I’m not too sure how they actually incorporate that. Maybe they have that logic somewhere, but when I think of doing it myself, I just think of there being too many potential typos to cover each base. But this was definitely something that I thought about.

As of right now, it also doesn’t handle user added synonyms, purely taking in the primary definition as the correct answer and expects to be typed out exactly as defined. This can be a bit annoying when you basically got the word right but maybe added an extra letter or was off by a character or two.

I’ll definitely keep that feature in mind though in case I figure out some potential ways to add that!

I really appreciate you trying out the UserScript! I think you may be the first user to install it besides myself, haha. So I hope you find some use of it and enjoy it :smile:. Your feedback about the UI also makes me happy!

Happy Studying!
DeadByCoffee

1 Like

The Self-Study Quiz does a typo leniency. You can go check how they do it. This is not whe Wanikani algorithm though.

3 Likes

This looks awesome! I’ve recently been looking for a WaniKani userscript with more flexible study options, kinda like ToriiSRS’ ‘Endless Practice’ mode. I don’t use ToriiSRS, but I love that feature. It basically lets you review items as much as you want, outside the regular SRS schedule, which is super helpful for retention, and this script seems like something that could work for now. Thanks for making this, and congrats on your first OSS project!

1 Like

Hi Prouleau,

Maybe when I have more time I’ll check that UserScript out. That sounds like a good place to find inspiration and see how they implement it. Thanks for pointing me in a good direction!

Regards,
DeadByCoffee

1 Like

Dear Ihatethislanguage,

I like the username, haha! Thank you for the kind comments! It makes me happy to hear you like it. :smiley:

I hope you’re able to find this UserScript helpful and fun in your studies! I’ve never heard of “ToriiSRS” but this “Endless Practice Mode” seems like a really cool idea! From what you’re saying, relative to this UserScript, you’d be able to practice your Kanji or Radicals until you basically press something like a “End Practice/Study” button?

That sounds like a cool practice mode! Would you find that useful or helpful? Not saying that it’ll be implemented right away, but sounds like a potential additional mode. As for vocab, kanji, and radicals, I am for now, trying to keep this UserScript showing Kanji and Radicals at the current user level.

Thank you for the feedback! :heart:

Happy Studying!
DeadByCoffee

1 Like

Haha, thanks! Yeah, that’s pretty much how ToriiSRS’ Endless mode works—you just keep going until you decide to stop. It also shows a counter at the top right, so you can track how many you’ve done, and I would usually aim for at least 200 a day to make sure it sticks. I think something like that in this script could be really useful for extra practice. But either way, I’m already liking what you’ve made. Appreciate you considering it!

1 Like

Thanks for the response, @ihatethislanguage!

I see! You gave me an idea as well, haha. What do you think about level options for an “Endless Mode”? For example, you said, “It also shows a counter at the top right, so you can track how many you’ve done”. In my mind this could be split up into two modes:

  • Regular
  • Hardcore

Both modes are “endless”; however, the difference is that in “Hardcore” mode, if you make a mistake the counter resets back to 0. Whereas, in “Regular” mode, the score would just be the total of correctly completed without resetting the total score. I think giving the option can kind of make it more challenging and may encourage people to try and get a higher score streak than last time!

Cheers,
DeadByCoffee

1 Like

I took a look at it myself. SSQ implements the Jaro-Winkler Distance algorithm in the jw_distance() function. It is called in the submit_answer() function.

Self Study Quiz code is released under the MIT license. This means you have permission from the author to copy paste the code in your script.

1 Like

Hi Prouleau,

Thanks for looking into that, I was also doing a bit of digging into the script and saw that algorithm. If I have the time, maybe this weekend or next weekend I may find the time to add it as an option that people can choose if they would like exact mode vs leniency mode. Along with a possible endless mode.

Appreciate it,
DeadByCoffee

Oh, I love that idea! Having both a Regular and Hardcore mode sounds like a fun way to add extra challenge and motivation. In ToriiSRS, the counter just keeps going until you exit Endless mode, which I think would be perfect for Regular mode. The Hardcore mode resetting on mistakes could make it even more engaging.

1 Like

Thanks for the reply, @ihatethislanguage!

I think I’ll need to do a bit of rethinking in terms of the UI for UX when adding those extra buttons, but you might see this in the next version. :slight_smile: Stay tuned!

Regards,
DeadByCoffee

1 Like

Oh btw, the buttons for me cover some of the characters for me, and for some reason, some of them are really big

Oh that’s really odd! Does that happen all the time or only some times? Do you happen to know the screen size e.g. if you’re using a phone, laptop, tablet, or desktop?

Good work on this script. It’s clean and straightforward.

I think WaniKani uses a variation of the Levenshtein Distance algorithm for typo leniency.

Levenshtein distance is a string metric for measuring the difference between two sequences. The Levenshtein distance between two words is the minimum number of single-character edits (insertions, deletions or substitutions) required to change one word into the other.

1 Like

According to this thread Wanikani is using Optimal String Alignment which is a relative to Levenshtein.

All the time, and it’s always the same characters that get enlarged. Also, sometimes the buttons are offscreen:



There probably should be a scrollbar or something. I’m on a laptop, but I use a 27’’ monitor

1 Like

Hmm weird, do you happen to know the zoom level you’re at? If you’re at 100% or even more?

I’m sure it has something to do with not being built to be responsive. But it looks like something I’ll have to look into!

Thank you for the feedback and information, it’s really helpful! :slight_smile:

Do you have any issues closing the session or going to the next screen since the buttons are off screen? I wouldn’t want you to be frozen on the screen.

1 Like

Thank you! I appreciate the kind comments!