By what I can see the forward vector will be changing between 0-1 on all axis’ due to it having physics turned on. I’d anticipate that your cube isn’t stationary at the start which gives it its jittering value.
Try multiplying the entire Get Forward Vector times the axis value then add the z value multiplier afterwards. This way if there is no input then the vector returned should always be 0. Use a print string on what you input into the Add Relative Location vector pin to see if you are inputting 0 before you do your K and M input keys.