[Userscript] Memrise Audio Provider

I am having an issue with the audio dropping after a few prompts. When this happens, the Audio Provider link on the top left disappears. Much thanks for the script, I am also using some of your other scripts and they are all excellent!

1 Like

Glad you like the scripts!
The problem you’ve experienced arises because google tts calls eventually get blocked by google to prevent abuse of their system.

I’ve improved the script by caching and preloading audio behind the scenes so that only one call will get made per unique word; this will help things a lot and you should hopefully get to complete your sessions without the audio cutting out anymore. Latest is v.0.1.0 :raised_hands:

2 Likes

Very slick :smiley: it works perfectly! the best memrise scripts out there :slight_smile: Thanks a lot for the fix!

2 Likes

you are genius @cooljingle

I had finally a possibility to use PC and try out this script… awsome

1 Like

Thank you for writing, and then providing both this Audio Provider script and a manual on Github.

There are three audio providers. Is there any way that the user can choose which audio provider is getting used? It would give an opportunity for the user to listen to an alternative audio if the first one is not clear for a particular word.

And, would I be able to modify the script, so it actually will download audio, for example to the download folder?

Sorry I have so many questions!

How does the script choose between the three anyway? First try Speech Synthesis API, if that doesn’t work, the Google TTS API and if that fails Voice RSS?

How does the script choose between the three anyway? First try Speech Synthesis API, if that doesn’t work, the Google TTS API and if that fails Voice RSS?

Yep!

Is there any way that the user can choose which audio provider is getting used?

Not right now. Speech Synthesis sounds have the most support in chrome where it’s pretty much identical to google tts, albeit without the call limit. Voice RRS sounds aren’t as clear to me as google tts; also it supports less languages, has its own call limit and requires people to get their own api key to get working. So the source priorities are quite logical to me.

And, would I be able to modify the script, so it actually will download audio, for example to the download folder?

I don’t think that’s possible to automate in just a userscript. You could possibly insert a link to the audio which you could then click to download, but I think it’s probably smarter to run a bulk audio generation program (which has been done).

As an aside, I fixed support for Spanish - latest is 0.1.1

2 Likes

Thanks for the sharing.[quote=“cooljingle, post:9, topic:10133”]
So the source priorities are quite logical to me.
[/quote]They are.

best script, period. Thank you for spending your value time contributing this awesome script to the community.

i just found your code and installed it, but it doesn;t work. Do you have any tips on how to get it to work. I installed tampermonkey. opens the js file in notepad and copied it in tampermonkey.

You can try directly installing through the installation link: https://github.com/cooljingle/memrise-audio-provider/raw/master/Memrise_Audio_Provider.user.js

The speech quality in Esperanto is very bad. Any way to improve it?

For esperanto it would use google text to speech to create the audio - i don’t know of a better alternative but if people know of one I can add it.

I’ve heard that Forvo do higher quality audio but their api isn’t free - $1 a month for 500 requests per day.

Hello, @cooljingle! A big fan of your scripts is here to report that recent memrise update has broken your script. I’m very very sad.

I’m sad too :cry:

It’s fixed! Latest version 0.1.3

If you have saved choices for the audio column (option on the left) then those will have been wiped out and will need to be reapplied.

2 Likes

Thank you for reacting so fast. But now this script freezes the review session when I make a mistake. Normal review word screen doesn’t show and the only way to continue is to exit the review session completely and start again. With script disabled everything is fine.
Thank you so much for supporting this awesome script.

There was an issue affecting just Firefox - hopefully it’s fixed now (0.1.4)

1 Like

Huh, I have the same issue as Huntress, but I don’t have this script. I’m thinking it might be the learning retries one.

Oh man, @cooljingle. I had no idea how DULL learning sessions could be without auto-learning. You’re such a prince for making that script.

heh, I’ll put that next on my list :stuck_out_tongue:

2 Likes

@cooljingle, thank you so much! It still has one minor problem though. Changing the column for audio in the options on the left doesn’t always work.
I have my own course consisting of levels based on two different databases. Both have English and Russian columns. The goal is to pronounce always English column, and before the memrise update it worked perfectly. But now changing one to English always results in the fact that words from other database are set to be pronounced in Russian column. If I have a joined review session I can change column options to English only for the first item (for the database of the first item). The words from the other database will show in options on the left to be set to English but in reality the Russian column will be pronounced.


On the screenshot it is shown that audio is set to English, but in fact the Russian column is pronounced.

If I finish the review session and start a new one and the word from other database will happen to be the first, the options will show as “Russian”, I will be able to change them to English, but if words from another database will happen in this session they will be reseted to Russian again.

Right now I deal with it by reviewing words per level (I have 34 of them in my course). In that case while I review words from the same database the audio option sticks. When I change level to the one with different database it is always set again to Russian and I start the review by changing the audio option.

This time I checked it both in firefox and chrome. It’s pretty much the same, but in firefox trying to change audio options for a different database in a mixed review session in the middle of the session leads to “whoops” mistake.

The main idea being… Thank you so much for the script! It works now and I am happy. But my complex personal course leads to few minor issues, which make it a little less comfortable than it used to be before the memrise update. Much appreciate you supporting this awesome script. I love it very much.