add core.py. Try to find out solution for communicating by PIPE