The teeth of a phallic-looking worm that lived 500 million years ago has led to the development of a "prehistoric dentists handbook" that could help identify new specimens from the Cambrian period.

The penis shaped worm was able to turn its horrifying cheese grater-like mouth inside out to drag itself around, the University of Cambridge reported. Reconstructing the teeth of the penis worm (also called a priapulids) enabled scientists to identify a number of previously unknown species from across the globe.

A team of researchers used electron microcopy to look at the teeth of the strange worm, which emerged during the Cambrian explosion, a period of rapid evolutionary development across many species. The teeth came in a variety of shapes such as cone, bear claw, and some that even resembled a city skyline. These types of early creatures have been extremely hard to study because of their soft bodies that decay quickly.

"As teeth are the most hardy and resilient parts of animals, they are much more common as fossils than whole soft-bodied specimens," said Martin Smith, a postdoctoral researcher in Cambridge's Department of Earth Sciences and the paper's lead author. "But when these teeth - which are only about a [millimeter] long - are found, they are easily misidentified as algal spores, rather than as parts of animals. Now that we understand the structure of these tiny fossils, we are much better placed to a wide suite of enigmatic fossils."

Penis worms still exist in modern times, and burrows into the sediment beneath the ocean. In this recent study the researchers looked at a type of penis worm called Ottoia, which lived during the Cambrian period. The fossils came from the Burgess Shale in Western Canada that hold a treasure trove of preserved ancient creatures.

Using high resolution electron and optical microscopy allowed the researchers to look at the teeth of a number of previously-unknown penis worm species.

"Teeth hold all sorts of clues, both in modern animals and in fossils," Smith said. "It's entirely possible that [unrecognized] species await discovery in existing fossil collections, just because we haven't been looking closely enough at their teeth, or in the right way."

The findings were published in a recent edition of the journal Paleontology.