Heat half the butter in a medium saucepan and sweat the onion and garlic for 5 mins. Meanwhile, remove the stalks of the ceps from the heads, cut them into chunks, cut the heads in half and set aside. Stir the chopped stalks in with the onions, raise the heat and fry for 2 mins until coloured. Pour in the wine and reduce by half. Add the chestnuts, 2 sprigs thyme and 400ml/14fl oz of water. Bring to the boil, reduce the heat and simmer for 40 mins.
Heat the oil in a large frying pan. Put in the cep heads, cut side down, around the outside, followed by the scallops in the centre. Fry over a high heat for 1 min each side until golden. Turn over and fry for 2 mins more. Sprinkle over the thyme leaves, season if you want and turn off the heat.
Remove the thyme and stir in the second half of the butter. Spoon the compote into the four deep plates and top with the scallops and fried ceps.