Evolving service logic using natural selection Peter Martin Service Creation using Genetic Programming Evolving service logic using natural selection Peter Martin © 1999 Marconi Communications Limited. All Rights Reserved.
Genetic Programming Evolving computer programs Natural selection Fitness improves survival Genetic inheritance
Steps in Using GP Start Create Population Test for Fitness No End of Run ? Evolve Next Generation No
Creating a population Select suitable functions and data Functional considerations - Sufficiency Problem Specific! Syntactical considerations - Closure All programs must be legal! Example:- Division by zero! Randomly create programs Population size ? Program size ?
Testing for Fitness The Fitness function Execution or Interpretation Fitness is problem specific Each individual is given a score
Evolving Generations Select fittest individuals Fitness proportionate or Tournament selection Use the fittest to create next generation Reproduction operators Mutation Asexual reproduction (copy) Sexual Reproduction (crossover)
Crossover Individual A Individual C Individual B Individual D F1 F2 T1 re 6 T4 F3 T5 T6 Individual A Individual B Parents Crossover point Crossover point A 2 1 B Offspring F3 T5 T6 F1 T1 Individual C A 1 B 2 F2 T2 T3 T4 Individual D A 2
Evolving Generations Start Create Population Test for Fitness Evolve Next Generation No End of Run Yes End
An Example - Service Creation Number Translation Translate number depending on time of day Fitness derived from Message Sequence
Call Sequence for a Service Switch DataBase Logic IDP (CalledDN) DB Request( CalledDN << 1) DBResp (TAD1) DB Request(TAD1 << 1) DBResp (TAD2) Connect(TAD2 << 1) End
The Function Set for Services Building block operations START Database lookup ROUTE String manipulation END
Data Types for Services Telephony services require many data types Telephone numbers Integers Boolean Polymorphic data representation Any variable is composed of sub-variables Each variable has one of each type of sub-variable All programs are legal!
Example Service Logic
The Outcome Service Logic creation successful Great variety of programs Fitness represents testing Fitness is the specification Software Engineering Management issues Specification vs. Coding Other Issues? Any hidden surprises?
Conclusions GP shown to be a powerful technique Novel programs evolved Step towards automatic program generation Shifts focus from HOW to WHAT