Presentation is loading. Please wait.

Presentation is loading. Please wait.

Case-based Reasoning A type of analogical reasoning

Similar presentations


Presentation on theme: "Case-based Reasoning A type of analogical reasoning"— Presentation transcript:

1 Case-based Reasoning A type of analogical reasoning

2 Problem Solving Humans are extremely good at problem solving
They have evolved that way Even problems that they seldom encounter or have never encountered before

3 Problem Solving Logics
Deductive Logic Inductive Logic Abductive Logic Analogical Logic Description Logic Fuzzy Logic

4 Analogy and Experience

5 Underlying Model of CBR
Humans are robust problem solvers Humans reason from cases in a wide variety of contexts Studies abound in how humans reason from cases

6 What is CBR? Case-based reasoning is [...] reasoning by remembering.
A case-based reasoner solves new problems by adapting solutions that were used to solve old problems. Case-based reasoning is a recent approach to problem solving and learning Case-based reasoning models both the ways people use cases to solve problems and the ways in which we can make machines use cases.

7 Analogical Reasoning (CBR)
Case-based reasoning (CBR) is a certain technique which was based on analogical reasoning. The main intention is to reuse previous experiences for actual problems. The difficulty arises when the actual situation is not identical to the previous one: There is an inexactness involved. Its main aspect is that CBR-techniques allow inexact (approximate) reasoning in a controlled manner. Here we will shortly describe its main features. Major applications include fault diagnosis, help desk systems, eCommerce

8 Could be called Similarity Based Reasoning
The central notion in CBR is the concept of similarity. The methods in CBR have been extended in a way which allows applications to other problems rather than reusing previous experiences: in electronic commerce e.g. to product selection. This is due to an abstract formulation of the similarity concept. In particular, the main algorithms of CBR can still be applied to these new situations. We will first describe the original technique informally and then proceed to the extensions.

9 Research in CBR ECCBR European Conference on Case-Based Reasoning ICCBR International Conference on Case based Reasoning

10 Case-Based Reasoning (CBR)
Basic Ideas: Store previous experience (case) Solve new Problems by selecting and reusing cases Store new experience again Replaces 0-1-logic by approximation Is a well-founded technology: Mathematically Algorithmically With respect to software technology Supported by experiments and applications Business success Most successful recent branch of AI

11 What is a Case ? A case has two parts:
Description of a problem or a set of problems (generalized case) Description of the solution of this problem (formally or informally) Possibly additions like explanations, comments on the quality of the solution etc. Cases represent experiences : They record how a problem was solved in the past

12 Different Case Representations
Free text: textual CBR Database like representations: structural CBR

13 Structured Case Representation
Many different case representations are used Depend on requirements of domain and task Structure of already available case data Flat feature-value list Simple case structure is sometimes sufficient for problem solving Easy to store and retrieve in a CBR system Object-oriented representations Case: collection of objects (instances of classes) Required for complex and structured objects Genauer im Teil III.

14 How to Use a Case Problem of the case Problem Solution ? Solution
Solution adaptation In general, there is no guarantee for getting good solutions because the case may be „too far away“ from the problem. Therefore the problem arises how to define when a case is “good enough”.

15 How to Use a Case-Base A case base is a data base of cases
If a new problem arises one will use a case from the case base in order to solve the problem If we have many cases then the chance is higher to find one with a suitable solution Because the given problem is usually not exactly in the base one wants to retrieve a case which solved a problem which is „similar enough to be useful“ Hence, the notion of similarity is central to CBR The concept of similarity based retrieval is compared with data base retrieval

16 Components of CBR In order to solve problems one needs knowledge.
Where is it located: In knowledge containers. Solution trans- formation Case base Similarity measure Vocabulary Storage Compilation Cases have not to be understood in order to be stored Data Information Knowledge A task of knowledge management is the maintenance of the containers.

17 The Classical CBR Algorithm
This cycle shows the main activities in CBR Retrieve Reuse Revise Retain Case Base Knowledge New Retrieved Solved Learned Tested/ Repaired Suggested Solution Problem Confirmed Learning Adaptation Similarity Verification Retrieve: Determine most similar case(s). Reuse: Solve the new problem re-using information and knowledge in the retrieved case(s). Revise: Evaluate the applicability of the proposed solution in the real-world. Retain: Update case base with new learned case for future problem solving.

18 Typical Problems Handled with CBR: Classification and Diagnosis
A class is a certain subset of some universe and a classification assigns to each element one or more classes to which it belongs. In fault diagnosis the classification is only the first step: Observations diagnosis repair classification Domain rules Diagnosis occurs frequently in after sales support

19 An Example Overview Typical Scenario: Call Center
Technical Diagnosis of Car Faults: symptoms are observed (e.g., engine doesn’t start) and values are measured (e.g., battery voltage = 6.3V) goal: Find the cause for the failure (e.g., battery empty) and a repair strategy (e.g., charge battery) Case-Based Diagnosis: a case describes a diagnostic situation and contains: description of the symptoms description of the failure and the cause description of a repair strategy store a collection of cases in a case base find case similar to current problem and reuse repair strategy

