An Integrated Natural Language Parser

by Andre M. Mesarovic


Submitted in partial fulfillment of the requirements for the Degree of Master Science
Thesis Advisor: Professor Yoh-Han Pao
Department of Computer Engineering and Science
Case Western Reserve University
May 1987

Abstract

The objective of this research is to explore the applicability of the integrated parsing model as a natural language interface, and to examine how the integrated and syntax-oriented approaches resolve some basic linguistic problems. Most clearly articulated by Roger Schank with his Conceptual Dependency (CD) theory, the integrated approach is based upon directly mapping the surface structure of a sentence into its semantic representation without using intermediate syntactic structures. Syntactic information is not ignored, but is jointly utilized along with semantic judgements in one unitary process. The system developed in this thesis, called the Understanding System of English (USE), is implemented as a production system with chief system expectations organized around words and conceptual entities. The emphasis in writing the "grammar" has been on depth rather than breadth. A number of semantic primitives representing typical queries to a database, and the surface phrases that map into them have been identified. Most of the effort has gone into supporting a wide range of combinations of these surface phrases, ranging from perfectly grammatical forms to fragmentary and incomplete sentences. Major linguistic categories covered are ellipsis, anaphora conjunctions and noun phrases.

Acknowledgements

I would like to thank Professors Yo-han Pao, David Helman and Leon Stirling for their encouragement and guidance in the course of this project. I owe a special debt of gratitude to my parents for the love of language they have imparted to me.

Table of Contents

  1. Introduction
    1. Nature of Natural Language Research
    2. Lingustic Levels
    3. Goals of Computational Linguistics
  2. Approaches to Natural Language Processing
    1. Subparadigms of Computational Linguistics
    2. Classical Linguistics
    3. Ambiguity
    4. Early Natural Language Systems
    5. Augemtned Transition Networks
    6. Deterministic Parsing
  3. Integrated Parsing
    1. Parsing
    2. Conceptual Dependency Theory
      1. Semantic Primitives
      2. Basic Elements of CD Theory
      3. Primitive Actions
      4. Scripts
      5. Syntactic and Semantic Forms
  4. Implementation
    1. Natural Language Interfaces
      1. Commercial Front-Ends
      2. Human Engineering
      3. Ungrammatical Input
      4. Extendibility
    2. Interpreter Algorithm
    3. System Architecture
      1. Process and Structure
      2. Parser Overview
      3. Description of Interpreter Algorithm
    4. Pattern Matcher
    5. Lisp Support Functions
    6. Requests
      1. Request Structure
      2. Defining Structure
    7. Concepts
      1. Concept Schema
      2. Top-level Concepts
      3. Intermediate Concepts
    8. Lexicon
  5. Capabilities
    1. Sample Parse
    2. Ellipsis
      1. Simple Ellipsis
      2. Ambiguous Ellipsis
    3. Conjunction And
      1. And Joining Noun Groups
      2. And Joining Independent Clauses
      3. And and Ellipsis Appearing together
    4. Anaphora
      1. Simple Anaphora
      2. Complex Anaphora
    5. Noun Groups
    6. Higher Level C-whatif Concept
    7. Error handling
    8. Using the System
  6. Sample Session with USE
  7. Conclusion
    1. Comparing Syntactic and Integrate Approaches
      1. Theoretical Differences
      2. Implementation Differences
    2. Future Research
  8. References

1 Introduction

1.1 Nature of Natural Language Research

Despite their recent appearence as commercial products, natural language (NL) understanding systems have a long pedigree within the aritificial intelligence (AI) field. In many ways they even predate AI in the guise of machine translation efforts of the 1950s and 1960s. Often regarded as a subdiscipline of AI, NL research (also referred to as computational linguisitics) has encompassed most of the methodological techniques amd theoretical ideas of AI; indeed, many AI concepts have often originated in the NL area. The concern with knowledge-based processing has mad an impact not only on other area of AI, but on other disciplines that NL research is related to, namely liguisitics and psychology. In many ways computational linguisitics is an exemplary mode olf an interdisciplinary field.

Computational linguistics distinguishes itself by trying to model the human faculty of language as a computational process: to implement on a computer machine a program that exhibits intelligent behavior by possessing an apparent ability to "understand" language as used by the human speaker. Computational linguistics' scope of inquiry is immediately broadened by the inescapable conclusion that by whatever definition of the human linguistic faculty used, recourse must be made to other deeper cognitive processes. Topics that come immediately to mind such as memory organization, learning, inferencing and remembering must all be accounted for by the computer-based model. With such an array of issues to handle, it is little surprise that many more questions than answers have arisen in the course of the development of NL research in the last two decades.

