Chop the pumpkin and onion into small pieces. Put in a pan and add enough vegetable stock to cover the bottom. Squeeze the garlic clove over it, add the spices and leave to cook with the lid on. Possibly add a little water now and then so that the pumpkin doesn`t burn.
In a saucepan, warm the milk with the vegetable stock and when it boils add the polenta. Simmer for a few minutes and stir in the cheese. Remove from heat and add parsley, salt and pepper and season to taste. Then add the eggs (preferably not before seasoning, then you don`t have to eat a raw egg).
Put the pumpkin in a baking dish and cover with the polenta mixture. Cut the tomatoes into slices, cover the mixture with them. Cook in a preheated oven at 190 ° C hot air for about 45 minutes.