Some great responses here about the finer techniques of upwind formula racing.
I dont think there 1 steadfast way of achieving the best vmg. It varies according to your weight, equipment and conditions.
The best way to determine what works for you is to try various techniques.
What works in SF may not work else where and vise versa.
In general, however, I have found- the big rig, wide board and soft fins of a modern formula set up allow you to add power and increase lift until a certain point where you need to start reducing power. One common success technique is to pinch to bleed the power off. Its a fine line of determining the best vmg but longer harness lines do allow you to sit down and bring the rig to windward to depower. Some guys to it with short lines- all personal preference.
In general if you are fighting or struggling with the rig and board, it's usually time to size down either fin or sail or both (or de power by moving your boom down and/or mast position forward)
The best techniques- keep the foot of the sail over the center line of the board and subtle adjustments are made to adjust the trim of the rig and the board.
On the opposite spectrum- in light winds- railing the board upwind with a softer more powerful wide fin and holding the rig more upright with the uphaul adds a lot of power to your setup. If you can successfully turn this into lift and better upwind performance- bravo!
What may work for a big powerful 200lb + sailor like Albeau may not work for a smaller 150lb Sylvester type sailor but that not to say either is wrong- just different in their approach.