Only display debug numbers when doing a slow job

i.e. more than one agent

Also lots of stylistic fixes as I come across them