Delfi 5.1 uci + polyglot crashes when out of the book

Discussions about Winboard/Xboard. News about engines or programs to use with these GUIs (e.g. tournament managers or adapters) belong in this sub forum.

Moderator: Andres Valverde

Delfi 5.1 uci + polyglot crashes when out of the book

Postby Marc Moisan » 09 Jun 2007, 21:04

Does anyone knows how to solves this?:

Code: Select all
POLYGLOT *** START ***
POLYGLOT INI file "delfi_51.ini"
POLYGLOT Dir "C:\Marco\Delfi 5.1"
POLYGLOT Command "Delfi.exe"
> ENGINE uci
< ENGINE ; Delfi 5.1 - Winboard/UCI chess engine
< ENGINE id name Delfi 5.1
< ENGINE id author Fabio Cavicchio
< ENGINE option name Hash type spin default 4 min 4 max 64
< ENGINE option name Elo type spin default 2600 min 1000 max 2600
< ENGINE uciok
> ENGINE setoption name Hash value 32
> ENGINE isready
< ENGINE readyok
< XBOARD xboard
< XBOARD protover 2
> XBOARD feature done=0
> XBOARD feature analyze=1
> XBOARD feature colors=0
> XBOARD feature draw=1
> XBOARD feature ics=1
> XBOARD feature myname="Delfi 5.1"
> XBOARD feature name=1
> XBOARD feature pause=0
> XBOARD feature ping=1
> XBOARD feature playother=1
> XBOARD feature reuse=1
> XBOARD feature san=0
> XBOARD feature setboard=1
> XBOARD feature sigint=0
> XBOARD feature sigterm=0
> XBOARD feature time=1
> XBOARD feature usermove=1
> XBOARD feature variants="normal"
> XBOARD feature done=1
< XBOARD accepted done
< XBOARD accepted analyze
< XBOARD accepted colors
< XBOARD accepted draw
< XBOARD accepted ics
< XBOARD accepted myname
< XBOARD accepted name
< XBOARD accepted pause
< XBOARD accepted ping
< XBOARD accepted playother
< XBOARD accepted reuse
< XBOARD accepted san
< XBOARD accepted setboard
< XBOARD accepted sigint
< XBOARD accepted sigterm
< XBOARD accepted time
< XBOARD accepted usermove
< XBOARD accepted variants
< XBOARD accepted done
< XBOARD new
POLYGLOT NEW GAME
POLYGLOT WAIT
> ENGINE ucinewgame
< XBOARD random
< XBOARD ics -
< XBOARD level 40 2 0
< XBOARD post
< XBOARD hard
POLYGLOT WAIT
< XBOARD easy
POLYGLOT WAIT
< XBOARD ping 1
> XBOARD pong 1
< XBOARD name Marc
< XBOARD time 12000
< XBOARD otim 12000
< XBOARD usermove f2f4
POLYGLOT MOVE f4
POLYGLOT WAIT -> THINK
POLYGLOT *BOOK MOVE*
> XBOARD move g8f6
POLYGLOT MOVE Nf6
POLYGLOT THINK -> WAIT
< XBOARD time 11995
< XBOARD otim 11714
< XBOARD usermove g1h3
POLYGLOT MOVE Nh3
POLYGLOT WAIT -> THINK
POLYGLOT START SEARCH
POLYGLOT FEN rnbqkb1r/pppppppp/5n2/8/5P2/7N/PPPPP1PP/RNBQKB1R b KQkq - 2 2
> ENGINE position startpos moves f2f4 g8f6 g1h3
> ENGINE go wtime 117140 btime 119950 movestogo 39
< ENGINE info depth 2 score cp 45 time 0 nodes 72 pv b8c6 b1c3
> XBOARD 2 +45 0 72 Nc6 Nc3
< ENGINE info depth 3 score cp 69 time 0 nodes 208 pv b8c6 b1c3 d7d5
> XBOARD 3 +69 0 208 Nc6 Nc3 d5
< ENGINE info depth 4 score cp 58 time 0 nodes 597 pv b8c6 b1c3 d7d5 h3g5
> XBOARD 4 +58 0 597 Nc6 Nc3 d5 Ng5
< ENGINE info depth 5 score cp 78 time 0 nodes 1967 pv b8c6 b1c3 d7d5 e2e3 c8h3 g2h3
> XBOARD 5 +78 0 1967 Nc6 Nc3 d5 e3 Bxh3 gxh3
< ENGINE info depth 6 score cp 72 time 20 nodes 8680 pv b8c6 b1c3 d7d5 h3g5 e7e5 f4e5 c6e5
> XBOARD 6 +72 2 8680 Nc6 Nc3 d5 Ng5 e5 fxe5 Nxe5
< ENGINE info depth 7 score cp 78 time 50 nodes 16077 pv b8c6 b1c3 d7d5 h3g5 h7h6 g5f3 c8f5
> XBOARD 7 +78 5 16077 Nc6 Nc3 d5 Ng5 h6 Nf3 Bf5
< ENGINE info depth 8 score cp 73 time 210 nodes 59782 pv b8c6 b1c3 d7d5 h3g5 c8f5 e2e3 e7e5 f1b5
> XBOARD 8 +73 21 59782 Nc6 Nc3 d5 Ng5 Bf5 e3 e5 Bb5
< ENGINE info depth 9 score cp 81 time 460 nodes 134115 pv b8c6 b1c3 d7d5 h3f2 d5d4 c3e4 e7e5 f4e5 c6e5
> XBOARD 9 +81 46 134115 Nc6 Nc3 d5 Nf2 d4 Nce4 e5 fxe5 Nxe5
< ENGINE info depth 10 score cp 72 time 981 nodes 339093 pv b8c6 b1c3 d7d5 h3f2 d5d4 c3e4 c8f5 e4f6 e7f6 e2e4 d4e3 d2e3
> XBOARD 10 +72 98 339093 Nc6 Nc3 d5 Nf2 d4 Nce4 Bf5 Nxf6+ exf6 e4 dxe3 dxe3
< ENGINE info depth 11 score cp 83 time 2673 nodes 959912 pv b8c6 b1c3 d7d5 h3g5 d5d4 c3e4 c8g4 e4f2 g4h5 f2d3 e7e6
> XBOARD 11 +83 267 959912 Nc6 Nc3 d5 Ng5 d4 Nce4 Bg4 Nf2 Bh5 Nd3 e6
< ENGINE bestmove b8c6 pondermove b1c3
parse_bestmove(): not a move "b8c6 pondermove b1c3"
POLYGLOT *** QUIT ***
> ENGINE quit
< ENGINE EOF
Marc Moisan
 
