[Userscript] Keisei 形声 Semantic-Phonetic Composition


#1

Keisei Semantic-Phonetic Composition

by acm

I am proud to release the stable version of my first script, Keisei Semantic-Phonetic Composition!

Installation Instructions

  1. Get Tampermonkey (installation instructions in this thread)
  2. Click on the installation link (Tampermonkey should auto-detect .user.js files)
  3. Install the script after you check the security (at least see that script will only change the wanikani website, all @include should be related to WK :wink:)

News

  • v1.7.3: Fixed issue where Keisei might interfere with other scripts on Firefox
  • v1.7.1: Layout fixed, and WK only mode!
  • Layout changes
  • beta features (enable them in the settings!)
  • Tooltips and “dakuten mode”

It is a full rewrite of the great script from ruipgpinheiro (LordGravewish) from this thread:

The script adds a phonetic compound information section to:

  • Kanji and Radical pages
  • Kanji and Radical lessons (also lesson reviews)
  • Kanji and Radical reviews

Example Screenshot

User Poll

I want to find out who is using the script, and send out @notifications I case I break something seriously in the future. Please click something!

  • I use the script and want notifications
  • I use the script but will just suffer silently
  • I just like to click on polls

0 voters

Features

  • All new database with 2201 kanji covered, 546 tone marks, 264 of which are also WK radicals. The goal is to show something for each and every kanji in WK.
  • Two new colors for phonetic marks in the character grid (see screenshots)
  • Badges show how useful the phonetic mark is for a kanji, in four levels (天、上、中、下)
  • The character-grid style is added to lessons and reviews as well (this is basically an ugly hack by adding some styles, let me know if pages look weird)
  • Some tone marks also have cross references to derived marks (for example 溥 → 尃) and (very rarely atm) warnings for kanji that have the component but are not phonetic compositions

Data Sources

I collected the phonetic information from
http://dic.nicovideo.jp
https://ja.wiktionary.org
http://jigen.net
http://www.kanjipedia.jp (main readings source)
http://blog.goo.ne.jp/ishiseiji

That being said there are nearly always different theories for the origin a kanji, so no guarantees for the accuracy of the information provided.

More Screenshots

Click to show ...

Radical Page

Review Page

Lesson Page

Narrow Screen

License

GPL v3, just do what you want with it.

Disclaimer

I am not responsible for any problems caused by this script. It currently has “works for me (most of the time)” status.

This script was developed on Chrome Version 61.0.3163.100 (Official Build) (64-bit) with Tampermonkey 4.4. It uses some fairly new features, but a recent browser version should do fine. Everything is done as strings, depending on your browser you may see some boxes instead of kanji for rare ones.
I tested it at some stage with Firefox or Greasemonkey, but just message me is you run into trouble.

Only the “meanings” of kanji are pulled from WK, readings may not fully correspond to what WK is saying.

Other Scripts

Also check out my similar kanji script!


