[Userscript] WaniKani Context

Update has arrived!

0.1.8

  • Fixed styles for users not running the Jitai script (whoops, lol)
  • Fixed code not running due to race condition if vocab appeared right as reviews start.
  • Gracefully failing when running into a conjugated adjective.

@flybot I think this should fix the issues you’ve been experiencing!

I definitely wouldn’t complain if our benevolent crabigator overlords added some more! Though, at 3 sentences per vocab, and 100+ reviews a day, I haven’t noticed a lack of them.

Theoretically there are plenty of online Japanese dictionaries that I could scrape for context sentences, but they tend to be much drier than the WK ones :upside_down_face:.

2 Likes

Any idea why the context sentences would not show up? I totally forgot I had this script installed because I’ve never seen it actually working. Outside of Jitai or Reorder script, I can’t think of any other script that might be a conflict issue, and disabling either doesn’t seem to do anything for WK Context. Is there something basic like a hotkey or setting I need to use or is it something else?

Levels 1-20, as well as newly added vocab, have 3. All others have 1, for now anyway.

It’s hard to say without more context (ba-dum-tssss).

But really. Some system info like OS, browser, and what other plugins you have installed would be a good place for me to start looking into the problem.

Also, if you’re using Chrome (and feeling adventurous) you could hit ctrl+shift+i and go to the ‘console’ tab and see if there are any errors.

Lastly, there’s a possibility that my 0.1.8 update (released like 15 mins ago) might help. There were some apparent dependancies on Jitai that I wasn’t bright enough to look for, haha.

Good to know. Maybe there is some value in trying to get some alt sentences in… I wonder what the ETA would be on new ones.

It’s currently going at about 10 levels per year (since they started adding more).

Here’s what I had in mind, I’m sure I didn’t say what I meant clearly. When WK user, let’s say for example, I, am confused by “diagnose” kanji or “discipline” kanji, of course, it’s good to have Confusion Guesser userscript on right top of the screen and acm similar kanji displayed side by side nicely. But if these kanji both are combined in context sentences, displayed side by side. That would be super. And this, what I had in mind, didn’t limit to what we have on WK context sentences only, but also any correct sentences from native Japanese. Anything. Road signs in Japan, Store signs in Japan, excerpts from Japanese books written by native Japanese, anything. It must be correct Japanese. It would be super. I won’t have to explore/dive Japanese media deeper just to search for specific thesaurus, homonyms, etc, one by one manually. It’s all there automatically after I got red because of these “discipline” and “diagnose” kanji, for example. Talking about leeches like this, of course, it’s obvious for a lvl 29 like me to recognise whether it’s “noon” or “cow”, but when I’m given “diagnose” and “discipline” or like “look at” kanji and “oversee” kanji. I must do all these manually without relying too much on technology. Ah, long sentences. I hope I won’t confuse English native speaker again.

Edit: Maybe I should tag a level 60 but I’m not sure who so I’ll just tag @Omun here someday somewhere これ分かるかな。

BTW. I just had this one. Ooh!! I like this userscript! So challenging!

1 Like

Thank you! you have my :

seal

2 Likes

By some magical witchcraft this beautiful plugin came to life tonight. No updates. Firefox with tampermonkey running some 29 various scripts wouldn’t work with this plugin until about half an hour ago.

I really like this script. It really adds a whole 'nother depth to the vocab reviews.

Hey all, I pushed a fix that should help stabilize the scripts behavior in Firefox.

2 Likes

Thanks for building this! Definitely pushes me to be more consistent in reviewing example sentences as part of my reviews.

I’m finding it sometimes ends up a bit too workload heavy to do this for all items. Any chance of providing an option to only show this for items above a certain SRS stage?

eg. Guru+ so that I get solidify the meaning in context after learning the vocab itself?

found this way too late. awesome plugin, thanks a lot :slight_smile:

I can add it to the backlog, but no promises about if/when I’ll have time to do it, as I’ve been quite busy recently. At least personally, I’ve found that with the vocab highlighted, skimming through without reading all the context is quite possible.

I’m just glad that people are finding my script useful the themselves in some way :grinning:

1 Like

Can you make a hotkey to toggle the context sentence appearing? I’d like to see if I can remember a vocab without it then toggle the context sentence as an extra hint.

Just found a problem with the script. It highlights the wrong word sometimes since it uses the same kanji, and since I assume the script highlights the first appearance of the word it gets mismatched. In this case kane (money) is highlighted instead of kin (gold). A possible fix for this would be nice otherwise I just have to be more vigilant in the future. I do like this script!

2 Likes

@rever4217 From a programming perspective, how would one even check this? Would a list of all WK words be needed to cross-reference?

I really don’t know. Without furigana it’s probably an impossible task. Probs no other way than to just search all the sentences where the word occurs multiple times and check each one manually.

Right, this error makes me wonder how it checks for the word.

1: Just searched part of the script, appears to look for the root (kanji) of the verb if the conjugated form is used? And I guess since 写る only has one kanji it just took the first instance of 写 which happened to be 写真.

I can’t code so I don’t know how to fix this, but I imagine something like searching for the instance where the root kanji is the only kanji present in the word may work since this would disqualify 写真 (since 真 exists). Then again there aren’t any spaces so how do you even define a word. Perhaps just taking the first instance of hiragana next to the root would work.

1 Like

Unless, 上がる and 上げる, or another verb pair like that, in the same sentence…

1 Like

The variety of special cases to look out for! I mean these cases are already special. I guess you need a way to properly get the root (sorry I called it stem before) as at the moment it only takes the kanji part of the root.

I would be interested to know how the extension decided that 。 is the answer, despite the original sentence not even having it at the beginning of the sentence.

4 Likes