Hmm...apparently arithmetic isn't covered in the Dungeon levels, and that's necessary to complete the level.
So, to count your gems, you'll want to do the below:
# define your gem counter outside the loop
gems = 0 # this is just a variable assignment; you've seen these before with enemy = self.findNearestEnemy()
# then once you pick up a gem, you can do the below
gems = gems + 1 # this makes gems equal the previous gem count plus 1
# or you could do `gems += 1`
# then you could just self.say(gems) when you need to