Template talk:Uw-translation

Improve the suggested attribution statement using the from-article param
This is a proposal to improve the template by taking advantage of the from-article param when it is available, to improve the suggested attribution statement.

Current operation

Currently, the template uses "French" as an example in the model attribution statement embedded in the output message, regardless of what parameters are used to invoke it:

Proposed improvement

But we sometimes know what the language is, because the template includes in optional positional param 1 the name of the foreign Wikipedia article translated from, preceded by the language code, e.g.:. In cases where we have the language code, why don't we change the language name in the attribution statement to take advantage of it, e.g.: We could take it a step further, and include the whole article name, making the suggested attribution statement copy-pastable right into the edit summary: Where there was no parameter 1, we would just default back to "French".
 * 1.
 * 2.

Case 1 – language name only

Here is an example of case #1, the result of subst'ing (using sandbox rev. 1077888254):

Thank you for your contributions to Wikipedia. It appears that you translated text from de:Kriegsschuldfrage into another page. While you are welcome to translate Wikipedia's content, here or elsewhere, Wikipedia's licensing does require that you provide attribution to the original contributor(s). When translating a foreign-language Wikipedia, this is supplied at minimum in an edit summary at the page into which you've translated content, disclosing the translation and linking to the translated page, e.g.,  It is good practice, especially if copying is extensive, to also place a properly formatted translated page template on the talk pages of the page you placed the translation. Please provide attribution for this duplication if it has not already been supplied by another editor, and if you have translated material before, even if it was a long time ago, you should provide attribution for that also. You can read more about the procedure and the reasons at Wikipedia:Copying within Wikipedia. Thank you.

Note: subst protection not yet included in the sandbox, so parser code is included if you view the wikicode.

Case 2 – lang name and article name

Here is an example of case #2, using sandbox rev. 1078125532 to substitute the foreign article name into the attribution summary as well, making it copy-pastable:

Thank you for your contributions to Wikipedia. It appears that you translated text from de:Kriegsschuldfrage into another page. While you are welcome to translate Wikipedia's content, here or elsewhere, Wikipedia's licensing does require that you provide attribution to the original contributor(s). When translating a foreign-language Wikipedia, this is supplied at minimum in an edit summary at the page into which you've translated content, disclosing the translation and linking to the translated page, e.g.,  It is good practice, especially if copying is extensive, to also place a properly formatted translated page template on the talk pages of the page you placed the translation. Please provide attribution for this duplication if it has not already been supplied by another editor, and if you have translated material before, even if it was a long time ago, you should provide attribution for that also. You can read more about the procedure and the reasons at Wikipedia:Copying within Wikipedia. Thank you.

The example looks better, when including the to parameter:

Thank you for your contributions to Wikipedia. It appears that you translated text from de:Kriegsschuldfrage into War guilt question. While you are welcome to translate Wikipedia's content, here or elsewhere, Wikipedia's licensing does require that you provide attribution to the original contributor(s). When translating a foreign-language Wikipedia, this is supplied at minimum in an edit summary at the page into which you've translated content, disclosing the translation and linking to the translated page, e.g.,  It is good practice, especially if copying is extensive, to also place a properly formatted translated page template on the talk pages of the page you placed the translation. Please provide attribution for this duplication if it has not already been supplied by another editor, and if you have translated material before, even if it was a long time ago, you should provide attribution for that also. You can read more about the procedure and the reasons at Wikipedia:Copying within Wikipedia. Thank you.

Note: subst protection not yet included in the sandbox, so parser code is included if you view the wikicode in these examples.

Bad values of param-1

Some invalid values of param-1 will cause illogical output in the model attribution text, where the current template doesn't. For example: But although the current (live) version would emit a proper attribution statement (for French, for this German example), the live version screws up differently, earlier in the template output, emitting: It would, of course, be possible to introduce parameter-checking to disallow values of param-1 that failed to include both a language code and an article name. But the current template doesn't do that now, so including that feature feels to me like an independent task or upgrade, and needn't be bundled into this proposal. In other words, if this proposal is implemented, we'll still have GIGO, as we did before. Mathglot (talk) 02:43, 20 March 2022 (UTC)
 * → ... translated from the existing French Wikipedia article at Kriegsschuldfrage ; ...
 * → ...translated from the existing German Wikipedia article at de: ; ...
 * "It appears that you translated text from Kriegsschuldfrage into another page..." (sans lang-code) in the first case, and:
 * "It appears that you translated text from de: into another page" (sans article name) in the second case.
 * Pinging contributing or likely interested editors.
 * Listed at: WT:Twinkle, Template talk:Translated page, WT:PNT, and WT:WikiProject Translation. Mathglot (talk) 03:29, 20 March 2022 (UTC)
 * Seems like a sensible, but low priority, improvement. I don't think the GIGO issue is significant, especially since this template is substituted so it won't affect previous uses. --Trialpears (talk) 08:34, 24 March 2022 (UTC)

Improve the mention of the 'translated page' template
Given the presence of optional param-1 (Article translated from) and named param to (Article translated to), we could improve the message and provide a copy-pastable version of the translated page template. For example, given, we could generate the text to "place a properly formatted translated page template on the talk pages, like this:. Mathglot (talk) 04:02, 20 March 2022 (UTC)