Cook shrimp in 1 tablespoon oil over moderate heat for 2 minutes. Set aside. In food processor, blend shallot, garlic, chiles, sugar, tamarind liquid, ginger, salt and tomato to form a paste. Heat remaining oil in pan. Stir-fry paste over moderate heat for 3 minutes. Add shrimp, cook 2 minutes. Serve with rice.