I really can't stand it when I figure out as a player that the GM has only one prescribed way of running the adventure, and the proof is that some NPC begins trying to course-correct the group on their plans. This NPC seems to the GM to be a helpful addition to the party, but to me such an NPC is obnoxious because the character is the embodiment of inflexibility of the GM. There are some situations in a game that have logical rails. If you are trapped in a garbage smasher then your options are obviously and understandably limited.
But Pre-Made adventures and adventures that the GM lovingly prepped are not given up easily, and therefore the players must find the right frequency across the spectrum in order to succeed. The way that I find a lot of GMs do this is not the good way: by describing that some plan isn't a good option by having them try it. Even better would be if the GM would simply adapt to the players plan and throw wrenches into it without invalidating it. The players are usually very satisfied in that situation because thy felt like their plan was worthy, that their choices not only mattered but were the kinds of choices that heroes might make. If their plan sucks too bad then ok I think they get their consequences, but if they have an ok plan why not make it happen to some degree? Instead they have an NPC simply tell them "go that way," or "I think you should do x."
For other Emergent GMs do you use this NPC much?
For you On-the-rails GMs how do you go about keeping your players on the tracks? Do you use this NPC or try to do other things instead?