Howdy,
Unscrew the set screw, on the bottom of the brush, just under where the needle is mounted. Then grip the rear of the needle and the front of the needle at the same time and unscrew the cap from the needle, the needle will slide backwards out of the mount, and the air cap will come away once the two are unscrewed from each other.
You don't need to completely remove the set screw, just back it out a couple of turns, the carpet monster really seems to find these quite tasty :)