What is the best way to apply force, then come to a smooth stop on control release?

Using keyboard/etc control I’d like to be able to apply a smooth acceleration to a maximum speed, using force if that is the best way to do it. When the control is released, I want to slow down to a stop.

Big note: All of this is done using physics, not transform.