Checking Trees

If phrase structure rules have been added to a project, then the user can run a process to check a tree against the grammar. The Check Tree process will highlight any of the following transgressions:


Checking a tree against the grammar

The current tree is checked against the grammar by choosing Tools|Check Tree or the   Check Tree button on the toolbar. This process will highlight any transgressions on the tree and provide a tool tip when you mouse over a highlighted node explaining the nature of the transgression.

Check Tree Draw

This process will also open a Check Tree dialog, which the user can use to run through the transgressions and correct them. As the user moves through each transgression within the dialog, the corresponding node on the tree will be selected.

Common actions available for all transgressions include ignoring the transgression and moving to the next one (Ignore), closing the dialog (Close), undoing the last change made from within the dialog (Undo) and opening the check tree option dialog to set preferences on how the check tree process is run (Options). The other actions available in the dialog will vary depending on the nature of the current transgression.

Invalid derivation

Check Tree

An invalid derivation transgression occurs when the daughters can not be derived from the rules. For this transgression the program does not provide the user with any suggestions. The user can change the daughters by entering new daughters and pressing Change. The sub-trees of any existing daughters that are kept will be retained. The user can also change the daughter nodes into a phrase by pressing To Phrase. If the dominating node is a lexical category, then an option to change the daughter(s) to a word will also be available. Finally, if the node with the transgression is not the root node, the user can press Delete to remove it.

Invalid word

Check Tree

An invalid word transgression occurs when the word does not exist in the lexicon. For this transgression the program provides the user with suggestions for replacement consisting of lexicon entries with the dominating node as category. The user can change the word by selecting an entry from the list or entering a new word and pressing Change. The user can also add the word to the lexicon by pressing Add. Finally, the user can press Delete to remove the word.

Invalid category termination

Check Tree

An invalid category termination transgression occurs when a category that is not the head of a rule has a category as a daughter. For this transgression the program provides the user with suggestions for replacement consisting of lexicon entries with the dominating node as category. The user can change the daughter to a terminating word by selecting an entry from the list or entering a new word and pressing Change. The user can also change the category to a word by pressing To Word. Finally, the user can press Delete to remove the category.

Invalid node

Check Tree

An invalid node transgression occurs when a category does not exist in the rules. For this transgression the program provides the user with suggestions for replacement consisting of categories which are possible daughters of the dominating node. In situations where a possible daughter differs from the invalid node only in terms of capitalization, that daughter will be the only suggestion listed and the text will indicate that it is an issue with capitalization. The user can change the daughter to a valid category by selecting an entry from the list or entering a new category and pressing Change. The user can also press Delete to remove the category.

Invalid word termination

Check Tree

An invalid word termination transgression occurs when a category that is not a lexical category (i.e. is the head of a rule and has not been specified as a lexical category in the grammar) is terminated with a word. For this transgression the program provides the user with suggestions for replacement consisting of categories which are possible daughters of the dominating node. The user can change the word to a valid category by selecting an entry from the list or entering a new category and pressing Change. The user can also change the word to a phrase by pressing To Phrase. The user can also press Delete to remove the word.

Invalid phrase termination

Check Tree

An invalid phrase termination transgression occurs when a category that is not the head of a rule is terminated with a phrase. For this transgression the program provides the user with suggestions for replacement consisting of lexicon entries with the dominating node as category. The user can change the phrase to a terminating word by selecting an entry from the list or entering a new word and pressing Change. The user can also change the phrase to a word by pressing To Word. Finally, the user can press Delete to remove the phrase.


Clearing transgressions

The current tree can be cleared of any transgressions highlights by choosing Tools|Clear Transgressions.

Check Tree options

Preferences on how the check tree process is run can be set by choosing Tools|Options which will open the options dialog. On the check tree tab, the user can set whether the check tree process will be case insensitive in regards to categories, whether it will ignore all terminating words and whether it will ignore all terminating words not in the lexicon (but create transgressions for words with invalid categories).

Check Tree options

These options can also be changed during the check tree process by clicking on the options button on the Check Tree dialog to display the check tree options tab. The check tree process can then be rerun with the new options by clicking the Check Tree button.