Might have to wait a little, I'm not certain, but raw may be better. I think there's something about the cooking process, kills off bacteria that are present on just about everything and it is those bacteria that start the 'rotting' process breaking down the flesh and producing ammonia. Cooked shrimp may become more of a meal for funghi.
Will a piece of pizza stay fresh forever just because it is cooked?
No, It would still rot over time just like any of the raw ingredients used to make it.
I recommand cooked over raw, provided cooked means placing it in boiling water ONLY! No seasoning or whatever...
The reason is because when you cook/boil, you are effectively killing any nasty bacteria that you do not want to introduce into your tank. Hence it is a much safer option.