That is a great question and I’m really glad you asked. Sometimes when those of us who have been making wines for quite some time write about some technique, process, or concept that we may think of as “simple,” we need to rethink for a moment that how we describe something might not be so obvious to everyone. I think your instincts are pointing you in the right direction. During an active fermentation the cap (the grape skins that float to the top of the vessel) can get very hot and so the cap’s temperature is definitely not indicative of the temperature of the entire must/fermentation.
I’m not aware of any specific article that points to “how to measure the temperature of a fermentation” but I’ll pass on to you what I know from how I was trained over many harvests and how I still conduct temperature measurements today. Like you say, the cap is always a local temperature and during the peak of fermentation, when we want to make sure we’re getting a red fermentation warm enough to extract “the good stuff” (anthocyanins, tannins, etc.) but we don’t want it so hot that the yeast start to be inhibited (no one wants cranky yeast), the cap will always be hotter than the juice below. This is why I will only “take the temperature” of the overall fermentation after a really good punchdown or pumpover, after the tank is well mixed.
Let’s say you’ve got your fermentation going in a one-ton (910-kg) macro bin and it’s been ripping along at about three °Brix drop per day and is now at about 10 °Brix. This is just about at peak fermentation time. I’d wager the cap would be super-hot and the wine would be slightly cooler below. Give your macro a big punchdown, going over the surface at least twice, very vigorously. Then, sink your cylinder or sample-collecting device underneath the cap about 2⁄3 of the way down (covered with your hand), let it fill, and bring it back up. That’ll give you a good idea of the overall, mixed temperature of that fermentation. That’s the 80–90 °F (27–32 °C) range you want to try to hit. In a stainless steel tank, you’d do a decently long pumpover to mix the tank well and then would take a sample from the sample valve, which is usually about 1⁄3 of the way up from the bottom of the tank. Winemakers may have their own specific definitions or techniques, but I’m pretty sure most of us mean a “well-mixed, just-punched-down” temperature when we talk about starting, finished, or peak fermentation temperatures.