Updated README: Equal sign not required with `--mode` flag.
[sgk-go] / patterns / aa_attackpats.db
CommitLineData
7eeb782e
AT
1# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
2# This is GNU Go, a Go program. Contact gnugo@gnu.org, or see #
3# http://www.gnu.org/software/gnugo/ for more information. #
4# #
5# Copyright 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, #
6# 2008 and 2009 by the Free Software Foundation. #
7# #
8# This program is free software; you can redistribute it and/or #
9# modify it under the terms of the GNU General Public License #
10# as published by the Free Software Foundation - version 3, #
11# or (at your option) any later version. #
12# #
13# This program is distributed in the hope that it will be #
14# useful, but WITHOUT ANY WARRANTY; without even the implied #
15# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR #
16# PURPOSE. See the GNU General Public License in file COPYING #
17# for more details. #
18# #
19# You should have received a copy of the GNU General Public #
20# License along with this program; if not, write to the Free #
21# Software Foundation, Inc., 51 Franklin Street, Fifth Floor, #
22# Boston, MA 02111, USA #
23# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
24#
25# The atari_atari attack pattern database.
26#
27# Further documentation may be found in the Texinfo documentation.
28#
29# First there is a pattern title of the form: Pattern [string]. The
30# string is used for identifying the pattern while tuning or debugging.
31#
32# Then a block of the following characters representing the pattern
33# itself.
34#
35# ? : don't care
36# . : empty
37# X : your piece,
38# O : my piece,
39# x : your piece or empty
40# o : my piece or empty
41# * : my next move
42# -, | : edge of board
43# + : corner of board
44#
45# If a pattern must not match at the edge of the board,
46# an extra row of ?'s in the pattern may be added. (This
47# will not add to the time taken to check the pattern.)
48#
49#################
50#
51# In the second field (classification) the following pattern attributes
52# are possible. Friendly stones are 'O', opponent stones are 'X'.
53#
54# s : "Sacrifice" pattern. Allow sacrifice through self atari.
55# Notice that this is different from the usual meaning of the
56# s classification since all but a few moves in an atari_atari
57# sequence are expected to be sacrifices.
58#
59# c : "Conditional" pattern. Don't accept the move unless it is also
60# found by a non-conditional pattern or by one more conditional
61# pattern that threatens some other string.
62#
63#########################################################
64
65
66attribute_map none
67
68goal_elements Xx
69callback_data X
70
71
72Pattern A1
73
74X*
75
76:-,-
77
78A*
79
80;lib(A) == 2
81
82
83Pattern A2
84
85xXOXx
86..X*.
87.....
88-----
89
90:8,-
91
92
93Pattern A3
94
95OX
96X*
97X.
98xx
99--
100
101:8,-
102
103
104Pattern A4
105
106?X
107O*
108X.
109xx
110--
111
112:8,-
113
114
115Pattern A5
116
117?O?
118X*X
119...
120---
121
122:|,-
123
124
125Pattern A6
126
127*.X
128oXO
129
130:8,c
131
132*.X
133oXO
134
135;olib(*)>3
136
137
138Pattern A7
139
140X.X reduce eyespace
141X*X
142OXO
143
144:|,s
145
146
147Pattern A7b
148# gf New pattern. (3.5.10)
149
150|.X reduce eyespace
151|*X
152|XO
153|.X
154
155:8,s
156
157
158Pattern A7c
159
160X.X reduce eyespace
161X*X
162OX.
163
164:8,s
165
166A.X
167A*X
168OXb
169
170;lib(A)==2 && olib(b)>1
171
172
173Pattern A8
174
175O..
176?X*
177??O
178
179:8,c
180
181
182Pattern A9
183
184X*
185OX
186
187:/,-
188
189X*
190OX
191
192;safe_omove(*)
193
194
195Pattern A10
196
197?X?
198XOX
199.*.
200
201:|,-
202
203
204Pattern A11
205
206*.X
207?.X
208?XO
209
210:8,c
211
212*.X
213?.X
214?XO
215
216;olib(*)>3
217
218
219Pattern A12
220
221.X?
222*.X
223.X?
224---
225
226:8,-
227
228.X?
229*.X
230.A?
231---
232
233;lib(A)==2 && olib(*)>3
234
235
236Pattern A13
237
238*O
239.X
240.X
241.x
242--
243
244:8,-
245
246*O
247.A
248.A
249.x
250--
251
252;lib(A)==3 && olib(*)>=3
253
254
255Pattern A14
256
257.X.
258X*X
259?O?
260
261:|,-
262
263.X.
264A*B
265?O?
266
267;safe_omove(*) && oplay_attack_either(*,A,B)
268;&& !oplay_connect(*,A,B)
269
270
271Pattern A15
272#evand new pattern (3.3.13)
273
274?X?
275X*.
276?XX
277
278:8,s
279
280?X?
281X*b
282?AA
283
284;lib(A) == 2 && xlib(b) <= 2
285
286
287Pattern A16
288#evand new pattern (3.3.13)
289
290*x
291X.
292x.
293--
294
295:8,-
296
297*x
298A.
299x.
300--
301
302;lib(A) == 3
303
304
305Pattern A17
306# gf New pattern. (3.3.16)
307
308?O??
309o*XX
310..xX
311...X
312----
313
314:8,-
315
316?O??
317o*AA
318..xA
319...A
320----
321
322;lib(A)==3 && olib(*)>=2
323
324
325Pattern A18
326# gf New pattern. (3.3.17)
327
328??.?
329?X*.
330OOX.
331?X..
332??.?
333
334:8,-
335
336??.?
337?C*.
338eeXa
339?Db.
340??.?
341
342;!oplay_attack(*,e) && oplay_attack(*,a,C) && oplay_attack(b,a,D)
343
344
345Pattern A19
346# gf New pattern. (3.3.17)
347
348?*X threaten snapback
349O..
350?XX
351
352:8,c
353
354?*X
355O..
356?AA
357
358;lib(A)==2 && olib(*)>1
359
360
361Pattern A20
362# gf New pattern. (3.3.17)
363
364|*X threaten snapback
365|..
366|XX
367
368:8,c
369
370|*X
371|..
372|AA
373
374;lib(A)==2 && olib(*)>1
375
376
377Pattern A21
378# gf New pattern. (3.3.17)
379
380.XO
381*.X
382---
383
384:8,-
385
386.XO
387*.A
388---
389
390;lib(A)==2 && olib(*)>2
391
392
393Pattern A22
394#evand New pattern. (3.3.18)
395
396?.X
397O.X
398X*X
399?X?
400
401:8,s
402
403?.A
404ObA
405X*A
406?X?
407
408;lib(A) <= 4 && oplay_attack(*,b,A) && oplay_defend(*,?,*)
409
410
411Pattern A23
412# evand New pattern. (3.3.19)
413
414XXO
415.X.
416.*.
417
418:8,-
419
420AAB
421.A.
422.*.
423
424;lib(A) == 3 && lib(B) > 1 && oplay_attack(*,A)
425
426
427Pattern A24
428# pp New pattern - see atari_atari:25 and blunder:31 (3.5.1)
429
430?*?
431XOX
432
433:|,-
434
435?*?
436BAC
437
438; lib(A) == 1 && lib(B) + lib(C) <= 6 && !oplay_defend_both(*,B,C)
439
440
441Pattern A25
442# gf New pattern. (3.5.4)
443
444..X
445*OX
446.XO
447
448:8,-
449
450..A
451*OA
452.BO
453
454;lib(A)<=3 && lib(B)<=3 && (oplay_attack(*,A) || oplay_attack(*,B))
455
456
457Pattern A26
458# pp New pattern, see kgs:490. (3.7.4)
459
460?XX
461O*.
462?X.
463
464:8,-
465
466?CC
467A*a
468?B.
469
470# FIXME: The constraint is not very good.
471; lib(B) <= 5 && lib(A) > lib(B) && !oplay_defend(*,?,a,C)
472
473
474# END OF FILE