support for lazy greedy and other small fixes