Check out Glinski's Hexagonal Chess, our featured variant for May, 2024.


[ Help | Earliest Comments | Latest Comments ]
[ List All Subjects of Discussion | Create New Subject of Discussion ]
[ List Earliest Comments Only For Pages | Games | Rated Pages | Rated Games | Subjects of Discussion ]

Comments/Ratings for a Single Item

EarliestEarlier Reverse Order LaterLatest
Fairy-Max: an AI for playing user-defined Chess variants. A chess engine configurable for playing a wide variety of chess variants.[All Comments] [Add Comment or Rating]
Aurelian Florea wrote on Thu, Jan 21, 2021 02:51 AM UTC:

@HG, I had asked two questions here, on this thread, earlier. Have you seen them?


Aurelian Florea wrote on Thu, Jan 21, 2021 03:26 AM UTC in reply to Aurelian Florea from 02:51 AM:

Actually I have managed to download it from the winboard forums along with winboard. Still I don't remember what the piece to char table's use is!


💡📝H. G. Muller wrote on Thu, Jan 21, 2021 08:37 AM UTC in reply to Aurelian Florea from 02:51 AM:

Oh sorry, I completely overlooked those questions. The latest version of Fairy-Max and WinBoard now are bundled in the WinBoard-AA package.

The pieceToCharTable is how Fairy-Max instructs WinBoard to map piece IDs on images. Each position in the pieceToChar string corresponds to a certain image, starting with Pawn, Knight, Bishop, Rook, Queen, ... and ending with King. First half for the white images (upper-case IDs), second half for the black (lower-case IDs). For an overview of the available images, look here. Images not needed in the game are indicated by a dot. The others by the ID of the piece they represent (a single letter, or letter plus a single quote or exclamation point, the latter only recommended for use when you run out of letters).

Fairy-Max just sends that string to WinBoard, when the variant it describes gets selected. It doesn't do anything with it itself.

There are some special notations in the pieceToChar WinBoard attaches additional meaning to: ^L , with L some piece ID that was already assigned to some other image means the image is for the promoted version of an L (which, in move and position notations, would be indicated as +L). This is needed mainly in Shogi variants; normally WinBoard assumes that the piece that uses the Pawn image promotes to a piece of your choice on reaching the zone (the depth of which depends on the parent variant and board size)


Aurelian Florea wrote on Thu, Jan 21, 2021 08:50 AM UTC in reply to H. G. Muller from 08:37 AM:

Ok! I got it!


Aurelian Florea wrote on Mon, Jun 7, 2021 03:09 PM UTC:

Can Fairy-Max do games that have pieces starting in other places than the back rank. For example Expanded chess?


💡📝H. G. Muller wrote on Mon, Jun 7, 2021 04:48 PM UTC in reply to Aurelian Florea from 03:09 PM:

Not 'natively'. But it is possible to define a game with an arbitrary setup, and then ask WinBoard to start from another position (e.g. with a -fen option). As long as the number of pieces in the variant does not exceed what Fairy-Max can handle this should be possible.


Aurelian Florea wrote on Mon, Jun 7, 2021 04:55 PM UTC in reply to H. G. Muller from 04:48 PM:

I remember doing this in 2016 with an early apothecary chess.


Aurelian Florea wrote on Tue, Jun 8, 2021 04:54 PM UTC:
HG,

I have added this game:

//Aurelian's test for NmH compared to bishop

Game: TestH1 # PNBRQ.EA.M.......G....pnbrq.ea.m.......g.... # fairy

10x10

12 8 5 9 10 7 3 5 8 11

12 8 6 9 10 7 4 6 8 11

p:100 -16,24 -16,6 -15,5 -17,5

p:100 16,24 16,6 15,5 17,5

k:-1 1,7 16,7 15,7 17,7 -1,7 -16,7 -15,7 -17,7

k:-1 1,7 16,7 15,7 17,7 -1,7 -16,7 -15,7 -17,7

n:259 14,7 31,7 33,7 18,7 -14,7 -31,7 -33,7 -18,7 48,6 -48,6 3,6 -3,6

b:296 15,3 17,3 -15,3 -17,3

Q:851 1,3 16,3 15,3 17,3 -1,3 -16,3 -15,3 -17,3

R:444 1,3 16,3 -1,3 -16,3

G:830 17,1003 15,1F003 -15,1003 -17,1F003 17,10003 -15,FFFF0003 -17,10003 15,FFFF0003

A:875 15,3 17,3 -15,3 -17,3 14,7 31,7 33,7 18,7 -14,7 -31,7 -33,7 -18,7

