'Titles' Tutorial: Step 1 2 3 4 5 6 7 8


Fixing the problem: why have we generated two possible strings?

 

When we generated in the previous step we saw that the grammar causestwo ‘sentences’ to be produced, one with the title before the name and one with the title after the name. Since the title after the name variant is not possible in English (in contrast to, for example, Japanese), we know that our grammar is not yet sufficient. It is not yet an accurate description of the possibilities offered by the English language and so it needs to be changed. The question is then: how do we do this?

Checking the grammatical structure

Firstly, we can look at the grammatical structure lying behind these results. This structure is the structure that the grammar produced because of the path that we told it to follow. Clicking on ‘Graph Structure’ (8 in the development window shown in the previous step) causes the grammatical structure to be shown in another window. This looks as follows.

So we have a single grammatical unit called, not too accurately, ‘Sentence’, and this has two subconstituents, one called ‘Name’ and the other called ‘Title’. The first of these, ‘Name’, is expressed by "Smith", the second of these, ‘Title’, is expressed as "Mr.". The graph only shows the structure, without all of the differing orderings that might have been possible. Here we see the last order generated, the one that would be good for Japanese but not so good for English.

The structure itself is not too bad, it is just that there are too many orders. We can then ask the structure questions about itself: asking why certain orders are allowed when they should not be...

Why are grammatical elements inserted into the structure?

For example, we can ask why there is a Title constituent at all by RIGHT CLICKING on it and selecting ‘Insertions’ from the menu that appears (second from the top).

This gives, again in the development window, information about the place in the grammar that caused the selected constituent to be inserted into structure.

This means that if we look back at the network of the grammar and find the system, or choice point, call TITLED, then this has a realization statement that is responsible for inserting the grammatical element Title.

Why is a certain order selected rather than another?

We can also ask about the ordering of the grammatical units by selecting ‘Orderings’ from around the middle of the menu above. When we do this, however, it tells us that it knows of no constraints that were applicable

This suggests that the grammar perhaps was not explicit enough about ordering its constituents anyway. No explicit instructions were given about ordering and perhaps this is the problem.

Important is to realize that the grammar only knows what we tell it: it cannot assume that certain constituents come in a particular order. It is the job of the grammar (and so, ultimately, the job of the grammar writer) to make the grammar so explicit that all the necessary information to describe the grammatical constructions that the grammar is to cover is directly present in the grammar, either in terms of the choice points that are available or by writing the appropriate realization statements in.

We can also go back to our overview of the grammar directly to remind ourselves of the path that we took through the network when generating. To do this, we first have to leave the Structure Graph by selecting the ‘Quit Structure Graph’ option in the grey menu bar at the top.

Next step Looking at the path we took through the network...