Skip to main content

If you don't have an IBM ID and password, register here.

By clicking Submit, you agree to the developerWorks terms of use.

The first time you sign into developerWorks, a profile is created for you. This profile includes the first name, last name, and display name you identified when you registered with developerWorks. Select information in your developerWorks profile is displayed to the public, but you may edit the information at any time. Your first name, last name (unless you choose to hide them), and display name will accompany the content that you post.

All information submitted is secure.

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerworks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

By clicking Submit, you agree to the developerWorks terms of use.

All information submitted is secure.

The Eclipse Voice Tools Project

A step-by-step introduction to obtaining and extending voice-development tools

Brent Metz (bdmetz@us.ibm.com), Staff Software Engineer, IBM
Author1 photo
Brent D. Metz is an engineer at IBM in Boca Raton, Florida working on enterprise voice tooling. He is a domain expert in Natural Language Understanding (NLU) technologies, speech user-interface design, and speech-tooling design. He represents IBM on the VoiceXML Forum's Tools Subcommittee and is the project lead for the open source Eclipse Voice Tools Project. Brent received a Bachelor's degree in computer science from Virginia Tech. Prior to joining IBM, Brent was the grand prize winner of the Cool Blue VoiceXML Challenge, an international VoiceXML application design competition.

Summary:  The Eclipse Voice Tools Project is a new effort that brings together companies and individuals from the voice industry to create a common set of standards-based, open source, voice-development tools. But how do you go about extending or contributing to the project's tools? This article explains how to set up and customize the Voice Tools Project environment. It also shows you the process involved in adding new functions.

Date:  23 Aug 2005
Level:  Introductory

Comments:  

Eclipse is an incredibly versatile development platform that has been widely adopted across the computer industry. Beyond its world-class Java™ development environment, the Eclipse Foundation hosts a number of projects designed to create a diverse set of tools -- from C to COBOL to BPEL. One of its latest efforts, the Eclipse Web Tools Project, creates a set of open source Web-development tools. Providing mature XML, SQL, and Java 2 Platform, Enterprise Edition (J2EE) tools, the Web Tools Project is poised to become the de facto open Web-development environment.

The Voice Tools Project (VTP) was formed to take advantage of the Web Tools Project by extending its base of Web-development tools into the voice-recognition world. This allows the Voice Tools Project to provide a great Web-development experience for voice applications out of the box and allows users to development their voice applications using the same tools they would use to develop their visual applications. For companies that use the Voice Tools Project as a base for their own tools, it means that all the tasks users come to expect from a modern Web-oriented Integrated Development Environment (IDE) are provided without any additional effort.

But how can the Voice Tools Project be put to work for your particular needs? I'll explain the process of getting the Voice Tools Project source and how to add your own "voice" to it -- whether the changes are for a commercial product or contributed back to the open source world, the basic concepts remain the same.

The setup

To set up the best development environment for your needs, it's important to understand what the prerequisites are. Because the Voice Tools Project depends on the Web Tools Project (which depends on the Eclipse SDK), several packages at the right version levels must be installed.

  1. Start by going to the Voice Tools Project home page to find out what the latest compatible version of the Web Tools Project is. At the time of this writing, the latest compatible version is 0.7.
  2. Visit the Web Tools Project download page to obtain the correct version of the Web Tools Project. You will need to obtain the SDK ZIP file version as well as any prerequisites listed under the Requirements section. When I wrote this, the requirements for the Web Tools Project were Eclipse 3.1, EMF 2.1, GEF 3.1, and Java EMF Model Runtime 1.1.
  3. Finally, if you don't have one installed already, you will need to install a version of the Java Runtime Environment (JRE).
  4. Unzip Eclipse to a base directory such as c:\eclipse. Each of the other required technologies will need to be unzipped to this same path so that the files are in their proper locations under the plugins\ and features\ subdirectories.
  5. To test your configuration, start Eclipse and try to create a new Web project by selecting File > New > Other... > Web > Dynamic Web Project. If this wizard is available and executes correctly, your installation is correct.

Figure 1. Starting the wizard is a simple test to check installation
Starting the wizard is a simple test to check installation

Now that you're up and running, let's do something with it.


Taking the source code for a drive

Because Eclipse has an integrated CVS client, it's simple to obtain and start working with the Eclipse Voice Tools Project's source code. In Eclipse, select Window > Open Perspective > Other... > CVS Repository Exploring to open the CVS Repository Exploring perspective. This perspective in Eclipse is used to browse remote CVS repositories, such as where the VTP source code is stored.

To download the VTP source code, first create an anonymous connection to the Eclipse CVS repository. In the CVS Repositories view, right-click and select New > Repository location... to open the Add CVS Repository window. In the Host: field, enter dev.eclipse.org. For the Repository path: field, enter /home/technology. In the User: field, enter anonymous. Go ahead and check Save Password and press Finish. A connection will be created in the CVS Repositories view that can be used to explore the entire CVS tree that the VTP is a part of.

