On 2015-08-05 12:58 +0100, RW wrote:

> The number of tokens is within 0.5% of the configured value. It's
> designed to produce a value between 75% and roughly 150%.

I can't quite parse that answer, so let's be more specific.

Doc says:

  bayes_expiry_max_db_size      (default: 150000)

    What should be the maximum size of the Bayes tokens database?  When
    expiry occurs, the Bayes system will keep either 75% of the maximum
    value, or 100,000 tokens, whichever has a larger value.

>From this (and the more elaborate description in the EXPIRATION section,
which I've also read) I thought it worked roughly like this:

if (ntokens < bayes_expiry_max_db_size)
    do_nothing()
else
    goal_ntokens = max(100000, 0.75 * bayes_expiry_max_db_size)
    while (ntokens > goal_ntokens)
        kill_oldest_tokens()

If I misunderstood, how/where?  Sorry for my density :-(

-- 
Please *no* private copies of mailing list or newsgroup messages.
Rule 420: All persons more than eight miles high to leave the court.

Reply via email to