Posts: 15
Joined: 28 Aug 2005, 03:57

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Roger Brown » 09 Jun 2007, 22:47

Marc Moisan wrote:Does anyone knows how to solves this?:



Hello Marc,

I assume that if your are using a UCI enabled engine with Polyglot that you are using it in a Winboard type gui.

However, Delfi is both UCI and Winboard protocol enabled so you do not need an adapter to use it as a Winboard engine.

I do not experience this crashing phenomenon in Winboard.

I recognise that this may not address your particular concern but then again, I am a devotee of Alexander's solution for the Gordian knot problem.

:-)

Later.
Roger Brown
 
Posts: 346
Joined: 24 Sep 2004, 12:31

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Marc Moisan » 09 Jun 2007, 23:23

I set up Delfi as UCI because I want to use a own-made polyglot book in winboardx. I usually use Delfi as a winboard engine without problems. I'll try bookthinker I guess.
Marc Moisan
 
Posts: 15
Joined: 28 Aug 2005, 03:57

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Roger Brown » 11 Jun 2007, 15:45

Hello Marc,

Unfortunately I can confirm this behaviour in Delfi.

:-(


Used as a UCI engine, once out of book it crashes.

The offending section seems to be here:

> XBOARD 12 -6 5076 12023010 d5 Nbd2 Nc6 e3 Bd6 Bd3 O-O O-O c4 Bc2 Bd7 Qe2
< ENGINE bestmove d7d5 pondermove b1d2
parse_bestmove(): not a move "d7d5 pondermove b1d2"
POLYGLOT *** QUIT ***

> ENGINE quit
< ENGINE EOF



It will take a guru to figure out where the problem lies.

Later.
Roger Brown
 
Posts: 346
Joined: 24 Sep 2004, 12:31

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Sven Schüle » 11 Jun 2007, 22:41

Hi,

although I'm neither guru nor UCI expert, after reading the polyglot source and the UCI protocol I'm pretty sure that this is both an engine bug and a polyglot "feature". The engine should send "bestmove xxxx ponder yyyy", not "bestmove xxxx pondermove yyyy", if I understand UCI correctly.

The polyglot parser seems not to understand the keyword "pondermove", so that the string "xxxx pondermove yyyy" instead of only "xxxx" becomes subject of further parsing of the best move, which in turn leads to the observed problem (the blank after "xxxx" is unexpected for polyglot when looking for a possible promotion piece character).

Some other guys more familiar with UCI may comment whether it is standard behaviour of polyglot to terminate with a fatal error when detecting a UCI protocol error of one engine.

Sven
User avatar
Sven Schüle
 
Posts: 240
Joined: 26 Sep 2004, 20:19
Location: Berlin, Germany

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Guenther Simon » 11 Jun 2007, 23:55

Sven Schüle wrote:Hi,

although I'm neither guru nor UCI expert, after reading the polyglot source and the UCI protocol I'm pretty sure that this is both an engine bug and a polyglot "feature". The engine should send "bestmove xxxx ponder yyyy", not "bestmove xxxx pondermove yyyy", if I understand UCI correctly.

The polyglot parser seems not to understand the keyword "pondermove", so that the string "xxxx pondermove yyyy" instead of only "xxxx" becomes subject of further parsing of the best move, which in turn leads to the observed problem (the blank after "xxxx" is unexpected for polyglot when looking for a possible promotion piece character).

Some other guys more familiar with UCI may comment whether it is standard behaviour of polyglot to terminate with a fatal error when detecting a UCI protocol error of one engine.

Sven


Yes I believe you are right, that Delfi sends the wrong command,
which breaks the Polyglot parser rules.
OTH it is easy to fix with Inbetween of course as long as Fabio
hasn't fixed it. Just translate 'pondermove' to 'ponder' in the
according section of Inbetween.
The behaviour from Polyglot is correct IMO as it is not intended
to forgive any UCI protocol errors and Fabien already told so lots
of times.


Code: Select all
[InBetween]
CommandLine := Delfi_51

[Server2Client]
pondermove := ponder


Regards,
Guenther
User avatar
Guenther Simon
 
Posts: 794
Joined: 26 Sep 2004, 19:49
Location: Regensburg, Germany

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Marc Moisan » 12 Jun 2007, 04:39

Guenther Simon wrote:
Sven Schüle wrote:Hi,

although I'm neither guru nor UCI expert, after reading the polyglot source and the UCI protocol I'm pretty sure that this is both an engine bug and a polyglot "feature". The engine should send "bestmove xxxx ponder yyyy", not "bestmove xxxx pondermove yyyy", if I understand UCI correctly.

The polyglot parser seems not to understand the keyword "pondermove", so that the string "xxxx pondermove yyyy" instead of only "xxxx" becomes subject of further parsing of the best move, which in turn leads to the observed problem (the blank after "xxxx" is unexpected for polyglot when looking for a possible promotion piece character).

Some other guys more familiar with UCI may comment whether it is standard behaviour of polyglot to terminate with a fatal error when detecting a UCI protocol error of one engine.

Sven


Yes I believe you are right, that Delfi sends the wrong command,
which breaks the Polyglot parser rules.
OTH it is easy to fix with Inbetween of course as long as Fabio
hasn't fixed it. Just translate 'pondermove' to 'ponder' in the
according section of Inbetween.
The behaviour from Polyglot is correct IMO as it is not intended
to forgive any UCI protocol errors and Fabien already told so lots
of times.


Code: Select all
[InBetween]
CommandLine := Delfi_51

[Server2Client]
pondermove := ponder


Regards,
Guenther


Thank you Guenther,

It works like a charm. I finally had decided to use wb2uci + polyglot (to keep the same book for all the engines - I'm not sure how would Bookthinker's Makebook optimize the book), but your solution make more sense.
Marc Moisan
 
Posts: 15
Joined: 28 Aug 2005, 03:57

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Roger Brown » 12 Jun 2007, 14:27

Guenther Simon wrote:
Yes I believe you are right, that Delfi sends the wrong command,
which breaks the Polyglot parser rules.
OTH it is easy to fix with Inbetween of course as long as Fabio
hasn't fixed it. Just translate 'pondermove' to 'ponder' in the
according section of Inbetween.
The behaviour from Polyglot is correct IMO as it is not intended
to forgive any UCI protocol errors and Fabien already told so lots
of times.


Code: Select all
[InBetween]
CommandLine := Delfi_51

[Server2Client]
pondermove := ponder


Regards,
Guenther





Hello Guenther,

GURU.

:-)

