-1

I want to convert words to its Arpabet translation.

Something like:

HELLO   HH AH L OW

But I want to do it programatically in java, sphinx offers a web tool here http://www.speech.cs.cmu.edu/tools/lmtool.html. I know I can request this tool in Java using sockets and sniffing out the .dic file returned but I cannot use this because not all users of my app has an internet connection.

I also checked-out logios package of Sphinx but it is written in perl and batch files. I can use it but I want to make my app platform-independent and I think it is a bit overboard if I include perl shell in my project.

If there's any java library or algorithm that I can reuse so I can just do something like ConvertToSphinxArpabet("HELLO") and I get the "HH AH L OW" string returned.

Marco Bonelli
  • 63,369
  • 21
  • 118
  • 128

1 Answers1

1

Please check the tutorial:

http://cmusphinx.sourceforge.net/wiki/tutorialdict

For example you can use g2p code from FreeTTS written in Java:

http://cmusphinx.sourceforge.net/projects/freetts

OpenMary Java TTS:

http://mary.dfki.de/

For FreeTTS example see our code in the long audio aligner branch:

http://cmusphinx.svn.sourceforge.net/viewvc/cmusphinx/branches/long-audio-aligner/Aligner/src/edu/cmu/sphinx/linguist/dictionary/AllWordDictionary.java?revision=11092&view=markup

Nikolay Shmyrev
  • 24,897
  • 5
  • 43
  • 87