Ethical and Legal issues - Brock University

Ethical and Legal issues - Brock University

Inference mechanisms Backward chaining - goal-driven reasoning which gathers data as needed - Prolog's default mechanism - good for identification problems Forward chaining - data-driven reasoning which must be initialized with all data values - system refines problem state towards solution state - good for configuration problems B. Ross Cosc 4f79 1 Misc Prolog notes 1. With Sicstus prolog, need to do either a "nl" or a "ttyflush" command in order to see output on screen before a read - these commands flush the output buffer (similar things happen in C) 2. With Prolog's "read", a capitalized word will be interpreted as a variable.

eg. read(X) B. Ross Cosc 4f79 --> enter Yes means X is unified with variable Yes enter 'Yes' unifies X with constant 'Yes' enter yes unifies X with constant 'yes' 2 Separation of KB and shell Important to separate declarative KB code from procedural shell utilities - knowledge base can then be used by other inference schemes - shell can be altered and made as flexible as one needs, w/o touching KB - Basically, put each into distinct files. In Merritt "bird" system, one line in KB is: top_goal(X) :- bird(X).

Then, shell always executes "top_goal(X)". --> this gives a hook between KB and shell B. Ross Cosc 4f79 3 Bowen Toy system from Prolog and Expert Systems, K.A. Bowen (McGraw Hill) similar in spirit to Bird he handles some things differently eg. to keep track of similar input words: synonym(pain, severe_pain). synonym(pain, numb_pain). ... then you can check synonym for user input X by doing: ?- synonym(S, X). he also uses

setof(V, synonym(pain,V), Vlist) --> returns Vlist = [severe_pain, numb_pain, ...] - setof(Template, Goal, List): successively solves Goal, and saves variables shared between Goal and Template in List, using Template - sorts List, and removes duplicates - Template is a term: a variables, or even a structure eg. p(X,Y) bagof: similar, except that it keeps all solutions in the order discovered, and doesn't sort nor remove duplicates B. Ross Cosc 4f79 4 Friendly User Input Prolog's Input-Output is too unfriendly and unforgiving should develop a library of user-friendy I/O expert system interface: - users may have little or no computer background

- users may have little or no background in domain area - recover from errors (typing, misunderstandings, ...) - avoid unnecessary dialog - remember input - use menus - perhaps remember input from different sessions - keep a history database - provide various levels of explanation and help B. Ross Cosc 4f79 5 Summary The knowledge base and shell utilities are separate. The knowledge base is declarative. It can be processed by any kind of inference system. It is easily modified. The system prompts user for facts. It remembers input.

Menu input is used. Note that, although shell utilities are procedural, it is possible to write declarative utilities. This is an ideal, but they might be inefficient. possible enhancements: - Better text messages for queries - more error checking - numeric input with menus (see handout) - *** explanation *** B. Ross Cosc 4f79 6

Recently Viewed Presentations

  • Asthma…


    The action plan is based on asthma signals and peak flow numbers and gives information on asthma medication schedules, what to do under different situations, and when to call the provider or go the emergency room. Asthma is a serious...
  • HRS Overview Workplace Issues Presented by: Human Resource

    HRS Overview Workplace Issues Presented by: Human Resource

    According to Bully in the Ivory Tower (Leah P. Hollis, ED.D) Bullying and harassment are synonyms. Both are belittling, demeaning treatment that escalates over time. The target is often left in a position where enduring the bad behavior is a...
  • Regions


    • climate, landform, or vegetation. • capital city, states, regions. Functional . ... Cylindrical map projection. ... These four New York counties (New York, Kings, Queens, and Bronx) have a combined African-American population of 2,121,882 and outnumbers the total number...
  • The Maryland Common Core Frameworks for

    The Maryland Common Core Frameworks for

    Maryland Common Core State Curriculum Frameworks for Braille. Heather. The content for the braille frameworks is the same, no standards were deleted or omitted. Braille readers will have the same rigor and high expectations. The braille skills necessary to access...
  • Moral Sense Theory - Bridgewater State University

    Moral Sense Theory - Bridgewater State University

    Moral judgments have an influence on our actions and affections. Conclusions of reason can never, by themselves, influence our actions or affections. Therefore, moral judgments are not conclusions of reason. Follows Hutcheson: Moral judgments arise from our sentiments.
  • Adapting to Environmental Uncertainty - Publish

    Adapting to Environmental Uncertainty - Publish

    New phones too bulky and expensive . Candy bar style . Slow to respond to changing customer preferences. In the end ….. Had to change their target market -waiting to see if their strategy will work..
  • Access Project 1 - Brooklyn College

    Access Project 1 - Brooklyn College

    Access Project 1 Creating and Using a Database Objectives Describe databases and database management systems Start Access Describe the features of the Access desktop Create a database Create a table and add records Objectives Close a table Close a database...
  • The Metric System - Weebly

    The Metric System - Weebly

    The Metric System. Easier to use because it is a decimal system. Every conversion is by some power of 10. A metric unit has two parts. A prefix and a base unit. prefix tells you how many times to divide...