work on prediction mode