added new triggers, updated regular expression, and am using sum instead of reduce