use null movement script. your problem is probably that you are hitting S and W at the same time when your fingers try to make the swap to fully hitting S.
heres a diagram of whats probably happening
you going up the stairs with someone chasing you:
- W -
- - -
you the moment you realize you can stair stab this guy:
- W -
- S -
at this point your character has stopped moving completely meaning your moment wont transfer on your next keypress, and instead you have to start from zero velocity.
you fully committed to the backpedal:
- - -
- S -
now you're ramping up from 0 velocity to max velocity instead of going the same velocity you'd be going if you counter strafed correctly
null movement script should stop you from halting your own movement