As thermal energy is transferred to the chocolate, its molecules vibrate faster and faster. Eventually they vibrate fast enough that they start to slide past each other and move around. As this happens, the chocolate changes from a solid to a liquid.