Giving effective help is an important collaborative skill that leads to improved learning for both the help-giver and help-receiver. Adding intelligent tutoring to student interaction may be one effective way of assisting students in giving and receiving better help. However, such systems have proven difficult to implement, in part due to the challenges of modeling productive dialogue in a collaborative activity. We present a theoretical model of good helping behavior in a peer tutoring context, and validate the model using student tutoring data, linking optimal and buggy behaviors to learning outcomes. We discuss the implications of the model with respect to providing intelligent tutoring for peer tutoring.