Brainsabc refactor