Changed ai output to a string