A Computational Framework for Social Capital in Online Communities