Thread View: news.software.readers
10 messages
10 total messages
Started by MikeV06
Mon, 17 Dec 2007 14:50
[Dialog] Compound Expression Scoring
Author: MikeV06
Date: Mon, 17 Dec 2007 14:50
Date: Mon, 17 Dec 2007 14:50
27 lines
1434 bytes
1434 bytes
Is it possible to score on two fields? I would like to compare the domain part of From with Message-ID and set a score if they are equal. From: madding@UHOHR.COM.UA Message-ID: <ed540117.a3c8a1d6@UHOHR.COM.UA> Both have @UHOHR.COM.UA or From: Ramzi Hamza Dawran <electron@recover.com> Message-ID: <P2bKWBR3hZGsHViotI@recover.com> Both have @recover.com or From: "Estefana C. Adas-Stadt" <pretty@PLATFORM.PW.US> Message-ID: <LWdSNC0ZnSX4QCBvlEfAeelq@PLATFORM.PW.US> Both have @PLATFORM.PW.US Thanks. Happy Holidays. Mike
Re: [Dialog] Compound Expression Scoring
Author: Blinky the Shark
Date: Mon, 17 Dec 2007 18:24
Date: Mon, 17 Dec 2007 18:24
40 lines
2250 bytes
2250 bytes
MikeV06 wrote: > Is it possible to score on two fields? I would like to compare the domain > part of From with Message-ID and set a score if they are equal. > > From: madding@UHOHR.COM.UA > Message-ID: <ed540117.a3c8a1d6@UHOHR.COM.UA> > > Both have @UHOHR.COM.UA > > or > > From: Ramzi Hamza Dawran <electron@recover.com> > Message-ID: <P2bKWBR3hZGsHViotI@recover.com> > > Both have @recover.com > > or > > From: "Estefana C. Adas-Stadt" <pretty@PLATFORM.PW.US> > Message-ID: <LWdSNC0ZnSX4QCBvlEfAeelq@PLATFORM.PW.US> > > Both have @PLATFORM.PW.US > > Thanks. > > Happy Holidays. > > Mike Do you mean by using variables, so that one rule or rule pair would catch all three of those examples and you wouldn't need a separate rule for each of them? -- Blinky Killing all posts from Google Groups The Usenet Improvement Project - http://improve-usenet.org
Re: [Dialog] Compound Expression Scoring
Author: Enrico Bauer
Date: Mon, 17 Dec 2007 18:33
Date: Mon, 17 Dec 2007 18:33
10 lines
1559 bytes
1559 bytes
17.12.2007 15:50:02, *MikeV06*: > Is it possible to score on two fields? http://www.40tude.com/dialog/wiki/index.php/Frequently_Asked_Questions#Q:_How_can_I_combine_two_conditions_in_one_score_rule.3F HTH Enrico -- No fear. No distractions. The ability to let that which does not matter truly slide.
Re: [Dialog] Compound Expression Scoring
Author: Oliver Cromm
Date: Tue, 18 Dec 2007 23:30
Date: Tue, 18 Dec 2007 23:30
45 lines
3123 bytes
3123 bytes
* MikeV06 wrote:
> Is it possible to score on two fields? I would like to compare the domain
> part of From with Message-ID and set a score if they are equal.
>
> From: madding@UHOHR.COM.UA
> Message-ID: <ed540117.a3c8a1d6@UHOHR.COM.UA>
>
> Both have @UHOHR.COM.UA
>
> or
>
> From: Ramzi Hamza Dawran <electron@recover.com>
> Message-ID: <P2bKWBR3hZGsHViotI@recover.com>
>
> Both have @recover.com
For any domain part? What an exotic idea.
The only ways I could think of are
- by script
- with a fairly complex and heavy regular expression, but I haven't used
regular expressions of that complexity in Dialog. I'm not even sure if
back-references work. Let me try that...
The following seems to make no mistakes, at least, in my small sample of
about a thousand messages from one group, though I doubt it will catch
all instances:
=+nnn Header: {(?m)^From: [^@]+(@[^>\"$]+)>\s*$.*^Message-ID: [^@]+\1>\s*$}
=+nnn Header: {(?m)^Message-ID: [^@]+(@[^>$]+)>\s*$.*^From: [^@]+\1>\s*$}
It works if people use the <...@...> format in both From and Message-ID
header, those parts are not encoded, the headers are not folded etc.
I tried to make it more general, but I didn't find a way to stop Dialog
from matching References or other headers without inserting explicit
line ends. OTOH, the rigidity helps efficiency - this version took 5
seconds for 1000 posts, while some other versions I tried took 30
seconds.
--
Java is kind of like kindergarten. There are lots of rules you have to
remember. If you don't follow them, the compiler makes you sit in the
corner until you do. - Don Raab
Re: [Dialog] Compound Expression Scoring
Author: MikeV06
Date: Wed, 19 Dec 2007 01:35
Date: Wed, 19 Dec 2007 01:35
29 lines
1824 bytes
1824 bytes
On Mon, 17 Dec 2007 19:33:11 +0100, Enrico Bauer wrote: > 17.12.2007 15:50:02, *MikeV06*: >> Is it possible to score on two fields? > > http://www.40tude.com/dialog/wiki/index.php/Frequently_Asked_Questions#Q:_How_can_I_combine_two_conditions_in_one_score_rule.3F > > HTH > Enrico Wow, that is cool. How can I combine two conditions in one score rule? A: To combine two conditions you just have to append the second term with "-@" for "and not" or "+@" for "and". Example: -100 Subject "sex" "viagra" "enlargement" -@From:"My Girlfriend" -100 Subject "help" "emergency" +@From:"My Boss" Notice there is no space after the "@" and the colon. This is important, otherwise it won't work. Now all I got to do is figure out the regex on them to make it work. Thank you kindly! Happy holidays. Mike
Re: [Dialog] Compound Expression Scoring
Author: MikeV06
Date: Thu, 20 Dec 2007 16:22
Date: Thu, 20 Dec 2007 16:22
31 lines
1849 bytes
1849 bytes
On Mon, 17 Dec 2007 19:33:11 +0100, Enrico Bauer wrote: > 17.12.2007 15:50:02, *MikeV06*: >> Is it possible to score on two fields? > > http://www.40tude.com/dialog/wiki/index.php/Frequently_Asked_Questions#Q:_How_can_I_combine_two_conditions_in_one_score_rule.3F > > HTH > Enrico That lets me combine two conditions. -100 Subject "sex" "viagra" "enlargement" -@From:"My Girlfriend" However, I need some form of local variable that will let me capture the part after the @ sign and then compare that. From: madding@foobar Message-ID: <ed540117.a3c8a1d6@foobar> local1 = From foobar and local2 = Message-ID foobar -100 From local1 +@Message-ID local2 I have noticed the crappy messages that we are seeing in this group have that characteristic. So how do I create regex local variables in Dialog scoring? Thanks. Mike
Re: [Dialog] Compound Expression Scoring
Author: Oliver Cromm
Date: Thu, 20 Dec 2007 17:24
Date: Thu, 20 Dec 2007 17:24
22 lines
2350 bytes
2350 bytes
* MikeV06 wrote: > On Mon, 17 Dec 2007 19:33:11 +0100, Enrico Bauer wrote: > >> 17.12.2007 15:50:02, *MikeV06*: >>> Is it possible to score on two fields? >> >> http://www.40tude.com/dialog/wiki/index.php/Frequently_Asked_Questions#Q:_How_can_I_combine_two_conditions_in_one_score_rule.3F > > That lets me combine two conditions. > > -100 Subject "sex" "viagra" "enlargement" -@From:"My Girlfriend" > > However, I need some form of local variable that will let me capture the > part after the @ sign and then compare that. That will only work if you use a single regex, as in my example in <news:1k8g5gv9r4v8w.dlg@mid.crommatograph.info>. -- A computer will do what you tell it to do, but that may be much different from what you had in mind. - Joseph Weizenbaum
Re: [Dialog] Compound Expression Scoring
Author: MikeV06
Date: Fri, 21 Dec 2007 17:07
Date: Fri, 21 Dec 2007 17:07
9 lines
1360 bytes
1360 bytes
On Thu, 20 Dec 2007 12:24:43 -0500, Oliver Cromm wrote: > That will only work if you use a single regex, as in my example in > <news:1k8g5gv9r4v8w.dlg@mid.crommatograph.info>. Ooops, forgot about your suggestions. Thank you very much. Off to play with scoring! Happy holidays, Mike.
Re: [Dialog] Compound Expression Scoring
Author: MikeV06
Date: Sun, 23 Dec 2007 01:39
Date: Sun, 23 Dec 2007 01:39
26 lines
1802 bytes
1802 bytes
On Tue, 18 Dec 2007 18:30:14 -0500, Oliver Cromm wrote:
> * MikeV06 wrote:
>
>> Is it possible to score on two fields? I would like to compare the domain
>> part of From with Message-ID and set a score if they are equal.
>>
>> From: madding@UHOHR.COM.UA
>> Message-ID: <ed540117.a3c8a1d6@UHOHR.COM.UA>
>>
>> Both have @UHOHR.COM.UA
>>
>> or
>>
>> From: Ramzi Hamza Dawran <electron@recover.com>
>> Message-ID: <P2bKWBR3hZGsHViotI@recover.com>
>>
>> Both have @recover.com
>
> =+nnn Header: {(?m)^From: [^@]+(@[^>\"$]+)>\s*$.*^Message-ID: [^@]+\1>\s*$}
> =+nnn Header: {(?m)^Message-ID: [^@]+(@[^>$]+)>\s*$.*^From: [^@]+\1>\s*$}
>
Drat. Header only works if one has retrieved the body. For these types of
messages, I definitely do not want the articles.
Shame cause it was really neat!
Re: [Dialog] Compound Expression Scoring
Author: Oliver Cromm
Date: Fri, 28 Dec 2007 22:29
Date: Fri, 28 Dec 2007 22:29
45 lines
3061 bytes
3061 bytes
* MikeV06 wrote:
> On Tue, 18 Dec 2007 18:30:14 -0500, Oliver Cromm wrote:
>
>> * MikeV06 wrote:
>>
>>> Is it possible to score on two fields? I would like to compare the domain
>>> part of From with Message-ID and set a score if they are equal.
>>>
>>> From: madding@UHOHR.COM.UA
>>> Message-ID: <ed540117.a3c8a1d6@UHOHR.COM.UA>
>>>
>>> Both have @UHOHR.COM.UA
>>>
>>> or
>>>
>>> From: Ramzi Hamza Dawran <electron@recover.com>
>>> Message-ID: <P2bKWBR3hZGsHViotI@recover.com>
>>>
>>> Both have @recover.com
>>
>> =+nnn Header: {(?m)^From: [^@]+(@[^>\"$]+)>\s*$.*^Message-ID: [^@]+\1>\s*$}
>> =+nnn Header: {(?m)^Message-ID: [^@]+(@[^>$]+)>\s*$.*^From: [^@]+\1>\s*$}
>>
> Drat. Header only works if one has retrieved the body.
That's right.
> For these types of
> messages, I definitely do not want the articles.
You could make it a !delete rule. I am pretty sure you won't be able to
filter those things from the Overview alone.
> Shame cause it was really neat!
I don't know if it's much of a consolation, but for the posts I think
you are after, your idea was not a particularly good filtering rule.
After all, it will hit people who are very serious about online, using
their own domain for both mail and usenet MIDs. Could as well be me once
the current address has reached an unbearable spam volume.
--
A computer will do what you tell it to do, but that may be much
different from what you had in mind. - Joseph Weizenbaum
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads