Surely the Sovs had something apart from studlier boosters going for them in the early years--there were obviously some unresolved engineering issues in play during the first American attempts.

Not really. The key engineering problems were not in making rockets, which they did pretty well, but in electronics and guidance. Our payloads were always vastly more complex and capable. American manned spacecraft from the start were designed to be flown in space, and not just from the ground. This required on-board guidance and navigation computers that were reliable, durable, redundant, and bug-free. The entire effort was above all public to an astonishing degree - and that turned it into a team effort from citizen to politician to manufacturer to controller to astronaut. The Russians were simply treated to spectacles, with the usual boasting about collectivism. Americans were made a part of it.

It is also a case study of how you can think of deficit spending as investment capital. The investment was tiny compared to the benefit reaped.