5 Designing Apps with Speech
5.1 Speech Design Considerations
What can I say? show commands
Make it fun. Add humor.
Keep grammar small. Allow variations of words.
Can lauch app using Cortana.
5.2 Interpreting User Intent
Natural Language Understanding
private void HandleNlpCommand(string recoText, bool actSilently)
{
string action=null;
string navigation=null;
string searchFor=null;
recoText =recoText.ToLower();
if(recoText.Contains("go to")|| recoText.Contains("goto")||recoText.Contains("find")|| recoText.Contains("search")|| recoText.Contains("show me"))
{
action="navigate";
if(recoText.Contains( "Windows phone dev center"))
{
navigateTo="http://dev.windowsphone.com";
}
}
else if (recoText.Contains ("learn how to")
{
action="find";
searchFor =recoText.Substring (recoText.IndexOf ("learn how to")+13);
}
else
{
action="find";
searchFor=recoText;
}
switch(action)
{
case "find" :
}
}