[Userscript] Memrise Audio Provider

Try to deactivate the “Memrise Turbo” user script.

You are probably typing much too fast; it really an enormous speed increasement using it and I couldn’t believe my eyes, once I installed/tested it on a 2nd PC when I compare how I review my PT BR DuoLingo course by MartinPen with Cooljingle’s “auto correct” script!

Anywhere from 1 to 50, usually, less than 100.
What is weird is that I’ve no issue with the learning session, and i do the reviews the same way and with the same speed.
I would’ve said you are right otherwise. I indeed do them very quickly though. About 600 questions in 40 minutes.

Would it be possible to create a script to auto-upload tts voice to courses like the Awesome TTS script for Anki? https://ankiweb.net/shared/info/301952613

That would be the best solution.
There is no real need to hit the google api every time for the same thing, when you can do it just once for everyone.
TTS voice is usually much better than nothing.

I don’t type or use the memrise turbo script. I do multiple choice questions.

The tts requests are cached during the session so when you are learning the requests aren’t repeated when words reappear.

1 Like

@cooljingle That’s a bummer. Thank you for explaining. :confused:
I might have to move this deck over to anki then, and try to populate the audio there.

Here is a tutorial about the anki script I mentioned.
I marked the time frame.

1 Like

There is a similar tool for memrise that @DrewSSP created which could work for you:

1 Like

@cooljingle

Merci beaucoup for this awesome userscript (v. 0.1.15) !

One of my favourite courses has 1/2 of the audio missing and this has solved my problem of having to go to Forvo or google translate to confirm the correct pronunciation.

Cheers,
Kim

@cooljingle cooljingle

