There could be many ways of doing it. I haven't tested any of it though

But before you try any of these please make backups of your backups plus backups of your working folder

I hope the clip-board supports copy pasting fsms across instances of unity. In theory it should work.
One possibility is to rename and copy your project (with good fsm) to your local hard-drive. Then use Unity hub to add this renamed project into the project list. Open this project. Keep it open.
Now also open your actual project (one with bad fsm) in the second instance of Unity.
Switch to renamed project and then Right click on the good FSM component in the inspector and select copy component.
Now switch to actual project and then right click on any component (transform for eg.) of the corresponding game object where the FSM should belong. Choose paste as new component. (remove old fsm first)
Alternate method would be to directly select all the states in the FSM editor and copy paste them across projects. As long as you haven't made any complex changes that involves dependencies across other fsms you should be good.
More simpler way could be to right click in empty space in the fsm editor and choose copy fsm. Then paste it in the corresponding spot in the working project.
Other possibilities would be to save the good fsm as a template may be. I haven't used templates but that should work provided it is done correctly.
If for some reason you can't open multiple instances of Unity, then I suppose you could open them one by one and hope that the clip board retains copied data.
Finally , you can turn the game object with good fsm into a prefab if it isn't already.
Place this prefab into your work project wherever you see fit. Unity should update its meta. Then delete the game object with bad fsm and replace it with this prefab. Unpack prefab completely if you want or stick to prefab (depends on your use-case) . Make backups before you try this one!