Separated ajax calls for gathering current routine and analysis of data.