dyzzypyxxy said: Although it's a little unusual to have earth worms in an indoor plant. Did you start your tomato planting in some sterile potting mix? There shouldn't have been any viable earthworm eggs in there, but it might have come from the tomato or somewhere else.
It won't do you any harm, and it won't smell or invade or come out of the pot. It will also make the soil better for the tomato plant.