ENH: compute scores in rulebased.py