Commented WordBag code