add recognition to server.js and index.js