Using RedMixer to Evolve Warriors for Coresize 8000

Evolving nano warriors with RedMixer is easy, basically just run it. Should produce competition-strength nano warriors after a few days and possibly a few tries, the default parameters are the same as I used to get near the top of the SAL Nano Hill. Evolving warriors for larger core sizes becomes progressively more difficult. Core size 800 isn't too difficult to evolve for but the results rank about a third of the way down on the Koenigstuhl tiny hill, OK for evolved without using "tricks" but hardly competition-strength. I had a difficult time getting one even on the bottom of the SAL Tiny Hill. They aren't bad when compared to other evolved warriors so set up my own hills - once upon a time there were evolved-only hills on SourceForge but they disappeared years ago. If coresize 800 isn't hard enough, I started trying for coresize 8000. So far the strongest examples I've come up with score about 100 Wilkies, compared to about 128 for the best RedRace-evolved warriors and about 75 for anything I can write by hand without copying something. Yet 100+ Wilkies is still fairly strong for an evolved warrior so I'll take it.

The main tricks are use a relatively small soup size, and start out with the maxlen parameter set low. Big soups are probably better but take half of forever to clock a few hundred generations. Grids of 15x15 give or take is enough to get started, 225 warriors evolve over 6 times faster than a full 21x77 soup of 1617 warriors. Starting out with maxlen set to 20 or 25 instructions forces simpler algorithms to be found early - once a large convulted form is established it likely won't optimize. Once the battle scores are past the "100 100" tie phase then maxlen can be increased to the usual 100 without getting huge warriors - but the line delete rate should be slightly greater than the insert rate to avoid adding junk just because it can (and it will). Another speed-up trick is use low rounds at first, say 10, then as the soup progresses increase rounds up to 30 or more for accurate battles - if it's going well. With a small soup size if fairly strong (Wilkies 70 or so) code isn't produced in a few hundred generations it's probably not going to. Small soups also tend to weaken after a point due to lack of diversity so stop and check often, and if the results aren't satisfying, start over. Finally, play around with the instruction, mode and modifier weighting (dup strings) and mutation parameters - I can document what I used as a start but they're probably not ideal. Every run is different so it's hard to tell what actual effect a parameter change has unless many runs are performed.

RedMixer isn't as automatic as some evolvers, but what fun is that! Rather it takes effort and patience to find good evolving parameters, and in its own way, skill. It's more than just running a program and out spits warriors. To recognize good warriors while in the RedMixer program, add a directory for the Wilkies test set or another set of benchmark warriors for the test function, and use the run function to see how the warrior looks in pmarsv. The TEST benchmarking program is useful for testing the whole soup against a particular benchmark - including a hill to target (use the battle-self option for more realistic scores). The batch files I use to run the hills might be useful for predicting warrior performance, use HILLREP.BAS after running the hill batch to chart which warriors each warrior is strong and weak against.

Ok here's the warriors...


Warrior BOOM.RED

;redcode-94
;name Boom!
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K8 4/15/09
;origin 14_05.red
;parents 07_01.red 08_02.red -> 08_01.red
;generation 696
;assert CORESIZE==8000
mov.ab # 0 , * 1
div.ab @ 0 , * 0
spl.i # 1391 , { 1
mov.i } 4796 , } -1
djn.x $ -1 , } -2
div.b $ 6 , # 3
dat.ba # 2 , { 2125
seq.i > 6 , < 2969
mov.i < 3 , * -2
jmn.ba < 8 , # 5369
mov.i } 6114 , > 3802
end 2
;species 01_11

Opponent Scores Results Performance of Boom!
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 49 676 8 217 25 **
nobody special 36 681 1 216 33 *
Paperone 36 681 1 216 33 *
Marcia Trionfal 12 729 1 240 9
Blue Funk 3 192 414 16 90 144 **********
Cannonade 289 349 59 79 112 ***************
Tornado 489 261 163 87 0 **************************
Fire Storm v1.1 496 244 162 78 10 **************************
Rave 224 524 74 174 2 ***********
Iron Gate 331 418 110 139 1 *****************
Porch Swing 471 273 155 89 6 *************************
Thermite 1.0 384 360 126 118 6 ********************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 100.3

Opponent Scores Results Performance of Boom!
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 135 495 5 125 120 *******
Newt 161 488 20 129 101 ********
The Fugitive 4 742 0 246 4
unrequited love 21 714 2 233 15 *
Blur 2 165 576 52 189 9 ********
He Scans Alone 320 395 95 120 35 *****************
Electric Head 228 462 56 134 60 ************
Jack in the box 17 728 4 241 5
Scan Man 613 136 204 45 1 ********************************
Stepping Stone 382 352 122 112 16 ********************
Torch t18 347 380 108 119 23 ******************
obvious to thos 80 653 21 212 17 ****
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 82.4


Warrior SOMEKIND.RED

