Fist version of swi prolog solver