transitioning stuff over from ruby