Fix capitalize function and add classify.