Next, you'll need to figure out what your organization has that you want to route callers directly to when they call. Make a listing of all of the places in your organization where a call can be routed. These are your routing destinations. Use this list to construct a data-collection questionnaire that you can give to internal users (or preferably real customers). For every destination you identified, ask your audience to think of a few things they would say to get there. Listing 1 is an example of what a questionnaire for a car company might look like.


Figure 2. The Add CVS Repository window with settings for exploring the Eclipse CVS server
The Add CVS Repository window with settings for exploring the Eclipse CVS server

The next step is to select the VTP components and extract them into projects in the local environment. Expand the tree that is created to HEAD > org.eclipse.vtp > editors > plugins. The list of tree items starting with org.eclipse.vtp are the editor plug-ins provided as part of the Voice Tools Project.

Select the entire set of plug-ins and right-click. Choose the menu item Check Out As... to open the CVS Checkout window. Select Check out into the workspace as projects and press Finish. You should now have a number of plug-in projects in your Eclipse workspace.

Switch over to the Plug-in Development perspective by selecting Window > Open Perspective > Other... > Plug-in Development. You should see all of the plug-ins you selected in the Package Explorer view.


Figure 3. The CVS Repositories view with VTP plug-ins selected for checkout
The CVS Repositories view with VTP plug-ins selected for checkout

It's a good idea to make a final check to see that everything is working with the downloaded code before you make changes. Select any of the plug-in projects in the Package Explorer view, right-click, then select Run As > Eclipse Application. This will start a second copy of Eclipse that incorporates the downloaded plug-in code in the workspace. After the second copy of Eclipse starts, try running the new VoiceXML wizard by selecting File > New > Other... > Voice > VoiceXML File. If the wizard starts up successfully, it is a good sign that the VTP source code was downloaded successfully. You're now ready to begin making changes!


Creating a custom action

In VoiceXML documents, a developer frequently refers to external resources like audio files or other VoiceXML documents while editing markup. A handy feature to add to the editor might be a way to quickly verify that a link is valid. To do this a new editor action has to be created and an extension point registered in the org.eclipse.vtp.editor.vxml plug-in's plugin.xml:


Listing 1. A new plug-in extension point to add a new action to the VoiceXML editor
   <extension
         point="org.eclipse.wst.sse.ui.extendedEditorActions">     
      <editorContribution
            targetID="org.eclipse.vtp.editor.vxml.StructuredTextEditorVXML"
            id="org.eclipse.vtp.editor.vxml.extendedActions">
         <action
         	   label="Validate linked item exists"
         	   tooltip="Checks to make sure that the item referenced exists"
               popupmenuPath="VOICETOOLS_GROUP_EDIT"
               class="org.eclipse.vtp.editor.vxml.CheckReferencedURLAction"
               id="org.eclipse.vtp.editor.vxml.actions.CheckReferencedURLAction">
         </action>      
      </editorContribution>     
   </extension> 

Now you need to create the class CheckReferencedURLAction to perform the work. Luckily, the source code to an existing editor action (EditReferencedFileAction) is available in the org.eclipse.vtp.editor plug-in, so you have a base to start from.

If you copy over EditReferencedFileAction.java and take a look, you can start to see how putting together an editor action works. It's simply a matter of making sure you show the action in the context menu correctly using the isVisible() method and perform the appropriate action in the run() method. Because you'll be checking for both local file existence and URL existence, you must take the XML attribute currently selected and determine what to do with it:


Listing 2. New action code to check reference item's existence
attrValueLoaded = ActionSupport.currentPosGetAttributeValue(textEditor, attrs[i]);
if (attrValueLoaded.toLowerCase().startsWith("file:") 
    || attrValueLoaded.toLowerCase().startsWith("http:") 
    || attrValueLoaded.toLowerCase().startsWith("https:") 
    || attrValueLoaded.toLowerCase().startsWith("ftp:")) { 
  // Check URL
  ..
} else {
  // Check local file
  ..
}

The link at the end of the article will connect you to the full implementation. Now we can start the editor on a file and see the results:


Figure 4. Editor window with the new customized action
XML error: The image is not displayed because the width is greater than the maximum of 580 pixels. Please decrease the image width.


Packaging the changes

Exporting the Voice Tools Project with the changes you've made is a simple process. Simply select all of the plug-ins in the Package Explorer view, right-click, and select Export... > Deployable plugins and fragments. Specify an output folder and press Finish to export the plug-ins in a deployable form.


Figure 5. The export deployable plug-ins and fragments dialog
The export deployable plug-ins and fragments dialog

Alternatively, you can take advantage of the open source development model the Voice Tools Project provides by providing a patch back to the project. Submitting your changes back to the project allows them to be improved, tested, and even maintained by a community of like-minded developers.

The first step is to create the patch. To do this, select the project you changed, org.eclipse.vtp.editor.vxml, right-click, and select Team > Create Patch... to open the Create Patch window. Select Save in file system and choose a temporary location to place the patch. Press Finish to create the file.

After the patch is created, it should be posted to the Eclipse bug-tracking site as a feature request for consideration. Go to http://bugs.eclipse.org/ and create a Bugzilla account. After you have an account, go to Enter a new enhancement/feature request and select VTP. Select the editors component and include a summary of your enhancement in the Description field.

