Uploading latest version from Kannan.

This includes many changes based on the reviews.