This is a weird problem because I am using it on a course that only has about 1/2 the audio loaded (https://www.memrise.com/course/756657/verb-conjugations-en-francais/). I added the script after I had done almost 20% of it. The lessons were working a treat until it came to doing reviews (even of the parts that had audio) - they would not load while the your script was running. I wanted the extra audio so much that I cleared the course (had already done this to re-review before I found this script).
This has worked for me - so, thanks for the heads up (just wish I had read it earlier :rofl:

Cheers again,
Kim

Hello, @cooljingle! Among other things that new memrise update has broken is unfortunately this awesome script. Even the option on the left doesn’t show up. As I think the update may have effected a lot of things and many of your scripts, I will only hope and patiently wait till you have time to fix it up.

Yours fan as always.

Update. Checked chrome. Chrome is Ok. Only in firefox the script has stopped working.

Update 2. Really sorry. False alarm. Now it is working fine both in firefox and chrome. (I downgraded my greasemonkey).

You are still the best.

@Huntress

What do you mean you “downgraded my greasemonkey”. Chrome is still playing up on revision even though I restarted the course. It is freezing after 1-2 revisions. I’ll try anything.

@ripcurlgirl

1 Like

I’m unable to learn this course with this script enabled:

You get an empty page:

The script was broken by another update - I’ve updated the script to fix the problem (0.1.16).

2 Likes

Hi @cooljingle,

the last Memrise code update from Wesnesday 01/17/2018 fucked up your audio script V0.1.16.

TypeError: context.learnable.audios is undefined[Weitere Informationen] Memrise_Audio_Provider.user.js:162:29
injectAudioIfRequired file:///C:/MyFirefoxProfileDirectory/gm_scripts/Memrise_Audio_Provider/Memrise_Audio_Provider.user.js:162:29
MEMRISE.garden.boxes.load</</MEMRISE.garden.session.make_box</< file:///C:/MyFirefoxProfileDirectory/gm_scripts/Memrise_Audio_Provider/Memrise_Audio_Provider.user.js:83:46
[1]</</s<.activate_box https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:291432
enableInfiniteLearning/g.boxes.activate_box</< file:///C:/MyFirefoxProfileDirectory/gm_scripts/Memrise_Infinite_Learning/Memrise_Infinite_Learning.user.js:37:21
[1]</</s<.begin https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:291201
[1]</</<.session_start https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:22066
[1]</</<.load_session/<.success https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:19961
at.Callbacks/l https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:36968
at.Callbacks/u.fireWith https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:37739
i https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:75655
.send/n/< https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:80514
i https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:439737

Basically almost all your other scripts are broken - I will repost to all other user script threads.

2 Likes

Hello, @cooljingle!
As @Thomas.Heiss has already reported, your awesome script has stopped working. The review session won’t start. Will be patiently waiting for my favorite script to be back and will miss it greatly. Thank you very much for it!

Hopefully it’s all fixed again with the latest script update (v0.1.17).

1 Like

Hi @Cooljingle, a new error with v0.1.17 pops up when you hit the ENTER key and the field is empty (red) or not ALL letters or accents (diacretics) have been typed 100% correctly (yellow).

For some tested words which where OK (green) it worked already for PT7 (no strict typing) + DuoLingo PT (strict typing).

However, I would have to re-test the next version of your audio script with the “50 languages” course where definitely many audios are missing so your script will jump into…

1 Like

@cooljingle
Thank you for supporting this great script! I can confirm that there are some problems with v0.1.17. I wasn’t able to start a review session in firefox. I just get this screen.

In Chrome the session starts ok and with words that are answered correctly everything is ok, but I can’t get past the words I answer wrong. I get the reminding screen of the word, but can’t get past it as nor Enter neither “Next” button works.


Clicking on Next does nothing.

Thank you for supporting this. You are the best!

Thanks for letting me know - the script was break on the ‘copytyping’ screens, should be fixed in the latest (v0.1.18)

@cooljingle

V0.1.18 first worked great in three courses and the red error after the empty text field (or words/sentence with errors) was definitely fixed when I pressed the NEXT button.

Now I run this night 4+ times with V0.1.18 into a new error on some items (not always) as soon as the next item is loaded automatically or manual with the NEXT button (Memrise’s own “auto accept” default, “auto correct” script activated, “all typing” disabled OR enabled) with this strict-typing course https://www.memrise.com/course/359836/duolingo-brazilian-portuguese

Exact same error happens for the Preview and Review for the 50 languages PT BR course (many missin audio files): https://www.memrise.com/course/702398/50-languages-brazilian-portuguese-no-typing/

It does not matter if the words are normal (e.g escola) or contain diacritics (e.g estatística, código).
AFAIK there are multiple items (words) where no audio is uploaded.

TypeError: e.replace is not a function[Weitere Informationen]  memrise-bundle-47c687a97413.js:1:31636
	[17]</t.exports/s.fixMediaUrl https://d2rhekw5qr4gcj.cloudfront.net/dist/js/memrise-bundle-47c687a97413.js:1:31636
	MEMRISE.garden.boxes.load</</MEMRISE.renderer.fixMediaUrl</< file:///C:\MyFirefoxProfileDirectory/gm_scripts/Memrise_Audio_Provider/Memrise_Audio_Provider.user.js:105:32
	[17]</t.exports/s.renderAudioPlayer/< https://d2rhekw5qr4gcj.cloudfront.net/dist/js/memrise-bundle-47c687a97413.js:1:35436
	.each https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:12366
	[17]</t.exports/s.renderAudioPlayer https://d2rhekw5qr4gcj.cloudfront.net/dist/js/memrise-bundle-47c687a97413.js:1:35407
	[17]</t.exports/s.renderVal https://d2rhekw5qr4gcj.cloudfront.net/dist/js/memrise-bundle-47c687a97413.js:1:36837
	[1]</</c.ThingBox<.get_context https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:284790
	Class</<.inherit/r https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:269317
	[1]</</c.TestBox<.get_context https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:288172
	Class</<.inherit/r https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:269317
	[1]</</c.Box<.render https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:281515
	[1]</</c.Box<.activate https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:281154
	[1]</</c.ThingBox<.activate https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:283301
	Class</<.inherit/r https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:269317
	[1]</</c.TestBox<.activate https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:288779
	Class</<.inherit/r https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:269317
	[10]</f<.activate https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:384723
	Class</<.inherit/r https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:269317
	[1]</</s<.activate_box https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:291486
	enableInfiniteLearning/g.boxes.activate_box</< file:///C:\MyFirefoxProfileDirectory/gm_scripts/Memrise_Infinite_Learning/Memrise_Infinite_Learning.user.js:37:21
	[1]</</s<.advance https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:291313
	MEMRISE.garden.boxes.advance</< file:///C:\MyFirefoxProfileDirectory/gm_scripts/Memrise_Ignore_Previous/Memrise_Ignore_Previous.user.js:48:24
	[1]</</c.Box<.next_press/< https://d2rhekw5qr4gcj.cloudfront.net/garden/dist/js/garden-bundle-94009e949c13.js:1:282695
	e/l.fn https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:159750
	o/l.id< https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:159473
	i https://d2rhekw5qr4gcj.cloudfront.net/dist/js/libs-41c582fa7c13.js:1:439737
MEMRISE.renderer.fixMediaUrl = (function () {
                **var cached_function = MEMRISE.renderer.fixMediaUrl;**
                return function () {
                    if (arguments[0] === "AUDIO_PROVIDER" || (_.isArray(arguments[0]) && arguments[0][0] === "AUDIO_PROVIDER")) {
                        return "";
                    } else {
                        return cached_function.apply(this, arguments);
                    }
                };