version 1.4.56b
[polyglot.git] / polyglot.man
1 .\" Automatically generated by Pod::Man 2.1801 (Pod::Simple 3.05)
2 .\"
3 .\" Standard preamble:
4 .\" ========================================================================
5 .de Sp \" Vertical space (when we can't use .PP)
6 .if t .sp .5v
7 .if n .sp
8 ..
9 .de Vb \" Begin verbatim text
10 .ft CW
11 .nf
12 .ne \\$1
13 ..
14 .de Ve \" End verbatim text
15 .ft R
16 .fi
17 ..
18 .\" Set up some character translations and predefined strings.  \*(-- will
19 .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
20 .\" double quote, and \*(R" will give a right double quote.  \*(C+ will
21 .\" give a nicer C++.  Capital omega is used to do unbreakable dashes and
22 .\" therefore won't be available.  \*(C` and \*(C' expand to `' in nroff,
23 .\" nothing in troff, for use with C<>.
24 .tr \(*W-
25 .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
26 .ie n \{\
27 .    ds -- \(*W-
28 .    ds PI pi
29 .    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
30 .    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch
31 .    ds L" ""
32 .    ds R" ""
33 .    ds C` ""
34 .    ds C' ""
35 'br\}
36 .el\{\
37 .    ds -- \|\(em\|
38 .    ds PI \(*p
39 .    ds L" ``
40 .    ds R" ''
41 'br\}
42 .\"
43 .\" Escape single quotes in literal strings from groff's Unicode transform.
44 .ie \n(.g .ds Aq \(aq
45 .el       .ds Aq '
46 .\"
47 .\" If the F register is turned on, we'll generate index entries on stderr for
48 .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
49 .\" entries marked with X<> in POD.  Of course, you'll have to process the
50 .\" output yourself in some meaningful fashion.
51 .ie \nF \{\
52 .    de IX
53 .    tm Index:\\$1\t\\n%\t"\\$2"
54 ..
55 .    nr % 0
56 .    rr F
57 .\}
58 .el \{\
59 .    de IX
60 ..
61 .\}
62 .\"
63 .\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
64 .\" Fear.  Run.  Save yourself.  No user-serviceable parts.
65 .    \" fudge factors for nroff and troff
66 .if n \{\
67 .    ds #H 0
68 .    ds #V .8m
69 .    ds #F .3m
70 .    ds #[ \f1
71 .    ds #] \fP
72 .\}
73 .if t \{\
74 .    ds #H ((1u-(\\\\n(.fu%2u))*.13m)
75 .    ds #V .6m
76 .    ds #F 0
77 .    ds #[ \&
78 .    ds #] \&
79 .\}
80 .    \" simple accents for nroff and troff
81 .if n \{\
82 .    ds ' \&
83 .    ds ` \&
84 .    ds ^ \&
85 .    ds , \&
86 .    ds ~ ~
87 .    ds /
88 .\}
89 .if t \{\
90 .    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
91 .    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
92 .    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
93 .    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
94 .    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
95 .    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
96 .\}
97 .    \" troff and (daisy-wheel) nroff accents
98 .ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
99 .ds 8 \h'\*(#H'\(*b\h'-\*(#H'
100 .ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
101 .ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
102 .ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
103 .ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
104 .ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
105 .ds ae a\h'-(\w'a'u*4/10)'e
106 .ds Ae A\h'-(\w'A'u*4/10)'E
107 .    \" corrections for vroff
108 .if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
109 .if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
110 .    \" for low resolution devices (crt and lpr)
111 .if \n(.H>23 .if \n(.V>19 \
112 \{\
113 .    ds : e
114 .    ds 8 ss
115 .    ds o a
116 .    ds d- d\h'-1'\(ga
117 .    ds D- D\h'-1'\(hy
118 .    ds th \o'bp'
119 .    ds Th \o'LP'
120 .    ds ae ae
121 .    ds Ae AE
122 .\}
123 .rm #[ #] #H #V #F C
124 .\" ========================================================================
125 .\"
126 .IX Title "POLYGLOT 6"
127 .TH POLYGLOT 6 "2009-11-30" "" ""
128 .\" For nroff, turn off justification.  Always turn off hyphenation; it makes
129 .\" way too many mistakes in technical documents.
130 .if n .ad l
131 .nh
132 .SH "NAME"
133 PolyGlot \-  Winboard protocol to UCI protocol adapter
134          \-  book engine for Polyglot books 
135          \-  a collection of utilities for creating and analyzing opening books
136          \-  a utility for analyzing epd files
137          \-  a perft counter
138 .SH "SYNOPSIS"
139 .IX Header "SYNOPSIS"
140 polyglot [configfile] [\-noini] [\-ec engine] [\-ed enginedirectory] [\-en enginename] [\-log] [\-lf logfile] [\-hash value] [\-bk book] [\-pg <name>=<value>]* [\-uci <name>=<value>]*
141 .PP
142 polyglot make-book [\-pgn inputfile] [\-bin outputfile] [\-max\-ply ply] [\-min\-game games] [\-min\-score score] [\-only\-white] [\-only\-black] [\-uniform]
143 .PP
144 polyglot merge-book \-in1 inputfile1 \-in2 inputfile2 [\-out outputfile]
145 .PP
146 polyglot info-book [\-bin inputfile] [\-exact]
147 .PP
148 polyglot dump-book [\-bin inputfile] \-color color [\-out outputfile]
149 .PP
150 polyglot [configfile] epd-test [engineoptions] [\-epd inputfile] [\-min\-depth depth] [\-max\-depth depth] [\-max\-time time] [\-depth\-delta delta]
151 .PP
152 polyglot perft [\-fen fen] [\-max\-depth depth]
153 .SH "DESCRIPTION"
154 .IX Header "DESCRIPTION"
155 .SS "PolyGlot as adapter and book engine"
156 .IX Subsection "PolyGlot as adapter and book engine"
157 PolyGlot is a \*(L"\s-1UCI\s0 adapter\*(R".  It connects a \s-1GUI\s0 interface (such as
158 XBoard, Winboard, Arena or Chessbase) to a \s-1UCI\s0 chess engine.
159 .PP
160 By specifying an opening book (in PolyGlot book format) chess engines can
161 transparently use such books.
162 .PP
163 PolyGlot understands the two main \s-1GUI\s0 protocols: \s-1UCI\s0 and
164 xboard. Normally the protocol will be auto detected but this can be
165 overridden in the configuration file.
166 .PP
167 In xboard mode PolyGlot fully translates between the xboard and \s-1UCI\s0 protocols.
168 In addition it tries to solve known problems with other adapters.
169 For instance, it detects and reports draws by fifty-move rule,
170 repetition, etc ... It also supports Chess960.
171 .PP
172 When in \s-1UCI\s0 mode PolyGlot mostly passes commands from the \s-1GUI\s0
173 to the engine and vice versa, except that it will play book moves on
174 behalf of the engine when the occasion arises.
175 .PP
176 The engine options are exported as \s-1UCI\s0 options in \s-1UCI\s0
177 mode and as \*(L"feature option=\*(R" commands in xboard mode. The latter form
178 an extension of the xboard protocol as defined by H.G. Muller.
179 .PP
180 Options which normally appear in the [PolyGlot] section of the
181 config file (see below) are exported as options with their name prefixed
182 by \*(L"Polyglot\*(R". This makes it easy to filter them in the \s-1GUI\s0.
183 .PP
184 \&\s-1NOTE:\s0 Not all options are exported, only those that make sense in the
185 given mode.
186 .SS "Book making utilities"
187 .IX Subsection "Book making utilities"
188 PolyGlot supports the \*(L"PolyGlot opening book format\*(R". This is the
189 defacto standard non-proprietary opening book format. It is fully documented
190 here
191 .PP
192 http://alpha.uhasselt.be/Research/Algebra/Toga/book_format.html
193 .PP
194 Roughly speaking a PolyGlot opening book is a collection of triples
195 (position, move, weight). A \*(L"position\*(R" is represented by a 64\-bit
196 Zobrist hash key. The weight is proportional to the probability the move should
197 be played.
198 .PP
199 Other opening book formats such as ChessBase's .ctg format and Arena's
200 \&.abk format are undocumented and proprietary. They can only be used 
201 by their own GUIs.
202 .PP
203 PolyGlot can compile a pgn file into a binary PolyGlot book and furthermore
204 it can merge two such binary books into a third one.
205 .PP
206 PolyGlot can also extract some useful information from PolyGlot books. The utility
207 \&\*(L"dump-book\*(R" dumps the \*(L"lines\*(R" in a book for a given color. By definition
208 a line is a sequence of moves (from the starting position) in which
209 the given color makes only book moves and the other color makes 
210 arbitrary moves (i.e. not necessarily book moves).
211 .PP
212 Since a PolyGlot book is built up from positions and not lines there
213 may be (and there usually are) many positions in the book that are not
214 on a \*(L"line\*(R" as defined in the previous paragraph. It is convenient
215 to call such positions \*(L"isolated\*(R" positions. The utility \*(L"info-book\*(R"
216 counts such isolated positions.
217 .PP
218 Some of the isolated positions are provably unreachable and they
219 could in principle be deleted from the book. For example if a book
220 contains only the move \*(L"e4\*(R" in the starting position but also the
221 position after \*(L"d4 d5\*(R" then this last position is provably unreachable
222 since it requires white to make a non-book move when a book move is
223 available. Such situations arise frequently from the priority rules
224 in merging books.
225 .PP
226 Unfortunately not all isolated positions are provably unreachable and
227 it is difficult to identify the latter. If invoked with \*(L"\-exact\*(R" the
228 utility info-book will attempt to count the isolated positions which
229 require a player to make a non-book move when a book move is available.
230 Due to the possibility of transpositions this is not a fool proof method.
231 .SS "Epd test mode"
232 .IX Subsection "Epd test mode"
233 In epd test mode, PolyGlot will search positions in an epd file and
234 record the number of times the right best move was found.  The
235 arguments specify when to stop the search in any given position.
236 .SS "Perft counts"
237 .IX Subsection "Perft counts"
238 A perft count is the number of legal move sequence in a given position
239 up to a given depth. PolyGlot can perform such perft counts. It
240 is however much slower than other more dedicated programs.
241 .SH "OPTIONS"
242 .IX Header "OPTIONS"
243 When PolyGlot is invoked as an adapter of in epd-test mode it gets its
244 options from a config file and then from the command line.  The
245 default config file is \*(L"polyglot.ini\*(R" but an alternative one may be
246 optionally included as first argument. The config file format is
247 described below.
248 .PP
249 The following engine options may be specified on the command line.
250 .IP "\fB\-noini\fR" 4
251 .IX Item "-noini"
252 Do not use a config file, even if one was specified on the command line.
253 .IP "\fB\-pg\fR" 4
254 .IX Item "-pg"
255 The argument is a string of the form <name>=<value>. This option will
256 set the Polyglot option <name> to <value>.
257 .IP "\fB\-uci\fR" 4
258 .IX Item "-uci"
259 The argument is a string of the form <name>=<value>. This option will
260 set the engine option <name> to <value>.
261 .IP "\fB\-ec\fR" 4
262 .IX Item "-ec"
263 This is an alias for \-pg \*(L"EngineCommand=<value>\*(R"
264 .IP "\fB\-ed\fR" 4
265 .IX Item "-ed"
266 This is an alias for \-pg \*(L"EngineDir=<value>\*(R"
267 .IP "\fB\-en\fR" 4
268 .IX Item "-en"
269 This is an alias for \-pg \*(L"EngineName=<value>\*(R"
270 .IP "\fB\-log\fR (default: false)" 4
271 .IX Item "-log (default: false)"
272 This is an alias for \-pg \*(L"Log=<value>\*(R"
273 .ie n .IP "\fB\-lf\fR (default: ""polyglot.log"")" 4
274 .el .IP "\fB\-lf\fR (default: ``polyglot.log'')" 4
275 .IX Item "-lf (default: polyglot.log)"
276 This is an alias for \-pg \*(L"LogFile=<value>\*(R".
277 .ie n .IP "\fB\-wb\fR (default: ""true"")" 4
278 .el .IP "\fB\-wb\fR (default: ``true'')" 4
279 .IX Item "-wb (default: true)"
280 This is an alias for \-pg \*(L"OnlyWbOptions=<value>\*(R".
281 .PP
282 When invoked as
283 .SS "polyglot make-book"
284 .IX Subsection "polyglot make-book"
285 PolyGlot supports the following options
286 .ie n .IP "\fB\-pgn\fR (default: ""book.pgn"")" 4
287 .el .IP "\fB\-pgn\fR (default: ``book.pgn'')" 4
288 .IX Item "-pgn (default: book.pgn)"
289 Input file in pgn format.
290 .ie n .IP "\fB\-bin\fR (default: ""book.bin"")" 4
291 .el .IP "\fB\-bin\fR (default: ``book.bin'')" 4
292 .IX Item "-bin (default: book.bin)"
293 Output file in PolyGlot format.
294 .IP "\fB\-max\-ply\fR (default: 1024)" 4
295 .IX Item "-max-ply (default: 1024)"
296 Specifies the maximum ply-depth of lines included in the book.
297 .IP "\fB\-min\-game\fR (default: 3)" 4
298 .IX Item "-min-game (default: 3)"
299 Specifies the minimum number of games that have to contain this move for it to be included in the book.
300 .IP "\fB\-min\-score\fR (default: 0.0)" 4
301 .IX Item "-min-score (default: 0.0)"
302 Specifies the minimum score (or weight) this move should have received for 
303 it to  be included in the book. The score is 2*(wins)+(draws), globally scaled
304 to fit into 16 bits.
305 .IP "\fB\-only\-white\fR" 4
306 .IX Item "-only-white"
307 Include only moves for white in the book.
308 .IP "\fB\-only\-black\fR" 4
309 .IX Item "-only-black"
310 Include only moves for black in the book.
311 .IP "\fB\-uniform\fR" 4
312 .IX Item "-uniform"
313 Set all weights to 1. In other words, all moves will be selected with 
314 equal probability.
315 .PP
316 When invoked
317 as
318 .SS "polyglot merge-book"
319 .IX Subsection "polyglot merge-book"
320 PolyGlot supports the following options
321 .IP "\fB\-in1\fR" 4
322 .IX Item "-in1"
323 First input file (in PolyGlot book format).
324 .IP "\fB\-in2\fR" 4
325 .IX Item "-in2"
326 Second input file (in PolyGlot book format).
327 .IP "\fB\-out\fR (default: out.bin)" 4
328 .IX Item "-out (default: out.bin)"
329 Output file (in PolyGlot book format).
330 .PP
331 Input files are not symmetrical, \*(L"in1\*(R" has priority over \*(L"in2\*(R". In other
332 words when a position occurs both in \*(L"in1\*(R" and \*(L"in2\*(R" only the
333 moves and weights from \*(L"in1\*(R" will be retained in \*(L"out\*(R".
334 .PP
335 When invoked
336 as
337 .SS "polyglot dump-book"
338 .IX Subsection "polyglot dump-book"
339 PolyGlot supports the following options
340 .IP "\fB\-bin\fR (default: book.bin)" 4
341 .IX Item "-bin (default: book.bin)"
342 Input file in PolyGlot book format.
343 .IP "\fB\-color\fR" 4
344 .IX Item "-color"
345 The color for whom to generate the lines.
346 .IP "\fB\-out\fR (default: book_<color>.txt)" 4
347 .IX Item "-out (default: book_<color>.txt)"
348 The name of the output file.
349 .PP
350 When invoked
351 as
352 .SS "polyglot info-book"
353 .IX Subsection "polyglot info-book"
354 PolyGlot supports the following options
355 .IP "\fB\-bin\fR (default: book.bin)" 4
356 .IX Item "-bin (default: book.bin)"
357 Input file in PolyGlot book format.
358 .IP "\fB\-exact\fR" 4
359 .IX Item "-exact"
360 Attempt to count the provably unreachable positions among the isolated ones.
361 Note that this takes a very long time.
362 .PP
363 When invoked as
364 .SS "polyglot epd-test"
365 .IX Subsection "polyglot epd-test"
366 (possibly with a config file as first argument) PolyGlot supports
367 besides the generic options described above the following additional
368 options.
369 .IP "\fB\-max\-depth\fR (default: 63)" 4
370 .IX Item "-max-depth (default: 63)"
371 Unconditionally stop the search when this depth has
372 been reached.
373 .IP "\fB\-max\-time\fR (default: 5.0)" 4
374 .IX Item "-max-time (default: 5.0)"
375 Unconditionally stop the seach after this amount of time.
376 .IP "\fB\-depth\-delta\fR (default: 3)" 4
377 .IX Item "-depth-delta (default: 3)"
378 Stop the search if the solution as been found and the best move has
379 been constant for this many depths, on condition that the mininal
380 depth and minimal time have been reached.
381 .IP "\fB\-min\-depth\fR (default: 8)" 4
382 .IX Item "-min-depth (default: 8)"
383 Minimal search depth when the search is stopped using \*(L"\-depth\-delta\*(R".
384 .IP "\fB\-min\-time\fR (default: 1.0)" 4
385 .IX Item "-min-time (default: 1.0)"
386 Minimal search time when the search is stopped using \*(L"\-depth\-delta\*(R".
387 .PP
388 When invoked as
389 .SS "polyglot perft"
390 .IX Subsection "polyglot perft"
391 PolyGlot supports the following
392 options
393 .IP "\fB\-fen\fR (default: starting position)" 4
394 .IX Item "-fen (default: starting position)"
395 Fen at which to start searching.
396 .IP "\fB\-max\-depth\fR (default: 1)" 4
397 .IX Item "-max-depth (default: 1)"
398 Maximum depth to search.
399 .SH "CONFIG FILE FORMAT"
400 .IX Header "CONFIG FILE FORMAT"
401 There should be a different config file for each engine.
402 .PP
403 The config file is in the traditional \s-1INI\s0 format.
404 .PP
405 .Vb 6
406 \&    [PolyGLot]
407 \&    option = value
408 \&    ...
409 \&    [Engine]
410 \&    option = value
411 \&    ...
412 .Ve
413 .PP
414 The characters \*(L"#\*(R" and \*(L";\*(R" serve as comment characters.
415 .PP
416 Initial and final white space is stripped from option names and
417 values. If you need to use characters which have a special meaning to
418 PolyGlot (these are ';#[]=\e') you should quote them by preceding them
419 with '\e'. \*(L"Quoting\*(R" other characters in this way has no effect. In
420 particular the use of '\e' as a path separator in windows should
421 normally not affected.
422 .SS "[PolyGlot] section"
423 .IX Subsection "[PolyGlot] section"
424 This section is used by PolyGlot only.  The engine is unaware of these
425 options.  The list of available options is detailed below.
426 .IP "\fBEngineName\fR (default: \s-1UCI\s0 name)" 4
427 .IX Item "EngineName (default: UCI name)"
428 This is the name that will appear in the \s-1GUI\s0.  It is
429 cosmetic only.  You can use different names for tweaked versions of
430 the same engine.
431 .ie n .IP "\fBEngineDir\fR (default: ""."")" 4
432 .el .IP "\fBEngineDir\fR (default: ``.'')" 4
433 .IX Item "EngineDir (default: .)"
434 Full path of the directory where the engine is installed.  You can use
435 \&\*(L".\*(R" (without the quotes) if you know that PolyGlot will be launched in
436 the engine directory or the engine is in the \*(L"path\*(R" and does not need
437 any data file.
438 .IP "\fBEngineCommand\fR" 4
439 .IX Item "EngineCommand"
440 Put here the name of the engine executable file.  You can also add
441 command-line arguments.  Path searching is used and the current
442 directory will be \*(L"EngineDir\*(R". On Linux the EngineCommand is passed
443 to wordexp so that shell quoting rules and expansions are applied.
444 On Windows the EngineCommand is simply passed to CreateProcess which
445 does its own shell like processing.
446 .ie n .IP "\fBSettingsDir\fR (default: $HOME/.polyglot on Linux; "".\e_PG"" on Windows)" 4
447 .el .IP "\fBSettingsDir\fR (default: \f(CW$HOME\fR/.polyglot on Linux; ``.\e_PG'' on Windows)" 4
448 .IX Item "SettingsDir (default: $HOME/.polyglot on Linux; ._PG on Windows)"
449 The directory where ini files are stored for engines that are started with
450 \&\-noini. Such ini files may be created by pushing the \*(L"Save\*(R" button in the
451 Engine settings dialog in \s-1WB/XB\s0 4.4.0 and higher. As a special exception
452 (for \s-1WB/XB\s0 4.4.0 compatibility) this directory is also used in case
453 PolyGlot is started with config files named \*(L"polyglot_1st.ini\*(R" or
454 \&\*(L"polyglot_2nd.ini\*(R".
455 .IP "\fBLog\fR (default: false)" 4
456 .IX Item "Log (default: false)"
457 Whether PolyGlot should log all transactions with the interface and
458 the engine.  This should be necessary only to locate problems.
459 .IP "\fBLogFile\fR (default: polyglot.log)" 4
460 .IX Item "LogFile (default: polyglot.log)"
461 The name of the log file.  Note that it is put where PolyGlot was
462 launched from, not into the engine directory.
463 .Sp
464 \&\s-1WARNING:\s0 Log files are not cleared between sessions, and can become
465 very large.  It is safe to remove them though.
466 .IP "\fBResign\fR (default: false)" 4
467 .IX Item "Resign (default: false)"
468 Set this to \*(L"true\*(R" if you want PolyGlot to resign on behalf of the
469 engine.
470 .Sp
471 \&\s-1NOTE:\s0 Some engines display buggy scores from time to time although the
472 best move is correct.  Use this option only if you know what you are
473 doing (e.g. you always check the final position of games).
474 .IP "\fBResignMoves\fR (default: 3)" 4
475 .IX Item "ResignMoves (default: 3)"
476 Number of consecutive moves with \*(L"resign\*(R" score (see below) before
477 PolyGlot resigns for the engine.  Positions with only one legal move
478 are ignored.
479 .IP "\fBResignScore\fR (default: 600)" 4
480 .IX Item "ResignScore (default: 600)"
481 This is the score in centipawns that will trigger resign \*(L"counting\*(R".
482 .IP "\fBShowPonder\fR (default: true)" 4
483 .IX Item "ShowPonder (default: true)"
484 Show search information during engine pondering.  Turning this off
485 might be better for interactive use in some interfaces.
486 .IP "\fBScoreWhite\fR (default: true)" 4
487 .IX Item "ScoreWhite (default: true)"
488 Report score from white's point of view in xboard mode.
489 .IP "\fBKibitzMove\fR (default: false)" 4
490 .IX Item "KibitzMove (default: false)"
491 Whether to kibitz when playing a move.
492 .IP "\fBKibitzPV\fR (default: false)" 4
493 .IX Item "KibitzPV (default: false)"
494 Whether to kibitz when the \s-1PV\s0 is changed (new iteration or new best move).
495 .ie n .IP "\fBKibitzCommand\fR (default: ""tellall"")" 4
496 .el .IP "\fBKibitzCommand\fR (default: ``tellall'')" 4
497 .IX Item "KibitzCommand (default: tellall)"
498 xboard command to use for kibitzing, normally \*(L"tellall\*(R" for kibitzing
499 or \*(L"tellothers\*(R" for whispering.
500 .IP "\fBKibitzDelay\fR (default: 5)" 4
501 .IX Item "KibitzDelay (default: 5)"
502 How many seconds to wait before starting kibitzing.  This has an
503 effect only if \*(L"KibitzPV\*(R" is selected, move kibitzes are always sent
504 regardless of the delay.
505 .IP "\fBKibitzInterval\fR (default: 0)" 4
506 .IX Item "KibitzInterval (default: 0)"
507 This is another form of throttling. PolyGlot will usually wait this
508 many seconds before doing the next kibitz.
509 .IP "\fB\s-1UCI\s0\fR (default: false)" 4
510 .IX Item "UCI (default: false)"
511 If true PolyGlot will not understand xboard commands.
512 .IP "\fBMateScore\fR (default: 10000)" 4
513 .IX Item "MateScore (default: 10000)"
514 Mate score reported to \s-1GUI\s0 when in xboard mode.
515 .IP "\fBBook\fR (default: false)" 4
516 .IX Item "Book (default: false)"
517 Indicates whether a PolyGlot book should be used.  This has no effect
518 on the engine own book (which can be controlled with the \s-1UCI\s0 option
519 \&\*(L"OwnBook\*(R" in the [Engine] section).  In particular, it is possible to
520 use both a PolyGlot book and an engine book.  In that case, the engine
521 book will be used whenever PolyGlot is out of book.  Remember that
522 PolyGlot is unaware of whether the engine is itself using a book or
523 not.
524 .IP "\fBBookFile\fR (default: book.bin)" 4
525 .IX Item "BookFile (default: book.bin)"
526 The name of the (binary) book file.  Note that PolyGlot will look for
527 it in the directory it was launched from, not in the engine directory.
528 Of course, full path can be used in which case the current directory
529 does not matter.
530 .IP "\fBBookRandom\fR (default: true)" 4
531 .IX Item "BookRandom (default: true)"
532 Select moves according to their weights in the book. If false the move
533 with the highest weight is selected.
534 .IP "\fBBookLearn\fR (default: false)" 4
535 .IX Item "BookLearn (default: false)"
536 Store learning information in the book (which must be writable). Currently
537 no engine actually uses this information.
538 .IP "\fBBookDepth\fR (default: 256)" 4
539 .IX Item "BookDepth (default: 256)"
540 Stop using the book after this number of moves.
541 .IP "\fBBookTreshold\fR (default: 5)" 4
542 .IX Item "BookTreshold (default: 5)"
543 Do not play moves with a weight (probability) lower than this (in per mil).
544 .IP "\fBUseNice\fR (default: false)" 4
545 .IX Item "UseNice (default: false)"
546 Run the engine at nice level 5, or \*(L"NiceValue\*(R" if it set.  On some
547 operating systems it may be necessary to run the engine at lower
548 priority for it to be responsive to commands from PolyGlot while
549 searching.
550 .IP "\fBNiceValue\fR (default: 5)" 4
551 .IX Item "NiceValue (default: 5)"
552 Nice levels go from \-20 to 20 with 20 being the lowest priority.
553 On Unix only root can set negative nice levels. On Windows the standard
554 Win32 priority levels are mapped in a sensible way to Unix nice levels.
555 .IP "\fBAffinity\fR (default: \-1)" 4
556 .IX Item "Affinity (default: -1)"
557 This a bit vector in which each bit represents the processors that a
558 process is allowed to run on. This option works only on Windows.
559 .IP "\fBOnlyWbOptions\fR (default: true)" 4
560 .IX Item "OnlyWbOptions (default: true)"
561 If true then PolyGlot restricts the options it sends to those that
562 are potentially useful for WinBoard.
563 .SS "Work arounds"
564 .IX Subsection "Work arounds"
565 Work arounds are identical to options except that they should be used
566 only when necessary.  Their purpose is to try to hide problems with
567 various software (not just engines).
568 .PP
569 \&\s-1IMPORTANT:\s0 Any of these work arounds might be removed in future
570 versions of PolyGlot.  You are strongly recommended to contact the
571 author of faulty software and truly fix the problem.
572 .PP
573 PolyGlot supports the following work arounds:
574 .IP "\fBUCIVersion\fR (default: 2)" 4
575 .IX Item "UCIVersion (default: 2)"
576 The default value of 2 corresponds to \s-1UCI+\s0.  Use 1 to select plain
577 \&\s-1UCI\s0 for engines that have problems with \s-1UCI+\s0.
578 .IP "\fBCanPonder\fR (default: false)" 4
579 .IX Item "CanPonder (default: false)"
580 PolyGlot now conforms to the documented \s-1UCI\s0 behaviour: the engine will
581 be allowed to ponder only if it (the engine) declares the \*(L"Ponder\*(R" \s-1UCI\s0
582 option.  However some engines which can actually ponder do not declare
583 the option.  This work around lets PolyGlot know that they can ponder.
584 .IP "\fBSyncStop\fR (default: false)" 4
585 .IX Item "SyncStop (default: false)"
586 When a ponder miss occurs, Polyglot interrupts the engine and
587 \&\s-1IMMEDIATELY\s0 launches a new search.  While there should be no problem
588 with this, some engines seem confused and corrupt their search board.
589 \&\*(L"SyncStop\*(R" forces PolyGlot to wait for the (now useless) ponder search
590 to finish before launching the new search.
591 .IP "\fBPromoteWorkAround\fR (default: false)" 4
592 .IX Item "PromoteWorkAround (default: false)"
593 Some engines do not specify a promotion piece, e.g. they send \*(L"e7e8\*(R"
594 instead of the correct \*(L"e7e8q\*(R".  This work around enables the
595 incorrect form (and of course promotes into a queen).
596 .IP "\fBRepeatPV\fR (default: true)" 4
597 .IX Item "RepeatPV (default: true)"
598 When true, PolyGlot repeats the last pv string (which also contains
599 score,depth and time usage) it got from the engine. Some engines
600 however do not send a new pv string just before sending the move.
601 In that case the output of PolyGlot would be inconsistent. 
602 When RepeatPV is false PolyGlot does not repeat the last pv string.
603 Due to the way kibitzing is implemented, KibitzMove is disabled in that case.
604 .SS "[Engine] section"
605 .IX Subsection "[Engine] section"
606 This section contains engine \s-1UCI\s0 options.  PolyGlot does not
607 understand them, but sends the information to the engine at startup
608 (converted to \s-1UCI\s0 form).  You can add any \s-1UCI\s0 option that makes sense
609 to the engine (not just the common options about hash-table size and
610 tablebases).
611 .PP
612 \&\s-1NOTE:\s0 use \s-1INI\s0 syntax, not \s-1UCI\s0.  For example \*(L"OwnBook = true\*(R" is
613 correct.  It will be replaced by PolyGlot with \*(L"setoption name OwnBook
614 value true\*(R" at engine startup.
615 .PP
616 Standard \s-1UCI\s0 options are
617 .PP
618 .Vb 4
619 \&    Hash 
620 \&    NalimovPath
621 \&    NalimovCache
622 \&    OwnBook
623 .Ve
624 .PP
625 Hidden options like \*(L"Ponder\*(R" or \*(L"UCI_xxx\*(R" are automatic
626 and should not be put in an \s-1INI\s0 file.
627 .PP
628 The other options are engine-specific.  Check their name using a \s-1UCI\s0
629 \&\s-1GUI\s0 or launch the engine in a console and type \*(L"uci\*(R".
630 .SH "EXAMPLES"
631 .IX Header "EXAMPLES"
632 Running the \s-1UCI\s0 engine \*(L"fruit\*(R" under xboard 4.3.15 and later (this invokes PolyGlot internally).
633 .PP
634 .Vb 1
635 \&    xboard \-fcp fruit \-fUCI
636 .Ve
637 .PP
638 An explicit command line for using the \s-1UCI\s0 engine \*(L"fruit\*(R" with 128M hash in xboard with logging enabled (this also works on xboard 4.2.7).
639 .PP
640 .Vb 1
641 \&    xboard \-fcp "polyglot \-noini \-log \-ec fruit \-hash 128"
642 .Ve
643 .PP
644 The equivalent config file would be:
645 .PP
646 .Vb 5
647 \&    [PolyGlot]
648 \&    EngineCommand = fruit
649 \&    Log = true
650 \&    [Engine]
651 \&    Hash=128
652 .Ve
653 .PP
654 Compile \*(L"games.pgn\*(R" into a book \*(L"book.bin\*(R" retaining all lines of at
655 most 30 plies.
656 .PP
657 .Vb 1
658 \&    polyglot make\-book \-pgn games.pgn \-bin book.bin \-max\-ply 30
659 .Ve
660 .PP
661 Merge books \*(L"w1.bin\*(R" and \*(L"w2.bin\*(R" into a book \*(L"w.bin\*(R".
662 .PP
663 .Vb 1
664 \&    polyglot merge\-book \-in1 w1.bin \-in2 w2.bin \-out w.bin
665 .Ve
666 .PP
667 Inspect lines for white in \*(L"w.bin\*(R"
668 .PP
669 .Vb 1
670 \&    polyglot dump\-book \-bin w.bin \-color white \-out w_white.txt
671 .Ve
672 .PP
673 Test epd file \*(L"test.epd\*(R" with a (maximum) search time of 7 minutes per position
674 .PP
675 .Vb 1
676 \&    polyglot epd\-test \-epd test.epd \-max\-time 420
677 .Ve
678 .SH "EXIT STATUS"
679 .IX Header "EXIT STATUS"
680 PolyGlot always returns 0 on exit.
681 .SH "AUTHORS"
682 .IX Header "AUTHORS"
683 Main author: Fabien Letouzey<fabien_letouzey(at)hotmail.com>
684 .PP
685 Native Windows port:  Huang Chen<webmaster@elephantbase.net> (\*(L"Morning Yellow\*(R")
686 .PP
687 Various enhancements: Fonzy Bleumers<match(at)geenvis.net>
688 .PP
689 \&\s-1UCI\s0 port and implementation of new \s-1WB\s0 protocol: Michel Van den Bergh
690 <michel.vandenbergh(at)uhasselt.be>
691 .SH "SEE ALSO"
692 .IX Header "SEE ALSO"
693 \&\fIxboard\fR\|(6)