CSC 350 Assignment #4 —
Database Storage/Retrieval via Natural Language
Part A: Due Tuesday, March 11 (scripted by midnight).
Part B: Due Tuesday, March 18 (scripted by midnight).
Mimicking the ideas of the "famous people database" discussed
in class, create a similar "natural language" retrieval-based
collection of information.
Proceed according to the following steps.
Part A
- Develop a problem domain in which the database is to be used.
(If you were to use the idea of maintaining data on "famous people",
you'd need to change the relevant aspects of it. For example, rather
than profession and nationality as attributes of your program's
expertise, you could keep tabs on celebrities' favorite foods, pets, etc.)
Some ideas: authors and their writings; Oscars and the winners;
aircraft/cars/ships/whatever and their specifications;
quotes, jokes, etc.
- Create a source language of sentences which store information into–
and retrieve information from– your database.
- Write a Prolog Definite Clause Grammar to recognize your language.
Note: this grammar has no attributes attached to the nonterminals.
- Run your system showing that it recognizes legal "sentences" and
rejects illegal ones.
- Capture a listing and the above run in a script file
called, perhaps, 4a.ts.
Part B
- Extend the grammar by adding appropriate attributes (aka
features) to appropriate elements.
I.e., create an
attribute grammar.
- Devise a data storage representation to maintain these attributes.
- Turn the grammar into an action grammar which interprets
the sentences.
I.e., either stores or retrieves information from the data collection.
- Run your system showing that it responds to legal sentences
with appropriate information.
- Capture a listing and the above run in a script file
called 4b.ts.