I want to express the Ricci flow as a gradient flow in a case that manifold $(M,g)$ is a Riemannian manifold with boundary. For this I use the Einstein-Hilbert action $$S(g_{\mu \nu})=\frac{1}{16\pi}\int _M\sqrt{g}R+\frac{1}{8\pi}\int_{\partial M}\sqrt{\gamma}K$$
where $\gamma$ is the induced metric and $K$ is the trace of the second fundamental form.
Recall that the general gradient flow equation, on a space with coordinate $g^A$ and "energy" function $S$, is
$$\frac{dg^A(\lambda)}{d\lambda}=-G^{AB}\frac{\partial S}{\partial g^B}$$
the inverse metric $G^{AB}$ is necessary to raise the index on the gradient. In our case $g^A$ is $g_{\mu \nu}(x)$, the index $A$ standing for both the point $x$ in M and the component $\mu \nu$. and $S$ is the Einstein-Hilbert action. But what should we take for $G_{AB}$?
Thanks