improved debugging model