Dynamic and Generalizable Process Reward Modeling