A complete solution to the pro

A complete solution to the problem of inexact matches to the buyer’s description in shopping is very difficult and requires a full array of natural language processing and information retrieval techniques. (See Chapters 22 and 23) One small step is to allow the user to specify minimum and maximum values for various attributes. We will insist that the buyer use the following grammar for product descriptions:

Description → Category [Connector Modifier] *

Connector → “with” │ “and” │ “,”

Modifier → Attribute │ Attribute Op Value

Op → “=” │ “>” │”<” 

Here, Category names a product category, Attribute is some feature such as “CPU” or “price,” and Value is the target value for the attribute. So the query “computer with at least a 2.5-GHz CPU for under $1000” must be re-expressed as computer with CPU > 2.5 0Hz and price <$1000.” Implement a shopping agent that accepts descriptions in this language.

 
"Our Prices Start at $11.99. As Our First Client, Use Coupon Code GET15 to claim 15% Discount This Month!!"