[Userscript] Keisei 形声 Semantic-Phonetic Composition


#122

Awesome, thanks for the information. Sounds like you found a good balance for what to include.


#123

I found a fun bug. I’m doing reviews and wanted to check out “Dakuten Mode”, so I opened the settings to turn it on. But it just duplicated the listed kanji instead of doing whatever it’s supposed to do. The same thing happens with “Full Info Mode” and I managed to get four copies of the kanji to appear at once.



image


#124

Thanks for the report, this was doing the correct thing but I must have broken it along the line. Version 1.6.5 now, I also delete the previous chargrid instead of just putting a new one.


I was also revising the database a bit because a was reading about the kanji reforms in the past. Several generations of people were messing around with the kanji big time, replacing phonetic marks with others, randomly replacing components with totally unrelated components, changing readings, replacing kanji in compounds that just share the reading (if you ever wondered why 注文 “pouring a sentence” is an order, it was 註文 before and someone decided it would be great to save a few strokes).

So some things are compounds now, while other were removed. For example 尺 was just used to replace stuff, so many kanji with readings that didn’t fit in the first place are removed.


#125

Hi, sorry if this isn’t the place to report errors or if this is a known issue, but I’m getting an error for the kanji 関.

“An error occurred while processing kanji []! Message was: ‘The requested kanji is not in the database (or typo in DB)!’”


#126

Oh yes, I forgot to push that change! I was changing a few things in the DB, like adding the old version of some kanji where the phonetic component is still visible.

Fixed in 1.6.6 now!


#127

Thanks!


#128

@acm2010 Have you considered making a lightweight website or iPhone app for all of this data you’ve gathered? It’s one of the most helpful resources I’ve used, but I feel like there’s more that can be done with it. It’s kind of a shame to only expose it through a userscript on WaniKani.


#129

I was considering what would be good changes to WK, but then I was too impressed by the Kodansha Kanji Learner Course :slight_smile: WK with KKLD ordering and sometimes their memory aids would be tremendous.

Somehow all resources downplay the usefulness of the phonetic compounds, I think RTK has “pure”, “semi-pure” and irregular groups as if it was a huge problem that a reading is sometimes か, sometimes が. But using the compounds is still the RTK (part 2?) approach I think.

One benefit of WK is that I can reuse the great styles here, getting a nice representation is very easy. A pity that past level 20 or so it doesn’t switch gears to a more effective (?) learning style.

All I was able to think of was resulting in a remake of WK, which seems like a huge task for a small market :slight_smile:


#130

Yeah, I can understand that. If you made your own website or application you’d have to do all that stuff too, which can be a pain.

Yeah, I agree. I think I’ve only seen phonetic components mentioned once or twice. It’s such a wasted opportunity.

I’m curious why you think that. I look at your database of phonetic components as a supplement. If you released it as a standalone dictionary that would still be useful. I don’t see a reason it would have to turn into a full learning program like WaniKani.


#131

I’m probably not thinking of a simple way :slight_smile: How would you imagine the app?

Actually I was looking all phonetic information up on the internet, it is quite accessible (on a per kanji basis). Books just add huge tables as a supplement. The problem is the presentation as huge pile of readings that may or may not fit and lack of guidance how to use it. A step-by-step approach like WK is also much better for it, so it always turns into some kind of course for me …


#132

I think it would work similarly to how you have it set up in WaniKani.

  1. There would be the “directory” of information like you have in the “Tone Marks” page on WaniKani. This would list out all of the phonetic components available and allow you to select them to see all kanji with the phonetic component.
  2. Then you could also allow the ability to search by reading. I think a search would be more intuitive than the “Column” and “Initial” options you have to select on the “Compounds” page that you created on WaniKani. This would show you all of the phonetic components available with that reading.
  3. Finally, you could search by kanji. This will allow you to see what, if any, the phonetic component is for that kanji. And of course you’d be able to select the phonetic component to see what other kanji use that phonetic component.

Like I said, more of a dictionary than a learning app. As a bonus, I think it would be nice to include less common kanji. As you explained to me a bit ago, sometimes the phonetic components are good identifiers, but are mostly used in less common kanji. So if you only show Jouyou kanji, it might not be obvious why a phonetic component is useful.


#133

Hello! This looks like an awesome utility and I really want to use it! I don’t know much about scripts, however. I’m using chrome and I’ve installed tampermonkey. I couldn’t find a guide to installing keisei in tampermonkey, at least not on this thread. If any of you know where to go, please point me in the right direction. :relaxed:


#134


#135

That was my issue! I clicked the link and downloaded the script before I got tampermonkey. Thank you :slight_smile:


#136

I added some installation instructions in the OP, the first script is the hardest :wink:


#137

For 綱, when I click the button to show more details / sub-components, I actually see the same information twice.


#138

Whoops, that should have been 罔 instead of 岡. I should use a larger font in vim :slight_smile: Fixed now.


#139

Omg rui’s version has been broken forever and I’m so happy it’s been replaced and improved?!!.

I love you so much for this and the visually similar scripts. Haven’t used either yet, but I can tell enough from the OP that they’ll both be great. :heart_decoration:


#140

@acm2010 I’m trying to write a script that inserts some text into the “additional info” section during reviews similar to this script. Can you point me to the code in your script that waits for the right moment to add the additional information?

It seems related to

$(document).on(`${GM_info.script.namespace}_wk_subject_ready`,
                       this.injectKeiseiSection.bind(this));

But I can’t figure out what ${GM_info.script.namespace}_wk_subject_ready is.


#141

There is a generic module named wk_interaction that triggers javascript events once it detects that WK is ready.

I wanted to avoid that the user has to install several scripts and tinker with the execution order, so all of my scripts that use wk_interaction run their own copy. To prevent that there are multiple events for the same thing, the events are put in the namespace of the script (by naming the events differently). The first part of ${GM_info.script.namespace}_wk_subject_ready is replaced with what you put in @namespace line in the script header, so the event name is for example wk_keisei_wk_subject_ready.

You can use the same line for any script to wait for events, and you just have to include the wk_interaction and activate it.

this.wki = new WKInteraction(GM_info.script.namespace);
this.wki.init();
this.wki.startInteraction.call(this.wki);