I think I understand.
I would suggest that you read the (AD603) datasheet a few times more.
As a VGA, AD603 has an AGC range (not gain) of about 40db - Figure 4 of the datasheet. The gain is adjust, up or down, based on the voltage differential on GPOS(pin 1) and GNEG(pin2).
The circuit on Figure 49 is a cascaded AGC circuit - A1/A2, with their GNEG fixed and GPOS floating, driven by a peak detector formed by Q1/Q2 and Cav.
Q2 charges up Cav, and Q1 discharges Cav, based on the negative peaks on Vout: low Vout drags down Q1's emitter and opens a current path from Cav to A2's output, thus lowering Cav / GPOS.
Lower GPOS leads to lower gain for A1/A2, which reduces the negative peaks on Vout, which restores Cav -> forms an AGC loop.
R5/R6/R7 set up the gain for A1/A2.
Similar structure can be adopted for a dual gate mosfet as well, with smaller AGC range per stage. Or if you don't need as much AGC range, you can simplify it to a one step implementation.
Again, all of this is well explained in the datasheet. All it takes is for you to go through it one sentence at a time.