connected predict method