Is there anything WB/UCI related you don't know?

Later.
Roger Brown
 
Posts: 346
Joined: 24 Sep 2004, 12:31

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Sven Schüle » 12 Jun 2007, 21:56

Sven Schüle wrote:The engine should send "bestmove xxxx ponder yyyy", not "bestmove xxxx pondermove yyyy"

Guenther Simon wrote:Yes I believe you are right [...]
Code: Select all
pondermove := ponder

Marc Moisan wrote:Thank you Guenther,

It works like a charm.

Roger Brown wrote:Hello Guenther,

GURU.

:-)

Is there anything WB/UCI related you don't know?

Later.

Interesting to learn how people think a GURU solves a problem ;-) ;-) ;-)

Sven
User avatar
Sven Schüle
 
Posts: 240
Joined: 26 Sep 2004, 20:19
Location: Berlin, Germany

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Jaap Weidemann » 15 Jun 2007, 00:59

Hi,

Perhaps this solution is cleaner?

Jaap
Jaap Weidemann
 
Posts: 18
Joined: 11 Aug 2006, 21:34
Location: Stellenbosch, South Africa

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Guenther Simon » 15 Jun 2007, 11:39

Jaap Weidemann wrote:Hi,

Perhaps this solution is cleaner?

Jaap


I forgot that the source code for Delfi is available too meanwhile
and it is an easy thing to fix there, but you sure have seen this
at Delfis site?

Code: Select all
LICENSE
The source code of Delfi is copyrighted, the license agreement allows you to:


Study the source code. If you are an expert chess programmer you may find interesting to compare your solutions with the ones implemented in Delfi.


Modify and recompile the source code, for personal use. Any recompiled version of Delfi must be kept private, it cannot be redistributed or used in public tournaments.


Regards,
Guenther
User avatar
Guenther Simon
 
Posts: 794
Joined: 26 Sep 2004, 19:49
Location: Regensburg, Germany

Re: Delfi 5.1 uci + polyglot crashes when out of the book

Postby Jaap Weidemann » 15 Jun 2007, 12:38

Hi Guenther,

Thank you for the pointing this out. Fortunately I did not recompile the source code, it is merely a modified version of the binary that is included in the source code distribution. If it offends Fabio in any way I will remove it.

Jaap
Jaap Weidemann
 
Posts: 18
Joined: 11 Aug 2006, 21:34
Location: Stellenbosch, South Africa


Return to Winboard and related Topics

Who is online

Users browsing this forum: No registered users and 19 guests