Reasoning by Analogy via Abstraction