Regarding Thomas Jefferson, I have read that although his original political philosophy was derived from the English Whig tradition, he became converted while in France, at least to some degree, to the French Rationalism in which government makes top down decisions for the benefit of its citizens and which also embraced egalitarianism. Rationalism is at the root of socialism, not that Jefferson was a socialist, I don't think.
I'm not exactly a scholar on this subject, perhaps someone else can let me know whether or not I have the right of this.
My understanding was that Jefferson championed the cause of the free individual over all else. The structure of government, therefore, should support the goal of individual liberty regardless of the consequences.
Perhaps his views did change later, I honestly don't know. But those earlier views are the ones which I admire.
I could go on about Hamilton, but I won't.