I think Casadi is solid. Primarily, I'd say Casadi is more specialized towards optimal control. To my knowledge it's much easier in SymForce to formulate complex objectives (ex: involving 3D poses, camera projections, Lie group operations), and has a more flexible code generation system that can generate structured APIs in multiple languages.