# PSG1.txt # very small grammar for English # (C) 2003-2008 by Damir Cavar # # This code is written and distributed under the # Lesser GNU General Public License version 3 or newer. # # See http://www.gnu.org/copyleft/lgpl.html for details # on the license or the the file gpl.txt that should always be # distributed with this code. # Grammar: S -> NP VP # simple sentence rule NP -> N NP -> Art N NP -> Art Adj N NP -> Adj N NP -> Art N PP NP -> Art Adj N PP NP -> Art N NP NP -> NP N NP -> Adj NP N VP -> V NP VP -> V VP -> V PP VP -> V NP PP VP -> Adv V NP PP -> P NP # Lexicon: N -> I N -> we N -> John N -> Mary N -> woman N -> man N -> dog N -> cat N -> mouse N -> car N -> ball N -> bench N -> tie N -> she N -> missile N -> missiles Art -> the Art -> a Adj -> green Adj -> yellow Adj -> red Adj -> blue Adj -> big Adj -> small Adj -> anti Adv -> often Adv -> yesterday V -> kissed V -> killed V -> loves V -> sees V -> meets V -> chases V -> sat P -> on P -> in P -> beside P -> under P -> with