| www.delorie.com/gnu/docs/gnugo/gnugo_45.html | search |
![]() Buy GNU books! | |
| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
Once we have found out all about the position it is time to generate the best move. Moves are proposed by a number of different modules called move generators. The move generators themselves do not set the values of the moves, but enumerate justifications for them, called move reasons. The valuation of the moves comes last, after all moves and their reasons have been generated.
The move generators in version 3.2 are:
fuseki()
Generate a move in the early fuseki.
semeai()
Find out if two dead groups of opposite colors are next to each other and, if so, try to kill the other group. This module will eventually be rewritten along the lines of the owl code.
shapes()
Find patterns from `patterns/patterns.db' in the current position. Each pattern is matched in each of the 8 possible orientations obtainable by rotation and reflection. If the pattern matches, a so called "constraint" may be tested which makes use of reading to determine if the pattern should be used in the current situation. Such constraints can make demands on number of liberties of strings, life and death status, and reading out ladders, etc. The patterns may call helper functions, which may be hand coded (in `patterns/helpers.c') or autogenerated.The patterns can be of a number of different classes with different goals. There are e.g. patterns which try to attack or defend groups, patterns which try to connect or cut groups, and patterns which simply try to make good shape. In addition to the large pattern database called by
shapes(), pattern matching is used by other modules for different tasks throughout the program. See section 12. The Pattern Code, for a complete documentation of patterns.
atari_atari()
See if there are any combination threats and either propose them or defend against them.
owl_reasons()
The Owl Code (see section 15.1 The Owl Code) which has been run duringexamine_position), beforeowl_reasons()executes, has decided whether different groups can be attacked. The modulereview_owl_reasonsreviews the statuses of every dragon and assigns move reasons for attack and defense. Unlike the other move generation modules, this one is called fromexamine_position().
endgame_shapes()
If no move is found with a value greater than 6.0, this module matches a set of extra patterns which are designed for the endgame. The endgame patterns can be found in `patterns/endgame.db'.
revise_semeai()
If no move is found, this module changes the status of opponent groups involved in a semeai fromDEADtoUNKNOWN. After this, genmove runsshapesandendgame_shapesagain to see if a new move turns up.
fill_liberty()
Fill a common liberty. This is only used at the end of the game. If necessary a backfilling or backcapturing move is generated.
| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
| webmaster donations bookstore | delorie software privacy |
| Copyright © 2003 by The Free Software Foundation | Updated Jun 2003 |