I learned this trick while trying to remove the flexplate bolts from my truck engine/tranny. There were up in a small space and tight as as all get-out. I had bent one allen-wrench and snapped another until I you-tubed this trick: Place an air chisel on the side of the bolt head and "chisel" for 10 seconds or so. No damage to the heads or bolts and the bolts all came right out.
So similar concept - Get chisel or other solid piece of metal that would allow you to tap on the key with a hammer. Effectively, you're just trying to vibrate the key loose, so many small taps - no large thunks. I would tap on the top of the key and the side of the key. I would not tap inward on the key because that might wedge it. Again - tapping for vibration - not hard enough to disfigure the key or cause other damage to the engine shaft.
So similar concept - Get chisel or other solid piece of metal that would allow you to tap on the key with a hammer. Effectively, you're just trying to vibrate the key loose, so many small taps - no large thunks. I would tap on the top of the key and the side of the key. I would not tap inward on the key because that might wedge it. Again - tapping for vibration - not hard enough to disfigure the key or cause other damage to the engine shaft.