Computer Chess Club Archives


Search

Terms

Messages

Subject: Re: Management Of Knowledge - In Crafty And In General

Author: Graham Laight

Date: 09:12:21 07/25/00

Go up one level in this thread


On July 25, 2000 at 09:43:44, Robert Hyatt wrote:

>On July 25, 2000 at 06:48:09, Graham Laight wrote:
>
><snip>
>
>
>>
>>It seems to me that you are selecting which knowledge to use on the basis of
>>"inductive reasoning", or a tree of questions.
>>
>>e.g.
>>
>>Is there plenty of material left?
>> |
>> |
>> |- Yes
>> |   |
>> |   |- Are the opponent's pieces near my king?
>> |   |
>> |   |- Yes
>> |   |   |
>> |   |   |- Are the pawns around my king well placed?
>> |   |   |
>> |   |   |- No
>> |   |   |  |
>> |   |   |  |- A king safety problem exists
>> |   |   |
>> |   |   |
>> |---|---|
>> |
>> |
>>A king safety problem does not exist
>
>You imply this is a boolean decision.  It isn't.  The king safety scores can
>range over a set of integer scores from roughly -5.00 (-500 in Crafty) to +5.00,
>rather than being a decision tree 0/1 as you have it above.  That seems to help
>my evaluations quite a bit, because over time, the endgame prediction score can
>catch up and surpass the king safety score causing crafty to want to trade
>even when it is attacking, because it has seen (or thinks it has seen) a way
>to reach an endgame where it has an advantage that is better than the attacking
>chances.
>
>That is important in my evaluation... there are no "on/off" things at all.  IE
>some turn king safety off when material drops below X.  Right around X, things
>are flakey as on one side you get a big negative score, while on the other side
>you get a 0, so a single capture can whack the score significantly.  I don't
>do that...  it smoothly transitions from big to small over many captures...  And
>endgame scores smoothly transition from small to big as material comes off.
>
>What it means is that I evaluate everything, then figure out how much of each
>"component" ought to be included in the current score, rather than turning some

How do you weight the various components?

I assume you have to calculate (or use existing calculations to make..) some
indices to determine the relative weight the score of each evaluation component
should be given. If so, this sounds similar to the position index building work
I would have to do before giving each eval fn a "match score".

>off completely.  IE if your king is in trouble, you might turn pawn structure
>analysis off as you are trying to save your king.  I am trying to save both
>my king _and_ pawn structure, but I try harder to save the king of course. :)

I would be able to set the match score threshold for using an eval fn to
whatever I liked.

It could be "top 5 + anything with a match score over 50%", or it could be "top
10 + anything with a match score over 10%". I could even choose to use all eval
fns, and use the match scores to determine weightings.

One could have hours of fun playing with the thresholds...  :)

Anyway, to go back to Crafty for a moment, the thing that struck me when looking
through evaluate.c (17.11) is just how little knowledge there is in there. I've
just done a quick count (unscientific I know), and I reckon there's fewer than
150 distinct pieces of chess knowledge in that file!

This is an eminently manageable number, so it's not surprising that knowledge
management issues are not seen as a serious problem in Crafty. Indeed, it is a
tribute to the programmer that Crafty plays so well with so little knowledge
about chess.

I think we can safely say that Crafty's depth of search eliminates the need for
large chunks of knowledge. Bad positional aspects which are hard to see must
eventually lead to bad things in the position which can easily be seen - and
evidently Crafty sees far enough ahead to catch most of these.

Still - having such a relatively small number of rules must leave positional
holes that players could exploit if there was a lot at stake (e.g. a big
competition).

-g



This page took 0 seconds to execute

Last modified: Thu, 15 Apr 21 08:11:13 -0700

Current Computer Chess Club Forums at Talkchess. This site by Sean Mintz.