The term "worm" is a broad term that can refer to many different types of invertebrates, including earthworms. Earthworms are a specific type of worm that belong to the phylum Annelida, while other worms may belong to different phyla, such as Nematoda or Platyhelminthes. Earthworms are known for their long, segmented bodies and play important roles in soil health and nutrient cycling. Other types of worms may have different body shapes and functions.