Prolog and Natural-Language Analysis
D E

Prolog and Natural-Language Analysis
Fernando C. N. Pereira and Stuart M. Shieber

Microtome Publishing
Brookline, Massachusetts

c F. C. N. Pereira and S. M. Shieber 1987
Millenial reissue c F. C. N. Pereira and S. M. Shieber 2002

This work is the digital edition of Pereira and Shieber’s Prolog and Natural-Language Analysis. The work is also available for sale in a hardbound edition (ISBN 0-97199970-4), printed on acid-free paper with library binding and including all appendices and two indices, from Microtome’s web site at http://www.mtome.com and other booksellers.

This work is covered by copyright, which restricts the uses that you may make of the work. All rights are reserved by the copyright holder. The copyright holder hereby gives you permission to reproduce and distribute the digital edition of this work, in whole or in part, in digital or physical formats, under the following restrictions: You may not charge for copies of the work, with the exception of recovery of direct costs of reproduction for distribution of the work to students in courses. You may not modify the work, including elimination or modification of any embedded notifications. You must include title, author, copyright information, and this license in any reproductions; this latter requirement may be discharged by reproducing copies of the pertinent pages from the work’s front matter.

This digital edition of Prolog and Natural-Language Analysis is distributed at no charge for noncommercial use by Microtome Publishing.

Contents
Preface

1. Introduction
1.1. Purpose  
1.2. Logic Programming and Language
1.3. Programming In Prolog  .
1.4. Overview   . . .
1.5. Bibliographic Notes  . . .

2. Database Prolog
2.1. Databases and Queries  
2.1.1. A Simple Database   . .
2.1.2. Querying the Database  
2.2. Extending the Query Language  
2.3. The Logic of Prolog    .
2.4. The Operation of Database Prolog  . . .
2.4.1. Proof Trees and Traces  
2.5. Recursive Predicate Definitions  
2.5.1. Variable Renaming   . .
2.5.2. Termination    .
2.6. Problem Section: Semantic Networks  .
2.7. Context-Free Grammars   . . .
2.7.1. Axiomatizing Context-Free Grammars . .
2.7.2. Context-Free Grammars in Prolog
2.7.3. Prolog as Parser  
2.8. Problem Section: Grammars   .
2.8.1. A Syntactic Analyzer for Database Prolog
2.8.2. Extending CFGs with Intersection
2.8.3. Transition Networks   .
2.9. Bibliographic Notes    .

3. Pure Prolog
3.1. Prolog Notation Revisited
3.2. Terms and Unification   .
3.3. Functions in Prolog and Other Languages
3.3.1. Alternate Notations for Functors .

Contents

A hardbound edition of Prolog and Natural-Language Analysis is available
from http://www.mtome.com and other booksellers.

3.4

4. Further Topics in Natural-Language Analysis
4.1. Semantic Interpretation  
4.1.1. The Lambda Calculus  
4.1.2. A Simple Compositional Semantics . . .
4.1.3. Encoding the Semantic System in Prolog
4.1.4. Partial Execution   . . .
4.1.5. Quantified Noun Phrases
4.1.6. Quantifier Scope   . . .
4.2. Extending the Syntactic Coverage  . . .
4.2.1. Auxiliary Verbs  
4.2.2. Yes-No Questions   . .
4.2.3. Filler-Gap Dependencies
4.2.4. Relative Clauses   . . .
4.2.5. WH-Questions  
4.2.6. Semantics of Filler-Gap Dependencies . .
4.2.7. Gap Threading  
4.3. Problem Section: Grammar Extensions  .
4.3.1. Noun Complements   .
4.3.2. Noun Postmodifiers   . .
4.3.3. More Filler-Gap Constructions  .
4.3.4. Categorial Grammars   .
4.4. Bibliographic Notes    .

5. Full Prolog
5.1. Metalogical Facilities   .
5.1.1. The call predicate  . . .
5.1.2. The cut command
5.1.3. The Negation-as-Failure Operator
5.1.4. The setof predicate  . .
5.1.5. The assert command  .

Lists     . . .
3.4.1. List Processing   . . .
3.4.2. Representing String Positions with Lists
The Logic and Operation of Prolog Revisited .
3.5.1. Substitutions  
3.5.2. Unification   
3.5.3. Resolution   
3.5.4. Prolog’s proof procedure  . . .
3.5.5. Semantics of Prolog  
Problem Section: Terms and Lists  . .
Definite Clause Grammars   .
3.7.1. Trees for Simple Sentences  . .
3.7.2. Embedding Prolog Calls in DCGs . . .
Problem Section: DCGs   . .
3.8.1. The Syntax of First-Order Logic
3.8.2. Extending Syntactic Coverage
Bibliographic Notes   

6. Interpreters
6.1. Prolog in Prolog    
6.1.1. Absorption     . .
6.1.2. Keeping Proof Trees    . .
6.1.3. Unit Clauses     .
6.2. Problem Section: Prolog Interpreters   . . .
6.2.1. Consecutively Bounded Depth-First Search
6.2.2. An Interpreter For Cut    .
6.3. Interpreters for DCGs     .
6.3.1. DCG in Prolog    
6.3.2. DCG in DCG     .
6.3.3. An Interpreter for Filler-Gap DCGs
6.4. Partial Execution and Compilers   
6.4.1. Partial Execution Revisited  
6.4.2. Compiling by Partial Execution   .
6.4.3. Generality of the Method   
6.5. Bottom-Up Parsing     . .
6.5.1. Linking    
6.5.2. Compiling DCGs into Left-Corner Parsers  .
6.6. Tabular Parsing    
6.6.1. Inefficiencies of Backtracking   . .
6.6.2. Tabular Parsing in the Abstract   . .
6.6.3. Top-Down Tabular Parsing  
6.6.4. Subsumption     .
6.6.5. The Top-Down Tabular Parser in Action  . .
6.6.6. General Tabular Parsing   
6.6.7. Earley Deduction and Earley’s CF Parsing Algorithm
6.6.8. Limitations of Tabular Parsers   . .
6.7. Problem Section: DCG Interpreters and Compilers
6.8. Bibliographic Notes     . .

A. Listing of Sample Programs
A.1. A Note on Programming Style     .
A.2. The TALK Program      . .
A.3. The DCG Compiler      . .

5.1.6. Other Extralogical Predicates .
A. Simple Dialogue Program  .
5.2.1. Overall Operation  . . .
5.2.2. Parsing   . . .
5.2.3. LF Conversion
5.2.4. Constructing A Reply
User Interaction   . . .
5.3.1. Simple Input/Output Commands
5.3.2. A Simple User Interface
Bibliographic Notes

Bibliography

Advertisements

About josberto

Mi ŝatas traduki librojn pri matematiko kaj komputilaj teknologio. Mi esperas ke miaj tradukadoj estus utila kaj agrabla por vi.
Aside | This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s