[Spambayes] feature request

Kenny Pitt kennypitt at hotmail.com
Mon Dec 8 09:47:35 EST 2003


Mark Hammond wrote:
> [Rayfes]
>> Is there
>> any way to have SpamBayes play a sound every time is marks
>> a message a spam and maybe a different sound for possible spam?
> 
> That is a pretty good idea.  If someone can nail down the exact
> feature request, I think we could add it.  The issues as I see them:
> * Play the sound for *every* mail that SpamBayes processes, or only
> at the end of a "batch"?
> * If a batch, what exactly is a batch, considering the "background"
> filtering option?

My thoughts:  I think once per batch would be best.  Especially when I
first start Outlook after the weekend and receive a bunch of e-mails at
once, one per message would get very annoying.  Per batch is also more
like the Outlook behavior.

As far as defining a batch, I would probably use a timer similar to, but
not exactly like, the background filter.  When the first message is
processed, set the timer.  Each time a new message is processed, reset
the timer.  If no new message is processed before the timer expires then
play the appropriate sound.  The trick is making sure that this timer
doesn't expire before the background filter timer, but that shouldn't be
too difficult.

> * If a batch and there are multiple classifications in the batch, do
> we play all sounds?
> * If so, in what order?

Seems like most people mainly want to know if there is anything
interesting to look at before opening Outlook.  To that end, I would
play only the sound for the "most interesting" classification which I
think most people would define as ham->unsure->spam.  I would also look
at which sounds are configured so that, for example, if no ham sound is
configured then I would consider the unsure sound to be the most
interesting.

> * Sounds can be played synchronously, or asynchronously.  Which one
> do we choose?

If we are playing only the one most interesting sound after each batch,
then I would just play it synchronously.

> Ultimately, these answers need to be expressed as a set of options
> that will exist in the INI file - from the above list, I doubt that 3
> simple "spam/ham/unsure_sound_filename" options will do.

Seems like we might be able to get by with these 3 plus a "batch
accumulation delay" setting.  Other possibilities to make it more
configurable would be defining the "most interesting" order, and an
option to play the sounds for all detected classifications instead of
the most interesting.

Is there an existing win32all function to play an arbitrary sound file?
If there is, I'd be glad to start looking into implementing this.

-- 
Kenny Pitt




More information about the Spambayes mailing list