Template talk:Interwiki from Wikidata

From Wikimedia Commons, the free media repository
Jump to navigation Jump to search

Preference of category links fails[edit]

@Jarekt: Hi Jarek. As i remember, recently the template combined category links and article links with preference of category links, as said in the documentation: "For Wikipedias without category interlanguage links, interlanguage links to Wikipedia articles are added." However, today the template displays article links only, as they are preferred to avialable category links (e.g. in Category:Radnice (Rokycany District), there exist cs and de category links but they are ignored and overlapped by article links, no category link is displayed). Is it some error or change of the function? --ŠJů (talk) 22:53, 7 September 2017 (UTC)[reply]

ŠJů, thanks for reporting this. I think that is caused by this change by User:Multichill. Multichill, the idea of the template is that when used in category namespace, it adds Wikipedia interwikilinks to languages for which category links are not available. (That is probably not how I was describing it in other discussions). I would like to restore previous functionality, but I can add a mode parameter, where mode=merge will have old functionality and mode=replace will have current functionality. --Jarekt (talk) 12:19, 8 September 2017 (UTC)[reply]
Consensus seems to be that linking to Wikipedia categories is useless (and I agree). I updated the template to reflect that. I oppose reverting this or adding this option. You might want to update the documentation. Multichill (talk) 13:57, 8 September 2017 (UTC)[reply]
@Multichill and Jarekt: This view can correspond to the fact that Commons categories of individual subjects are equivalents of Wikipedia articles (while Commons gallery pages are equivalents of photocollage files). However, Commons category of an individual subject is also an equivalent of Wikipedia category of the subject (if such category exists). Regrettably, our primary problem is in wrong construction of Wikidata which don't follow their own point that "one item = one Q code". IMO Wikidata item page should contain both - article links and category links of identical item under one Q code – the linking through "main article" and "main category" is too tortuous and not so functional and effective and complicates to apply and excerpt other properties. Independently on the fact which solution will winn now, I want to thank Jarekt for the previous variant of this template. This combinative way of interwiki linking was just that which was used previously by intelligent users to span gaps and imperfectness of the system. Maybe, a better and more systematic solution can be to display two blocks of interwikis separately: at first all links to categories, after that all links to articles. Of course, most of Commons categories would have one of the two blocks empty. --ŠJů (talk) 21:22, 8 September 2017 (UTC)[reply]
One recurring thing I see is that people want to mess up data models to achieve their short term goals. A category is a set of wikipages related to a certain subject an article is about the subject. Wikidata is pragmatic. We split up when we need to, but we try to keep it consistent. That's the data modelling. The next step is how and what you want to show to your users. When I'm on Category:Haarlem it makes more sense to me to link to nl:Haarlem instead of nl:Categorie:Haarlem. This is a user interface choice that can be made without changing the data model.
Let's focus on this user interface part. This is the part we can change and improve. See for example what the taxo people are doing in Category:Biology pages with wikidata link. They're slowly switching to Wikidata. Per domain (taxons, people, etc) you could make different layout templates that show the convenient information for that domain and maybe some of them will also show links to Wikipedia categories.
Some people keep trying to change the fundamental data model of Wikidata, but that's as useful as banging your head against a block of concrete: It just hurts and it won't budge. Let's work on the things we can change and improve here. Multichill (talk) 10:27, 9 September 2017 (UTC)[reply]
@Multichill: A category is a container of pages about its item and an article is a block of illustrated text about its item. Even a Wikipedia article is not identical with its item itself, as well as a category isn't. According to the original idea, one Wikidata item page should represent one item: thus it should link both, articles of the item as well as categories of the item, both by the same way, directly and effectively. As you said correctly, the output interfaces and their settings can controll selectively which of the data from the Wikidata item page are displayed. Regrettably, designers of Wikidata had probably not so advanced conceptual thinking to understand it. Maybe they had few information and experiences about Commons and little capability to analyse essence and types of categories (their notion applies only to "group categories" and "meta categories", typical by plural name - but even they can be equivalents of list or summary articles). Maybe, they was who really "mess up data models to achieve their short term goals." That caused all the problems, the mess, the needless duplication of Wikidata item pages by secondary and unusable "category items", the hobbling and disunited connection to Commons etc.
This template {{Interwiki from Wikidata}} is only a makeshift patch to compensate the basal problem. Regrettably, the new function of this template lost (hid) links from Commons categories to Wikipedia categories of identical item. The Jarek's solution was a reasonable compromise which merged both wanted and seemingly colliding functions and treated their collision sensibly (if two interwiki links are in overlap, the higher of them should be preferred because the article of the item should be always contained in the category of the item if such a category exists). The recent Multichill's version simulates simply a (constantly wanted and rejected) direct Wikidata linking "Commons category - Wikipedia articles" and hides completely matching Wikipedia categories. I think, there exists a simplier way to get such a result, and this template is not needed for it :-) And the other (and better) solution I proposed above remains uncommented still.
Reciprocal properties which really don't work as reciprocal are the second fatal problem. Chaotic amount of properties which have no effective relation each to others and which cause unsustainable, unmaintenable, unorganized tangle of reduncancies and inconsistencies is the third fatal problem. Poor and inconsistent structure of the base and skeleton make the whole work less usable and every application more complicated and less attainable. The sooner will fundamental defects of Wikidata construction rectified, the better. Regrettably, as you aptly said, every such trial is as banging a head against a block of concrete. We can await no intelligent reaction from a block of concrete. The question is whether a block of concrete should lead development of MediaWiki. To overcome technical obstacles and to find technical solutions seems to be much easier than to discuss with "blocks of concrete" and to gain their comprehension and consensus. I would like to keep my believe that not all developers (and Wikimedia managers) are like "blocks of concrete". :-) Of course, if this my believe fails, Wikimedia users will look for solutions despite blocks of concrete, they will bypass such barriers like the mindless concrete. I'm thankful for original wiki developers who invented such brilliant and universal ideas as wikilinks, interwikis, wikicategories and multihierarchic categorization which interlocks more types of relations! I wish they have their respectable successors! ---ŠJů (talk) 14:15, 9 September 2017 (UTC)[reply]
Supposedly a Wikidata item refers to a particular topic, not just a collection of Wikipedia articles, so linking both categories and articles would make sense. It seems it won't change anytime soon. In the meantime, I don't think adding an argument to the template to switch between the two behaviours is a good idea. It could be a user preference, if that was practical to implement. I like the idea of displaying the articles and categories in two blocks, although it will be a long list in some cases. --ghouston (talk) 23:46, 10 September 2017 (UTC)[reply]
What about a 2 columns-list displaying articles and categories interwiki-links and an empty space in the table for a non-article or a non-category link ? and showing of a columnsheadline of Article ! Category. Best regards Migrant (talk) 22:01, 14 September 2017 (UTC)[reply]
I don't know if a Commons template has that much control over the formatting. Some lanaguage labels are also quite wide, like "Bahasa Melayu", and there wouldn't be enough space for two columns. --ghouston (talk) 22:13, 14 September 2017 (UTC)[reply]

