diff options
author | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-01-05 18:02:47 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@highsecure.ru> | 2016-01-05 18:02:47 +0000 |
commit | 8be715956820c4b14d3a3d7f41e50e4e69b7e679 (patch) | |
tree | 934d45c3e84b5e4c98982dee360267bd74e693a2 /src/libstat/stat_internal.h | |
parent | a53bd05ff9eac93f444b7bf8dd1607e16301ef5b (diff) | |
download | rspamd-8be715956820c4b14d3a3d7f41e50e4e69b7e679.tar.gz rspamd-8be715956820c4b14d3a3d7f41e50e4e69b7e679.zip |
Fix bayes classifier for the new architecture
Diffstat (limited to 'src/libstat/stat_internal.h')
-rw-r--r-- | src/libstat/stat_internal.h | 26 |
1 files changed, 3 insertions, 23 deletions
diff --git a/src/libstat/stat_internal.h b/src/libstat/stat_internal.h index 09fd87fb6..edced84de 100644 --- a/src/libstat/stat_internal.h +++ b/src/libstat/stat_internal.h @@ -30,11 +30,6 @@ #include "backends/backends.h" #include "learn_cache/learn_cache.h" -enum stat_process_stage { - RSPAMD_STAT_STAGE_PRE = 0, - RSPAMD_STAT_STAGE_POST -}; - struct rspamd_statfile_runtime { struct rspamd_statfile_config *st; gpointer backend_runtime; @@ -42,29 +37,14 @@ struct rspamd_statfile_runtime { guint64 total_hits; }; -struct rspamd_classifier_runtime { - struct rspamd_classifier_config *clcf; - struct classifier_ctx *clctx; - struct rspamd_stat_classifier *cl; - struct rspamd_stat_backend *backend; - struct rspamd_tokenizer_runtime *tok; - double ham_prob; - double spam_prob; - enum stat_process_stage stage; - guint64 total_spam; - guint64 total_ham; - guint64 processed_tokens; - GList *st_runtime; - guint start_pos; - guint end_pos; - gboolean skipped; -}; - /* Common classifier structure */ struct rspamd_classifier { + struct rspamd_stat_ctx *ctx; struct rspamd_stat_cache *cache; gpointer cachecf; GArray *statfiles_ids; + gulong spam_learns; + gulong ham_learns; struct rspamd_classifier_config *cfg; }; |