Added a simple partial support for boolean type and a type-guessing routine