|
Building Intelligent .NET Applications(c) Agents, Data Mining, Rule-Based Systems, and Speech Processing Authors: Rea S.M. Published year: 2005 Pages: 43-45/123 |
| < Day Day Up > |
The Manifest FileThe Manifest.xml file contains a reference to the start page used for the application along with a listing of resources that can be preloaded by Speech Engine Services (SES). When you create a new speech project, it automatically includes entries for the default project grammars. If new grammars are added, make sure a reference to them is added to this file in order to take advantage of the preloading ability. The manifest for this chapter is seen as follows :
<manifest>
<application frontpage="Default.aspx">
<resourceset type="MultimodalRecognizer">
<resource src="Grammars/Library.grxml"/>
<resource src="Grammars/Days.grxml"/>
<resource src="Grammars/Departments.grxml"/>
<resource src="Grammars/Instructors.grxml"/>
<resource src="Grammars/QueryPostamble.grxml"/>
<resource src="Grammars/QueryPreamble.grxml"/>
<resource src="Grammars/SpeakQuery.grxml"/>
<resource src="Grammars/StartTimes.grxml"/>
<resource src="Grammars/Title.grxml"/>
</resourceset>
</application>
</manifest>
The manifest file contains a resourceset node with a type attribute. This value specifies the type of engine to use when loading a resource. For voice-only applications it should be valued as "TelephonyRecognizer." For the multimodal application in this chapter, it is valued as "Multimodalrecognizer." |
| < Day Day Up > |
| < Day Day Up > |
Running the Application on PocketPCIn order to access the sample application from a PocketPC device, you must first install the speech add-in for Internet Explorer on the device. The files for this install are found on the installation CD for Microsoft Speech Server. They can be found in the Redistributable Installers\Speech Add-in for Pocket Internet Explorer directory. To install the files, ensure that the PocketPC device is connected to your PC using ActiveSync. You will then browse to the setup directory on your PC and execute setup.exe. The setup will install the necessary files and notify you if any additional steps are necessary. To allow PocketPC devices to access the application, you must set the MIME type for all .aspx pages. This ensures that the Speech Add-in is able to instantiate SALT objects. To set the MIME type, add the following to the Page_load routine for all pages: Response.ContentType = "text/salt+html"
Tip The application can include code that checks the HTTP header for the correct value. If it is not set correctly, the user should be notified. |
| < Day Day Up > |
| < Day Day Up > |
Application TuningThe SASDK offers several options for debugging and tuning your speech application. When testing and deploying an application used by the general public, it is vital to maintain a log of all recognitions. These log files can be used to later identify problems with the grammar files. Speech Debugging Console LoggingSpeech Debugging Console allows you to enable logging which is helpful during the development and debugging process. To enable logging, execute the following steps:
Refer to Figure 4.7 to see what a log file resulting in a non-recognition exception looks like. In this case, the user entered the phrase "list all financial accounting 1" and would have received an error stating that the phrase was not recognized. Non-recognition exceptions are those resulting in a Type value of "NoReco." Figure 4.7. Portion of an application log file in which the recognition was unsuccessful . In this case the user entered the phrase "list all financial accounting 1." This phrase was not recognized prior to a change in the grammar and would have resulted in an error. The non-recognition exception is indicated with a Type value of "NoReco."
Tip You do not want to leave logging enabled indefinitely because it adds overhead to the speech process. However, the log files can be invaluable during a period in which you are identifying application grammar errors. Examining Log Files from MSSTrace log files, produced on the Speech Server, can also be used to debug a speech application. The SASDK provides three methods for extracting data from trace log files. In order to retrieve this data you must first enable trace logging on the Microsoft Speech Server by creating a log trace session. This is typically done by an Administrator using the logman utility provided with Windows XP. The session is defined from a command prompt and an output path is specified. Starting a trace session results in the creation of a file with an .etl extension It is not necessary for developers to install MSS in order to access logging functionality. Instead, developers can ask the Administrator of the Microsoft Speech Server to send them the resulting .etl file. This text-based file can then be analyzed using any of three tools available with the SASDK installation:
The three logging tools available with the SDSDK can be accessed by browsing to Microsoft Speech Application SDK 1.0 , Debugging Tools , and Microsoft Speech Application SDK Command Prompt . This will open a command-prompt window that points to the location of the logging tools. Instructions on which command parameters to use can be accessed by typing the tool name followed by "/?". Call ViewerChapter 2 introduced the Call Viewer Utility as a method for analyzing MSS .etl files. This is a great visual tool for developers to use while debugging an application. The utility is not installed by default, but is available with the SASDK. To install the tools, execute the following steps:
Once Call Viewer is installed, you will need to import the log data to a Microsoft SQL Server Database. The import can be done with a DTS (Data Transformation Services) package or with the MSSLogToDatabase command line tool. To import the log files with a DTS package, refer to the help file for the Log Analysis Tools. The help file, named LogAnalysis.chm is available in the ..\Redistributable Installers\Microsoft Speech Application Log Analysis Tools\Program Files\Microsoft Speech Application SDK 1.0\SDKTools\LogAnalysis\directory. |
| < Day Day Up > |
|
Building Intelligent .NET Applications(c) Agents, Data Mining, Rule-Based Systems, and Speech Processing Authors: Rea S.M. Published year: 2005 Pages: 43-45/123 |