From d7a69a6074c200c1b16bff477a4187a5ff841104 Mon Sep 17 00:00:00 2001 From: skoester <skoester@techfak.uni-bielefeld.de> Date: Thu, 23 Apr 2015 10:43:03 +0200 Subject: [PATCH] grammar for speech recognition and gpsr updated --- ps-grammar/gpsr/gpsr.jsgf | 48 +++++++++++++------ .../speechRecognition/speechRecognition.jsgf | 37 +++++++++----- 2 files changed, 59 insertions(+), 26 deletions(-) diff --git a/ps-grammar/gpsr/gpsr.jsgf b/ps-grammar/gpsr/gpsr.jsgf index 7e314bc6..deff6390 100644 --- a/ps-grammar/gpsr/gpsr.jsgf +++ b/ps-grammar/gpsr/gpsr.jsgf @@ -4,30 +4,48 @@ grammar ToBI_GPSR; public <task> = (<location_task> | <item_task> | <interact_task>); -<location_task> = (<nav_commands> [the] (<locations> | <objects>) [[(and | then)] <task>]); +<location_task> = (<nav_commands> [the] (<locations> | <furniture>) [[(and | then)] <task>]); + + +<locations> = [the] (kitchen | bathroom | corridor); +<nav_commands> = (((move | go | navigate) to) | (get into) | exit | leave); +<furniture> = (shelf | (diner table)); -<locations> = (kitchen | bathroom); -<nav_commands> = (((move | go | navigate) to) | exit | leave); -<objects> = (shelf); <item_task> = ((<interact_item> | <move_item> | <transport_item>) [[(and | then)] <task>]); -<interact_item> = (<search_commands> [the] <items> [[and] <move_item>]); -<move_item> = (<move_commands> (([the | this] <items>) | it | them )); -<transport_item> = ([and] <transport_commands> [it | them] [<item_destination>]); -<item_destination> = ([to] [the] ((<person> [(at the <locations>)])| <locations>)); -<items> = (coffee); +<interact_item> = (<search_commands> [the] <items> [[and] <move_item>]); <search_commands> = (identify | detect | find | count); + +<move_item> = (<move_commands> (([the | this] <items>) | it | them )); <move_commands> = (get | take | grasp ); -<transport_commands> = (bring | carry | retrieve); + +<transport_item> = [and] <transport_commands> [<pron>] [<items>] [<item_destination>]; +<transport_commands> = (bring | carry | retrieve) [<noname>]; +<item_destination> = ( [<person>] [at | to] [<locations>]); + + +<items> = ([the] (coffee | crackers)); + + + +<interact_task> = ((<talk_with_person> | <interact_with_person>) [[(and | then)] <task>]); + + +<talk_with_person> = <talk_commands> ((something about (<person> | <name>)) | (the day of the month)); +<talk_commands> = tell | report | answer | introduce; + +<interact_with_person> = (<memory_commands> [<pron>] [<person>] [(in front of you) | ([<noname>] [the] <locations>)]); + +<person> = [<noname> | <pron>] (yourself | person | him | her | them | he | she | (the person)); +<names> = (tobi); +<talk_commands> = (((introduce | (tell something about)) <person>) | (the day of the month)); +<memory_commands> = follow | memorize | find; -<interact_task> = ((<talk_commands> | <interact_with_person>) [[(and | then)] <task>]); -<interact_with_person> = (<memory_commands> [the | a | it] <person> [(in front of you) | to | (a question)]); -<person> = (tobi | yourself); -<talk_commands> = ((introduce | (tell something about)) <person>); -<memory_commands> = (tell | follow | memorize | find | report | answer); +<pron> = (it | them | a | this | the); +<noname> = (to | at | from | in | from); diff --git a/ps-grammar/speechRecognition/speechRecognition.jsgf b/ps-grammar/speechRecognition/speechRecognition.jsgf index 5db272c1..32ecfc63 100644 --- a/ps-grammar/speechRecognition/speechRecognition.jsgf +++ b/ps-grammar/speechRecognition/speechRecognition.jsgf @@ -1,15 +1,30 @@ #JSGF V1.0; grammar speechRecognition; -public <task> = <question1> | <question2> | <question3> | <question4> | <question5> | <question6> | <question7> | <question8> | <question9> | <question10>; +public <task> = <question1> | <question2> | <question3> | <question4> | <question5> | <question6> | <question7> | <question8> | <question9> | <question10> | <question11> | <question12> | <question13> | <question14> | <question15> | <question16> | <question17> | <question18> | <question19> | <question20> | <question21> | <question22> | <question23> | <question24> | <question25>; -<question1> = what time is it; -<question2> = what is your name; -<question3> = what is the capital of brazil; -<question4> = in which year was robo cup founded; -<question5> = how many rings has the olympic flag; -<question6> = what is the answer to the ultimate question about life the universe and everything; -<question7> = what is the worlds most popular green vegetable; -<question8> = what is the oldest drug used on earth; -<question9> = which insect has the best eyesight; -<question10> = who lives in a pineapple under the sea; +<question1> = which american state is nearest to the former soviet union; +<question2> = how many tentacles does a sqiud have; +<question3> = what is converted into alcohol druring brewing; +<question4> = which river forms the eastern section of the border between england and scotland; +<question5> = in what year was prince andrew born; +<question6> = name the two families in romeo and juliet; +<question7> = if cats are feline what are sheep; +<question8> = for which fruit is the us state of georgia famous; +<question9> = which is the financial centre and main city of switzerland; +<question10> = which tv programmes theme was called hit and miss; +<question11> = which guitarist is known as slowhand; +<question12> = what is an infant whale commonly called; +<question13> = what do the british call the vegetables that americans call zucchini; +<question14> = what is an otters home called; +<question15> = how have vedgetables been cut which are served julienne; +<question16> = in roman mythology neptune is teh equivalent to which greek god; +<question17> = which ty character said live longand prosper; +<question18> = in which state would you find the city birmingham; +<question19> = which hills divide england from scotland; +<question20> = what continent has the fewest flowering plants, +<question21> = what is canadas national animal; +<question22> = what is the alternative common name for a black leopard; +<question23> = what in cornwall is the most southerly point of mainland britain; +<question24> = what explorer introduced pigs to nord america; +<question25> = what is the world biggest island; -- GitLab