extract caculate probability method for extending to chain CRF
remove redundent methods