|
|
|
|
|
|
|
Total page views :
117397
|
|
Total downloads :
5988
|
|
|
|
|
Download
Files:
|
|
|
|
|
|
|
|
|
|
|
|
|
Similar ArticlesMost ReadTop RatedLatest
|
|
|
|
|
|
|
|
|
|
Description
This article provides some elementary information about how to implement Speech Recognition capabilities in to your applications. The tools we would use to speech enable would be the speech SDK 5.1. Speech SDK 5.1 is the latest release in the speech product line from Microsoft. Speech SDK 5.1 can be used in various programming languages.
Introduction
Speech is one of the most natural way to interact. When it comes to computers it is no different. If an application can be controlled solely by way of voice commands then the opportunity that lies is unlimited. Even though the idea of using speech as an input mechanism for an application is not new there are not a lot of applications that use speech as in input. In other words speech is still an big opportunity that is yet to be explored.
Microsoft speech SDK is one of the many tools that enable a developer to add speech capability in to a applications. Speech SDK can be used in either C#, C++, VB or any COM compliant language.
Broadly, speech can be divided in to two paradigms. Text to speech conversion and speech recognition. In this article I shall be focusing on the speech recognition conversion.
Command & Control Vs. Dictation
Speech recognition can be of two types based on the grammar that the recognition is based on. (Grammar is in other words the list of possible recognition outputs that can be generated.) An application can limit the possible combination of the words spoken by choosing proper grammar.
In a command and control scenario a developer provides a limited set of possible word combinations, and the speech recognition engine matches the words spoken by the user to the limited list. In command and control the accuracy of recognition is very high. It is always better for applications to implement command and control as the higher accuracy of recognition makes the application respond better.
In Dictation mode the recognition engine compares the input speech to the whole list of the dictionary words. For the dictation mode to have a high accuracy of recognition is it important that the user has prior trained the recognition engine by speaking in to it. The training or creating of a profile can be done by using the speech properties in the control panel.
Speech Recognition Engines
There are two different speech recognition engines, namely a Shared Recognition engine and an InProc recognition engine. A shared recognition engine can be shared across applications. This is the engine one would use when there could be multiple applications looking for speech input. A shared recognition context is the recommended for most speech applications. On large speech applications that run on server alone an InProc speech recognition context is better suited.
The speech recognition engine interacts with applications using events that could be subscribed to by the application. A couple of the most important events are the recognition event and the hypothesis event. these event are raised when the engine make a good recognition or an hypothesis respectively. The code along with this article will show how to subscribe to these events.
Sample Application
The sample application with this article gives a idea to a developer on the steps one need to take in order to speech enable the menus in an application. The listing below shows a few of the important steps.
// Get an insance of RecoContext. I am using the shared RecoContext. objRecoContext = new SpeechLib.SpSharedRecoContext(); // Assign a eventhandler for the Hypothesis Event. objRecoContext.Hypothesis += new _ISpeechRecoContextEvents_HypothesisEventHandler(Hypo_Event); // Assign a eventhandler for the Recognition Event. objRecoContext.Recognition += new _ISpeechRecoContextEvents_RecognitionEventHandler(Reco_Event); //Creating an instance of the grammer object. grammar = objRecoContext.CreateGrammar(0); //Activate the Menu Commands. menuRule = grammar.Rules.Add"MenuCommands",SpeechRuleAttributes.SRATopLevel| SpeechRuleAttributes.SRADynamic,1); object PropValue = ""; menuRule.InitialState.AddWordTransition(null,"New"," ,SpeechGrammarWordType.SGLexical,"New", 1, ref PropValue, 1.0F ); menuRule.InitialState.AddWordTransition(null,"Open"," ",SpeechGrammarWordType.SGLexical,"Open", 2, ref PropValue, 1.0F ); //Commit the grammar rules for reco. grammar.Rules.Commit(); grammar.CmdSetRuleState("MenuCommands", SpeechRuleState.SGDSActive);
The screen shot below shows the main form of the sample application.