1.2 Lingustic Levels

Language is a complex human phenemonon and any serious study must at some point decompose it itno a series of levels of abstractions each dealing with a self-contained domain, and interacting with other levels in limited ways. Traditionally the linguistic strata identified have been: phonology, morphology, syntax, semantic and pragmatics. The study of language is an ancient human enterprise and in one light computational linguistics can be seen as a continuation of this long tradition with the important novel application of the digital computer. Classical linguistics has concentrated on the lower strata of the level hierarcgy since these levels have provoded researchers with an area that could be studied in a more scientific manner. Syntactic structures of language have also been subject to rgorous scrutiny beginning with the Chmoskyan revolution, albeit in a more abstract and mathemmatical sense.

However, the higher linguistic levels such as semantics, and the more mentally oriented processes such as memory organization, have proven to be more problematic and have traditionally been excluded from the realm of linguistics. One of the maor reasons for controversies among the various schools studying language is the lack of a common definition of the human language faculty. In the often bewildering array of approaches to the study of language, each school has seen fit to draw its own boundaries around language. To the phonoligists, language is essentially a series of distinct sounds (phonemes) produced by the human vocal chords; to the Chomskyan, language is an abstract formal mechanism analyzing grammatacality; to the sociologist or anthropologist, language is a communicative process in a social setting; to the philosopher, it is the examination of theories of meaning.

1.3 Goals of Computational Linguistics

Computational linguistics has provided yet another approach to the study of language: language as a computational process. In attempting to construct computer models that can "understand" language, computational linguistics has not had the luxury of addressing a single linguistic level, but has had to confront all the levels, from the morphological to the pragmatic. The phonetic level is usually ignored (except for researchers in speech understanding) although it must not be forgotten that written language is already a significant abstraction over speech, the primary linguistic phenomenon. Much prosodic information, such as stress and intonation, which imparts important syntactic and semantic information, is lost when dealing with the written representation of language.

The goal of computational linguistics is the mapping of the linear surface structure of a sentence into a representation of its underlying meaning. But how this process is to be modeled is still a very open question, the main points fo disgreement centering on the precise relationship between the syntactic and semantic aspects of the language comprehension process. except for a few basic notions, such as the analogy between mental processes computational processes, there is a wide divergence of opinion as to what ar the proper mthods needed to analyze sentences, and on what level their meaning should be represented. One important theme that underlies much of the difference in computational linguistics is the relationship between language and thought. Some researchers, such as Schank, question if it is even useful to make this distinction. The journey from utterance to understanding is a long an tortuous one, traversing several physical and mental processes that interact in complex and largely unknown ways. No school has yet satisfactorily explained this process in full.

2 Approaches to Natural Language Processing

2.1 Subparadigms of Computational Linguistics

Using Kuhn's notion of a scientific paradigm (Kuhn, 1970), computational linguisitics can be regarded as a field still in flux, i.e. in a pre-paradigmic stage with a number of loosely related competing subparadigms. The principle point of debate has centered on the relationship between syntactic and semantic components of the language understanding process. Two approaches can be roughly discerned. One school, henceforth called the syntactic school, believes that a complete syntactic analysis of a sentence is a prerequisite for the extraction of its meaning. The other school, called the integrated school, is most often associated with Roger Schank (Schank 1975, 1977) although more moderate versions have been advanced (Wilks, 1975). Schank's claim is that a separate syntactic pass is not needed, and the integration of syntactic, semantic and world knowledge is not only more efficient, but also best approaches the cognitive processes that humans utilize.

It is important to realize that neither side claims that syntax and semantics is unnecessary; rather, the contrtoversy centers on the precise bandwidth of the communication channel between these two knowledge sources. The nature of the controversy could be better seen as revolving around the semi-autonomy of syntax rather than the autonomy of syntax. A number of other differences arise from this elementary distinction: the nature fo the control mechanism used to implement the parse, and the type of structures used to encode logical relations. Syntax-oriented researchers have spent most of their energy on extending the Augmented Transition Network (ATN) model to handle complex syntactic constructs, while adherents of the integrated approach concentrate on more cognitive issues such as memory organization.