Maybe we should ask broader community at Commons:Village pump/Proposals about their opinion. --Jarekt (talk) 17:30, 11 September 2017 (UTC)[reply]

I agree, even though such a discussion can remain without any conclusion. Is somebody able and willing to formulate the problem briefly and aptly at Commons:Village pump/Proposals?
Btw. Multichill, you wrote "Consensus seems to be that linking to Wikipedia categories is useless". Can you link please the discussion where such a consensus seems to be shown? I think, interwiki links category-category are generally reasonable and useful, even though main articles should be also linked from their categories, and maybe, article links are more desired.
@Migrant, Ghouston, and Multichill: According to my very rough estimate, ca 45% of Commons categories will never have any interwiki, 30% will link to articles only, 15% can link to categories only and no more than 10% can link both together, categories as well as articles – and no more than 1% of Commons categories can have problems with too long list of interwikis. Btw., in case of the most frequented items, such a problem we have also with one simple block of interwikis, and some attempts to filter the most relevant interwikis were done.
Of course, to use two columns of the current width is not compatible with the current layouts. However, it is not useful to repeat twice the language name when we have two links to identical wiki version. We can use e.g. two small clickable icons (C for a category, A for an article, with tooltips) past or before the language name. --ŠJů (talk) 12:40, 16 September 2017 (UTC)[reply]
@ŠJů: Thanks for elaborating on my idea and making it even a better solution!! Best regards Migrant (talk) 12:53, 16 September 2017 (UTC)[reply]

Description[edit]

Explore the wonders of Template:Interwiki from Wikidata, its description is wonderfully unclear without any example, well it worked for me, I got rid of sILLy ILLs inserted by me, but what I really wanted was the normal "wikidata item" link for d:Q728415, how can I trigger that? It would be perfectly fine if it's handled automatically at least once per year. –89.15.239.28 06:44, 22 October 2017 (UTC)[reply]

