The Learn contrib is an automated way to implement the
LearnAsSpam script, so reading up on that might help.
I also configure
Bayesian Autolearning on all of my systems.
I read the specific 'config...' commands on the
Learn Installation section to say:
1) use 'config setprop LearnAsSpam status enabled' to turn on "learn as spam"
2) use 'config setprop LearnAsHam status enabled" to turn on "learn as ham"
3) use 'config setprop Learn cron hourly' to schedule the 'LearnAsSpam' script to run hourly. The script, when run, will then reference the other config settings to determine what to do.
To enable your changes to the cron schedule, you need to 'expand-template /etc/crontab'