AI playing the walking animation when not moving

This could be several different things.

First of all, I would hook your speed variable up to a print string to see if it thinks it is moving.

-If speed is at 0 and it is animating a run, then I would go into your state machine and check for any issues there.
-If speed is significantly over 0 even when the character is in place, then it might be the navigation.
-If it is just being nitpicky and speed is at .00001 or something, I believe there is a node for that to fix it. You can plug in a “roughly equal” node of some sort rather than a perfect greater than node, but I don’t remember the exact name of it.