Schematically, four different possible types of NL systems can be identified (Sowa, 1984, Schank, 1984):

  1. Staged system
  2. Nearly decomposable system
  3. Coroutined system
  4. Integrated system
The first type, the staged system, has rarely been implemented but is included here because it represents an ideal type best exemplified by the Chomskyan view. In this model, syntax and semantics are clearly modules and operate in temporal sequence. The syntactic component executes all its work in isolation and then delivers its output to semantics.

The nearly decomposable model also contains independent modules devoted to syntax and semantics, but, here the syntax modul frequently invokes to aid it in disambiguation phrases. Syntax can be seen as issuing subroutine calls to semantics, but control still remains with syntax. When the syntactic phase has finished, processing passes on to semantics. An example of such as system is the semantic grammars often used by ATN-based parsers (Hendrix, 1978, Waltz 1978).

The coroutine mechanism can be viewed as a variation of the second type. Again, autonomous syntactic and semantic units exists, but they exhibit a much closer degree of cooperation. Control does not exclusively lie with syntax but is shared jointly with semantics. When syntax encounters a problem it will pass contol to semantics, which, in turn, returns contol to syntax when it (semantics) can proceed no further. Winorad's SHRDLU system (Winograd, 1972) can be seen as an example of this class of system.

In all three versions described above the main difference has centered on the best way to build syntaqctic structures. What is at issue here is not the validity of an autonomous level of syntactic representation; rather, the manner in which extra-syntactic knowledge is utilized along with syntactic information in generating syntacitc structures. Although syntactic and semantic rules operate with varying degrees of cooperation, the problem they are working on is syntactic representations.

The integrated approach deos not subscribe to this assumption and advocates a close coupling of syntactic and semantic information in all stages of the comprehension process. Syntactic structures are not regarded as necessary, and the parsing process maps a sentence directly into its semantic constituents. Integrated parsing is examine in depth in chapter 3.

2.2 Classical Linguistics

The syntactic school owes much of its origin to the autonomy of syntax hypothesis derived from the transformational grammar school of Chomsky (Chomsky, 1978, 1982). The human mind is assumed to possess a language faculty that enable the speaker to distinguish grammatical sentences from ungrammatical ones. This theory does not pretend to speak to the problem of how humans process language, defined as pertaining only to the syntactic level. The Chomskyan approach is predicated upon the distinction between linguistic competence, the abstract knowledge of a lnaguage that a native speaker possesses, and linguistic performance, the actual rela-world utterances used by the speaker which often do not totally conform to the idealized notion of competence. This school limits its attention to accounting for syntactic knowledge and denies that semantics plays a role in deriving represenations for the syntactic level.

However, computational linguistics's main concern is not in describing linguistic capabilities as an abstract formal mecahnism, but in developing a framework to represent meaning, the real-world objects and concepts that a sentence connotes. The derivation of phrase structures is not the primary objective as in transformational linguistics, but, if used, is merely a means to the end of decoding the meaning underlying a sentence. This broadening of the scope of inquiry to semantics and the organization of knowledge presents computational linguistics with a task that necessitates cooperation with other fields studying the human mind such as philosophy and psychology.

Although transformational grammar influenced much of the early work in NL understanding, its direct utility proved limited since it is primarily concerned with transformations from syntactic deep level structures to surface structures, and NL researches' goal is the reverse, mapping surface structures into syntactic and semantic structures. It is this distinction between performance and competence that puts transformational grammar at odds with computational linguistics. In disregarding questions of process, transformational grammar effectively isolates itself from real-world issues of human language understanding. Computational linguistics' main concern is performance, and implementationl models are an integral pars of its methodology.

2.3 Ambiguity

One of the key stumbling blocks of NL understanding is ambiguity (Birnbaum, 1985). Ambiguity can take on many different forms, and it is worthwhile to briefly examine some of them. Syntactic theories are based upon the identification of regularities in language and are not easily adaptable to deal with ambiguities and idiomatic phrases. Natural language, however, is riddled woth ambiguities and nuances usually not immediately discernable to the native speaker. In fact, most words are ambiguous, such as catch, take, give, her. The paradox is while humans find it difficult to spot all the ambiguities in an utterance a computer finds it all to easy to discover them. People generally process language unambiguously, assigning meaning to each word as it is encountered. A strict syntactic approach ends up generating a large number of alternative parses for even the simplest sentences, and leaves it to the semantic stage to choose the appropriate one. To illustrate the magnitude of this problem, the sentence

