Housekeeping

Major cleanup of UCT codebase to refactor/remove over-complex and obsolete code.