Generalised models of predictive coding (Feldman & Friston, 2010) suggest that the precisions at different hierarchical levels depend on the context (e.g., paying attention to a particular feature of the sensory stimulus will increase the precision of pathways reporting that feature).
In these models, precisions are estimated in much the same way the causes of sensory input. Specifically, the top-down input not only predicts the input at the lower level (content) but also predicts the precision (context) at that level.
The important point here is that the precision or post-synaptic gain, at a given level, can be adjusted by a top-down input.
Mechanistically, post-synaptic gain can be changed by several factors that include fast oscillatory activity (Fries, Womelsdorf, Oostenveld, & Desimone, 2008) and the activity of neuromodulators such as acetylcholine (Yu & Dayan, 2005).