People who apply for marriage licenses wearing shorts of pedal pushers will be denied licenses

results in forty possible parse trees (Sowa, 1984).

The principle type of ambiguity that causes most grief is word class ambiguity, where a word can belong to several different grammatical categories. For example, the word duck can be either a verb as in I would duck if I saw a ball coming, or a noun when describing the type of bird that swims in a pond. Without recourse to some discourse context, two parse trees are equally valid for the sentence I saw her duck.

Structural ambiguity arises when several alternative syntacic structures can be derived from a string of words whose word classes are unambiguous. In the phrase old men and women it is not clear whether both the men and women are odl, or if only the men are old. Again, context can help out but this problem is not as easily solved as word class ambiguity.

Lexical ambiguity, or word sense ambiguity, is when a word of a given class can have several different meanings. The phrase he cannot bear kids has two lexically ambiguous words, bear meaning tolerate as in he cannot bear loud noises, or meaning to give birth to as in a woman can bear children. The other ambiguousword is kid, signifying a human child or baby goat. This type of ambuguity is outside the scope of syntax analyzers, but is often amenable to semantic resolution based on discourse context. Of course, real problem arise when these ambuguities occur simultaneously in a senctence as in she was sick and he took her flowers. Here, took is lexcially ambiguous, meaning either to give or to take away, and her is word class ambiguous, its part-of-speech being either a personal pronoun or a possessive pronoun.

Modifier (prepositional phrase) attachment is another issue that cannot be decided solely upon syntactic grounds. In a sentence there will often be many noun phrases a given phrase can refer to, and usually only one will be semantically plausible. For instance, in the phrase I went to the park with a girl, the modifier with a girl can either be attached to the park or I, although the latter is the usual interpretation.

Ambiguity can be also classified along another dimension scope (Ritchie, 1984). ALl different classes of ambiguity enumerated above pertain to global ambiguity. Local ambiguity is when words are ambiguous in the course of parsing a sentence, but are not ambiguous once the whole sentence has been processed. For instance, if the parse encounters the words plastic covers they are locally ambiguous in two ways: plastic can be a noun and covers a verb as in the plastic covers the table, or plastic can be an adjective and covers aa noun as in the plastic covers protect the table. Until the parse has reached the fourth word in the sentence, it has no way of correctly assigning a category for either word.

2.4 Early Natural Language Systems

The earlies work in computer understanding of human language, machine translation, foundered in its inability to resolve ambiguity since it did not come to grips with the syntactic and semantic complexities of language. Largely based on word-based dictionary look-ups, this effort was for all practical purposes extinct by 1970.

The current phase of NL research was ushered in by two events: Woods' concise formulation of the Augmented Transition Network (ATN) model (Woods, 1970, 1973) which provided researchers with a practical and versatile formalism within which to pursue syntactic analysis, and Winograd's SHRDLU sustem (Winograd, 1972) which demonstrated that combining syntactic parsing with procedural semantics could produce behavior approximating human unerstanding. However, SHRDLU's methods proved to be too domain specific, too tied to the block world, to be generalizable. Winograd's experiment demonstrated that a more complete understanding of the role that world knowledge plays in the language comprehension process was necessary. On the other hand, Woods' project turned out to be a more fruitful enterprise although it was also confronted by the challenge of semantic and world knowledge. A variety of hybrid systems have since been developted along ATN lines, and, in fact, ost commercial NL front-ends are based on this model.

2.5 Augmented Transition Networks

The ATN model has proven to be one of the most popular approaches to NL processing, and is worth examining in some detail to see where some of the major disgreements lie with the integrated approach. A recursive transition network (RTN) is a recursive finite-state machine consisting of a set of states represented as nodes, and legitimate transitions between states represented by arcs. An ATN is a RTN with two major enhancements:
  1. The ability to associate arbitrary conditions and actions with arcs.
  2. The ability to create structures that are independent of the flow of control of the parser.
Although an ATN is formally equivalent in power to a context-free grammar, it shares with transformational grammar the major improvement of being able to account for non-adjacent dependencies. This is made possible by the arcs' arbitrary actions that build the structure as the parse navigates through the network. In fact, the fixed part of the ATN model is only the recognizer; it does not imply a commitment to any particular grammar theory. Various theories such as case grammar or domain-specific structures can be implemented within the ATN framework.

