To take the tamarind essence, place the tamarind seeds in a small bowl and add 1/4 cup of water, let it sit for 10 minutes. Then massage the seeds, until the water becomes brown and all the tamarind essence have been converted into the water. take the seeds out and leave aside. ( The seeds can be further soaked to get more tamarind flavour) Place the sliced onion, tamarind juice, curry leaves, oil, chilli flakes, salt in a large pan and place it on medium fire
Let it cook for about 5 minutes, once its cooked and soft, add in the cinnamon, crushed cloves, cardamom and cook for further 5 minutes
Once the onions are really soft, add in half of the sugar, Maldive fish cook for 5 minutes, then turn off the fire and cover with a lid and leave it for 5 minutes.
Once again turn on the fire to low heat, add in the rest of the sugar and let it cook for 15-20 minutes on low heat until really caramelised and soft. The colour should be dark. The taste should be a good balance of saltiness, sweetness and sour. if the sourness is not enough add more tamarind ( in the last part of cooking do not cover with a lid)