cleaned up DiscourseEntity, added some doc comments