CSC 494 · Introduction to Artificial Intelligence
Our notes
2 min readWhat knowledge representation is
Choosing a form in which facts, rules and relationships are stored so a program can reason with them. A good scheme is expressive, efficient to reason with, easy to understand and modify.
Kinds of knowledge
Declarative (facts), procedural (how to), meta-knowledge (knowledge about knowledge), heuristic (rules of thumb), common sense.
Schemes
| Scheme | Description | Example |
|---|---|---|
| Logic | propositional or first-order sentences | ∀x Bird(x) ⇒ HasFeathers(x) |
| Production rules | IF condition THEN action | IF temperature > 38 AND cough THEN suspect infection |
| Semantic networks | nodes (concepts) joined by labelled links (is-a, has-part) | Canary is-a Bird; Bird has-part Wings |
| Frames | structured records with slots and values, default values and inheritance | Frame Car: wheels 4, fuel petrol (default) |
| Scripts | stereotyped sequences of events | "eating at a restaurant": enter, order, eat, pay, leave |
| Ontologies | formal shared vocabularies of concepts and relations | medical terminologies, web ontologies |
| Knowledge graphs | large networks of entities and relations | search engine facts panels |
Inheritance
In semantic networks and frames, properties flow down is-a links: if Bird can fly and Canary is-a Bird, Canary can fly. Exceptions override defaults (Penguin is-a Bird but cannot fly).
Reasoning with uncertainty
Real knowledge is often uncertain.
- Probability and Bayes' rule: P(H | E) = P(E | H) P(H) / P(E).
- Certainty factors (MYCIN, next topic).
- Fuzzy logic: degrees of truth between 0 and 1 ("temperature is high to degree 0.7").
- Bayesian networks: graphs of variables with conditional probabilities.
Worked example: Bayes' rule
A disease affects 1% of people. A test detects 90% of cases (sensitivity) but gives a positive result in 5% of healthy people.
- P(positive) = 0.01 × 0.9 + 0.99 × 0.05 = 0.009 + 0.0495 = 0.0585.
- P(disease | positive) = 0.009 / 0.0585 = 0.154 (about 15%).
Most positives are false positives because the disease is rare: a key lesson for diagnostic systems.
Knowledge-based systems
Programs that separate a knowledge base from an inference engine, so knowledge can be updated without rewriting the program. Expert systems are the main example.
Exams usually ask
- Describe and compare semantic networks, frames and production rules.
- Explain inheritance and exceptions.
- Apply Bayes' rule to a diagnosis problem.
Common mistake
Confusing P(E | H) with P(H | E). A test that is 90% sensitive does not mean a positive result is 90% likely to be right.
Written by the UniHive team in our own words. Spotted a mistake? Tell us on WhatsApp.
Read
-
Knowledge representation and reasoning
(opens en.wikipedia.org in a new tab)
Wikipedia, Knowledge representation and reasoning, CC BY-SA 4.0 · licence
-
Semantic network
(opens en.wikipedia.org in a new tab)
Wikipedia, Semantic network, CC BY-SA 4.0 · licence
-
NPTEL: Artificial Intelligence: Knowledge Representation and Reasoning (IIT Madras, whole course)
Prof. Deepak Khemani: propositional and first-order logic, proofs, unification and resolution, representing knowledge. Video lectures, many hours in all: watch on Wi-Fi where you can.
(opens nptel.ac.in in a new tab)
NPTEL, NPTEL: Artificial Intelligence: Knowledge Representation and Reasoning (IIT Madras, whole course), CC BY-NC-SA 4.0 · licence
Watch
-
Best pick Knowledge Representation in Artificial Intelligence | Knowledge Representation in AI | Simplilearn
13 min · ≈ 59 MB · about ₦33
(opens youtube.com in a new tab)
-
Knowledge Representation in AI | Semantic Networks | Artificial Intelligence Tutorial | Edureka
18 min · ≈ 81 MB · about ₦45
(opens youtube.com in a new tab)
-
10. Knowledge Representation & Mappings | AI Concepts, Knowledge Graphs & KR Issues
10 min · ≈ 45 MB · about ₦25
(opens youtube.com in a new tab)
-
AI Explained: Knowledge Representation and Reasoning
10 min · ≈ 45 MB · about ₦25
(opens youtube.com in a new tab)
-
Lec-37 | Core Methods of Knowledge Representation in AI | AI Tutorial in English
13 min · ≈ 59 MB · about ₦33
(opens youtube.com in a new tab)
-
Knowledge - Lecture 1 - CS50's Introduction to Artificial Intelligence with Python 2020
1 h 48 min · ≈ 486 MB · about ₦273
(opens youtube.com in a new tab)
We link to free material and never copy it. Every link was opened by our team before it went up; video data is a rough guide at 360p.