Scala implementation of Spore