tag:mentalfaculty.tenderapp.com,2010-10-19:/discussions/suggestions/3743-text-to-speechThe Mental Faculty: Discussion 2018-10-19T02:24:16Ztag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-10-31T18:39:18Z2014-10-31T18:39:20ZText-to-speech<div><p>I second this feature request. There's a free app for iOS,
Flashcards, that does this already.</p></div>Justintag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-01T07:52:49Z2014-11-01T07:52:49ZText-to-speech<div><p>I’ve added this request to our list.</p>
<p>In the meantime, on OS X, there is a standard Edit > Speech
menu that you can use to speak the slides. I think you can add a
keyboard shortcut using the System Preferences.</p>
<p>I just tried this, and it didn’t read my foreign words
well, but I think if you changed your keyboard or language
settings, you can probably get the Korean.</p>
<p>If you want to try adding the sound files with
‘say’, there is no applescript, but there is an
export/import format that is editable: Study Archive. If you export
your notes in Study Archive format, the file you get is a zip
archive (change extension to zip in order to unzip, or use command
line tool).</p>
<p>It is a basic comma-separated values format. You can read more
here: <a href=
"http://www.mentalcaseapp.com/studyarch/">http://www.mentalcaseapp.com/studyarch/</a>
<a href=
"http://www.mentalcaseapp.com/studyarch/">http://www.mentalcaseapp.com/studyarch/</a></p>
<p>I think it should not be too hard to extract a value from one
column, run it through ‘say’ to generate a file, and
append an audio column. The advantage of this is that it would also
work on iOS.</p>
<p>If you manage to generate the new files, just zip it up again,
and change the extension to studyarch.</p>
<p>Kind regards,<br>
Drew</p>
<p>PS If you like the app, please consider writing an app store
review. They really help us.</p></div>drewmccormacktag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-01T20:27:58Z2014-11-01T20:27:58ZText-to-speech<div><p>Thanks Drew. I tried the Edit > Speech menu item here and it
did nothing in the slideshow view (and I definitely have the voice
for Korean installed).</p>
<p>I had a look at the Study Archive and there were 6 columns -
nothing for audio attachment. If I just add a column prefixed with
the facet number 1 referencing the filename, zip it back up - how
would I get this back in to the app?</p>
<p>Would be good to get this in the app sooner rather than later
(should be quite easy - I'm a developer too). There's another issue
I'm having with sync. I'll hold off on writing a review until these
are resolved as they will definitely affect my review score.</p></div>andytag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-01T20:52:41Z2014-11-01T20:52:41ZText-to-speech<div><p>I tested the speech menu today and it was working for me. What
version do you have?</p>
<p>If you add an Audio column, as the web page describes, then zip,
and change the file extension to studyarch, you can just double
click to reimport the data.</p>
<p>Kind regards,<br>
Drew</p></div>drewmccormacktag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T08:41:25Z2014-11-03T08:41:25ZText-to-speech<div><p>Sorry Drew, I'd skipped the link you sent me as I'd already been
nosey and looked at the contents of the file :-)</p>
<p>I'll write a little Ruby script to unzip the archive, add the
audio for any missing ones and then zip it back up again. I'll post
a link when I'm done for anyone else.</p>
<p>Regarding the Edit menu option, I'm running MC 2.6.6. However it
is probably the fact that there's no way of choosing the
language/voice for my Facet 1s. If I run the following at the
command line:</p>
<p>say "안닝 하세요"</p>
<p>I get nothing. But if I change it to:</p>
<p>say -v "Yuna" "안닝 하세요"</p>
<p>It correctly says it in Korean.</p>
<p>Anyway, it will be lovely when this functionality is integrated
in some way, but for now I'll write a script as a work around. I
don't suppose there's any command line utility to export/import
these studyarch files so I can automate it more completely? I had a
nose around in Mental Case.app/Contents but couldn't find
anything.</p></div>andytag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T08:47:23Z2014-11-03T08:47:23ZText-to-speech<div><p>Hi Andy,<br>
No, there is no command line tool. You can export multiple stacks
at once though, and have your script iterate over the
directories.<br>
I played a little with the voice, and it seems like if you change
your keyboard selection to Korean, it then will use the Korean
voice. I am pretty sure you should be able to find a combination of
language options in the System Preferences to speak in Korean.<br>
Drew</p></div>drewmccormacktag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T08:52:30Z2014-11-03T08:52:30ZText-to-speech<div><p>Hmmmm... I have a global keyboard shortcut that I use a lot to
switch between keyboard layouts, whether it's currently in English
or HNC Romaja (one of the Korean input styles) seems to make no
difference to the Edit > Speech menu.</p>
<p>For me when I click Start speaking, if I go back to the menu
both are still enabled (start and stop). Is that the same for you?
Or does the Start speaking item become disabled (because it's
already started)?</p>
<p>I definitely have the Voice installed and the Keyboard layout
installed and working fine outside of Mental Case. Any other ideas
to help debug it?</p>
<p>The only error I am getting in "Console.app" is:</p>
<p>03/11/2014 08:50:01.791 Mental Case[26198]: Error merging: Error
Domain=CDEErrorDomain Code=201 "The operation couldn’t be
completed. (CDEErrorDomain error 201.)"</p>
<p>I don't think that will help though as that seems to be related
to your Ensembles framework.</p>
<p>For now, don't worry about it - I'll go down the MP3 route. I
can hold off on native functionality until the Text to Speech API
is more fully integrated.</p></div>andytag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T09:07:19Z2014-11-03T09:07:19ZText-to-speech<div><p>From my script so far, it seems the CSV file in the Study
Archive isn't in UTF-8? I've tried reading it as BINARY but Ruby's
CSV library really doesn't like that...</p></div>andytag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T09:15:59Z2014-11-03T09:15:59ZText-to-speech<div><p>I think it should definitely be UTF8.</p>
<p>Drew</p></div>drewmccormacktag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T09:18:21Z2014-11-03T09:18:21ZText-to-speech<div><p>It's definitely not showing correctly as UTF-8 in Atom either
(aside from Ruby 2.1's CSV library).</p></div>andytag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T09:18:59Z2014-11-03T09:18:59ZText-to-speech<div><p>Ah, sorry, I was wrong. I remember now: we changed it to UTF16,
because windows didn’t handle UTF8 well. That seemed to be an
option that worked well for most.</p>
<p>Drew</p></div>drewmccormacktag:mentalfaculty.tenderapp.com,2010-10-19:Comment/351400412014-11-03T09:24:30Z2014-11-03T09:24:30ZText-to-speech<div><p>Ahh OK. Now I've converted to using UTF-16 I get a different
issue (something internal to Ruby's CSV library). I think I'll just
have to do this by hand...</p></div>andy