I read an article recently regarding a person who went to a hotel and realized after Shabbos began that all the rooms were controlled by smart thermostats. A smart thermostat detects when one is in the room and conforms to the temperature set previously at that point. When one leaves the room the thermostat goes to a higher setting in the summer and a lower setting in the winter. Is one stuck in his room in such a situation until Shabbos is over? What should one do in such a circumstance?
It appears that since the person will be acting regularly and not doing any special actions to affect the turning on or off of any device it is permitted on Shabbat (see Orchot Shabbat vol. 1 page 513 in the name of Rav Vozner; Siach Nachum siman 25).
I am in no strong position to offer opinion, but my understanding is that this situation is Melacha Derbanan, but is not Psik Reisha D'lo Nicha Ley — unless maybe if you genuinely do not benefit from the temperature. If you benefit from the temperature then its Psik Reisha.
I can imagine a crafty person suggesting that you thoroughly embrace and hold the position of the needlessness of the automatic temperature change, by realizing the 'stuffiness' or 'chilliness' of the room — but please don't think of this as justification in anything pragmatic until you consult an acknowledged authority.
Now, if one came from a plane flight to a hotel, and was feeling a sick (that they were exposed to a germ on the airplane), and the controlled temperature of the room was a benefit, maybe it could be considered allowed — if the lack of such temperature control could pose a danger to becoming ill, especially where that illness could have significant secondary impacts. But I think that would still expose you to ramifications from what were your intentions prior to becoming sick (since you didn't plan on catching a flu on the airplane). The illness kept you within halacha, but you didn't plan for that.