Fix automation engine to honor the data type.

@mkanoor 
Automation engine only supports array of strings as all inputs are treated as string.
Have fixed the rubocop errors that could/should be fixed.