Because natural language is inherently ambiguous, ATNs are non-deterministic machines since there can be several arcs leaving any given state, and the decision as to which one to follow is arbitrary. An ATN describes what the acceptable patterns are but not how these patterns are to be recognized. An ATN is a top-down parser, pursuing a breadth-first searcg through the network. When an incorrect path is chosen by the interpreter, i.e. no more legal transitions can be undertaken, the system will back up to the most recent node that still has an untried arc. From this choicepoint an arc will be selected and pursued until the final halt state is reached, signifying a succesful parse.

In the aforementioned ambiguous example plastic covers protect the table, when confronted with the word plastic, an ATN parser has to hypothesize either a noun or adjective, and if it chooses the wrong part-of-speech for plastic it will have to backup to this word and try another word class. In the course of even a short normal sentence, an ATN can be forced to backup a large number of times even though the sentence is not globally ambiguous. In the case of global ambiguity, either the system outputs the first alternative it parses, or it generates all possible parses and hands over the dilemma to the semantic component.

The key drawback to this approach is the ambuguity of so many words and the non-deterministic strategy used to overcome this problem. Herein lies the Achilles heel of the ATN approach: the combinatorial explosion of candidate paths. In principle, this can be solve by backtracking or parallel pursuit of all legitimate path. But either alternative results in an unacceptable number of paths unless elaborate scheduling strategies are devised for ordering choicepoints. Nevertheless, this still does not alter the fact that the basic method remains guess and if wrong, back up.

The major inefficiency with backtracking lies in the resotration of prior states, i.e. the saving of structures and deleting of already built structures. A partial solution to this problem consists of maintaining a chart, which is a record of existing constituents that do not have to be recreated when backtracking (Kay, 1973, Thompson, 1984).

It is important to point out that the type of ambiguity that has been discussed above is local ambiguity. An ATN may have to backtrack a large number of times due to locally ambiguous words, even though the sentence has only one legitimate parse. Global ambiguity presents another type of problem that in a strict sense falls outside the framework of the ATN model. This type of ambiguity results in there being several valid paths through the network for a given sentence, and the decision of which one to retain cannot be decided upon strictly syntactic grounds. A well known example of a globally ambiguous sentence is time flies like an arrow which has at least three parse trees.

The simplest solution is to generate all these representations, and then pass on the problem to the semantic mopdule to pick the mist desirable one. But this presents serious computational problems as well as not accurately reflecting human parsing techniques. The more common used strategy is to embed semantic checks inside the syntactic module in order to prune undesirable paths early in the parsing process. This method, often called a semantic grammar, has arc tests not only for parts of speech, i.e. syntactic categories, but also test for elements of the semantic domain. For instance, if the database pertained to auto repair tools, tests would be for wrench and screwdriver, and not only for noun and verb. Moreover, the ATN model, as well as other parsers within the syntactic paradigm, do not address the process of mapping the parse trees into semantic structures.

2.6 Deterministic Parsing

An important alternative to the nondeterministic ATN model is the determistic PARSIFAL parser (Marcus, 1980). Still entirely within the syntactic paradigm, the goal of this system is to overcome problems associated with local ambiguity. The claim of the determinism hypothesis is that by using a three-place lookahead buffer, and providing for both top-down and bottom-up parsing, a sentence can be processed without having to backtrack. By not immediately assigning a structure to an ambiguous word and saving it in a buffer, PARSIFAL avoids having to delete extant structures. PARSIFAL is organized as a production system and shares some major characteristics with integrated parsers, namel the ability to mix data-driven and expectation-driven parsing. Although this approach can deterministically handle certain subsets of English, its scope still pertains only to local ambiguity, and does not address the issues of word class ambiguity or modifier attachment.

3 Integrated Parsing

3.1 Parsing

The integrated scheme presents a radical departure from the premise that autonomous syntactic structures play a useful role in language understanding. In this approach, syntactic knowledge is not rejected per se, but there is no sequential flow of control through separate components representing syntactic and semantic knowledge. Instead, all potential useful sources of knowledge (syntact, semantic, and worl knowledge) are brought into play under the guidance of one control mechanism. Syntactic judgements, i.e. information about word order (in English at least), are not distinguished from semantic information. This implies that the parse does not generate any autonomous syntactic representations, and that syntactic relations are subsumed by higher level conceptual structures. Although the distinction between syntactic and semantic rules has been traditional in linguistic studies, the functional role they play in language understanding is considered indistinguishable by the integrated school. Primary control is in the hands of conceptual expectations, and syntactic rules are utilized only when these higher level rules cannot proceed any further.

