Mar 13, 2019

[Info] Still around

So fiveish years later, I'm still around and still answering questions from time to time. I've updated the contact email to one that I actually use, so feel free to get in touch.

Lately I've started working on a new engine. The main and basically only difference is that it's using bitboards (still Java though). It has one simple goal, to be stronger than Mediocre (shouldn't be too hard right?).

I'll let you know when it's ready to let loose on the world.

Dec 17, 2013

[Info] Mediocre in ChessGUI

Since Jim Ablett closed down his site there've been quite a few mails from people unable to run Mediocre. Again, I'm not planning on doing executables of Mediocre, it's a Java engine.

But here is a repost of a comment just posted by Norbert Leisner regarding running Mediocre in ChessGUI:
Mediocre Chess Java from http://sourceforge.net/projects/mediocrechess/files/mediocrechess/

can be easily embedded into ChessGUI / BigLion-Interface
http://biglion.bplaced.net/

Engines/Install Engine > select UCI1 + Java > and under "browse for engine file"= location where executable .jar file (660 KB) exists after extraction of .zip-folder - confirm the entry with "save engine option"

No extra batch-file is required, but the menu item UCI 1 + Java must be clicked simultaneously to recognize the .jar-file!
There are also plenty more GUIs out there that can handle Java. It's both a bit sad and surprising that some of the major ones still doesn't...

Sep 6, 2013

[Info] Jim Ablett's page is gone

Sadly Jim Ablett has decided to stop his excellent work with compiling various chess engines. This of course includes Mediocre.

I've never spent much time generating native exceutables of Mediocre and I'm quite sure I won't start now. Mediocre is a Java engine after all, and should probably be run as a Java application. I'm quite aware of the limitations on some UIs (like Chessbase, atleast in the past), but I still see it as a limitation on their side and not mine.

Feel free to ask if you need help getting Mediocre to run as a Java application in whatever UI you use, I'm still around and answering questions. :)

Jul 31, 2012

[Info] Corrupted performance.bin

The previous release included a corrupted performance.bin file. Meaning Mediocre loaded the opening book but didn't play any moves from it.

The reason it was corrupted was me adding it to the filtered resources in my build process. Filters replaces certain strings, e.g. ${version} with a real value (I have a couple of them in my readme.txt for example).

But when you try to filter a binary file, all sorts of weird things happens to it. I.e. not good. :)

I've fixed this and uploaded it to sourceforge (same name and link). So if you haven't downloaded the new version yet, you won't have to do anything.

However if you did download it already, either re-download from the same link, or replace performance.bin with a fresh copy.

The perfomance.bin file can be downloaded separately here.

Jul 30, 2012

[New Version] v0.5 - Futility pruning, revamped evaluation

Changes:
  • Futility pruning working, should give a noticeable strength increase
  • Added tapered eval and some significant changes to evaluation, shouldn't matter to much in terms of strength or style though
  • Major background changes in the build process and so on (now using Maven)

Note: Should be noticable stronger than v0.4, mainly due to futility pruning which is finally working. The revamped evaluation might add some style or strength differences, but nothing to get excited about. Next version I will concentrate on evaluation only, and hopefully get something nice out of it.

Download here

[Info] Found it!

To recap my last post, I found a mystery version of Mediocre called v0.5beta that I'd left undocumented last December.

No sources or clues as to why it was beating v0.4 by a good margin.

After a couple hours of manual digging in the class-files I gave up. But having a terrible cold today I decided to give it another go (what else would you do half-consious in bed than read decompiled java programs? :).

Since the decompiled versions are slightly different on almost every row I tried to rule out parts of the code by testing. Evaluation seemed to be exactly the same as what was left in source (my experimental changes to evaluation).

But the search was still returning a different tree. Having been almost certain the evaluation was the culprit I turned to the search instead.

So taking Matthew's advice from my previous post I took a look at all the lines touching futility pruning, and I found a difference. It was indeed futility being turned off (I had missed a third boolean).

However, this version was still being crushed by both v0.4 and v0.5beta. So I looked through Engine.java line by line, and found another "slight" difference, I had completely turned off LMR.

The second I saw it I remembered I did it to get better lines for the University project I was doing around that time...

Lesson to be learned: If you're going to ruin your code, commit your changes first. :)

Jul 26, 2012

[Info] One of those versions again

I've been working on getting a decent build/release procedure in place and it's coming along nicely. The readme and bat-file and resources and anything you can think of really is now being updated automatically.

Very very convenient.

But when looking in the development directory on my old harddrive I found a version of Mediocre called v0.5beta from December 7 2011. This version is actually crushing v0.4 (or maybe not crushing, but a good 70-80 elo stronger).

Now, the problem is I have no idea what this version contains. I know it uses my new evaluation but any setup I try with that doesn't come close in strength.

