Code cleanup and Activator template documentation