I think that both working well with others and having rationally decided that cooperation in PD-like problems is right are good things. I don't think they necessarily come together! When I'm friendly to people, this tends to be for reasons that come out of my experience (e.g. "Maybe this person will be my friend, like So-and-so!") or my emotions (e.g. "It's a beautiful day! I just want to grin at everybody I meet and compliment them on their outfits!") or my goals (e.g. "I want my friend to be happy, so I'll bring her a glass of juice and ask her if there's anything else I can do!") rather than the fact that I think in PD situations you should be cooperative.
As for irrational biases against particular people, the easiest way to practically get around them is to hold a belief that people can and will change for the better. That way, if you have decided that someone is a stupid jerk, the next time you see a post of theirs you can check to see if they might have ceased to be a stupid jerk, instead of saying that because they are a stupid jerk the post must be stupid and jerky.
I think that both working well with others and having rationally decided that cooperation in PD-like problems is right are good things. I don't think they necessarily come together!
As an example of how they should but do not come together, we have people here who agree that they should cooperate in extended PD, yet engage each other in an extended PD-like situation in which they have a discussion via comments and each continue to down-vote each others' comments.
David Brin suggests that some kind of political system populated with humans and diverse but imperfectly rational and friendly AIs would evolve in a satisfactory direction for humans.
I don't know whether creating an imperfectly rational general AI is any easier, except that limited perceptual and computational resources obviously imply less than optimal outcomes; still, why shouldn't we hope for optimal given those constraints? I imagine the question will become more settled before anyone nears unleashing a self-improving superhuman AI.
An imperfectly friendly AI, perfectly rational or not, is a very likely scenario. Is it sufficient to create diverse singleton value-systems (demographically representative of humans' values) rather than a consensus (over all humans' values) monolithic Friendly?
What kind of competitive or political system would make fragmented squabbling AIs safer than an attempt to get the monolithic approach right? Brin seems to have some hope of improving politics regardless of AI participation, but I'm not sure exactly what his dream is or how to get there - perhaps his "disputation arenas" would work if the participants were rational and altruistically honest).