(source) C. Scott Ananian: Ideas/Some thoughts on Global Templates, so called

Lots of folks are talking about "Global Templates" these days, and the need for the Wikimedia movement to better support them. Let's start by pointing out the ambiguity embedded in the name of this discussion, to wit: both "Global" and "Template" are used to mean some rather different things by different parties.

Let's list a number of ways that "Global" is used, to start:

Note that these three definitions are all orthogonal! We can have cross-wiki transclusion without solving any localization issues or building a nonlocal community; we can internationalize the languages used to write templates/modules without doing anything about cross-wiki transclusion or community; and we can build a global community of template authors (say, on commons, supported by annual conferences and similar) while not doing anything about localization of the templates themselves or about cross-wiki transclusion. Thinking positively, working on these aspects independently is still useful in isolation—for example, if you "just" localize the implementation language then you can use localized templates on wikiprojects which are already global, like commons or the annual Wikimania sites. The "global" efforts can reinforce each other—and it would be wise to gently harmonize them—but we don't need to wait until we can do everything at once to get started.

Turning to "Templates":

As with "global", we can solve various part of global "templates" in isolation, but it is probably very important for speakers to be clear about exactly which meaning(s) of "template" they mean, because it is pretty unlikely that any work is going to apply to all "template" systems and all meanings of/use cases for "templates".

Types

When programmers, the parsing team, the Visual Editor team, linguists, and Wikidata folks are brought together by this discussion, they will all talk about "types". But again, caution is warranted, because these four communities mean different things by this term:

We should be careful not to assume our definition of "type" is universal, nor that our notions of what "type" distinctions are useful map cleanly to the sorts of types useful to a different community or use case. If the argument to a template is "a number", then the phrase "about a million" (a string not a number to a programmer type) might well be a valid input, depending on your perspective.

Theory of change

Embedded in many discussions is also an accompanying "theory of change": assuming we want "global templates" (using the speaker's own preferred definition) and that we don't currently have "global templates", how do we get there from here? There seem to be three main theories of change, which in turn influence a speaker's perspective on their idea of "global templates" and its feasibility:

These are stated in a rather extreme manner, of course; any actual person will have more nuance to their views. However, locating proposals among these axes can be useful for helping determine how success is to be measured and what resources are required "after the project is done" ie, deployed and usable. The theory of change often frames the question: are we trying to build the best new thing possible, any thing (and we'll see if its a good thing later, and if not iterate), the best low-cost improvement, the thing the community wants most, or something decided via another (good or bad) process which the community ultimately will have to use? Will we only succeed if enough people use it? If everyone uses it?

Hopefully this document as it stands can help support clear communication and help folks clarify what, exactly, they are talking about when the discussion turns to "global templates". In another document I will try to lay out some of my own thoughts about possible solutions and my own theory of change.

References

  1. There are actually a number of other "template" implementations, too! We have mustache-like templates used for building UIs, a template system built into vuejs, and various partial reimplementations of portions of wikitext, both client- and server-side, for localized messages. It is always worth double-checking exactly what system is meant when the word "template" floats up.
  2. Templates in the "work flow" context often generate user interface elements, and this leads to its own complexities. Our parser infrastructure in general doesn't handle switching between "content language" and "user interface language" very well, and we quickly stumble into caching and other issues. Separating "user interface" from the "content area" is usually considered desirable, which then dovetails with page layout and other "template" issues (are the labels in infoboxes really "content language" or should they actually be "user interface language"?).
C. Scott Ananian [[User:cscott]]