ChessUSA.com TalkChess.com
Hosted by Your Move Chess & Games
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

What should I support, UCI or Winboard?
Goto page 1, 2, 3, 4, 5, 6, 7, 8  Next
 
Post new topic       TalkChess.com Forum Index -> Computer Chess Club: General Topics Threaded
View previous topic :: View next topic  
Author Message
Asim Pereira



Joined: 25 Mar 2012
Posts: 31
Location: Bangalore

PostPosted: Sun Apr 22, 2012 5:28 am    Post subject: What should I support, UCI or Winboard? Reply to topic Reply with quote

Hi,

I am planning to include engine support in my Chess apps.
I have never worked on UCI or Winboard protocols before and hence wanted your opinion on what protocol should I support, to begin with.
Which protocol will be easier to work with?

Note I am NOT planning to write my own engine but just provide an interface to existing popular engines.

Regards,
Asim
Back to top
View user's profile Send private message Visit poster's website
Ted Wong



Joined: 01 Nov 2010
Posts: 236

PostPosted: Sun Apr 22, 2012 6:26 am    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

That depends on what engine you want in your Android app?
Back to top
View user's profile Send private message Visit poster's website
Asim Pereira



Joined: 25 Mar 2012
Posts: 31
Location: Bangalore

PostPosted: Sun Apr 22, 2012 7:39 am    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

I am thinking of first getting the protocol right such that I get familiarized with GUI-engine communication.
Then I will use any of the strong engines available in either of the protocols.

Do you think the approach is ok?

As I understand there are strong (and open source) engines in either category.
Back to top
View user's profile Send private message Visit poster's website
H.G.Muller



Joined: 10 Mar 2006
Posts: 12765
Location: Amsterdam

PostPosted: Sun Apr 22, 2012 8:27 am    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

If you support one of the protocols, you could support the other through an adapter. Especially for GUI engines to run UCI engines there are exellent open-source adapters.
Back to top
View user's profile Send private message Visit poster's website
Ted Wong



Joined: 01 Nov 2010
Posts: 236

PostPosted: Sun Apr 22, 2012 9:14 am    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

I don't think it's difficult to support a protocol if you can communicate with an engine. In terms of software engineering, you just need a design pattern where you implement an abstract interface. I've used it, and it's much more flexible than integrating the whole something like UCI2WB into the source. Up to you, I personally prefer an interface with some pure virtual functions.
Back to top
View user's profile Send private message Visit poster's website
H.G.Muller



Joined: 10 Mar 2006
Posts: 12765
Location: Amsterdam

PostPosted: Sun Apr 22, 2012 9:32 am    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

I was not implying the adapters should be integrated in the source. In fact I think that is highly undesirable, because it would deny the user the choice of adapter, and the possibility to adapt it. That I mentioned their open-sourceness was only to indicate they can easily be made available on any platform.

The design with an abstract interface is also my guiding design principle for WinBoard. Except that the abstract interface in that case is identical to WB protocol, as it is the most potent of all protocls. This can then translated to other protocols (or at least the subset supported by those protocols) by adapters, which for flexibility are kept as independent programs, automatically invoked by the GUI.
Back to top
View user's profile Send private message Visit poster's website
Matthias Gemuh



Joined: 09 Mar 2006
Posts: 2876

PostPosted: Sun Apr 22, 2012 3:04 pm    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

On the GUI side, UCI is easy to support, WB is messy.
Look at permitted move formats, for example.
_________________
My engine was quite strong till I added knowledge to it.
http://biglion.bplaced.net
http://w2410tmq9.homepage.t-online.de
Back to top
View user's profile Send private message Visit poster's website
H.G.Muller



Joined: 10 Mar 2006
Posts: 12765
Location: Amsterdam

PostPosted: Sun Apr 22, 2012 6:48 pm    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

Indeed, that it is alowed to send SAN, or that an engine can even request the GUI sends SAN to it, is an abomination. OTOH, a GUI would need to be able to parse and generate PGN, and thus SAN to be any good. Using the routines required for that makes it almost zero work to apply them to the engine communication. So in practice the impact of this is not significant.
Back to top
View user's profile Send private message Visit poster's website
Matthias Gemuh



