Wikipedia:Automated taxobox system/notes

Notes for "old hands"
Major changes to the automated taxobox system were made from the middle of 2016 onwards. There were two motivations:
 * 1) to remove expansion depth overflows, caused by the constant addition of clades to some taxonomic hierarchies, especially dinosaur taxa
 * 2) to clarify and simplify the system, both for maintaining editors and for editors creating and editing taxonomy templates.

Use of Lua
All traversals of the taxonomic hierarchy are now coded in Lua, in Module:Autotaxobox. This completely removes the need for clever tricks to get round the absence of iteration and recursion in the template language, as well as expansion depth issues caused by these tricks. Hierarchies with levels can now be handled without problems (a figure that can probably be increased).

See Detailed map for a map of the code as it is now.

Taxonomy templates simplified
"Duplicate" templates – templates with essentially the same function but different names – were previously needed to avoid loops forbidden in the template language. These are no longer necessary. This allows a major simplification to taxonomy templates. Previously, a variant taxonomy template that obtained some of its information from another taxonomy template (the "same as" taxonomy template) had to contain a different internal template (such as  rather than  ).

(Had both the variant and "same as" taxonomy templates contained, then to obtain, for example, the value of   for a variant taxonomy template would have involved the variant taxonomy template calling  , which then called   again, this time from the "same as" taxonomy template. This would have created a loop, which is forbidden. By converting to Lua, the loop problem has been avoided.)


 * All taxonomy templates should now begin


 * Any taxonomy template can contain same_as; any information missing from that taxonomy template (i.e. blank) will be looked up in the "same as" taxonomy template. This only works once, i.e. the "same as" taxonomy template must not contain a same_as.
 * Hence /skip and /? templates are now coded using  and.


 * The  bit in a taxonomy template has long been redundant to the use of the   parameter, but until late 2016 was still used in a few places. These uses have all been removed, so this   is no longer needed, and a bot has removed all occurrences from taxonomy templates.