So you have to judge whether it's Sanqu or Zaju.
If it is Sanqu (with a musical name), it generally belongs to poetry (it should be said that it is a word, not a poem). Sanqu generally has only one paragraph (called Xiao Ling) and several paragraphs (called divertimento), which rhymes to the end. If it is a zaju (often multi-paragraph, not necessarily with the same rhyme), it belongs to a drama, and a script performance can be arranged.