add adaptive flow, but need more parameter tuning