[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
scoring crossposts
From: |
Dale Henderson |
Subject: |
scoring crossposts |
Date: |
15 Apr 2006 11:14:50 -0500 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.4 |
I'm trying to score crossposts down. I found this piece of code:
("xref"
;; the more cross posting, the exponentially worse the article
("^xref: \\S-+ \\S-+ \\S-+ \\S-+" -1 nil r)
("^xref: \\S-+ \\S-+ \\S-+ \\S-+ \\S-+" -2 nil r)
("^xref: \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+" -4 nil r)
("^xref: \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+" -8 nil r)
("^xref: \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+ \\S-+" -16 nil r)
...)
Then I noticed a massively crossposted article that wasn't
scored. When I investigated the headers, I noticed there was no Xref
header.
So I was wondering could I score on the newsgroups header. According
to the documentation Newsgroups isn't a valid header to score on.
On another note, is there any way to check a header to see how many
times a particular regex matches and use the count to set the score.
That is in the example above see how many times the regex \\S-+
matches the xref header and then set the score to
(- (expt 2 (- count 3)))
- scoring crossposts,
Dale Henderson <=