  A well-known theorem of Wolpert shows that the Weil-Petersson symplectic form
on Teichm\"uller space, computed on two infinitesimal twists along simple
closed geodesics on a fixed hyperbolic surface, equals the sum of the cosines
of the intersection angles. We define an infinitesimal deformation starting
from a more general object, namely a balanced geodesic graph, by which any
tangent vector to Teichm\"uller space can be represented. We then prove a
generalization of Wolpert's formula for these deformations. In the case of
simple closed curves, we recover the theorem of Wolpert.
