Dry fry the coconut in a large wok until evenly browned. Add the vegetable oil, shallots or onion, garlic, lemon grass, ginger, chillies and tamarind paste. Fry for 2 - 4 minutes to release the flavours. Add the chicken pieces to the wok and brown evenly with the spices for 2 - 3 minutes.
Strain the coconut milk, and add the thin part with the chicken stock, lime leaves, if using, sugar and vinegar. Transfer to a glazed clay pot, cover and bake in the centre of the oven for 50 minutes or until the chicken is tender. Stir in the thick part of the coconut milk and return to the oven for 5-10 minutes.
Place the tomatoes in a bowl and cover with boiling water to loosen and remove the skins. halve the tomatoes, then remove the seeds and chop into large dice.
Add the chopped tomatoes to the finished dish, sprinkle with the chopped coriander and serve.
Plain rice is the usual accompaniment, but I normally serve with Naan Bread.