A "normal" site link? I've set it up for that page. There's a link at the bottom of the left toolbar called "Add links" where it can be done, or by editing the item directly in Wikidata. --ghouston (talk) 21:48, 31 October 2017 (UTC)[reply]

Removal[edit]

Can we remove this template from those categories which also have a {{Wikidata Infobox}}? [1]. --Arnd (talk) 06:42, 22 August 2018 (UTC)[reply]

Only in categories?[edit]

In this edit by Jarekt, with the comment add Category:Interwiki from wikidata, this template was disabled everywhere except for categories. Why? It makes sense elsewhere as well, for example I tried to use it on Commons:Village pump/Interwiki, but had to call the module directly, which is not a nice solution. If some particular other template doesn’t want to display the links outside of the category namespace, than that template should add the namespace guard, not this. —Tacsipacsi (talk) 22:53, 22 March 2020 (UTC)[reply]

In most cases interwikis are added automatically based on Wikidata sitelinks. Commons categories are special since sometimes it is a gallery that is connected, so we have this template to add sitelinks to categories. The problems arise when the code is used in other namespaces, I do not recall in what kind of trouble we run into but the simplest solution was to restrict the module to the namespace it was written for. May be the trouble was with all the categories which are pretended to be templates and are displayed in files, like this one. --Jarekt (talk) 23:14, 22 March 2020 (UTC)[reply]
Then hide in file namespace, but don’t hide in all namespaces. It’s basically useful anywhere. —Tacsipacsi (talk) 01:41, 23 March 2020 (UTC)[reply]
@Jarekt: Also on Template:Main2d:Q6797933 is occupied by Template:Main gallery, so we can only rely on wikitext interwiki links, and, because of this namespace guard, only manual ones, which are bound to get out of sync—there are already some pointing to redirects, and it’s only a question of when to also have broken ones. —Tacsipacsi (talk) 18:24, 5 March 2021 (UTC)[reply]
Tacsipacsi, Sorry forgot about this thread Shall we rewrite the first line as {{#ifeq:{{NAMESPACE}}|File||{{#invoke:Interwiki|interwiki|qid={{{wikidata|{{{Wikidata|{{{1|}}}}}}}}}}} ? --Jarekt (talk) 18:58, 5 March 2021 (UTC)[reply]
@Jarekt: No problem, I also forgot about it, just wanted to use it and found out again that it doesn’t work… Yes, your proposal looks much better than the current solution. —Tacsipacsi (talk) 23:32, 7 March 2021 (UTC)[reply]
✓ Done --Jarekt (talk) 01:40, 8 March 2021 (UTC)[reply]

Template use in file descriptions[edit]

Hello Jarekt and all- I came across this template while looking for one that would make use of a Wikidata ID number in the description of a species-related file on Commons. However I cannot see how to implement the template. I experimented with using it in the description for File:Mimus_polyglottos_adult_02_cropped.jpg ( Wikidata:Q829683), for example, but my previews either generated errors or ignored the template completely. I was hoping to find some template that would use a Wikidata Q number the way the first parameter of Template:Depicted person does;

For example, {{Depicted person|Q7742}} generates:

Depicted person: Louis XIV of France – King of France and Navarra, from 1643 to 1715 — I'm guessing the resulting description is generated in English because Commons "knows" I'm anglophone, and that if my home wiki were pl, the info on Louis would be in Polish.

But my searches for species-related templates yielded nothing helpful. I did find Template:Species, but it does not call for Wikidata IDs. Any ideas? Eric talk 19:13, 28 December 2021 (UTC)[reply]

Eric, There is {{VN|useWikidata=Q829683}} that uses wikidata item ID, and there are {{Specimen}} and {{Biohist}} which are rather badly written and do not use Wikidata. We also have Module:Wikidata4Bio and Module:Biology, but I am not sure what they do. If you want something similar to Template:Depicted person. Than you can use {{#invoke:Depicted people|main|Q829683}} ("Northern Mockingbird – species of bird") --Jarekt (talk) 07:13, 29 December 2021 (UTC)[reply]
Thanks, Jarekt! I don't think I would have found VN on my own. Side note: ...Template:vn and ...Template:Vn were redirecting to Template:Neutral, which I found annoying, so I changed the redirect. Hope I didn't screw anything up! Eric talk 19:19, 29 December 2021 (UTC)[reply]