The parsing process can be divided into two phases:

  1. A recognition stage that breaks up a linear string of words of a sentence into its consituent parts.
  2. A structure building stage where these consituents are rearranged according to some cheme specified by the grammar.
For instance, in the sentence the large boy threw a red ball, three consituents are recognized, two noun phrases and a verb, but they fullfil different roles in the syntactic structure.

Constituents:

  1. Noun phrase 1: the large boy
  2. Verb: threw
  3. Noun phrase 2: a red ball
Grammatical structure:
  1. Subject: Noun phrase 1
  2. Verb: Verb
  3. Object: Noun phrase 2
Traditionally, parsing has usually designated the mapping of a surface sentence into its syntactic representation, but since the integrated approach does not utilize syntactic structures, the meaning of parsing has been extended to include the sentence's mapping into its conceptual representation.

Integrate parsing is based upon the premise that semantic and syntactic knowledge have to be used concurrently in language analysis, and that a separate and distinct syntactic stage is not necessary (Riesbeck, 1975). The parse should use all information at its disposal, both linguistic and non-linguistic, as early as possible in the parsing process and not limit itself to one arbitrarily defined class of knowledge such as syntax. Psychological evidence indicates that people do not first interpret a sentence syntactically and then semantically, but rather, they use all available information to extract the final meaning. Since people have little trouble understanding incomplete or incorrectly formed sentences, a parse that relies solely on syntactically well-formed sentences leaves unaccounted a wide range of human language performance.

XX

3.2 Conceptual Dependency Theory

The swing from syntax to semantics in NL research can be seen as part of the trend in AI from generic problem-solving methods to domain-specific techniques relying heavily on world knowledge.

3.2.1 Semantic Primitives

Although the terms semantics and concepts are often used interchangably in CD literature, in a strict sense the two are not entirely equivalent.

3.2.2 Basic Elements of CD Theory

The basic unit of the conceptual level is the conceptualization, the meaning proposition embodied in a sentence.

3.2.3 Primitive Actions

Eleven types of ACTs exist that express all possible actions. These primitive actions have played an important, albeit controversial, role in CD thoery since many researchers have questioned this particular axiomatization scheme. ACTs, although similar to verbs, do not directly correspond to verb senses. Any verb can be decomposed int one or more of the following elvel ACTS:
  1. PTRANS:
    The physical transfer of an object. The most obvious example is the verb move, as in Juan moved the boat.
  2. MTRANS:
  3. ATRANS:
  4. PROPEL:
  5. MOVE:
  6. GRASP:
  7. INGEST:
  8. EXPEL:
  9. MBUILD:
  10. SPEAK:
  11. ATTEND:

3.2.4 Scripts

Higher level aggregations of conceptualizations are grouped together as scripts (Schank, 1977).

3.2.5 Syntactic and Semantic Forms

An important motivating force in the development of CD theory was the realization that the surface structure of a sentence bore little corresponance to its conceptual representation. Identifying the syntactic structure, although not entirely devoid of implication for meaning, was not an extermely useful guide in predicting the final conceptual form. Take the following two sentences:
  1. John's can of beans was edible.
  2. John's love of Mary was harmful.
Though thes two sentences have identical syntactic forms, their representations on the conceptual level are different. In sentence 1, the referent of edible is the beans, and in sentences 2 it is love. Understanding is not obtained from syntactic rules, but from semantic information, i.e. knowing that it is the beans and not the can that is edible.

4 Implementation

4.1 Natural Language Interfaces

The advantage of NL systems over other forms of database interfaces, such as menus and query languages, seems rather obvious.

4.2 Interpreter Algorithm

While the user does not exit do
  Begin
  Read a sentence
  Replace all the synonyms in sentence
  While a word still exists in the input sentence do
    Begin
    Get a word from the sentence
    Get the word's requests from the Word Dictionary 
    Call procedure activate-requests with these requests 
    For all requests on the Rlist do
      If a request is fired then
        For all action in the Then part of the request
          Begin
          If the action will add a concept to the Clist then
            Begin
            Get the default requests associated with the concept
            Call procedure activate-requests with these requests 
            Add the concept to the Clist
            End_if
          Else
            Execute the action
          End_for
    End
  End

4.3.1 Process and Structure

An important distinction to bear in mind is the difference between the control mechanism used to transform a linear string of words into some representation scheme (grammar), and the scheme itself.