Context-free Grammars for Natural Languages

Noam Chomsky, in 1957, used the following notation called productions, to define the syntax of English. The terms used here, sentence, noun phrase,etc. plus the following rules describe a very small subset of English sentences. The articles a, and thehave been categorized as adjectives for simplicity.

        <sentence>      -->   <noun phrase> <verb phrase>
        <noun phrase>   -->   <adjective> <noun phrase> 
                            | <adjective> <singular noun>
        <verb phrase>   -->   <singular verb> <adverb>
        <adjective>     -->   a | the |little
        <singular noun> -->   boy
        <singular verb> -->   ran
        <adverb>        -->   quickly
Here, the arrow, -->, might be read as "is defined as" and the vertical bar, "|", as "or". Thus, a noun phrase is defined as an adjective followed by another noun phrase or as an adjective followed by a singular noun. This definition of noun phrase is recursive because noun phrase occurs on both sides of the production. Grammars are recursive to allow for infinite length strings.

This grammar is said to be context-free because only one syntactic category, e.g., , occurs on the left of the arrow. If there were more than one syntactic category, this would describe a context and be called context-sensitive.

A grammar is an example of a metalanguage- a language used to describe another language. Here, the metalanguage is the context-free grammar used to describe a part of the English language.

Example 2 shows a diagram called a parse tree or structure tree for the sentence the little boy ran quickly.

The sentence: "quickly, the little boy ran" is also a syntactically correct sentence, but it cannot be derived from the above grammar. In fact, it is impossible to describe all the correct English sentences using a context-free grammar.

On the other hand, it is possible, using the grammar above, to derive the syntactically correct, but semantically incorrect string, "little the boy ran quickly." Context-free grammars cannot describe semantics.

Send questions and comments to: Karen Lemone