First draft of generateResponse()