20 A Simple Example (II) What does a Case Look Like?
A case describes one particular diagnostic situation A case records several features and their specific values occurred in that situation  A case is not a ( general) rule !! Feature Value Problem (Symptoms) Problem: Front light doesn’t work Car: VW Golf IV, 1.6 l Year: 1998 Battery voltage: 13,6 V State of lights: OK State of light switch: OK Solution Diagnosis: Front light fuse defect Repair: Replace front light fuse C A S E 1

21 A Case Base With Two Cases
Problem (Symptoms) Problem: Front light doesn’t work Car: VW Golf III, 1.6 l Year: 1996 Battery voltage: 13,6 V State of lights: OK State of light switch: OK Solution Diagnosis: Front light fuse defect Repair: Replace front light fuse C A S E 1 Each case describes one particular situation All cases are independent of each other Problem (Symptoms) Problem: Front light doesn’t work Car: Audi A4 Year: 1997 Battery voltage: 12,9 V State of lights: surface damaged State of light switch: OK Solution Diagnosis: Bulb defect Repair: Replace front light C A S E 2

22 Solving a New Diagnostic Problem
A new problem has to be solved We make several observations in the current situation Observations define a new problem Not all feature values have to be known Note: The new problem is a “case” without solution part Feature Value Problem (Symptom): Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12.6 V State of Lights: Surface damaged State of light switch: OK

23 You are required to identify between case 1 and case 2 the case that is most similar to to the problem case Compare the New Problem with Each Case and Select the Most Similar Case : C A S E x Similar? New Problem When are two cases similar? How to rank the cases according to their similarity?  Similarity is the most important concept in CBR !! We can assess similarity based on the similarity of each feature Similarity of each feature depends on the feature value. BUT: Importance of different features may be different

24 Class Exercise Which case is most similar to the problem case?
Case 1 (Symptoms) Problem: Front light doesn’t work Car: VW Golf III, 1.6 l Year: 1996 Battery voltage: 13,6 V State of lights: OK State of light switch: OK Solution Diagnosis: Front light fuse defect Repair: Replace front light fuse Case 2 (Symptoms) Car: Audi A4 Year: 1997 Battery voltage: 12,9 V State of lights: surface damaged Diagnosis: Bulb defect Repair: Replace front light New Problem Case Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12.6 V State of Lights: Surface damaged State of light switch: OK Which case is most similar to the problem case?

25 A similarity algorithm
Not similar Very similar Assignment of similarities for features values. Express degree of similarity by a real number between 0 and 1 Examples: Feature: Problem Feature: Battery voltage (similarity depends on the difference) Different features have different importance (weights)! High importance: Problem, Battery voltage, State of light, ... Low importance: Car, Year, ... 0.8 Front light doesn’t work Break light doesn’t work 0.4 Front light doesn’t work Engine doesn’t start 0.9 12.6 V 13.6 V 0.1 12.6 V 6.7 V

26 Compare Similarity Similarity computation by weighted average
Problem (Symptom) Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12.6 V State of lights: OK Problem (Symptoms) Problem: Front light doesn’t work Car: Audi A4 Year: 1997 Battery voltage: 12.9 V State of lights: surface damaged State of light switch: OK Solution Diagnosis: Front light fuse defect Repair: Replace front light fuse 0.8 0.8 0.4 0.95 Very important feature: weight = 6 Less important feature: weight = 1 Similarity computation by weighted average similarity(new,case 2) = 1/20 * [ 6* * * * *0 ] = 0.585 Case 1 is more similar: due to feature “State of lights”

27 Compare Similarity Similarity computation by weighted average
Problem (Symptom) Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12.6 V State of lights: OK Problem (Symptoms) Problem: Front light doesn’t work Car: VW Golf III, 1.6 l Year: 1996 Battery voltage: 13.6 V State of lights: OK State of light switch: OK Solution Diagnosis: Front light fuse defect Repair: Replace front light fuse 0.8 0.4 0.6 0.9 1.0 Very important feature: weight = 6 Less important feature: weight = 1 Similarity computation by weighted average similarity(new,case 1) = 1/20 * [ 6* * * * * 1.0 ] = 0.86

28 Case adaption algorithm
Problem (Symptoms): Problem: Front light doesn’t work ... Solution: Diagnosis: Front light fuse defect Repair: Replace front light fuse Adapt Solution: How do differences in the problem affect the solution? Problem (Symptom): Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12,6 V State of light: OK New Solution: Diagnosis: Break light fuse defect Repair: Replace break light fuse

29 New case inserted into the case library ??
If diagnosis is correct: Store new case in the memory. Problem (Symptoms): Problem: Break light doesn’t work Car: Audi 80 Year: 1989 Battery voltage: 12.6 V State of lights: OK State of light switch: OK Solution: Diagnosis: break light fuse defect Repair: replace break light fuse C A S E 3