e:400 15,7 17,7 -15,7 -17,7 30,7 -30,7 34,7 -34,7 48,7 -48,7 3,7 -3,7

M:400 1,7 16,7 -1,7 -16,7 13,7 47,7 49,7 19,7 -13,7 -47,7 -49,7 -19,7

#
# G& FyafsF
# A& BN
# E& FAH
# M& CW

to fairymax.ini.

How do I make Xboard display it?

Aurelian Florea wrote on Wed, Jun 9, 2021 02:21 PM UTC:

HG, I had tried again but have not managed to do it. I don't yet need to set up a machine match, this will come later. I only need to know if fmax can play the game.


Aurelian Florea wrote on Thu, Jun 10, 2021 04:53 PM UTC in reply to Aurelian Florea from Wed Jun 9 02:21 PM:

@HG,

Haven't you seen my comments or was I unclear?


💡📝H. G. Muller wrote on Thu, Jun 10, 2021 05:20 PM UTC:

I had computer trouble, so I had no opportunity to check it out yet.

Fairy-Max does ignore game names that start with a capital. I forgot what was the reason for that (but originally there was one). But when you change the T to t the variant will appear in WinBoard's New Variant menu, from where you can select it. (If you did not put the definition too far down in the fmax.ini file; WinBoard can only display a limited number of engine-defined variants.

You did not specify what piece should be used for K/k in the pieceToChar string. Change it to

PNBRQ.EA.........G......MKpnbrq.ea.........g......mk


Aurelian Florea wrote on Thu, Jun 10, 2021 05:38 PM UTC:

It works, thanks!


Aurelian Florea wrote on Sat, Jun 12, 2021 09:35 AM UTC in reply to H. G. Muller from Thu Jun 10 05:20 PM:

HG,

You have explained to me here :

https://www.chessvariants.com/index/listcomments.php?id=33121

how to set up a machine match to test something. Is this still the way to do it or are there different things now?


💡📝H. G. Muller wrote on Mon, Jun 14, 2021 09:33 PM UTC in reply to Aurelian Florea from Sat Jun 12 09:35 AM:

At the time I wrote that there was a problem with engine-defined variants running in a match that started from an externally set-up position, where the position sent by the engine overruled the position requested by the user. But I think this was fixed in the latest beta version of WinBoard. There it should be possible to run a tournament or match specifying a 'position file' in the Tournament Options dialog, which contains the FEN(s) of the desired start position(s). I hope.


Aurelian Florea wrote on Tue, Jun 15, 2021 04:01 PM UTC in reply to H. G. Muller from Mon Jun 14 09:33 PM:

HG,

For fairy max the promotion zone of the games is still 1 or 3 deep (no 2)?

Later Edit: Is there a way to do castling if the king and rook start on the second to last rank (like in expanded chess say)?

Even Later Edit: How do I tell Winboard that the promotion zone is the last 3 ranks?


Aurelian Florea wrote on Sat, Jun 19, 2021 04:01 PM UTC:

@HG,

I had asked a few questions earlier this week. May you find the time to take a look?


💡📝H. G. Muller wrote on Sun, Jun 20, 2021 09:43 AM UTC in reply to Aurelian Florea from Tue Jun 15 04:01 PM:

Recent versions of Fairy-Max allow the nottation FxR=D in the line of the game definition that sepecifies the board size. The number D after the equal sign specifies the depth of the zone. In case this number is larger than 2 it also assumes that the Pawns start at the foremost rank in the zone. So for Camboian Chess and Makruk the game definitions specify 8x8=3. (A negative number there redefines the Pawn rank without affecting the zone size, and its absolute value then indicates the number of ranks behnd the Pawns. So Grant Acedrex uses 12x12=-3.)

The depth of the promotion zone icannot be independently set in WinBoard, but follows from the parent variant. So you would have to pick a parent variant that has a zone depth of 3, rather than 'fairy' (which has only promotion on the last rank). Variant 'elven' could be good for this.

Castling will be a problem. This is related to the way position setup works in Fairy-Max: it only assumes castling is possible if the piece on which such a move is defined, and the pieces on the edge of the same rank, start in the same location as what was defined as the start position. And in the current version of Fairy-Max start positions can only have pieces on the back rank, plus a single rank of Pawns.


Aurelian Florea wrote on Sun, Jun 20, 2021 11:34 AM UTC in reply to H. G. Muller from 09:43 AM:

Thank you for the info HG!


