Created
April 25, 2013 22:58
-
-
Save jacobhak/5463919 to your computer and use it in GitHub Desktop.
Applescript which takes an audio recording from Evernote and runs speech2text on it.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "Evernote" | |
set notel to find notes "db" | |
set theNote to notel's first item | |
set att to get attachments of theNote | |
set theAtt to att's first item | |
set filepath to "Macintosh HD:Users:jacob:kod:speech2text-test:test.wav" | |
write theAtt to filepath | |
set s2t to do shell script "/bin/bash -lc 'speech2text /Users/jacob/kod/speech2text-test/test.wav'" | |
set s2t to characters 5 thru -2 of s2t as string | |
append theNote text s2t | |
set title of theNote to characters 1 thru 3 of s2t as string | |
move theNote to notebook named "log" | |
end tell |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
See speech2text