Socket working for character recognition and mongo working