After the feature request has been created, you must attach your patch to it. To do this, view the feature request and select Create a New Attachment. Select your patch from the filesystem, include a brief description, and check the patch checkbox. Press Submit to attach the patch to the feature request.


Figure 6. The attachment-upload Web page
XML error: The image is not displayed because the width is greater than the maximum of 580 pixels. Please decrease the image width.


In conclusion

Customizing the Eclipse Voice Tools Project is a simple process that allows a user or company to take advantage of a great set of voice-development code. While the open source model encourages contributions, there is often a need for customization and the easy availability of source code to allow developers to rapidly build a product to suit their needs.

This article has gotten you started with the Eclipse Voice Tools Project by taking you step by step through setting up and testing your environment, enabling the Project source code, building your own customized action, incorporating the change, and submitting it back to the Project.



Download

DescriptionNameSizeDownload method
Sample codewi-eclipsesource.zip3 KBHTTP

Information about download methods


Resources

Learn

Get products and technologies

  • Multimodal Tools Plus (alphaWorks, March 2005) is a package including voice-enabled Multimodal Browsers and the Multimodal Toolkit, an Eclipse-based tool designed to speed development of browser-based applications on embedded devices that require both visual and voice interaction.

  • Embedded Voice Toolkit Preview (alphaWorks, July 2004), an Eclipse-based tool designed to speed development of speech applications on embedded devices.

  • Visit the Eclipse Voice Tools Project home page to get started.

Discuss

About the author

Author1 photo

Brent D. Metz is an engineer at IBM in Boca Raton, Florida working on enterprise voice tooling. He is a domain expert in Natural Language Understanding (NLU) technologies, speech user-interface design, and speech-tooling design. He represents IBM on the VoiceXML Forum's Tools Subcommittee and is the project lead for the open source Eclipse Voice Tools Project. Brent received a Bachelor's degree in computer science from Virginia Tech. Prior to joining IBM, Brent was the grand prize winner of the Cool Blue VoiceXML Challenge, an international VoiceXML application design competition.

Report abuse help

Report abuse

Thank you. This entry has been flagged for moderator attention.


Report abuse help

Report abuse

Report abuse submission failed. Please try again later.


developerWorks: Sign in

If you don't have an IBM ID and password, register here.


Forgot your IBM ID?


Forgot your password?
Change your password


By clicking Submit, you agree to the developerWorks terms of use.

 


The first time you sign into developerWorks, a profile is created for you. This profile includes the first name, last name, and display name you identified when you registered with developerWorks. Select information in your developerWorks profile is displayed to the public, but you may edit the information at any time. Your first name, last name (unless you choose to hide them), and display name will accompany the content that you post.

Choose your display name

The first time you sign in to developerWorks, a profile is created for you, so you need to choose a display name. Your display name accompanies the content you post on developerWorks.

Please choose a display name between 3-31 characters. Your display name must be unique in the developerWorks community and should not be your email address for privacy reasons.

(Must be between 3 – 31 characters.)


By clicking Submit, you agree to the developerWorks terms of use.

 


Rate this article

Comments

Help: Update or add to My dW interests

What's this?

This little timesaver lets you update your My developerWorks profile with just one click! The general subject of this content (AIX and UNIX, Information Management, Lotus, Rational, Tivoli, WebSphere, Java, Linux, Open source, SOA and Web services, Web development, or XML) will be added to the interests section of your profile, if it's not there already. You only need to be logged in to My developerWorks.

And what's the point of adding your interests to your profile? That's how you find other users with the same interests as yours, and see what they're reading and contributing to the community. Your interests also help us recommend relevant developerWorks content to you.

View your My developerWorks profile

Return from help

Help: Remove from My dW interests

What's this?

Removing this interest does not alter your profile, but rather removes this piece of content from a list of all content for which you've indicated interest. In a future enhancement to My developerWorks, you'll be able to see a record of that content.

View your My developerWorks profile

Return from help

static.content.url=http://www.ibm.com/developerworks/js/artrating/
SITE_ID=1
Zone=Open source, XML, Java technology
ArticleID=92449
ArticleTitle=The Eclipse Voice Tools Project
publish-date=08232005
author1-email=bdmetz@us.ibm.com
author1-email-cc=htc@us.ibm.com

Tags

Help
Use the search field to find all types of content in My developerWorks with that tag.

Use the slider bar to see more or fewer tags.

For articles in technology zones (such as Java technology, Linux, Open source, XML), Popular tags shows the top tags for all technology zones. For articles in product zones (such as Info Mgmt, Rational, WebSphere), Popular tags shows the top tags for just that product zone.

For articles in technology zones (such as Java technology, Linux, Open source, XML), My tags shows your tags for all technology zones. For articles in product zones (such as Info Mgmt, Rational, WebSphere), My tags shows your tags for just that product zone.

Use the search field to find all types of content in My developerWorks with that tag. Popular tags shows the top tags for this particular content zone (for example, Java technology, Linux, WebSphere). My tags shows your tags for this particular content zone (for example, Java technology, Linux, WebSphere).