Adding key compression