refactor UCT/weiqi classes