added translatePairs method