I've tried to look at the class-files (with a decompiler) but it's really hard to follow as the decompiler isn't perfect and I can't follow the code line by line.

I refuse to start working on anything before I figure out how I made this version. :) Hopefully I'll figure it out soon.

[Tournament] WBEC-Ridderkerk division 5 results

So the division 5 finals of WBEC-Ridderk finished. Top 7 qualified for division 4, and Mediocre placed in... 7th place. :)

 1: DiscoCheck 3.61-x64      29.5 / 36
 2: iCE 0.2-b1092            26.5 / 36
 3: Atlas 3.20-x64           25.5 / 36
 4: Ifrit m1.8-x64-JA        25.0 / 36
 5: Bearded Neural 44.5-x64  24.5 / 36
 6: TJchess 1.1-x64          23.5 / 36
 7: Mediocre 0.4-JA          22.0 / 36
 8: Sjakk 1.1.9              21.5 / 36
 9: EveAnn 1.67-b11          20.5 / 36
10: Ayito 0.2.994            17.5 / 36
...

Really sad that Leo decided to stop running his tournaments after this edition, but one of my longterm goals have been to get Mediocre up to the fourth division and I guess it happened on the last try. :)

Jul 15, 2012

[Tournament] WBEC-Ridderkerk

Mediocre 4.0 is playing in the fifth division final in WBEC-Ridderkerk, qualifying for the fourth division. Top seven engines qualify and Mediocre is currently in.. seventh place (having played a couple games fewer that the engines in front though).

So fingers crossed, fourth division would be quite neat.

[Plan] Back at it

So new job, new town (Stockholm), new apartment, new ideas.

This time around I'm going to try creating a proper build procedure, running JUnit tests, keeping track of versions and spitting out a fully functional Mediocre in the end.

I've always wanted to do this, but never really found the inspiration to do it right. Especially JUnit tests have been missing. I did a very crude test-class that runs some basics, but it's not automated at all and quite cumbersome.

Also, I got some input from a reader (or whatever I should call it), Zong Li, which I will try out and see if I can improve performance slightly.

And lastly, I'll turn that futility pruning on again. :)

So look forward to some progress again, we'll see where it ends up.

Dec 7, 2011

[Info] Silliness again

I've been writing a paper for an evening course I've been taking, related to chess engine searches.

To get a clean output of the search I had to turn off most of the features, like killer moves, PVS search, aspiration windows etc.

Funny thing, when I was going to turn off the futility pruning, I noticed it was already turned off... :) I apparently accidentally returned false for "use futility pruning" even when it met the requirements.

That means Mediocre v0.4 is playing without it.

I ran a quick 128 game test and turning it on seems to gain some 30-40 elo points in self play. Not too huge, but definitely silly to not have.

I'll be sure to turn it on again in the next release. :)

Nov 29, 2011

[Info] Jim Ablett's compile of Mediocre v0.4

Jim has compiled Mediocre v0.4 and I added it to my sourceforge page.

I haven't had time to test it myself, but previous experience has it that Jim's compiles are far stronger than the Java version, so I'd recommend using that.

Jim's page

Mediocre v0.4 JA compile

Nov 27, 2011

[New Version] v0.4 - Ponder, revamped search, UCI only

Changes:
  • Any hash move used is now verified, this fixes a very rare occurrence of Mediocre crashing
  • The transposition table is now using the full 64 bit zobrist keys
  • The search was completely rewritten, possibly catching some bugs. Should show help quite a bit in playing strength
  • Ponder implemented
  • Removed the dependency of a settings file, things like hash sizes are now done through the UCI protocol
  • Removed the semi-working xboard protocol entirely. Sorry.

Note: This version is notably stronger than version 0.34, mainly due to bugfixes in the search.

Mediocre is as mentioned an UCI only engine from here on. This also means I've removed old settings file, use the UCI settings commands mentioned in the readme file.

Download here

Nov 25, 2011

[Info] Testing results

So some testing to confirm I didn't do anything silly.

M1-1 is a version with 64 bit zobrist keys in the transposition table, removal of the notion of "row" and some evaluation fixes. But without the tapered eval. (see previous posts for more info)

Against the Mediocre v1.0 beta it turned out like this:


Program Elo + - Games Score Av.Op. Draws
1 M1-1 : 2401 6 6 11029 50.4 % 2399 24.5 %
2 M1B : 2399 6 6 11029 49.6 % 2401 24.5 %


So pretty much equal, which is good enough. The worst scenario here would be the beta version being slightly stronger, but that should only be at most with a few elo points.

And against some other engines just to confirm.


Program Elo + - Games Score Av.Op. Draws
1 counter : 2593 15 15 2048 76.4 % 2389 23.4 %
2 M1-1 : 2392 8 8 6154 48.2 % 2405 14.4 %
3 adam : 2337 14 15 2048 42.5 % 2389 9.3 %
4 bikjump : 2294 15 15 2048 36.6 % 2389 10.6 %