Aurelian Florea wrote on Sun, Jun 20, 2021 07:30 PM UTC in reply to H. G. Muller from 09:43 AM:

How do I pick a parent variant in winboard? The variants I had defined in Fairy-max.ini have the dimension line set 10x10=3 but whenever promotion occurs winboard gives an error. This was happening actually before my last questions. Do I have to name my variant Elven? Later Edit. I prefer a depth of 2 anyway. So this probably cannot be done! Even later edit: You meant at the end after the piece to char. I figured it know. But this is still for a depth of 3. How do I make a depth of 2?


Aurelian Florea wrote on Sun, Jun 20, 2021 08:20 PM UTC:

Unrelated to my earlier questions: It seems to me that fmax understands the Osprey as n:600 32,1003 32,1F003 -32,1003 -32,1F003 2,10003 2,FFFF0003 -2,10003 -2,FFFF0003 but WinBoard does not understand : DmpafyafsW . Am I correct?


💡📝H. G. Muller wrote on Sun, Jun 20, 2021 09:09 PM UTC in reply to Aurelian Florea from 07:30 PM:

The parent variant is indeed the word on the ' Game:' line after the piece-to-char table. I don't think there are any standard variants with a 2-deep zone, for 8x8 boards or larger. In variant shogi it uses 1/3 of the board height, which works for the 6x6 Judkin's Shogi (which has a zone of 2 ranks).

With legality testing switched off, however, WinBoard would obey the engine when it plays a promotion move. That solves the problem in engine-engine games. In human-engine games it might work when you type moves that should promote, in this case.


💡📝H. G. Muller wrote on Sun, Jun 20, 2021 09:23 PM UTC in reply to Aurelian Florea from 08:20 PM:

I think even pretty old WinBoard versions should understand that Betza string. (But I did not actually try it). Just to be sure, use the version at http://hgm.nubati.net/WinBoard-AA.zip .

The Fairy-Max in that package also has a more user-friendly way to specify bent sliders; you can specify each move also as a triple s1,r,s2 . Where s1 is the initial step (+/-32 or +/-2 for an Osprey), and s2 is the step after the bend (+/-15 or +/-17).  The middle parameter specifies the 'move rights' and should be 3 for a piece that slides and can both capture and non-capture.


Aurelian Florea wrote on Mon, Jun 21, 2021 04:25 AM UTC in reply to H. G. Muller from Sun Jun 20 09:23 PM:

Well, Winboard rejects the Osprey move as illegal, although it represents it correctly for the human player.


Aurelian Florea wrote on Mon, Jun 21, 2021 05:43 AM UTC in reply to H. G. Muller from Sun Jun 20 09:23 PM:

While holding a tournament after a game ends, I keep getting an error saying the system cannot open a certain png file. Why?

How do I label the 2 engines (both fairy-max) so that I can figure out who plays a set of pieces and who plays the other? Something like bishops vs knights.

Edit: I had managed to figure out the firs matter.


💡📝H. G. Muller wrote on Mon, Jun 21, 2021 11:55 AM UTC in reply to Aurelian Florea from 05:43 AM:

First matter is usually because you ask for a save file in a non-existent folder.

You can register Fairy-Max twice (through the Load Engine dialog), specifying different nicknames, and ticking the checkbox to use the nicknames also in the PGN files. What you can also so is start WinBoard with ' additional option' -sameColorGames 100 . This will suppress the color alternation in matches, so that you can configure Fairy-Max with a variant that uses, say, Knights for white and Bishops for black, and just play a match. Then the first number in the match score will be the white Knights.

About the Osprey moves: I think it is not WinBoard that rejects them, but Fairy-Max. The Betza notation is correct, and WinBoard understands it (as the highlighting on user moves shows). But the line you posted for the move definition is not an Osprey. (Not sure what it is, but it doesn't have the correct step after the trajectory turns the corner.) The problem is that you use the notation that specifies a move through 2 numbers (separated by comma), where the second number has to specify both the move rights, and the alteration in step vector. I suspect you started from the Griffon definition, and just changed the vector of the first step. But because the second number encodes the change in step (in a cumbersome way), that implicitly also alters the secondary step.

Recent Fairy-Max versions allow you to specify the secondary step explicitly, rather than as a change of the primary step, by appending the secondary step after an extra comma. For the Osprey this would give a move definition like

2,3,17 2,3,-15 -2,3,15 -2,3,-17 31,3,15 32,3,17 -32,3,-15 -32,3,-17


25 comments displayed

EarliestEarlier Reverse Order LaterLatest

Permalink to the exact comments currently displayed.