Yet another on line chess program

Sort:
Avatar of HGMuller
mike_bike_kite wrote:
...
I just tried keeping the best moves at one level and then searching deeper with the best moves. Then repeating this until it runs out of time. I was hoping for a huge jump in strength and sadly it played worse! It was also quite complicated so now I'm faced with either debugging the code, seeing if the idea was flawed or just deleting that section

This is unfortunately quite common in Chess programming: you have a smart idea to improve the play, and it turns out not to work at all.

One problem if you are using alpha-beta pruning is that it tells you what the best move is, but never what the second-best move is. So things like you describe, focusing on a few best moves, is really not possible. Unless you do not use alpha-beta to the full, but that makes searching the non-best moves to get an exact score on them so costly, that the best way to gain is usually swicth to full alpha-beta.

Avatar of themothman

You should create a blog post about your experience programming it.  What shared libraries you used, what you made from scratch.  I'm sure people would find it interesting.

Avatar of mike_bike_kite
themothman wrote:

You should create a blog post about your experience programming it.  What shared libraries you used, what you made from scratch.  I'm sure people would find it interesting.


Shared libraries???? It's all from scratch.

Avatar of mike_bike_kite

Version d9.3
It now tries to push pawns where possible.
It tries to get the king to the centre in end games.
It tries to avoid pawn forks.
Favours centre pawns over outside pawns.

Any points that people have raised have been added to my "to do" list.

Avatar of themothman

I would have no idea how you made it.  Nothing is really from scratch, of course there are shared libraries used, but I guess you are saying nothing chess related.  Maybe there are formats you used that are standard, I have no idea, which is why I said a blog post would be interesting.

Avatar of Link8523

make sure the white parts in the pieces stay white on the dark squares

Avatar of mike_bike_kite

make sure the white parts in the pieces stay white on the dark squares : I've updated the graphics now.

One problem if you are using alpha-beta pruning is that it tells you what the best move is, but never what the second-best move is : alpha beta should return exactly the same set of scores for each move as min max. The only difference is that certain parts of the search tree can now be ignored. Because you have a score for every move it means you can work out the 2nd best, 3rd best etc.

Version 9.4 (sorry for all the new versions)

I fixed some bugs in the evaluation which resulted in it exchanging when behind. I've added some new ideas which make it play better but the style of play is now more "gritty" than the fluid style it used to use - not sure why.  The new version definitely plays stronger but the old style is available on level 5. I's also much better in endgames now - not perfect but better.

Avatar of davidmelbourne

God knows how you program such a thing; enjoyed my (easy) win:))

Avatar of mike_bike_kite

The current version (9.5) is now a much stronger player. You can also alter the appearance of the board and pieces. There are a few move sound affects as well now. Hopefully it will do a bit better against the stronger players who've beaten it while still being fun to play for the rest of us.

 

Chess

Avatar of mike_bike_kite

Oh dear! I did play the new version against the old and it seemed to win easily and take less time while doing it. The default level has changed from 6 to 5 so the new version starts off at a lower level but this wouldn't explain it playing weaker and slower. What level were you playing at? Must admit I'm a bit confused - perhaps it just had an off game? :)

Avatar of mike_bike_kite

I think I found the bug Embarassed

If you get a chance please try it again.

Any comments on the user interface?

Has anyone tried the different boards and pieces? or setting up a position? or just didn't know you could?

Does anyone know any publically available graphics for ultra modern chess pieces? or perhaps you're an artistic type and feeling generous?

Avatar of Kaspa1988

Hey, good work dude, i've been a little into programming, but im certainly not close to where you are!, how did you study programming?, do you use Python or C++? if you need any help i am more than willing to

Avatar of WGMJustinBieber

 

Does anyone know any publically available graphics for ultra modern chess pieces? or perhaps you're an artistic type and feeling generous?

 


Dont know if you can use any of these:

http://www.enpassant.dk/chess/fontimg/utrecht.htm

http://www.enpassant.dk/chess/fontimg/millenia.htm

http://www.enpassant.dk/chess/fontimg/mark.htm

http://www.enpassant.dk/chess/fontimg/line.htm

http://www.enpassant.dk/chess/fontimg/harlequi.htm

Avatar of mike_bike_kite

This computer needs a better opening book. You can tell that from my game against it. I mean a6 after 2.Bg5 doesn't do much at all : It actually has no opening book but I agree with your comment and will try and get it to avoid such moves.

do you use Python or C++ : It's a Java applet which is why it will run in your web browser. Because it is down;loaded with the web page the program needs to be quite compact otherwise it takes too long to download and this is why it has no opening book or end game database.

[Fonts] Dont know if you can use any of these: Certainly can - I'll put them in. Many thanks.

it takes much longer per move than before but still plays weaker : that's depressing - I guess I'll need to play it against itself and just switch out each part of the scoring routines until I find out the bit that's going wrong. Thanks for trying it out again though.

Avatar of mike_bike_kite

New version 9.6 - I've fixed yet more bugs and added more stuff to improve play. I'm currently having issues trying to beat it on level 6 so I have to believe it must be getting stronger. Feedback as always is appreciated. Thanks.

Avatar of PrawnEatsPrawn

Mike,

arrived at the following position, with Black to move (your program), when it just stopped moving:

 

Avatar of mike_bike_kite

much better now : Excellent news!

it played alekhine defence again but lost a piece later to a tactic at level 9 : It has no opening book or end game database as these are too large to load via a web page. But it seems to play ok even without these things. To be fair you two are both a little too strong for my poor little program but it likes a workout.

arrived at the following position, with Black to move (your program), when it just stopped moving: my appologies and, as it's creator, I feel I should at least offer you a draw Wink That position has highlighted a bug in my code. It's also reproducable so I'll have it fixed today.

Can you give me an indication of it's playing strength?

Is there anything obvious it's not taking into account when looking at a position?

Mike

Avatar of mike_bike_kite

it turns out it wasn't a bug but it did take nearly 20 mins to move on my (admitidly old) PC. I know what I have to do to make the program reply with it's "best" move in a given time but the coding for this is quite a big change. Oh well Cry

Avatar of PrawnEatsPrawn

Can you give me an indication of it's playing strength?

 

I've played one and half games against it on level 9 since you started to change this about, so I'm not sure I'm really qualified to say. However, I'll take a guess, around 1600-1700 (FIDE) on level 9 (blitz or rapid time controls).

I think that the program could probably be easily ground down in locked-pawn and quiet positions by positional play. I'd say that playing tactically gives your program the game it is best at.

Avatar of mike_bike_kite

I've just released a new version (10.1) which has better a bit better graphics, more functionality and doesn't make the same mistakes though it still does make a few mistakes. The new search is based on time which I think is better.

I'll be trying to ramp up the strength a bit more next.

New version at the same old web url.