This is actually pretty simple, but it makes use of a diode bridge, which is not commonly done nowadays.
Take this circuit
simulate this circuit – Schematic created using CircuitLab
Start by assuming V1 = V2 and R1 = R2, and R3 is infinite. Then for Vin = 0, so does Vout. Call the current through R1 or R2 the reference current. Note that, for a fairly large range of input voltages, the output voltage will follow the input voltage quite closely. Although the input source will provide extra current through D2, since the diodes are biased on with about half the reference current, this will have little effect on the diode voltage. So in general, the top and bottom of the bridge will follow the input, and so will the output.
Similarly, making R3 non-infinite will cause inaccuracies in the output voltage, but the effect will be small so long as R3 does not become too small. Note that in the ap note, R17 is about twice R15 and R16, and at these levels you can expect errors of about 1%.
Of course, this only applies with the voltages shown. If the polarities of V1 and V2 are reversed, the bridge becomes reverse-biased, no current flows, and Vout becomes zero. In addition, from an AC standpoint, Vin and Vout are decoupled by the capacitance of the diodes, and at the frequencies in the ap note this provides a high impedance. So for one polarity the bridge acts as something like a short circuit, and for the other it acts as an open circuit. In other words, a rectifier. Admittedly, it's not as good as a standard op-amp precision rectifier at low frequencies, but it works well for frequencies one to two orders of magnitude higher than such rectifiers.
The rest of the circuitry simply senses the polarity of the input and switches the bridge voltage as appropriate. Of course, as with all Jim Williams' circuits this involves clever handling of various important (but not always obvious) effects. In this case, the switching of the gate voltage must be very fast and precisely synchronized. If not, you'll get switching transients feeding the output.