Added lazy implementation of consistency checker.
Added lazy implementation of consistency checker.