;redcode-94
;name Some kind of rocky thing
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K8 4/15/09
;origin 14_05.red
;parents 03_14.red 02_15.red -> 04_14.red
;generation 703
;assert CORESIZE==8000
mov.a # 0 , > 0
spl.f # 1391 , { 1
mov.i } 5462 , } -1
djn.x $ -1 , } -2
mov.x > 6347 , { 7
sne.i $ 6007 , # 4447
djn.f < 4 , * -2
spl.f * 7192 , @ 4749
sne.f * -2 , @ -1
jmn.a > -1 , $ 5
end 1
;species 12_10

Opponent Scores Results Performance of Some kind of rocky thing
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 56 668 10 214 26 **
nobody special 25 700 0 225 25 *
Paperone 23 704 0 227 23 *
Marcia Trionfal 48 654 0 202 48 **
Blue Funk 3 185 425 15 95 140 *********
Cannonade 269 347 45 71 134 **************
Tornado 472 277 157 92 1 *************************
Fire Storm v1.1 483 261 159 85 6 *************************
Rave 271 478 90 159 1 **************
Iron Gate 349 400 116 133 1 ******************
Porch Swing 543 198 178 63 9 ****************************
Thermite 1.0 411 327 133 105 12 *********************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 104.5

Opponent Scores Results Performance of Some kind of rocky thing
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 103 559 5 157 88 *****
Newt 132 516 10 138 102 *******
The Fugitive 88 583 3 168 79 ****
unrequited love 25 709 3 231 16 *
Blur 2 123 627 41 209 0 ******
He Scans Alone 402 294 116 80 54 *********************
Electric Head 226 466 56 136 58 ************
Jack in the box 67 637 7 197 46 ***
Scan Man 428 317 141 104 5 **********************
Stepping Stone 441 297 143 95 12 ***********************
Torch t18 250 457 69 138 43 *************
obvious to thos 89 644 24 209 17 ****
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 79.1


Warrior CRUNCH.RED

;redcode-94
;name Crunch!
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K5(20) 4/12/09
;origin 08_09.red
;parents 03_10.red 02_10.red -> 04_10.red
;generation 445
;assert CORESIZE==8000
spl.f # 0 , } 1730
mov.i } 0 , } 245
mov.i @ -2 , > -1
djn.x * 2 , < 3
div.x @ -1 , * 2736
spl.f @ -3 , < 6812
seq.f # -2 , @ 5315
djn.i # 1 , < 1
mod.i < 2 , > -3
mov.x # -8 , { 6627
sne.i > 0 , { 6527
end 0
;species 11_15
;wins 2
;score 182

Opponent Scores Results Performance of Crunch!
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 61 637 3 195 52 ***
nobody special 57 636 0 193 57 ***
Paperone 63 636 4 195 51 ***
Marcia Trionfal 50 653 1 202 47 **
Blue Funk 3 206 494 52 148 50 **********
Cannonade 195 408 16 87 147 **********
Tornado 456 294 152 98 0 ************************
Fire Storm v1.1 473 269 155 87 8 *************************
Rave 102 648 34 216 0 *****
Iron Gate 132 615 43 204 3 *******
Porch Swing 458 287 151 94 5 ************************
Thermite 1.0 267 444 76 135 39 **************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 84

Opponent Scores Results Performance of Crunch!
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 101 572 8 165 77 *****
Newt 153 522 26 149 75 ********
The Fugitive 84 585 1 168 81 ****
unrequited love 52 646 0 198 52 **
Blur 2 116 620 34 202 14 ******
He Scans Alone 162 585 53 194 3 ********
Electric Head 99 645 31 213 6 *****
Jack in the box 29 698 2 225 23 *
Scan Man 262 451 75 138 37 *************
Stepping Stone 366 381 121 126 3 *******************
Torch t18 190 544 58 176 16 **********
obvious to thos 83 590 2 171 77 ****
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 56.5


Warrior BANG.RED

;redcode-94
;name Bang!
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K7 4/14/09
;origin 03_05.red
;parents 04_02.red 03_02.red -> 03_03.red
;generation 395
;assert CORESIZE==8000
div.ab { 2707 , @ 3667
mov.ab { 315 , # 0
mul.x @ 5391 , * 0
jmz.a # 1 , $ 0
spl.i $ 3782 , $ 1
spl.ab $ 5175 , { 2
spl.f # 2 , } 1
mov.i } 531 , { 7927
mov.i * 6 , { -6
djn.f @ -4 , { -7
seq.i # 6 , # -7
end 5
;species 03_05
;wins 10
;score 202

Opponent Scores Results Performance of Bang!
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 66 618 0 184 66 ***
nobody special 56 641 1 196 53 **
Paperone 63 627 1 189 60 ***
Marcia Trionfal 31 688 0 219 31 *
Blue Funk 3 127 529 11 145 94 ******
Cannonade 136 505 9 132 109 *******
Tornado 444 306 148 102 0 ***********************
Fire Storm v1.1 459 282 150 91 9 ************************
Rave 73 676 24 225 1 ***
Iron Gate 90 660 30 220 0 ****
Porch Swing 336 408 110 134 6 *****************
Thermite 1.0 275 443 81 137 32 **************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 71.8

Opponent Scores Results Performance of Bang!
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 97 556 0 153 97 *****
Newt 94 586 8 172 70 *****
The Fugitive 44 671 3 212 35 **
unrequited love 64 634 4 194 52 ***
Blur 2 132 612 42 202 6 *******
He Scans Alone 55 694 18 231 1 **
Electric Head 119 629 39 209 2 ******
Jack in the box 33 696 4 225 21 *
Scan Man 276 444 82 138 30 **************
Stepping Stone 376 370 124 122 4 ********************
Torch t18 236 494 72 158 20 ************
obvious to thos 63 657 11 209 30 ***
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 52.9


Warrior POOF.RED

;redcode-94
;name Poof!
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K5 4/12/09
;origin 08_09.red
;parents 09_03.red 08_03.red -> 10_03.red
;generation 311
;assert CORESIZE==8000
spl.f # 0 , } 1731
mov.i } 0 , } 244
mov.i $ -3 , > -12
djn.x * -2 , < 4917
div.a $ 1798 , > 3
spl.ba > -5 , { 3991
spl.ba > -6 , { 3991
dat.x # -4 , { 0
div.ba * -4 , { 140
end 0
;species 14_13
;wins 2
;score 165

Opponent Scores Results Performance of Poof!
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 80 590 0 170 80 ****
nobody special 65 620 0 185 65 ***
Paperone 43 664 0 207 43 **
Marcia Trionfal 38 674 0 212 38 **
Blue Funk 3 226 517 73 170 7 ************
Cannonade 266 428 70 124 56 **************
Tornado 423 327 141 109 0 **********************
Fire Storm v1.1 325 424 108 141 1 *****************
Rave 117 633 39 211 0 ******
Iron Gate 156 594 52 198 0 ********
Porch Swing 348 402 116 134 0 ******************
Thermite 1.0 295 445 95 145 10 ***************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 79.4

Opponent Scores Results Performance of Poof!
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 87 594 6 175 69 ****
Newt 66 651 11 206 33 ***
The Fugitive 51 648 0 199 51 **
unrequited love 60 636 2 194 54 ***
Blur 2 145 595 45 195 10 *******
He Scans Alone 133 616 44 205 1 *******
Electric Head 179 566 58 187 5 *********
Jack in the box 38 683 3 218 29 **
Scan Man 355 373 111 117 22 ******************
Stepping Stone 328 418 108 138 4 *****************
Torch t18 240 495 75 160 15 ************
obvious to thos 71 614 2 183 65 ***
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 58.4


Warrior PALLENS.RED

;redcode-94
;name Pallens Calx
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K9 (4/24/09)
;origin 07_07.red
;parents 06_08.red 05_08.red -> 06_09.red
;generation 949
;assert CORESIZE==8000
spl.ba # 2 , $ -4
mov.i } 2692 , { 7906
mov.i { 0 , < 3
djn.ab $ -2 , $ 2
spl.b { 1396 , @ 381
spl.b $ 1397 , @ 5867
end 0
;species 02_02

Opponent Scores Results Performance of Pallens Calx
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 41 668 0 209 41 **
nobody special 23 704 0 227 23 *
Paperone 40 670 0 210 40 **
Marcia Trionfal 13 727 1 239 10
Blue Funk 3 105 573 11 167 72 *****
Cannonade 118 574 20 172 58 ******
Tornado 382 367 127 122 1 ********************
Fire Storm v1.1 429 318 142 105 3 **********************
Rave 199 547 65 181 4 **********
Iron Gate 170 578 56 192 2 *********
Porch Swing 277 442 82 137 31 **************
Thermite 1.0 367 355 113 109 28 *******************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 72.1

Opponent Scores Results Performance of Pallens Calx
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 99 552 0 151 99 *****
Newt 86 617 13 190 47 ****
The Fugitive 41 671 1 211 38 **
unrequited love 25 703 1 227 22 *
Blur 2 159 588 52 195 3 ********
He Scans Alone 198 552 66 184 0 **********
Electric Head 354 378 112 120 18 ******************
Jack in the box 19 727 5 241 4 *
Scan Man 509 230 166 73 11 ***************************
Stepping Stone 446 293 145 94 11 ***********************
Torch t18 318 396 94 120 36 ****************
obvious to thos 32 704 6 230 14 *
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 76.2

Here are the INI files used to make these, at least in the final stages. In the initial stages rounds were typically set to 10 and maxlen set to 20 or 25 until working code was produced. If reusing edit as needed (soup name, bench directory, pmars[v] names etc). Extra commented instruction strings removed, and commented out the listprog lines which I have set to use list rather than RedMixer's internal file pager.

These settings were used to make Crunch!... (similar settings with fewer rounds used for Poof!)


; This is the settings file for RedMixer 1.0d
; Modified 4/12/09 for evolving warriors for coresize 8000.
; pmars parameters...
pmars pmars ;path\name of pmars binary
coresize 8000 ;size of core
processes 8000 ;how many processes are allowed
cycles 80000 ;how many cycles to run per round
rounds 20 ;how many rounds to run per battle
maxlen 100 ;maximum warrior length
doublefixed no ;if yes then do double-fixed battles
; file/start parameters...
soupdir SOUP8KS ;name of directory to put warriors in
deletefile DeleteMe ;name of file to delete to stop
tempbase rmtemp ;base name for temp files
redcodeline redcode-94 ;redcode comment line
authorline anonymous ;author comment line
versionline RedMixer 1.0d-8K5(20) ;strategy Evolved by line (use to track parms)
minstartsize 1 ;minimum instructions for new warriors
testnew no ;if yes test new warriors
testwarrior test.red ;name of warrior to test new warriors against
mintestscore 150 ;minimum score to pass the new warrior
; soup/display/benchmark parameters...
xsize 10 ;number of warriors in X-dimension
ysize 10 ;number of warriors in Y-dimension
displaysoup yes ;if yes then show the soup and user interface
colormethod 2 ;0=color by size 1=by origin 2=by species
colorshift 0 ;to offset colors if needed
textcolor 2 ;color used for border and stat text
pmarsv pmarsv ;path\name of pmarsv program
vparms -v 014 ;rounds and display parms for pmarsv
;listprog list ;path\name of external list program
benchdir WILKIES ;directory containing test warriors
benchrounds 100 ;number of rounds for benchmark battles
benchfixed yes ;if yes then use fixed sequence for benchmark
benchprog ;path\name of external benchmark program
; redcode strings... maintain field structure...
; extended '94... (but no nop or pspace)
instructions spl spl spl spl mov mov mov mov
instructions mov dat dat djn djn jmp jmn jmz
instructions slt sne seq add sub mul div mod
modifiers i i i i f f x x a b ab ba
adrAmodes # $ @ < > * { }
adrBmodes # $ @ < > * { }
; mutation parameters...
deletechance .007 ;chance of deleting a line
insertchance .005 ;chance of inserting a line
duplinechance .1 ;chance of inserted line being previous
instchance .01 ;chance of changing an instruction
modchance .02 ;chance of changing a modifier
modeAchance .02 ;chance of changing A-field mode
dataAchance .04 ;chance of changing A-field data
dataAincdec .4 ;chance of inc/dec A-field data
dataAsmall .6 ;chance of using small A-field number
modeBchance .02 ;chance of changing B-field mode
dataBchance .04 ;chance of changing B-field data
dataBincdec .4 ;chance of inc/dec B-field data
dataBsmall .6 ;chance of using small B-field number
endchance .1 ;chance of changing end number
endincdec .5 ;chance of inc/dec end number
end0chance .1 ;chance of using end 0
; crossover/species parameters...
crossmode 1 ;0=none 1=species 2=origin 3=size 4=any
attraction yes ;if yes pick surrounding mate with most wins
flipstart .7 ;chance of starting with winning warrior
flipitemchance .01 ;chance of flipping per item
fliplinechance .1 ;chance of flipping per line
randomspecies yes ;if yes then use random numbers for species tag
randomtagrange 20 ;range of each number in random species tags
specieschanges 4 ;percent instruction changes for same species
; end of parameters

These settings were used to make Bang!...


; This is the settings file for RedMixer 1.0d
; Modified 4/13/09 for evolving warriors for coresize 8000.
; pmars parameters...
pmars pmars ;path\name of pmars binary
coresize 8000 ;size of core
processes 8000 ;how many processes are allowed
cycles 80000 ;how many cycles to run per round
rounds 20 ;how many rounds to run per battle
maxlen 100 ;maximum warrior length
doublefixed no ;if yes then do double-fixed battles
; file/start parameters...
soupdir SOUP8KS2 ;name of directory to put warriors in
deletefile DeleteMe ;name of file to delete to stop
tempbase rmtemp ;base name for temp files
redcodeline redcode-94 ;redcode comment line
authorline anonymous ;author comment line
versionline RedMixer 1.0d-8K7 ;strategy Evolved by line (use to track parms)
minstartsize 1 ;minimum instructions for new warriors
testnew no ;if yes test new warriors
testwarrior test.red ;name of warrior to test new warriors against
mintestscore 150 ;minimum score to pass the new warrior
; soup/display/benchmark parameters...
xsize 20 ;number of warriors in X-dimension
ysize 10 ;number of warriors in Y-dimension
displaysoup yes ;if yes then show the soup and user interface
colormethod 2 ;0=color by size 1=by origin 2=by species
colorshift 0 ;to offset colors if needed
textcolor 2 ;color used for border and stat text
pmarsv pmarsv ;path\name of pmarsv program
vparms -v 014 ;rounds and display parms for pmarsv
;listprog list ;path\name of external list program
benchdir WILKIES ;directory containing test warriors
benchrounds 100 ;number of rounds for benchmark battles
benchfixed yes ;if yes then use fixed sequence for benchmark
benchprog ;path\name of external benchmark program
; redcode strings... maintain field structure...
; extended '94... (but no nop or pspace)
instructions spl spl spl spl mov mov mov mov
instructions mov dat dat djn djn jmp jmn jmz
instructions slt sne seq add sub mul div mod
modifiers i i i i f f x x a b ab ba
adrAmodes # $ @ < > * { }
adrBmodes # $ @ < > * { }
; mutation parameters...
deletechance .007 ;chance of deleting a line
insertchance .005 ;chance of inserting a line
duplinechance .1 ;chance of inserted line being previous
instchance .01 ;chance of changing an instruction
modchance .02 ;chance of changing a modifier
modeAchance .02 ;chance of changing A-field mode
dataAchance .04 ;chance of changing A-field data
dataAincdec .4 ;chance of inc/dec A-field data
dataAsmall .6 ;chance of using small A-field number
modeBchance .02 ;chance of changing B-field mode
dataBchance .04 ;chance of changing B-field data
dataBincdec .4 ;chance of inc/dec B-field data
dataBsmall .6 ;chance of using small B-field number
endchance .1 ;chance of changing end number
endincdec .5 ;chance of inc/dec end number
end0chance .1 ;chance of using end 0
; crossover/species parameters...
crossmode 1 ;0=none 1=species 2=origin 3=size 4=any
attraction yes ;if yes pick surrounding mate with most wins
flipstart .7 ;chance of starting with winning warrior
flipitemchance .01 ;chance of flipping per item
fliplinechance .1 ;chance of flipping per line
randomspecies yes ;if yes then use random numbers for species tag
randomtagrange 20 ;range of each number in random species tags
specieschanges 4 ;percent instruction changes for same species
; end of parameters

These settings were used to make Boom! and Some kind of rocky thing...


; This is the settings file for RedMixer 1.0d
; Modified 4/14/09 for evolving warriors for coresize 8000.
; pmars parameters...
pmars pmars ;path\name of pmars binary
coresize 8000 ;size of core
processes 8000 ;how many processes are allowed
cycles 80000 ;how many cycles to run per round
rounds 10 ;how many rounds to run per battle
maxlen 100 ;maximum warrior length
doublefixed no ;if yes then do double-fixed battles
; file/start parameters...
soupdir SOUP8KS2 ;name of directory to put warriors in
deletefile DeleteMe ;name of file to delete to stop
tempbase rmtemp ;base name for temp files
redcodeline redcode-94 ;redcode comment line
authorline anonymous ;author comment line
versionline RedMixer 1.0d-8K8 ;strategy Evolved by line (use to track parms)
minstartsize 1 ;minimum instructions for new warriors
testnew no ;if yes test new warriors
testwarrior test.red ;name of warrior to test new warriors against
mintestscore 150 ;minimum score to pass the new warrior
; soup/display/benchmark parameters...
xsize 15 ;number of warriors in X-dimension
ysize 15 ;number of warriors in Y-dimension
displaysoup yes ;if yes then show the soup and user interface
colormethod 2 ;0=color by size 1=by origin 2=by species
colorshift 0 ;to offset colors if needed
textcolor 2 ;color used for border and stat text
pmarsv pmarsv ;path\name of pmarsv program
vparms -v 014 ;rounds and display parms for pmarsv
;listprog list ;path\name of external list program
benchdir WILKIES ;directory containing test warriors
benchrounds 100 ;number of rounds for benchmark battles
benchfixed yes ;if yes then use fixed sequence for benchmark
benchprog ;path\name of external benchmark program
; redcode strings... maintain field structure...
; extended '94... (but no nop or pspace)
instructions spl spl spl spl mov mov mov mov
instructions mov dat dat djn djn jmp jmn jmz
instructions slt sne seq add sub mul div mod
modifiers i i i i f f x x a b ab ba
adrAmodes # $ @ < > * { }
adrBmodes # $ @ < > * { }
; mutation parameters...
deletechance .007 ;chance of deleting a line
insertchance .005 ;chance of inserting a line
duplinechance .1 ;chance of inserted line being previous
instchance .007 ;chance of changing an instruction
modchance .015 ;chance of changing a modifier
modeAchance .015 ;chance of changing A-field mode
dataAchance .03 ;chance of changing A-field data
dataAincdec .4 ;chance of inc/dec A-field data
dataAsmall .8 ;chance of using small A-field number
modeBchance .02 ;chance of changing B-field mode
dataBchance .04 ;chance of changing B-field data
dataBincdec .4 ;chance of inc/dec B-field data
dataBsmall .7 ;chance of using small B-field number
endchance .1 ;chance of changing end number
endincdec .5 ;chance of inc/dec end number
end0chance .1 ;chance of using end 0
; crossover/species parameters...
crossmode 1 ;0=none 1=species 2=origin 3=size 4=any
attraction yes ;if yes pick surrounding mate with most wins
flipstart .5 ;chance of starting with winning warrior
flipitemchance .01 ;chance of flipping per item
fliplinechance .2 ;chance of flipping per line
randomspecies yes ;if yes then use random numbers for species tag
randomtagrange 20 ;range of each number in random species tags
specieschanges 4 ;percent instruction changes for same species
; end of parameters

These settings were used to make Pallens Calx...


; This is the settings file for RedMixer 1.0d
; Modified 4/16/09 for evolving warriors for coresize 8000.
; pmars parameters...
pmars pmars ;path\name of pmars binary
coresize 8000 ;size of core
processes 8000 ;how many processes are allowed
cycles 80000 ;how many cycles to run per round
rounds 20 ;how many rounds to run per battle
maxlen 100 ;maximum warrior length
doublefixed no ;if yes then do double-fixed battles
; file/start parameters...
soupdir SOUP8KS2 ;name of directory to put warriors in
deletefile DeleteMe ;name of file to delete to stop
tempbase rmtemp ;base name for temp files
redcodeline redcode-94 ;redcode comment line
authorline anonymous ;author comment line
versionline RedMixer 1.0d-8K9 ;strategy Evolved by line (use to track parms)
minstartsize 1 ;minimum instructions for new warriors
testnew no ;if yes test new warriors
testwarrior test.red ;name of warrior to test new warriors against
mintestscore 150 ;minimum score to pass the new warrior
; soup/display/benchmark parameters...
xsize 20 ;number of warriors in X-dimension
ysize 20 ;number of warriors in Y-dimension
displaysoup yes ;if yes then show the soup and user interface
colormethod 2 ;0=color by size 1=by origin 2=by species
colorshift 0 ;to offset colors if needed
textcolor 2 ;color used for border and stat text
pmarsv pmarsv ;path\name of pmarsv program
vparms -v 014 ;rounds and display parms for pmarsv
;listprog list ;path\name of external list program
benchdir WILKIES ;directory containing test warriors
benchrounds 100 ;number of rounds for benchmark battles
benchfixed yes ;if yes then use fixed sequence for benchmark
benchprog ;path\name of external benchmark program
; redcode strings... maintain field structure...
instructions spl spl spl mov mov mov
instructions dat djn jmp jmn jmz slt
instructions sne seq add sub mul div mod
modifiers i i i f x a b ab ba
adrAmodes # $ @ < > * { }
adrBmodes # $ @ < > * { }
; mutation parameters...
deletechance .007 ;chance of deleting a line
insertchance .005 ;chance of inserting a line
duplinechance .1 ;chance of inserted line being previous
instchance .01 ;chance of changing an instruction
modchance .015 ;chance of changing a modifier
modeAchance .015 ;chance of changing A-field mode
dataAchance .03 ;chance of changing A-field data
dataAincdec .4 ;chance of inc/dec A-field data
dataAsmall .5 ;chance of using small A-field number
modeBchance .02 ;chance of changing B-field mode
dataBchance .04 ;chance of changing B-field data
dataBincdec .4 ;chance of inc/dec B-field data
dataBsmall .5 ;chance of using small B-field number
endchance .1 ;chance of changing end number
endincdec .5 ;chance of inc/dec end number
end0chance .1 ;chance of using end 0
; crossover/species parameters...
crossmode 1 ;0=none 1=species 2=origin 3=size 4=any
attraction yes ;if yes pick surrounding mate with most wins
flipstart .5 ;chance of starting with winning warrior
flipitemchance .01 ;chance of flipping per item
fliplinechance .2 ;chance of flipping per line
randomspecies yes ;if yes then use random numbers for species tag
randomtagrange 20 ;range of each number in random species tags
specieschanges 4 ;percent instruction changes for same species
; end of parameters

This is a work in progress... I feel like the parameters could be much better but other than continuing to experiment I don't know what needs changing and in what direction. Consider these settings only as starting points. Note that if maxlen is set to 100 when starting rather than being reduced, replicators (such as the RepliBombers) can be produced but they're huge and so far not all that strong. [note 6/4/09 - the new version of RedMixer now has a maxpmlen setting to permit setting pmars' length to the normal 100 while setting maxlen to a lower value to limit the size of the evolved warriors without breaking benchmarking or distorting the soup battle results. The new version is compatible with existing INI's and defaults to pmars length = maxlen if maxpmlen is not specified.]

4/29/09 - Update... found coresize 8000 replicator settings that produce stronger and more compact replicators, at least for the current run. It was not necessary to start with a constricted size, but these settings might depend on an initial random form having the right ingredients to seed development. Here's the new redmixer.ini settings...


; This is the settings file for RedMixer 1.0d
; Modified 4/26/09 for evolving warriors for coresize 8000.
; pmars parameters...
pmars pmars ;path\name of pmars binary
coresize 8000 ;size of core
processes 8000 ;how many processes are allowed
cycles 80000 ;how many cycles to run per round
rounds 20 ;how many rounds to run per battle
maxlen 100 ;maximum warrior length
doublefixed no ;if yes then do double-fixed battles
; file/start parameters...
soupdir SOUP8K ;name of directory to put warriors in
deletefile DeleteMe ;name of file to delete to stop
tempbase rmtemp ;base name for temp files
redcodeline redcode-94 ;redcode comment line
authorline anonymous ;author comment line
versionline RedMixer 1.0d-8K13(20) ;strategy Evolved by line (use to track parms)
minstartsize 1 ;minimum instructions for new warriors
testnew no ;if yes test new warriors
testwarrior test.red ;name of warrior to test new warriors against
mintestscore 150 ;minimum score to pass the new warrior
; soup/display/benchmark parameters...
xsize 10 ;for starting
xsize 77 ;number of warriors in X-dimension
ysize 10 ;number of warriors in Y-dimension
displaysoup yes ;if yes then show the soup and user interface
colormethod 2 ;0=color by size 1=by origin 2=by species
colorshift 0 ;to offset colors if needed
textcolor 2 ;color used for border and stat text
pmarsv unix xterm -e pmv8k8k ;path\name of pmarsv program
; modified pmarsv hack for DosEmu...
; /usr/local/bin/pmv8k8k contains...
; #!/bin/bash
; cd /media/ramdisk/work/8k # change to where RedMixer is
; parms=$* # get command line parameters
; parms=${parms//SOUP8K/SOUP8K\/} # must match soup dir name
; pmarsv $parms
; echo "----- press a key -----"
; read -n 1 nothing
; (comment next pmarsv line to enable)
pmarsv pmarsv ;path\name of pmarsv program
vparms -v 014 ;rounds and display parms for pmarsv
;listprog list ;path\name of external list program
benchdir WILKIES ;directory containing test warriors
benchrounds 100 ;number of rounds for benchmark battles
benchfixed yes ;if yes then use fixed sequence for benchmark
benchprog ;path\name of external benchmark program
; redcode strings... maintain field structure...
; another weighting guess...
instructions mov mov mov mov spl spl spl djn djn dat
instructions sne seq slt jmp jmn jmz add sub mul div mod
modifiers i i f x a b ab ba
adrAmodes # $ $ @ < > * { }
adrBmodes # $ $ @ < > * { }
; mutation parameters...
deletechance .008 ;chance of deleting a line
insertchance .006 ;chance of inserting a line
duplinechance .4 ;chance of inserted line being previous
instchance .012 ;chance of changing an instruction
modchance .018 ;chance of changing a modifier
modeAchance .015 ;chance of changing A-field mode
dataAchance .035 ;chance of changing A-field data
dataAincdec .6 ;chance of inc/dec A-field data
dataAsmall .6 ;chance of using small A-field number
modeBchance .015 ;chance of changing B-field mode
dataBchance .035 ;chance of changing B-field data
dataBincdec .4 ;chance of inc/dec B-field data
dataBsmall .4 ;chance of using small B-field number
endchance .05 ;chance of changing end number
endincdec .5 ;chance of inc/dec end number
end0chance .1 ;chance of using end 0
; crossover/species parameters...
crossmode 1 ;0=none 1=species 2=origin 3=size 4=any
attraction yes ;if yes pick surrounding mate with most wins
flipstart .7 ;chance of starting with winning warrior
flipitemchance .01 ;chance of flipping per item
fliplinechance .2 ;chance of flipping per line
randomspecies yes ;if yes then use random numbers for species tag
randomtagrange 20 ;range of each number in random species tags
specieschanges 5 ;percent instruction changes for same species
; end of parameters

This INI file includes a (disabled) version of the hack I use to run a Linux version of pmarsv from RedMixer, much faster than running the 286 dos version of pmarsv. Ignore unless using DosEmu/FreeDos.

Here's a warrior produced after a couple of overnight runs with the above settings...


;redcode-94
;name Infractus Lepus
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K13(20)
;origin 09_75.red
;parents 02_04.red 03_05.red -> 02_05.red (4/28/09)
;generation 282
;assert CORESIZE==8000
spl.b # 0 , < 4014
spl.ab @ 701 , } 5023
mov.i } -2 , } -1
spl.x $ -1 , > 4873
mov.i * 2698 , < 7988
djn.ab $ -3 , $ 4
mov.b } 6911 , # 6168
sne.i < 3 , { 6032
mod.ba < -2 , @ 3
mod.b < -2 , @ 1398
djn.i > 2230 , * 5861
djn.i > 7243 , * 1991
mul.ba $ 0 , $ -8
jmp.i > 5203 , $ 1992
djn.i # 3 , { 1
jmp.i $ 8 , * -3
djn.x < 5693 , } 4563
mov.i { 12 , $ 15
div.i { 10 , # 3
dat.a @ -10 , } -13
djn.i # 1 , $ 4811
end 1
;species 08_06

Opponent Scores Results Performance of Infractus Lepus
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 221 308 0 29 221 ***********
nobody special 219 312 0 31 219 ***********
Paperone 173 407 1 79 170 *********
Marcia Trionfal 143 464 0 107 143 *******
Blue Funk 3 170 479 23 126 101 *********
Cannonade 200 374 8 66 176 **********
Tornado 586 160 194 52 4 *******************************
Fire Storm v1.1 354 378 112 120 18 ******************
Rave 95 647 29 213 8 *****
Iron Gate 114 630 36 208 6 ******
Porch Swing 258 474 80 152 18 *************
Thermite 1.0 193 526 54 165 31 **********
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 90.8

Opponent Scores Results Performance of Infractus Lepus
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 205 361 7 59 184 **********
Newt 189 414 14 89 147 **********
The Fugitive 243 267 1 9 240 ************
unrequited love 212 344 6 50 194 ***********
Blur 2 104 620 26 198 26 *****
He Scans Alone 78 663 23 218 9 ****
Electric Head 181 556 56 181 13 *********
Jack in the box 125 518 6 137 107 ******
Scan Man 107 632 32 207 11 *****
Stepping Stone 199 523 57 165 28 **********
Torch t18 154 574 44 184 22 ********
obvious to thos 209 425 31 103 116 ***********
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 66.8

Evolution was continued for another overnight run with rounds increased to 30 to produce this...


;redcode-94
;name Melior Lepus
;author Terry Newton
;strategy Evolved by RedMixer 1.0d-8K13(30)
;origin 09_75.red
;parents 02_48.red 03_49.red -> 01_49.red (4/29/09)
;generation 333
;assert CORESIZE==8000
spl.b # 0 , $ 0
spl.ba $ 700 , } 569
mov.i } -2 , } -1
spl.ab $ -1 , # 1
mov.i * -5 , < 3
djn.i $ -3 , { 1129
spl.f } -7 , $ 6169
sne.ab # 3610 , @ 7219
djn.a > 5 , * 6619
sub.x } 2150 , < 7851
djn.a $ -8 , < 7584
jmz.i $ -11 , @ 5370
mov.i } 6810 , > 7382
end 0
;species 14_04
;wins 5
;score 179

Opponent Scores Results Performance of Melior Lepus
--------------- --------- ----------- ---------=---------=---------=---------=
TimeScape (1.0) 242 266 0 8 242 ************
nobody special 241 271 1 11 238 ************
Paperone 221 311 1 31 218 ***********
Marcia Trionfal 200 353 1 52 197 **********
Blue Funk 3 196 373 5 64 181 **********
Cannonade 202 364 6 60 184 **********
Tornado 619 124 204 39 7 *********************************
Fire Storm v1.1 333 399 105 127 18 *****************
Rave 81 660 24 217 9 ****
Iron Gate 109 631 33 207 10 *****
Porch Swing 199 538 62 175 13 **********
Thermite 1.0 225 495 65 155 30 ************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 95.6

Opponent Scores Results Performance of Melior Lepus
--------------- --------- ----------- ---------=---------=---------=---------=
Impfinity v4g1 196 361 1 56 193 **********
Newt 178 433 13 98 139 *********
The Fugitive 246 258 0 4 246 *************
unrequited love 220 313 1 32 217 ***********
Blur 2 121 604 32 193 25 ******
He Scans Alone 184 481 33 132 85 *********
Electric Head 269 407 65 111 74 **************
Jack in the box 222 366 20 68 162 ***********
Scan Man 131 596 36 191 23 ******
Stepping Stone 282 447 87 142 21 ***************
Torch t18 164 554 44 174 32 ********
obvious to thos 227 332 12 47 191 ************
--------------- --------- ----------- ---------=---------=---------=---------=
Adjusted Score: 81.3

Another varient from the soup scored slightly higher against benchmarks but chose this one as it was stronger against other evolved warriors. Continuing the run with rounds set to 40...

4/30/09 - well that didn't go so well, with rounds set to 40 rocky things began to appear and the scores got worse. No conclusions can be drawn from a single run but I've noticed this phenomena before - sometimes too accurate of evaluation hurts performance by not permitting slightly weaker members to replicate and potentially grow stronger. Another possibility is the dominant soup form simply reached its maximum likely optimization and the warriors that evolved to counter it happen to be weaker on benchmark tests - this happens all the time. With unguided evolution there is no internal pressure for it to produce warriors that perform well against a particular set of warriors, rather I have to apply the pressure by tinkering with the INI and deciding when to call a run done.

Here's how Infractus Lepus performs on my mixed hill (4/28/09)...


1 184.08 FireHouse by P.Kline
2 168.92 Forked Lite Ning 4.076 by Ansel G. Sermersheim
3 166.96 Maya v1.7 by Christoph C. Birk
4 156.64 Infractus Lepus by Terry Newton
5 155.48 Boom! by Terry Newton
6 155.20 RedPixel.2 by John Lewis
7 154.60 Jolt v0.3 by J.A-Worth
8 152.44 Pallens Calx by Terry Newton
9 143.72 DualScanV3 by Skybuck Flying
10 142.03 Refried RedBeans by Terry Newton
11 141.92 Dev5 by Roy van Rijn
12 141.88 Opti-4 by Terry Newton
13 140.36 NastyBomberV7 by Skybuck Flying
14 140.16 Goin' Mobile by Anonymous
15 139.03 MoreVamp v4 by Franz
16 137.12 Best of the best by Compudemon
17 133.03 SimpleJMNWarriorV2 by Skybuck Flying
18 130.16 Bang! by Terry Newton
19 129.20 Crunch! by Terry Newton
20 126.44 A Mess of Imps by rebs1.4a1-standard
21 126.44 2 by Chris Stubbs
22 124.44 RepliBomber Strain 1B by Terry Newton
23 122.40 Deep Green Sea by Pierre Baillargeon
24 119.96 RepliBomber Strain 1A by Terry Newton
25 115.27 ga_24 by jason

Here's how Melior Lepus performs on my evolved 8000 hill (4/30/09)...


1 158.44 Machines Will Rule by bvowk
2 157.32 redrace x by Dave Hillis
3 155.88 Yak Snout by Dave Hillis
4 149.72 redrace_h1_22 by Dave Hillis
5 149.44 Melior Lepus by Terry Newton
6 147.39 869211-5957-xt430-10-eai3 by bvowk
7 146.88 h1_8 by Dave Hillis
8 146.44 chl_382 by Hillis
9 144.16 x3_1 by Dave Hillis
10 144.03 redrace_7_31_00 (djn-clear) by Dave Hillis
11 132.88 redrace_7_12_00 (paper) by Dave Hillis
12 130.56 Evolver 88x150 by Martin Ankerl
13 127.72 Boom! by Terry Newton
14 121.08 Evolver 1100 by Martin Ankerl
15 112.19 Evolver 1090 by Martin Ankerl
16 112.16 RepliBomber Strain 2B by Terry Newton
17 111.96 RepliBomber Strain 2A by Terry Newton
18 110.00 h1_11 by Dave Hillis
19 109.40 Bang! by Terry Newton
20 108.92 v4_260 by Dave Hillis
21 107.87 Evolver 2283x321 by Martin Ankerl
22 105.80 RepliBomber Strain 1B by Terry Newton
23 103.00 redrace (1/08/01) by Dave Hillis
24 102.88 RepliBomber Strain 1A by Terry Newton
25 099.20 A Mess of Imps by rebs1.4a1-standard

Both of these run with normal 8K settings, 100 rounds per battle fixed sequence.

Performance of these warriors against "real" hills is dismal, scores need to improve by 50 points or more for any chance of being strong enough to compete against good hand-coded warriors and I don't see that happening anytime soon. The very best "pure" evolved warriors for coresize 8000 are in the bottom half of the Koenigstuhl hills, a long way from anything that could remotely be considered "strong". Even warriors from "super-evolvers" that assimilate existing redcode and employ sophisticated code hinting cannot match the best hand-coded warriors, at least when it comes to coresize 8000 (warriors for coresize 80 and 800 are an entirely different story, in those environments evolved warriors can be and are kings of the hills).

I think it is more useful to compare standard-size warriors to members of their own kind, then there can be competition, or if hand-coded warriors are involved then employing a limiting factor such as what I do with the mixed hill - hand-coded warriors can't have a benchmark score greater than the strongest evolved warrior. This is not as unfair to the hand-coded warriors as it might seem from the description - the top evolved warrior on the present mixed hill has a Wilkies score of about 100 yet it's in 5th place, a warrior with a score of 17 is in 7th place, and the top 3 slots are held by hand-coded warriors scoring in the 60's and 70's. The rule certainly makes it easier for the evolved warriors while at the same time not making it too easy - to achieve a lasting KOTH an evolved warrior would probably have to evolve some scanning ability to compete with the hand-coded scanners, which don't have to bench well to do well in a mixed environment. If stronger evolved warriors are added then stronger hand-coded warriors can also be added to keep the balance, however if the hill became too strong it could become a battle between a few exceptionally strong evolved warriors against a lot of lower-scoring but more intelligent hand-coded warriors.

To put this theory to the test I prepared a hill composed of the 25 warriors from the evolved 8000 hill then added warriors from the Wilkies and Wilmoo test sets that scored below 157.8 Wilkies (the score of Machines Will Rule). To fill the remaining slots for an equal number of evolved and hand-coded samples I selected 7 warriors from the Koenigstuhl 94nop hill that ranked just below Machines Will Rule and had a lower Wilkies score. The results are brutal...


1 180.14 Boys are Back in Town 1.1 by Philip Kendall
2 179.72 Dandelion II by Schmidt/Zapf
3 175.14 Ikarus II by Christian Schmidt
4 174.02 Blur 2 by Anton Marsden
5 172.32 Speeed by Christian Schmidt
6 167.14 Mandragora by Christian Schmidt
7 165.10 Iron Gate by Wayne Sheppard
8 164.90 Mooncake by Christian Schmidt
9 164.64 Rave by Stefan Strack
10 164.00 obvious to those who know my son :-) by Robert Macrae
11 163.54 Jack in the box by Beppe Bezzi
12 160.74 Torch t18 by P.Kline
13 156.75 Marcia Trionfale 1.3 by Beppe Bezzi
14 156.56 unrequited love by kafka
15 152.98 devilish 2.02 by David Houston
16 150.64 The Fugitive by David Moore
17 148.96 Machines Will Rule by bvowk
18 147.80 Thermite 1.0 by Robert Macrae
19 147.39 Blue Funk 3 by Steven Morrell
20 146.58 Impfinity v4g1 by Planar
21 146.47 nobody special by Mike Nonemacher
22 143.80 TimeScape (1.0) by J. Pohjalainen
23 140.20 Paperone by Beppe Bezzi
24 137.26 869211-5957-xt430-10-eai3 by bvowk
25 125.54 Cannonade by P.Kline, Paul Kline
26 122.30 redrace x by Dave Hillis
27 117.04 redrace_7_31_00 (djn-clear) by Dave Hillis
28 116.48 Melior Lepus by Terry Newton
29 116.24 Fire Storm v1.1 by W. Mintardjo
30 114.74 redrace_h1_22 by Dave Hillis
31 114.64 Yak Snout by Dave Hillis
32 114.28 x3_1 by Dave Hillis
33 113.91 h1_8 by Dave Hillis
34 111.88 chl_382 by Hillis
35 111.22 v4_260 by Dave Hillis
36 109.40 Evolver 1100 by Martin Ankerl
37 108.59 h1_11 by Dave Hillis
38 107.60 redrace_7_12_00 (paper) by Dave Hillis
39 106.18 Boom! by Terry Newton
40 102.90 Evolver 1090 by Martin Ankerl
41 102.24 Evolver 88x150 by Martin Ankerl
42 093.66 RepliBomber Strain 2B by Terry Newton
43 093.64 RepliBomber Strain 2A by Terry Newton
44 093.10 Tornado by Beppe Bezzi
45 092.22 RepliBomber Strain 1B by Terry Newton
46 091.36 Evolver 2283x321 by Martin Ankerl
47 091.22 RepliBomber Strain 1A by Terry Newton
48 085.92 redrace (1/08/01) by Dave Hillis
49 082.80 Bang! by Terry Newton
50 078.66 A Mess of Imps by rebs1.4a1-standard

Here are the full battle details for this run showing who beat who.

Conclusions so far... evolving effective warriors for coresize 8000 is quite difficult! Even with slanted rules. The "less than" rule only works to even up the competition if other evolved warriors are able to approach the benchmark score of the strongest evolved warrior, to compensate for this if necessary an absolute strength can be imposed on a mixed hill to avoid takeover by humans and the best evolver on the planet... 130 Wilkies would do it. Of course another benchmark set could be used if uniformly applied and scaled appropriately, and this is all highly theoretical.