30 The Classical CBR R4-Cycle
This cycle shows the main activities in CBR [from: Aamodt & Plaza, 1994] Retrieve Reuse Revise Retain Case Base Knowledge New Retrieved Solved Learned Tested/ Repaired Suggested Solution Problem Confirmed Learning Adaptation Similarity Verification Retrieve: Determine most similar case(s). Reuse: Solve the new problem re-using information and knowledge in the retrieved case(s). Revise: Evaluate the applicability of the proposed solution in the real-world. Retain: Update case base with new learned case for future problem solving.

31 Retrieve: Modeling Similarity
The similarity based retrieval realizes an inexact match which is still useful: Useful solutions from a case base Useful products from a product base Different approaches depending on case representation Similarity measures: Are functions to compare two cases sim: Case x Case ® [0..1] Local similarity measure: similarity on feature level Global similarity measure: similarity on case or object level

32 Similarities (1) Similarities are described by measures with numerical values They operate on problem descriptions, demands, products ,... Intention: The more similar two problem descriptions C and D are, the more useful it is two use one of the solutions also for the other problem. The more similar a demand and a product are the more useful is the product for satisfying the demand.

33 Similarities and Inexact Reasoning
The similarity measure controls the utility when inexact solutions are employed or the desired product is not exactly as desired available.

34 A Typical Similarity Measure
Given two problem descriptions C1, C2 p attributes y1, ..., yp used for the representation simj : similarity for attribute yj (local measure) wj : describes the relevance of attribute j for the problem

35 Nearest Neighbor Problem: Should a person be granted a load or not (Ian Watson Slide) Depends on Monthly income and loan amount. The loan decisions will be clustered

36 Retrieval: Finding The Nearest Neighbor
For a new problem C the nearest neighbor in the case base is the case (D,L) for which problem D has the greatest similarity to C. Its solution L is intended to be most useful and is then the best solution the case base can offer (or best available product). Classical databases use always total similarity (i.e. equality). The access to data in databases is in similarity based systems replaced by the search for the nearest neighbor. It can be regarded as an optimization process. This requires more effort but can be much more useful.

37 Thresholds The nearest neighbor (in the given case base) is not always sufficient for providing an acceptable solution. On the other hand, a case which is not the nearest neighbor may be sufficient enough. For this purpose one can introduce two thresholds a and b, 0 < a < b < 1 with the intention If sim(newproblem, caseproblem) < a then the case is not accepted; If sim(newproblem, caseproblem) > b then the case is accepted. This partitions this case base (for the actual problem into three parts: accepted cases, unaccepted cases and an uncertainty set. The same works for product bases.

38 Retrieve: Efficiency Issues
Efficient case retrieval is essential for large case bases and large product spaces. Different approaches depending on the representation complexity of similarity computation size of the base Organization of the base: Linear lists, only for small bases Index structures for large bases, e.g., kd-trees, How to store cases or products: Databases: for large bases or if shared with other applications Main memory: for small bases, not shared

39 Reuse: How to Adapt the Solution
No modification of the solution: just copy. Manual/interactive solution adaptation by the user. Automatic solution adaptation : Transformational Analogy: transformation of the solution Rules or operators to adjust solution w.r.t. differences in the problems Knowledge required about the impact of differences Compositional adaptation: combine several cases to a single solution

40 Summary CBR is a technique for solving problems based on experience
CBR problem solving involves four phases: Retrieve, Reuse, Revise, Retain CBR systems store knowledge in four containers: Vocabulary, Case Base, Similarity Concept, Solution Adaptation Large variety of techniques for: representing the knowledge, in particular, the cases realizing the different phases CBR has several advantages over traditional KBS The basic techniques of CBR can be extended to the needs of E-Commerce. Some Slides adapted from: Dr. Michael Richter and Dr. Ralph Bergman, University of Kaiserslautern and University of Calgary AI Resources

41 Table 1 (Adapted from [Abr, Jac] and [Neg])
Table 1 (Adapted from [Abr, Jac] and [Neg]). A comparison of the utility of case based reasoning systems (CBR), rule induction systems (RI), neural networks (NN) genetic algorithms (GA) and fuzzy systems (FS), with 1 representing low and 4 representing a high utility. CBR (Experience) KBS NN GA FL Know. rep. 3 4 1 2 Approximation (exact matching vs approx matching) Adaptable Learnable Interpretable Learns from scratch

42 Case Based Reasoning Algorithm
Retrieve Reuse Revise Retain Case Base Knowledge New Retrieved Solved Learned Tested/ Repaired Suggested Solution Problem Confirmed Learning Adaptation Similarity Verification

43 Case Based Forecasting

44 Case Base in Java


Download ppt "Case-based Reasoning A type of analogical reasoning"

Similar presentations


Ads by Google