Summary
This article gives an introduction to speech recognition using the Speech SDK 5.1.
|
|
|
Login
to add your contents and source code to this article
|
|
|
|
|
|
|
|
|
|
Suhil Srinivas
Suhil Srinivas is a seasoned developer, developing applications using various microsoft technologies. Suhil is a MCP and has been actively involved in mentoring and helping new-comers. He has a rich experience of building web, wireless and backend systems and has been doing consulting for various enterprises. Suhil in particular has been working a lot with the credit card and payment processing industry. EKS as a company has several products for the Educational institutes of any size. One of the chief products is the School-ERP system, which completely revolutionizes the day-to-day operation of an educational institute. Among other products EKS also has products for the small and medium healthcare providers. EKS is in to consulting and does offshore development for its customers from its office at Bangalore, India.
|
|
|
|
|
|
|
|
|
C# Consulting is founded in 2002 by the founders of C# Corner. Unlike a traditional
consulting company, our consultants are well-known experts in .NET and many of them
are MVPs, authors, and trainers. We specialize in Microsoft .NET development and
utilize Agile Development and Extreme Programming practices to provide fast pace
quick turnaround results. Our software development model is a mix of Agile Development,
traditional SDLC, and Waterfall models.
|
|
Click here to learn more about C# Consulting. |
|
|
|
|
|
|
|
Introducing MaxV - one click. infinite control. Hyper-V Hosting from MaximumASP.
Finally – a virtual platform that delivers next-generation Windows Server 2008 Hyper-V virtualization technology from a managed hosting partner you can truly depend on. Visit www.maximumasp.com/max for a FREE 30 day trial. Hurry offer ends soon.
Climb aboard the MaxV platform and take advantage of High Availability, Intelligent Monitoring, Recurrent Backups, and Scalability – with no hassle or hidden fees.
As a managed hosting partner focused solely on Microsoft technologies since 2000, MaximumASP is uniquely qualified to provide the superior support that our business is built on. Unparalleled expertise with Microsoft technologies lead to working directly with Microsoft as first to offer IIS 7 and SQL 2008 betas in a hosted environment; partnering in the Go Live Program for Hyper-V; and product co-launches built on WS 2008 with Hyper-V technology.
|
Dynamic PDF
ceTE software specializes in components for dynamic PDF generation and manipulation. The DynamicPDF™ product line allows you to dynamically generate PDF documents, merge PDF documents and new content to existing PDF documents from within your applications.
|
Go.NET
Build custom interactive diagrams, network, workflow editors, flowcharts, or software design tools. Includes many predefined kinds of nodes, links, and basic shapes. Supports layers, scrolling, zooming, selection, drag-and-drop, clipboard, in-place editing, tooltips, grids, printing, overview window, palette. 100% implemented in C# as a managed .NET Control. Document/View/Tool architecture with many properties&events. Optional automatic layout.
|
Dundas Software
Dundas Chart for .NET is the most advanced .NET charting package available today. With an extremely complete feature set, elegant architecture and easy implementation, Dundas Chart can quickly add advanced Charting functionality to enhance and transform ASP.NET and Windows Forms applications. Whether you are implementing charting into internal projects, or building applications for clients, Dundas Chart offers advanced technology and advanced results to get the most out of data.
|
Clickatell's SMS Gateway
Clickatell's Developer Solutions allow you to SMS enable any website or
application via a range of API's. Learn More about our API connections.
|
Microsoft Visual Studio 2010 Professional
Microsoft Visual Studio 2010 Professional will launch on April 12, but you can beat the rush and secure your copy today by pre-ordering at the affordable estimated retail price of $549 (US). Pre-order now.
|
Nevron Chart for .NET 2010.1 Now Available
The leading .NET charting control now features PDF, Flash and Silverlight export, visualization of large datasets and more. Deliver true charting functionality to your BI, Scorecard, Presentation or Scientific apps. Download evaluation now.
|
Developer-Ready ASP.NET 2.0 Web Hosting with 3 MONTHS FREE
Now supporting .NET 3.0 Framework with Windows Workflow Foundation, Windows Communication Foundation (WCF), Windows Presentation Foundation (WPF), windows CardSpace (WCS)! Providing more flexibility for Developers with Web Services Support and a User/Permission Manger. Also supporting MS SQL 2005/2000 with Real-Time Backups, FREE Automated Attach .MDF Tool, FREE SQL Restore and Shrink SQL DB Tools, and SQL
|
|
|
|
|
|
|
|
|
Download
Files:
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|