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