Joined: 09 Mar 2006
Posts: 2876

PostPosted: Sun Apr 22, 2012 8:14 pm    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

hgm wrote:
Indeed, that it is alowed to send SAN, or that an engine can even request the GUI sends SAN to it, is an abomination. OTOH, a GUI would need to be able to parse and generate PGN, and thus SAN to be any good. Using the routines required for that makes it almost zero work to apply them to the engine communication. So in practice the impact of this is not significant.


Mr Winboard Wink ,

I expected you to defend your protocol !

However, UCI has only one move format, while WB will use combinations of the following scenarios :

- move in SAN format
- move in coordinate format
- move preceded by "usermove"
- move not preceded by "usermove"
- move preceded by "..."
- move not preceded by "..."
- etc.

... and move formats are not the only issue with WB.


UCI is simple.
_________________
My engine was quite strong till I added knowledge to it.
http://biglion.bplaced.net
http://w2410tmq9.homepage.t-online.de
Back to top
View user's profile Send private message Visit poster's website
H.G.Muller



Joined: 10 Mar 2006
Posts: 12765
Location: Amsterdam

PostPosted: Sun Apr 22, 2012 9:10 pm    Post subject: Re: What should I support, UCI or Winboard? Reply to topic Reply with quote

Matthias Gemuh wrote:
I expected you to defend your protocol !


Why? Shocked It did not design most of it, and as a scientist I am usually very objective.

Quote:
However, UCI has only one move format, while WB will use combinations of the following scenarios :

- move in SAN format
- move in coordinate format
- move preceded by "usermove"
- move not preceded by "usermove"
- move preceded by "..."
- move not preceded by "..."
- etc.


Well the "..." are of course an abomination. Actually, I dont think they are really part of WB protocol. They are merely documented tolerance of WinBoard for the non-compliance of GNU Chess. (Some GNU Chess versions, that is. Michel produced a decent one, nothing bad about that!) I would strongly recommend no other GUI implements that, and I am severely tempted to remove it from WinBoard as well. I am strongly against catering to non-compliant engines. (But I am too busy adding things to be bothered with removing things... Wink )

The 'usermove' is a very good feature, and in the Alien Edition it proved essential for letting engines that support a wide variety of games with different move formats reliably generate Illegal-move messages. Unfortunately it was not in the protocol from the beginning. I admit the cost of maintaining backward compatibility can sometimes be high. But that is nothing compared to abandoning it.

Quote:
... and move formats are not the only issue with WB.


You probably know that better than I: I never implemented WB protocol from the GUI side. From browsing through existing WB code, I got the impression that most of the complexity comes from going the extra lightyear to cater to non-compliant engines. I don't really consider that WB protocol, and if I wre to write a GUI from scratch that supported WB protocol, I would certainly not do such things. (E.g. sending 'hard' before 'easy', using 'white' + 'a2a3' to avoid using 'black'.) Basically all the 'idiom' stuff mentioned in the specs is obnoxious, and I would abandon it without hesitation. The 'black' and 'white' commands are superfluous for engines that support 'setboard', and I would never send them to such engines. If there are egines that would not work because of that, it must mean that they implemented other commands in a way that violated the specs, and that would just be to bad for them. Out they go!

Quote:
UCI is simple.


Yeah, micro-Max is simple too. But it plays very poorly... Laughing

Perhaps it would be a good idea to rewrite the protocol specs, and more clearly brand a lot of things that are described there now as "deprecated, please do not use, please do not implement", and leave only a subset of the protocol ('modern WB protocol') that GUIs would have to support to run state-of-the-art engines. E.g. kicking out the 'edit' command, (oops. Fairy-Max uses that...) and require that the engine supports setboard, ping etc.


Last edited by H.G.Muller on Sun Apr 22, 2012 9:21 pm; edited 1 time in total
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic       TalkChess.com Forum Index -> Computer Chess Club: General Topics All times are GMT
Goto page 1, 2, 3, 4, 5, 6, 7, 8  Next
Threaded
Page 1 of 8

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum




Powered by phpBB © 2001, 2005 phpBB Group
Enhanced with Moby Threads