turning type inference into class instead of dispatch
turning type inference into class instead of dispatch
working on new type inference