Setting Up the IBM Voice Server SDK for PollyWorld Speech Recognition
by Chris Robbins
Download the IBM Voice Server SDK
- Go to the IBM WebSphere Voice Server SDK Download Page
- From the rightmost column, beneath the More Info heading, select the second download, Download the WebSphere Voice Server SDK. Doing so will take you to a "Trials and Betas Download" page.
- On the "Trials and Betas Downloads" page, select the second item in the table, which is the FREE IBM WebSphere Server Software link.
- Downloading the software is a multistep process:
- Configure: Specify US English as your language then click on the continue button.
- Register: Select the first bulleted link, I have not registered before, which will take you to a registration form. Fill out the required fields of the registration form, then click on the Accept License button.
- Download: On the page for this step click on the Download Now button corresponding to Base:vssdkinstall_launcher.exe, and the Download Now button corresponding to US English:vssdkinstall_en.exe.
Install the IBM Voice Server SDK
- The vssdkinstall_launcher.exe and vssdkinstall_en.exe files are self-extracting achives. Go to the folder in which they were downloaded and double-click on each file to extract its contents. The default extraction location for each file should default to C:\TEMP\wvsSDK311.
- Go to the C:\TEMP\wvsSDK311 directory and double-click on setup.exe.
The setup program initally runs a check to ensure that your operating system and Java Runtime Environment(JRE) meet its requirements.
- If this check indicates that you do not have a compliant Java Runtime Environment you will need to install the Java 1.3 Runtime Environment, packaged with the SDK. To do so, go to the C:\temp\wvsSDK311\install\jre131 directory and double-click on the j2re-1_3_1-win-i.exe installation file.
- It is okay if the check indicates that you do no have a compliant OS, but you are using Windows XP.
Please use the default installation directory,C:\Program Files\VoiceServerSDK, to remain consistent with the remaining install instructions.
- Now reboot your PC as requested by the setup program at the end of the installation.
- From the Window's Start menu, execute Programs->IBM WebSphere Voice Server SDK->Audio Setup - US English. This application, which is installed along with the SDK, allows you to callibrate your microphone and accomodate for background noise.
Setting up the IBM Voice Server SDK for Use with Java Applets
To run a Java Speech Applet in your browser, your Windows PATH and CLASSPATH environment variables need to be updated, and your Java Virtual machine needs to know where to find the Speech Recognition JAR file.
I have automated the process via this Windows2000/XP Professional Polly Speech installer. To dowload it, right-click on the link and select Sava Target As.... This installer basically performs the following steps, which can also be performed by hand if you prefer:
- Your Windows PATH environment variable needs to include the paths for the IBM Recognition Library, ibmreco.dll, and the Voice Recognition Engine, engine.exe. The default locations for these files are C:\Program Files\VoiceServerSDK\lib\ and C:\Program Files\VoiceServerSDK\ViaVoice\bin respectively. You can add these locations to your Windows PATH as follows:
- Right-click on the My Computer desktop icon and select Properties.
- Select the Advanced tab.
- Click on the Environment Variables button.
- Double-click on the Path System Variable.
- Add the following paths to the Path Variable Value:
- C:\Program Files\VoiceServerSDK\lib
- C:\Program Files\VoiceServerSDK\ViaVoice\bin
- Your Windows CLASSPATH environment variable needs to include the IBM JavaSpeech JAR file, ibmjs.jar. The default location for this file is C:\Program Files\VoiceServerSDK\lib You can add this location to your Windows CLASSPATH as follows:
- Right-click on the My Computer desktop icon and select Properties.
- Select the Advanced tab.
- Click on the Environment Variables button.
- Double-click on the CLASSPATH System Variable.
- Add the C:\Program Files\VoiceServerSDK\lib\ibmjs.jar to your CLASSPATH Variable Value:
- Your Java Virtual Machine also needs to locate the IBM JavaSpeech JAR file, ibmjs.jar. The default location for this file is C:\Program Files\VoiceServerSDK\ViaVoice\bin\. You can tell the virtual machin the location of JAR files by doing the following:
- Go to the Windows Start menu and select Settings->Control Panel->Java Plug-in
- Select the Advance tab
- In the Java Runtime Parameters field add -cp C:\PROGRA~1\VoiceServerSDK\lib\ibmjs.jar.
- A copy of the speech.properties file needs to be placed in your WindowsNT/2000/XP home directory.
- The IBM VoiceServer installation creates the original speech.properties file in your current Java Runtime Environment lib directory (eg. C:\j2sdk1.4.2\jre\lib\speech.properties). You may need to run a windows search to find it.
- Once found, copy the speech.properties file into your home directory, which is usually, C:\Documents and Settings\<your_windows_user_name> for Windows 2000/XP
- Grant permission to the ibmjs.jar classes and my web URL's to run the native Voice Recognition engine on your machine.
- Open the .java.policy file located in your home directory using notepad or some similar text-based editor.
- Add the following grant CodeBase entries:
grant codeBase "http://www.mrl.nyu.edu/~robbins/-" {
permission java.security.AllPermission;
};
grant codeBase "jar:file:/C:/Program Files/Java/j2re1.4.2/lib/ext/ibmjs.jar!/-" {
permission java.security.AllPermission;
};