Was having a discussion with a friend: the topic of rebellion and treason arose. We were discussing West Point graduates (and officers) who fought for the South. What happened after the War? Were these leaders considered traitors, did any hang? What about army regulators? By definition a rebel who loses usually is considered traitorous. How did the Union deal with it's former adversary in this matter?
I can't speak to the treatment of everyday soldiers on a person-to-person basis, but the Radical Reconstruction congress did do something quite radical directly after the end of the war. In 1866, Congress passed and the states ratified the 14th Amendment, which is best known for the birthright citizenship clause. What is not as well known is that the 14th Amendment also explicitly gave Congress the power to prevent anyone who participated in armed rebellion against the United States from serving in Congress, state legislatures, or becoming Presidential electors.
One has to imagine that there was frequently a lot of resentment of ex-confederates by the soldiers who occupied the South during the period of martial law during Reconstruction. I'm sure that there's a good amount of primary source evidence documenting these tensions.
Later on, however, public attitudes shifted towards what historians call the "Reconciliation Cause" school of thought. This school of thought sought to alleviate lingering tensions between Northerners and Southerners by avoiding discussions about the casus belli of the war and instead emphasized the military history of the conflict, generally stressing that both sides produced many honorable men and that the average soldier fought bravely whether he wore grey or blue. This school of thought became very popular about a decade after the war when much of the public in the North had grown frustrated with Reconstruction due to widespread reports of corruption as well as its tremendous social and psychological costs. By 1872, all but a handful of the previously blackballed ex-Confederate officials were granted pardons when President Grant signed the Amnesty Act into law.