Dear WaniKani speed demons and level 60s, how do/did you do it?
Must have scripts?
Frick Level 14
[Userscript] WaniKani Similar Kanji
Feature Request: Enhance 'visually similar kanji' section
I've hit the wall
Chart of Frequency of Kana used in WK Kanji readings
Using old Kanji to learn new Kanji
Sinyaven reached level 60!
Biggest Realizations / Mind Blows You've Experienced Learning Japanese
Biggest Realizations / Mind Blows You've Experienced Learning Japanese
Mnemonics are often Useless - Need simplifying
Notes on my WK experience
The quick or short Language Questions Thread (not grammar)
Kickstarter for Outlier Kanji dictionary is now live
Let's praise these USERSCRIPTS and their awesome CREATORS
Let's praise these USERSCRIPTS and their awesome CREATORS
Is there a resource where we can search kanji with the same Onyomi?
[Userscript] Niai 似合い Visually Similar Kanji
Worried about my accuracy?
Harder to recall
Sunflower - - 里
Wani Kani Mnemonics
About to enter the painful levels... searching for advice on how to handle the pain
Level 19, stuck forever, hating myself, rolling backward
命 versus 令
Is it okay to forget mnemonics?
[iOS] Tsurukame - native app with offline lessons and reviews
What do you want now? (Request extensions here)
Radical Priority
Most common onyomi
What's the damn problem?
Learning kanji - No similar Kanji shown - Why?
Anyone else using primarily Anki for WK?
Favorite or Must Have Scripts and Apps?
Do you use the Mnemonics or opt for rote memorization?
Resources for Starting to Read Japanese Content
Powerpunching my way to the golden badge! (AKA my level 60 thread)
Update beneficial or detrimental for higher levellers?
I won't need to remember those stories after a while right?
Add note about common radical pronuncations
[Userscript] Hitsuji Animated Stroke Order Diagrams
[Userscript] Niai 似合い Visually Similar Kanji
Note Taking Methods
[Userscript] WaniKani Rendaku Information
[iOS] Mobile AlliCrab for WaniKani
Looking for generic user script to help with enhancing lesson information
Is there really a big jump every 10 levels?
Most lessons done at once?
Any resources to group kanji reading?
Inefficient radical combinations
#2

Ping for @gzovak, @temporaryuser381, @seanblue, @galg, @EvilTrout, @polv because they were interested in this.


#3

Looks nice, I’ll be sure to check it out. I’m curious though, what’s the reason for including the WK radical with the phonetic component and kanji?


#4

The examples in the screenshot accidentally are always related to a WK radical, this is not always the case. It also doesn’t need to be a kanji in WK either. This looks like this:

And I added it to the radical pages because it is easier to figure out for example “Ken the Squid”:


#5

How did you handle when the semantic component doesn’t exist as a character? The old script indicated that sometimes, so I’m curious.


#6

Most of the times it does exist (I didn’t encounter one that didn’t, rather there are multiple legacy versions), but there are two problems. It’s not guaranteed that everyone can see stuff like 丩, 囟, 𢦏, and you need a page where you can copy/paste it from, I have no idea how you would enter these manually. WK does some radicals as pictures, but I figured that if you can run scripts you don’t run on a phone or something, they can display less symbols.

For the old script my guess would be that finding the symbols was the problem, it used what was already there in a thesis. For me, if there is no symbol the component is too obscure anyway, I skipped some kanji where there is only one compound in WK with a tone mark that didn’t even look like it was included in the kanji anymore.


#7

If you can list some or all of the kanji with a standalone component you can’t find, let me know. I found a lot of the components by trawling Chinese dictionaries, and inserted them into the old userscript that I was still using (definitely giving this a shot though, the other does have some annoyances).

They are, necessarily, Chinese characters rather than Japanese. But most devices that display Japanese will also display Chinese.


#8

