ClarityDB + Tests
Modularising of stats.