You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

neural.conf 1.7KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. options = {
  2. url_tld = "${URL_TLD}"
  3. pidfile = "${TMPDIR}/rspamd.pid"
  4. lua_path = "${INSTALLROOT}/share/rspamd/lib/?.lua"
  5. filters = [];
  6. explicit_modules = ["settings"];
  7. }
  8. logging = {
  9. type = "file",
  10. level = "debug"
  11. filename = "${TMPDIR}/rspamd.log"
  12. log_usec = true;
  13. }
  14. metric = {
  15. name = "default",
  16. actions = {
  17. reject = 100500,
  18. add_header = 50500,
  19. }
  20. unknown_weight = 1
  21. }
  22. worker {
  23. type = normal
  24. bind_socket = ${LOCAL_ADDR}:${PORT_NORMAL}
  25. count = 1
  26. task_timeout = 10s;
  27. }
  28. worker {
  29. type = controller
  30. bind_socket = ${LOCAL_ADDR}:${PORT_CONTROLLER}
  31. count = 1
  32. secure_ip = ["127.0.0.1", "::1"];
  33. stats_path = "${TMPDIR}/stats.ucl"
  34. }
  35. modules {
  36. path = "${TESTDIR}/../../src/plugins/lua/"
  37. }
  38. lua = "${TESTDIR}/lua/test_coverage.lua";
  39. neural {
  40. rules {
  41. SHORT {
  42. train {
  43. learning_rate = 0.001;
  44. max_usages = 2;
  45. spam_score = 1;
  46. ham_score = -1;
  47. max_trains = 10;
  48. max_iterations = 250;
  49. }
  50. symbol_spam = "NEURAL_SPAM_SHORT";
  51. symbol_ham = "NEURAL_HAM_SHORT";
  52. ann_expire = 86400;
  53. watch_interval = 0.5;
  54. }
  55. SHORT_PCA {
  56. train {
  57. learning_rate = 0.001;
  58. max_usages = 2;
  59. spam_score = 1;
  60. ham_score = -1;
  61. max_trains = 10;
  62. max_iterations = 250;
  63. }
  64. symbol_spam = "NEURAL_SPAM_SHORT_PCA";
  65. symbol_ham = "NEURAL_HAM_SHORT_PCA";
  66. ann_expire = 86400;
  67. watch_interval = 0.5;
  68. max_inputs = 2;
  69. }
  70. }
  71. allow_local = true;
  72. }
  73. redis {
  74. servers = "${REDIS_ADDR}:${REDIS_PORT}";
  75. expand_keys = true;
  76. }
  77. lua = "${TESTDIR}/lua/neural.lua";