Thanks, I will let you know if I find one that would be nice because it has several compounds. I had some that won’t even display for me, but the kanji itself was simplified as well like 活 (http://dic.nicovideo.jp/a/活). But such knowledge is not helping as a shortcut to guess readings, rather it’s learning one more kanji you will never need. If you go beyond jouyou it’s of course a different thing.


#9

@acm2010 I’m finally using the script during lessons, and I have a couple suggestions.

  1. Add some padding/margin between the bottom of the “hint” and the start of the Phonetic-Semantic Composition section.
  2. Allow section to be hidden, just like the old script. It takes up a lot of space, so being able to hide it (ideally hidden by default) would be helpful.

For reference:


#10

The lessons part is not that tested yet because I need for lessons to come up :smile:

No problem, I already added additional space for radical pages, the layout is non-standard there.

For longer information there are already some hidden parts. You also want the character grid hidden? I’m planning to add some settings for the script, I can add a way to choose this. Just the sentences for you?


#11

I’m referring to hiding the whole section, including the character grid (that takes up the bulk of the space after all). I guess I haven’t encountered one of the kanji that already had hidden content.


#12

Out of curiosity, why does the squid radical look different than WK squid radical?

Other than that, looks cool, like something I’ve been wanting to create, but lack the ability to do so…


#13

I’m glad that the script works at least works nicely, it can easily happen that nothing appears at all. I will add a “minify” option.

If you want so see the maximum you can look at “turkey” related kanji, the number of kanji there really surprised me. It doesn’t even include 隼 and others yet.
https://www.wanikani.com/kanji/稚

For this one the squid is a simplified form, those kanji started out as 儉, 驗,險, etc. 僉 is something like a hieroglyph of a discussion among people. I just copied it over, WK uses a picture so maybe the squid is not available standalone.

If you are interested you can browse a bit, looking at the history and the old Chinese scripts is quite interesting.
http://dic.nicovideo.jp/a/験
https://ja.wiktionary.org/wiki/僉


#14

Oh, absolutely. The script’s UI looks very nice by the way, and I think it will be very useful. Thanks for spending so much time on it. :slight_smile:

EDIT: I looked at the 稚 example. You might want to remove the hyperlink for the “not in WK” kanji, or maybe link to jisho’s kanji page instead (for example: http://jisho.org/search/堆%20%23kanji).


#15

Good call, I will consider it for the release version. But there is a story behind it: The meanings are not gathered on demand from WK, I just used the API to get a list of kanji and meanings in advance. For some reason half of level 60 was missing at first, so “not in WK” may be wrong, and I wanted to click the links when they come along to find errors. I will fix this once the database saw more exposure. If WK adds more kanji this must be adjusted manually as well.


#16

I’ve been using this with my latest lessons.
Clicking on the phonetic component marked by green (even if it’s a middle-click for opening in a new tab) goes to https://www.wanikani.com/lesson/session which refreshes the session and I get a new batch of kanji for the session.

Also, on this particular kanji the url for the radical (blue) is misspelled as https://www.wanikani.com/radicals/speciality
instead of https://www.wanikani.com/radicals/specialty which opens the “We’re sorry, but something went wrong” page.

Oh and I’m using FF 56.0.2/ Tampermonkey.


#17

@gzovak, @seanblue

I just pushed a new version, just click on the Download Link again or “Check for Userscript Updates”. If you want the newest databases you probably have to clear the Externals in Tampermonkey.

Fixes:

  • Added additional padding in some screens
  • Green links now do nothing (I hope, the sessions are strange beasts)
  • specialty fixed

New feature:

  • You can now toggle the visibility of the first chargrid as well, and toggle this setting globally so that it always starts hidden

Click on the eye to hide once.

Go for the cogwheel and click the “Toggle Mini Mode button” to always start out with a closed eye. This should be semi-permanent, it is stored inside Tampermonkey.

I must say that the last feature is an insane hack for review and lesson pages, adding some bootstrap features to pages that use another toolkit … I will do more tests when I get lessons or reviews with kanji and radicals :wink:


#18

Got undefined for a reading. During my review of 緊.


#19

Could you add target="_blank" to the links when on the lesson page? (And possibly the review page–I don’t have any reviews right now to check.) That would be consistent with WK’s own links.


#20

I updated the version to 0.9.7, you probably have to update manually again.

Fixes:

  • Changed the structure to split the main file into several, I hope nothing broke
  • @seanblue Fixed undefined readings. This happens when the kanji is not yet in the new database, I added a fallback to WKs database.
  • less links should now lead to oblivion (“not in WK” kanji)

Which version are you using, and was it for all links or just radical or something? I already added this some time ago (meaning 2 or 3 days ago**), if it doesn’t work I broke it again. I will check when new reviews come up. Can you update (just click the download link again) and see if it still happens?

** Tampermonkey only checks once per week or so, in the beginning it’s best to update manually