0

We are passed the *parent* of the taxon in question, as a string "{{{1}}}".

If the taxon in question doesn't have a taxonomy/ page, {{{1}}} will be "Template:Taxonomy/taxon-in-question". (Return X)

Otherwise, it should be an English string (so start with a letter). (Return A)

If we've hit a top level taxon (e.g. "Life"), the string will begin with a non-letter character (e.g. {). (Return 0)