Incremental Software Engineering

Post on 06-May-2015

353 views 0 download

description

Paul Compton, UNSW, RAISE'13

Transcript of Incremental Software Engineering

Incremental Software Engineering

Paul ComptonSchool of Computer Science and EngineeringThe University of New South Wales, Australia

Knowledge

Can Software Engineering be reduced to Knowledge Engineering?

Knowledge Engineering ??!!**

The problem

• Requirements are never complete Why?• McCarthy’s qualification problem (1977)

– You can never anticipate every situation a robot will have to deal with

• Domain knowledge is never complete– An expert can’t recall every situation related to the context.

• Is knowledge acquisition asymptotic?– Smaller and smaller improvements– At greater and greater cost

96% accurate

99.7% accurate

Neural Net?Support Vector Machine?Decision tree learners?

iLog, Drools?Etc?

Building a classifier

7 rules added 8 rules added

Ripple Down Rules

Ripple-Down Rules Features• Controlled inference

• Cornerstone cases– Any set of cases correctly handled by previously

rules which may fire a new rule being added– Generally, cases for which rules were added

• Monitoring– 85.4% auto-validated

Standard production rules If [condition] then [action-list]Linked production rules If [condition] then [case action-list]

[inference action]else [inference action]

• 7.5 million cases, 6 months, 12 labs, 185 KBs• 85.4% auto-validated (labs range 48% to 96%)• Rules added for 0.3% of the 14.6% manually monitored

General Biochemistry

2003 2004 2005 2006 2007 2008 2010 2011

253 different comments7.3M reports processed

28hrs 8hrs 10hrs 9hrs 12hrs 5hrs 6hrs

Data from Pacific Knowledge Systems

Data from Pacific Knowledge Systems

Data from Pacific Knowledge Systems

Data from Pacific Knowledge Systems

Comparison Data

Rule-building techniques

Time to add rules number of rules Source of the data

Various standard techniquesZacharias - 2008

38 mins per ruleTo

385 mins per rule

126,016(estimate)

64 survey respondents

Ripple Down RulesCompton et al - 2011

78 secs per rule 57,626 Logs from 17 labs

Other applications

Pathology applicationsPacific Knowledge Systems

• Report interpretation• Auditing data entry• Real-time alerts• Risk management

• Data cleansing• Information extraction

– Part of speech– Named entity– Relations

Re-engineering legacy systems

RDR System

Legacy Systeminput output

compare

rules added when necessary

Erudine Pty. Ltd.

What sort of Software Engineering is Possible with Ripple-Down Rules?

output

General RDR

2 3 4 41

input

If A & B THEN X , (RULE 1, ELSE RULE 4) If A & B THEN X UNLESS C THEN nul (rule 4, ELSE rule 1)

If C THEN Y (rule 1, exit)

5

If . . . . . THEN . . (rule 1, exit)If . . . . . THEN . . (rule 1, rule 5) No rule can change an assertion

made by any other rule

Linked production rules If [condition] then [case action-list] [inference action]

else [inference action]

General RDR

output2 3 4 41

input

5

Another knowledge-based

system

If A & B Then X

Some other program

A

other program

All Acyclic Decision Problems

Summary

• The unexpected will always arise.– (but everything was unexpected once)

• Incremental knowledge engineering works• Is incremental software engineering possible?• Can incremental knowledge engineering by used in

software engineering?

THANK YOU