[Userscript] Self-Study Quiz

it is already installed, all 5 items are marked there.

still no luck :frowning:

1 Like

Here’s the diff for opening item’s page on ctrl/cmd + O:

@@ -1690,11 +1690,13 @@
     var keycode_xlat = {
         '8':'Backspace', '13':'Enter', '27':'Escape', '37':'ArrowLeft', '39':'ArrowRight', '65':'KeyA',
         '69':'KeyE', '72':'KeyH', '76':'KeyL', '80':'KeyP', '82':'KeyR', '83':'KeyS', '112':'F1',
+        '79': 'KeyO',
     };
     function quiz_key_handler(e) {
         if (quiz_settings_state === 'open') return true;
         var input = quiz.dialog.find('.answer input');
         var input_readonly = input.prop('readonly');
+        var qinfo = quiz.qinfo.load(quiz.index);
         var code;
         if (e.type === 'keydown') {
             if (e.originalEvent.keyCode) {
@@ -1741,6 +1743,7 @@
                 case 'KeyS': manual_shuffle(); break;
                 case 'ArrowLeft': quiz.prev(); break;
                 case 'ArrowRight': quiz.next(); break;
+                case 'KeyO': window.open(qinfo.item.object.data.document_url, '_blank').focus(); break;
                 default: return true;
             }
         } else {

I might be missing something, but the “Include this source” checkbox is kind of misleading.

2021-07-08-23:33:38_457x391

If it were to remove the preset from the list in the main window, that would be another story. But it doesn’t. Also, is there a difference between a source and a preset?

There is a difference between a source and a preset. A source is a collection of items you can select from while a preset is a setting you save.

Currently Self Study Quiz supports only Wanikani as a source so this checkbox is a hook for future extensions in case you want to exclude Wanikani items because you only want items from a future alternative source.

1 Like

To expound upon what @prouleau said:
A ‘source’ is a 3rd party source of items, such as a “10k Vocabulary” list, or a “JLPT” list of kanji and vocab.

A preset is a group of setting for a combination of [sources] + [filters]. So, assuming a 3rd-party source has the corresponding information available, you can still filter that source based on things like [kanji/vocab], or [part of speech], etc.

It is true: not all filters are applicable to all sources. So, not all presets would work with all sources. But the interface isn’t sophisticated enough to know whether a preset’s settings will work with a particular source. Doing so would make the task of designing a filter or source significantly more difficult than it needs to be, so I didn’t bother adding that to the framework.

[edit: After a quick glance at the framework documentation, I remembered that filters are registered to specific sources. So, when someone creates a new source, any filters that were written for the Wanikani source would need to be modified or copied to support the new source.]

3 Likes

Your explanations seem to have cleared things up for me. But I needed to add a new preset after a while, and was confused again. I thought, “Shouldn’t it be called ‘Include the Wanikani source’?”. But then I saw the tab name, and everything fell into place.

So I’d say it’s confusing. Probably because the list is implemented using tabs. But probably okay. Because not confusing if you know what it means, and it doesn’t look like it can be fixed easily.

Yes, I can see how it can be confusing without any other item sources available. I had envisioned someone creating a Core5k or Core10k deck soon after Self-Study was released, but (surprisingly) it never happened.

1 Like

is there a way to allow typos in self study quiz? I use it mostly for failed last reviews and I just wrote govermetn office and got as an error.

Also, is it possible to connect it with confusion guesser script?

1 Like

It does have a typo algorithm, but it has some weaknesses. I did some testing years ago, and the algorithm I chose (Jaro-Winkler) performed slightly better than the one Wanikani uses (Levenshtein) in most cases, and slightly worse in other cases.

Edit: Thinking out loud
 Is there a setting in Self-Study to enable/disable typo forgiveness??

Depends on what you mean by “typo forgiveness”

Yep, that’s it.

1 Like

Bug report. The summary reports kanji with the vocabulary background color.

ssquiz

In case this information is useful, ssquiz was called through Item Inspector using the calling interface.

Fixed. [v3.0.32]
Also added trim() to eliminate spaces before and after the answer.

image

2 Likes

Thanks a lot.

1 Like

I have noticed that SSQ doesn’t accept answers allowed through the whitelist. This causes SSQ not to accept answers accepted in Wanikani reviews. I didn’t test the blacklist but I wonder whether this is not checked as well


Yep, those didn’t exist when I wrote SSQ. I probably won’t implement it myself, though I would consider merging someone else’s change. I’m mostly only planning on fixing scripts when they break, and only if it doesn’t take much time. (Gotta move on eventually :cry: )

2 Likes

Was there any recent change to Self Study Quiz? Since a couple of days SSQ displays the items in a bold font. This is a bit annoying. There was no change on my end that I can think of that could explain this.

SSQ

this bold way it always showed for me like this.

do you have jitai and japanese fonts installed? I think it could be implemented to show those fonts as well in ssq.

I have no jitai script and only the stroke order font installed.

No changes. You should be able to find where the change is coming from by looking at the ‘Computed’ tab of the CSS rules in the dev console, then look at the link next to “font-weight” to see which file it’s in.

1 Like