If a large pan of soup and a small bowl of soup have the same temperature, what do you know about the thermal energy of the two containers of soup?
It is proportional to the masses of the two containers' contents.
Thermal energy is the heat contained in something. The amount of heat something can contain is a function of its mass and heat capacity. Therefore, the difference in thermal energy of things will similar properties will depend only on the differences of their masses.