I do not believe there is any such thing as a "medium" cage XT derailleur, just long and extended. Medium and short cages are typically the domain of road/touring drive trains, as they use more compact gearing on the cassettes.
All modern XT derailleurs appear to have can take the same cassette range (e.g., one, two, three) while some have a little extra capacity to pick up more chain slack for multiple chainring set ups. (Among a few other subtle differences.)
UPDATED
I stand corrected (thank you cherouvim). What I termed long and extended appear to be officially termed "medium" and "long". A list of definitions can be found here: How to calculate the capacity of a rear derailleurHow to calculate the capacity of a rear derailleur. I leave the above incorrect answer intact for reference purpoes.
For the OP, here are pictures of a the Shimano XT derailleur (RD-M786) in both a medium and long version. Looking at the cage in your derailleur it is more consistent with long cage model.