Program Elo + - Games Score Av.Op. Draws
1 counter : 2580 14 14 2048 75.1 % 2388 25.4 %
2 M1B : 2390 8 8 5854 47.5 % 2407 15.8 %
3 adam : 2343 14 14 2048 43.7 % 2388 9.3 %
4 bikjump : 2290 16 16 1748 36.4 % 2388 12.1 %

The newer version seems to be holding up.

I'll release a new version with this during the weekend, probably on Sunday.

Then I have a steady foundation to start tackling the evaluation again.

Nov 23, 2011

[Info] So wrong again, but at least closer

So yeah, my imagined strength increase mentioned in the last post was non-existent of course.

But, the tapered eval seems to be holding up as the culprit of my recent failures.

I've tried to zone in on the exact version after Mediocre v1.0 Beta that did the best. With all kinds of combinations with and without 64 bit hash tables, tapered eval and removal of the notion of "row".

The results are... inconclusive.

However, it seems a version with everything except the specific addition of tapered eval seems to be playing at least equal with the beta version. So I think I'll just go with that one. Do a new release (to get a firm base to build from). And then start with my evaluation tampering.

I'll post some testing results in a day or two. (not going to leave any doubt this time)

Nov 18, 2011

[Info] Importance of thorough testing

Lately I've been struggling with one of those "super versions" that seems to beat everything I throw at it.

When I got done with my search improvements I did some really extensive testing against Mediocre v0.34 and concluded the new version to have pretty much exactly 60% win rate against it.

So I tagged that version and called it Mediocre v1.0 beta.

Then I committed three things to the trunk of svn: renaming of row to file, tapered eval and the change from 32 bit to 64 bit keys in the transposition table (along with a sanity check of all tt moves).

I thought I'd tried all of these extensively, scoring more or less equal to v1.0 beta, which I deemed ok since the changes were more or less needed for readability, stability, and future work.

During the passed weeks any change I did, no matter how tiny it seemed, got slaughtered by 1.0 beta. All my evaluation tweaking seemed to give results, but against 1.0 beta it still lost.

Now, the newer (uncommitted) versions had some utility changes that I really wanted to have committed (things like the mirror evaluation test). So I took those changes and added them to the 1.0 beta tag one by one, testing quite extensively between every change.

After I'd moved over all the utility, I thought I might just as well try the three things I'd committed after 1.0 beta. This is how that testing went:

  1. Row to file change: This should just have been a readability change (the usage of "row" had lingered around since the very first version of Mediocre, while the correct terminology is of course "file"). But it turned out while doing this I'd changed the rank, file and distance methods to static (rather than instance methods). This seems to be a very good move since they're called a lot, and suddenly 1.0 beta was playing better, quite a bit better.

  2. 32 to 64 keys and hash move validation: I thought if anything, this would be the culprit since messing around with the transposition tables is very likely to introduce bugs. Now when re-adding it, it seems to give a tiny but noticeable strength increase..

  3. Tapered eval: Horrible horrible reduction in strength. I have no idea how I missed this, but it seems to completely ruin the evaluation. Here's the actual culprit and I'll be much more careful when trying to put it back.


So the moral of the story. Never assume you did enough testing if you see signs that you didn't.

Nov 14, 2011

[Tournament] GECCO - Final results


1 Spike wwbwbw xrtnbd 111==1 5
2 Nightmare wbwbbw ctgsrb 1=1=1= 4.5
3 Tornado bwwbbw bnsdgm 1=0111 4.5
4 Rookie -bwbwb msdbnc 101=01 3.5
5 Baron wbbwwb tgmrsn 0=1=== 3
6 Goldbar wwbbwb dbnctx ==0101 3
7 Deuterium bwbwwb gxrtcs =10010 2.5
8 Mediocre -bw-bb rcbxxt 010010 2
9 Spartacus bwbwbw nmxgdr 001000 1
10 micro-Max bbw-ww sdcmmg 000100 1

Not what I'd hoped for, but with two forfeits I guess that's what I deserve. Atleast Mediocre won the two games it should and played very well against The Baron, while pretty horrible against Tornado.

Next time Mediocre will be in the top half. :)

[Tournament] GECCO - Game 6

Bit unlucky with the pairing and got Tornado here. Mediocre had the bishop pair and felt quite comfortable but underestimated the insanely strong white knight that ultimately lead to an unstoppable pair of passed pawns. Not much to say about this loss, Tornado was just better.

[Tournament] GECCO - Game 5

A second chance against micromax. Started out a bit crazy and then turned in to an endgame where Mediocre had the upper hand from the start.

[Tournament] GECCO - Game 4

Forfeit against micromax... yeah I overslept (and was a bit hungover after a late saturday night...), was connected to the server but for some reason Mediocre couldn't start the game. No idea why.