gems code