Similar Items: Global semantic typing for inductive and coinductive computing