This is a perennial question on this site, and always leads to confusion over the distinction between "work" and "effort". To avoid confusion, we need to be explicit about the many terms in the energy.
Energy contributions
Crudely, the energy of the dog can be written as the sum of four terms,
$$E = U_{\text{pot}} + K_{\text{KE}} + U_{\text{chem}} + K_{\text{thermal}}.$$
The first two are macroscopic, and the last two are microscopic. They are:
- $U_{\text{pot}}$ represents the macroscopic potential energy due to external fields, such as $M g h_{\text{CM}}$ for gravitational potential energy
- $K_{\text{KE}}$ represents their macroscopic kinetic energy, i.e. the kinetic energy of all the parts big enough for you to see, such as their overall center of mass motion, the motion of their limbs, etc.
- $U_{\text{chem}}$ represents the potential energy stored in the chemical bonds of the molecules they can metabolize; it is what is released by the mitochondria, powerhouse of the cell.
- $K_{\text{thermal}}$ represents the thermal energy, the microscopic kinetic energy of individual molecules jiggling around in thermal motion.
For simplicity, we're going to ignore any heat transfer with the environment. Then the work-energy theorem (which is now equivalent the first law of thermodynamics) only tells you about the total change in energy,
$$\Delta E = W = \int F \, dx.$$
Therefore, in isolation it tells us almost nothing about how each of the four individual terms change. The amount of "effort" roughly follows $\Delta U_{\text{chem}}$, but an understanding of how it changes in various situations requires a detailed treatment of metabolism and biomechanics.
Dog on a leash
For the example in this problem, we have
$$\Delta U_{\text{pot}} = \Delta K_{\text{KE}} = 0$$
so if the dogs apply a force $F$ over a distance $x$,
$$-Fx = \Delta U_{\text{chem}} + \Delta K_{\text{thermal}}.$$
At this point it would be tempting to set $\Delta K_{\text{thermal}} = 0$, so conclude that
$$-Fx = \Delta U_{\text{chem}}$$
so the "effort spent" by the dog is proportional to $Fx$. While that might be true for an idealized machine, it isn't remotely true for biological systems. In general, the chemical energy spent is much more than $Fx$, and is not necessarily even linear in $F$ or $x$. The extra spent energy goes into thermal energy, which is why the dogs will start panting and a human would start sweating. Explicitly, the energy conservation equation above might actually look like
$$(-100 \text{ J}) = (-1000 \text{ J}) + (900 \text{ J}).$$
It's not even obvious how $\Delta U_{\text{chem}}$ depends on $F$ and $x$. For example, as $F$ increases, the dog might have to pull in a less biomechanically efficient way, causing $\Delta U_{\text{chem}}$ to increase faster than linearly in $F$. Or, for very high $x$, the dog could get tired and switch to a less efficient metabolic pathway, causing $\Delta U_{\text{chem}}$ to increase faster than linearly in $x$. Or, even if you kept both $F$ and $x$ the same, the chemical energy spent might vary if the dog decided to pull a different way.
Person squatting a barbell
An even more extreme example of this is a person squatting a heavy barbell. For simplicity, let's assume they do it slowly, and that the barbell is much heavier than they are, so that we can neglect the person's gravitational potential energy. Then for the system containing just the person,
$$\Delta U_{\text{pot}} \approx 0, \quad \Delta K_{\text{KE}} \approx 0.$$
If the barbell has mass $M$ and its range of motion is $d$, then in the first half of the exercise, the barbell does work $Mgd$ on the person,
$$Mgd = \Delta U_{\text{chem}} + \Delta K_{\text{thermal}}.$$
In the second half of the exercise, they raise the weight back up, so
$$-Mgd = \Delta U_{\text{chem}} + \Delta K_{\text{thermal}}.$$
For an idealized machine, we would have $\Delta K_{\text{thermal}} = 0$, so
$$Mgd = \Delta U_{\text{chem}}, \quad -Mgd = \Delta U_{\text{chem}}$$
for the two halves of the exercise. That is, a machine can gain energy from lowering a weight. Then it pays it back by raising it back up, leaving it in the same state as before.
None of this is remotely true for a biological system. In fact, even the sign of $\Delta U_{\text{chem}}$ is different! It takes effort for biological muscles to steadily lower something, so $\Delta U_{\text{chem}}$ is negative for both halves.
In fact, it's even worse: you will in general feel more tired, in the long run, due to the lowering portion than the raising portion. The reason is that the lowering portion stretches your muscle fibers, which causes more of them to break. Again, none of this contradicts energy conservation. The point is that energy conservation alone doesn't tell us the answer; we have to actually understand the biology.