When having freeform forward kinematic animation - such as motion capture input - you may want to assign an IK solver to the animated chain - doing this will not destroy the underlying animation - and using this script - you will be able to snap the IK Solver Goal motion to the FK animation.