Wikidata:Bot requests/Archive/2016/02

Changing values (P1417)

Currently just a question (need to do a preparation job). Could a bot go through Encyclopædia Britannica Online ID (P1417) and change value to what you get at their page URL. That is, for Jean-François Champollion (Q260) change "105225" to "biography/Jean-Francois-Champollion". Digits-only values are old identifiers, which should be converted to the new ones. --Edgars2007 (talk) 17:55, 5 February 2016 (UTC)

I don't think this should be done. New identifiers should go to a new property.
--- Jura 09:22, 11 February 2016 (UTC)
@Jura1: but those digit values are simply redirecting to the new ones. OK, actually I don't care do we convert these or create a new property, I just want to get working property :) So I request the new property and then mark Encyclopædia Britannica Online ID (P1417) as deprecated (if the new property is created, of course)? --Edgars2007 (talk) 12:20, 16 February 2016 (UTC)
This section was archived on a request by: Edgars2007 (talk) 10:17, 25 February 2016 (UTC)

Moving coordinates to headquarters (again)

In a case of company items instance of (P31)=company (Q783794) or business (Q4830453) the coordinates coordinate location (P625) are related to headquarters headquarters location (P159), so if listed separately (WDQ (CLAIM[31:783794] OR CLAIM[31:4830453]) AND CLAIM[625] AND CLAIM[159]), they need to be moved as qualifier of headquarters location (P159). Any bot can help me with this again (app 100 items)? --Jklamo (talk) 00:31, 8 February 2016 (UTC)

  Done
This section was archived on a request by: --Pasleim (talk) 17:12, 25 March 2016 (UTC)

Import GND identifiers from VIAF dump

We found out that the VIAF dump contains about 48,000 more links to the German integrated authority file GND (P227) than Wikidata. That could be an easy and worthy enrichment of Wikidata!? --Michael Büchner (talk) 13:08, 15 February 2016 (UTC)

How can a wikidata-item be connected to an entry from the VIAF-dump? Edoderoo (talk) 12:11, 17 February 2016 (UTC)
We have VIAF ID (P214). So the VIAF id can be matched against that property. Mbch331 (talk) 12:24, 17 February 2016 (UTC)
The VIAF dump contains the Wikipedia URL, too. --Michael Büchner (talk) 15:57, 17 February 2016 (UTC)
In most cases yes, but if the VIAF id was recently added to an item, it might not have been synchronized yet. So matching VIAF id against VIAF ID (P214) looks safer too me. Mbch331 (talk) 22:00, 17 February 2016 (UTC)
In August 2015 User:KrBot tried to add missing VIAF Id's to Wikidata based on VIAF listing the corresponding Q'ids. This went moderately well for persons but had to be aborted for other classes of items. Just today I noticed that Giacomo Franco (Q3762105) was about a completely different person thant the sitelink the item had been created for - User:ShonagonBot had flooded the item with high quality BNF data, unfortunately founded on the association VIAF had performed. Furthermore (especially with ULAN data) VIAF has a tendency to mix different persons in one item. Thirdly many of the P214's here stem from a donation from VIAF to en:WP in 2012(?) and where never intellectually checked. So: Even when we can have some more confidence that a VIAF ID (P214) here is really about the item (in comparison to a Q-id listed by VIAF) we should not too heavily rely on that being the case and the ingestion of the inferred other authority numbers performed by VIAF adds another layer of incertainity on top of this. And there is also a question of incompatible licenses... -- Gymel (talk) 13:37, 21 February 2016 (UTC)
This section was archived on a request by: Jura 08:14, 8 April 2016 (UTC)

Clean-up

Some time ago I wrote at Project chat about ~7200 items (at that moment) for categories (with Q4167836) and without sitelinks in them. Multichill said then:

A bot should go over it and only work on items that had 1 sitelink:
  1. If the linked category was deleted -> nominate for deletion
  2. If the linked category was moved to another item -> merge with the other item
  3. If the linked category doesn't have a wikidata item -> restore the sitelink

Is anyone interested in this task? --XXN, 21:50, 17 February 2016 (UTC)

I think (2) is already done by PLbot. If (3) applies, eventually a bot will or already has created a new item.
--- Jura 17:41, 18 February 2016 (UTC)
(1): If the only linked page (not only category) was deleted, I put it on User:Pasleim/Items for deletion/Page deleted. Maybe WD:RFD would be a better place. --Pasleim (talk) 12:34, 26 February 2016 (UTC)
Probably items marked with Wikimedia category (Q4167836) or Wikimedia template (Q11266439), with the only sitelink removed because page on wiki was deleted - can be deleted directly by some bot-sysop, as such type of items does not meets notability criteria. I think I saw somewhere here such a task aproved. In case of articles probably is still necessary additional verification by humans and is ok to list them on a special page. This page and its subpages are not very visible; maybe to put a link to it somewhere in WD:RFD page? --XXN, 13:10, 26 February 2016 (UTC)

Soft redirected categories in WD items

Some time ago I noticed that there was more than 900 sitelinks of en.wiki soft-redirected categories in WD items, 400+ pt.wiki and 100+ sitelinks of ro.wiki soft redirected categories in WD items. The sitelinks to soft redirected categories should be removed, and, if there are no more sitelinks - current items to be merged in items of target categories /or proposed for deletion. --XXN, 21:50, 17 February 2016 (UTC)

Instance of category/template etc.

In last days some user created thousends of items for categories/template/modules from major Wikipedias, but without any statement. It's necessary to query DB for these/all items with namespace titles (Category, Template, etc.) in sitelinks to add P31 to them (Q11266439, Q4167836, etc.) --XXN, 21:50, 17 February 2016 (UTC)

I did some clean-up for those few months ago. Will re-do. --Edgars2007 (talk) 19:14, 18 February 2016 (UTC)
I'm now checking for 11 languages, but it seems that most of the templates are now done. Will check the other name spaces too. Edoderoo (talk) 15:56, 19 February 2016 (UTC)

@XXN: @Edgars2007: @Edoderoo: just remembered I had a bot to do this. I first do a query to find all items with a sitelink with a ":" in it, but without any statements. I had to modify the old query because it was too slow. Slight difference is that categories that only have Commons category (P373) won't be returned, but that's quite minor. The resulting list contains 138.985 lines. I have a simple Pywikibot based bot that adds the type based on the namespace:

It's currently running and doing quite a few edits. I was thinking about setting this up as a regular job and using User:NoclaimsBot for that, but never really got around doing that. Multichill (talk) 12:36, 21 February 2016 (UTC)

138k... OMFG! Thanks Multichill, I see your bot working. It was important to do this task now, coz a delay of one week/month or more - would have made tools like "Random item without instance" somehow useles, and meanwhile some users would have done a Sisyphean work adding these P31. --XXN, 22:09, 21 February 2016 (UTC)
@Multichill: BTW, some Wikipedias have special namespace "WikiProject", which could be tagged as Wikimedia project page (Q14204246). See for example WikiProject Speculative fiction (Q22138339) ru and pl wikis. OK, that page is already tagged, but wanted to let you know about this fact. Although, don't know, how popular this namespace is at Wikidata without instance of (P31). --Edgars2007 (talk) 10:16, 25 February 2016 (UTC)
Almost forgot to mention: the list is much shorter now 9.359 lines to be exact. That should relieve the humans. As for other namespaces, "WikiProject" has difference namespace numbers across projects so that doesn't work with this logic. MediaWiki (8) and Help (12) will work. Could someone point out which objects I should use for these?
The remainder will be human work. Multichill (talk) 22:28, 25 February 2016 (UTC)
Nice work. Thanks!
--- Jura 06:34, 26 February 2016 (UTC)
Maybe enwiki:Book: → P31:Q6540697
--- Jura 13:59, 26 February 2016 (UTC)
@Multichill: I'd use Q14204246 for Help:
--- Jura 08:19, 2 March 2016 (UTC)

Double redirects

There are many double redirects: 98% items + some other pages. Is anyone interested to get this task to do on a regular basis (if is not already done by someone else; but I see some items are double-redirected for no less than 10-12 days)? --XXN, 12:15, 26 February 2016 (UTC)

My bot is normally doing this. It stopped couple weeks ago due to an error but I have now restarted it. --Pasleim (talk) 12:28, 26 February 2016 (UTC)
Didn't know. Ok, TY! --XXN, 13:05, 26 February 2016 (UTC)
This section was archived on a request by: Jura 08:14, 8 April 2016 (UTC)

Importing ECHA InfoCard ID

ECHA Substance Infocard ID (P2566) is ready to be added to a few thousand items of chemicals (example). Data is available on http://echa.europa.eu/information-on-chemicals/registered-substances. Matching should be done using CAS Registry Number (P231). --Leyo 22:45, 29 February 2016 (UTC)

Leyo I don't want to be the bad guy but before starting to import some data based on CAS Registry Number (P231) we should solve the constraint violations of this property. See Wikidata:Database reports/Constraint violations/P231. Then I think we should combine CAS Registry Number (P231) and PubChem CID (P662) in the import: a ECHA InfoCard ID should be imported only if CAS Registry Number (P231) and PubChem CID (P662) of the data set match the CAS Registry Number (P231) and PubChem CID (P662) values present in WD item. Snipre (talk) 11:04, 14 March 2016 (UTC)
Items listed in Wikidata:Database reports/Constraint violations/P231 may be skipped and treated manually or later.
There is no PubChem CID (P662) in ECHA's data set. --Leyo 23:21, 14 March 2016 (UTC)
This section was archived on a request by: Jura 08:14, 8 April 2016 (UTC)

Moving coordinates to headquarters (again)

In a case of company items instance of (P31)=business (Q4830453) the coordinates coordinate location (P625) are related to headquarters headquarters location (P159), so if listed separately (WDQ (CLAIM[31:783794] OR CLAIM[31:4830453]) AND CLAIM[625] AND CLAIM[159]), they need to be moved as qualifier of headquarters location (P159). Any bot can help me with this again (app 200+ items)? --Jklamo (talk) 00:31, 8 February 2016 (UTC)

seems to be done
This section was archived on a request by: --Pasleim (talk) 13:26, 11 July 2016 (UTC)

Metadata on listed buildings in Wales from en:Template:Cadw listed building row

en:Template:Cadw listed building row is transcluded in 41 list articles about historic buildings in Wales on the English Wikipedia. The pages contain a lot of information it would be helpful to have on Wikidata, notably images, Commons categories and locations. Wikidata items exist for all the buildings in question but in most cases they don't have this information – here's a random example: Church of Saint David (Q17743261). The hb = parameter in the template matches up with Cadw Building ID (P1459), so that's how the items would be identified. Could a bot add the following metadata to the items?

Cheers, Ham II (talk) 16:50, 29 January 2016 (UTC)

Ham II, not sure you discovered Wikidata:WikiProject Cultural heritage yet. I did what you're describing several years ago for the Rijksmonument (Q916333). Strategy is to find all items already here and clean them up and then grab data from the monuments database. Multichill (talk) 20:07, 5 February 2016 (UTC)
@Multichill: Thanks for the pointer towards WikiProject Cultural heritage. The reason I think importing data from the Wikipedia lists is important is because of the images and Commons categories that have been added to those pages over the years. The rest of the data, I'm sure, could come from the monuments database. Ham II (talk) 09:45, 6 February 2016 (UTC)

Storing ICD9 and 10 codes from EN medical templates

Proposal

I propose that the ICD9 and ICD10 codes are located on medical templates in the English Wikipedia and stored here.

Context

Most templates associated with WikiProject Medicine on the english wikipedia have associated ICD9 and 10 stored in their titles: eg. [1]

This is an attempt to store related data that is better stored here, on Wikidata. This benefits readers by allowing data to be stored in a more appropriate location, and benefits data handlers by giving them more data to play with and analyse at some future date :)

Precedence

A previous bot took similar data (Gray's Anatomy and Terminologia Anatomica data) from anatomical templates and stored them here. The bot request for that is here: [2]

Comments

Ping to @ValterVB who was so helpful last time :). --LT910001 (talk) 22:13, 10 February 2016 (UTC)

Just for record: Wikidata:Bot requests/Archive/2015/02#Move all template ICD9 and ICD10 references to wikidata. --Edgars2007 (talk) 22:31, 10 February 2016 (UTC)

Sorting flags by level of government

Hello. I'm trying to control constraint violations for applies to jurisdiction (P1001). Could someone please:

  1. For items in w:en:Category:National flags, change instance of flag (Q14660) to national flag (Q186516).
  2. For items in w:en:Category:United States state flags could you please change instance of flag (Q14660) or national flag (Q186516) to flag of a country subdivision (Q22807280).
  3. For items in subcategories of w:en:Category:Flags of cities by country, change instance of flag (Q14660) to municipal flag (Q22807298).

Thank you! --Arctic.gnome (talk) 20:59, 15 February 2016 (UTC)

@Arctic.gnome: Sorry for the delay, I'm ready to do this. Could please just in case provide a rationale why it is okay to do this task? Matěj Suchánek (talk) 13:32, 16 April 2016 (UTC)
@Arctic.gnome: please respond to this section, otherwise it will be archived. Sjoerd de Bruin (talk) 08:51, 12 October 2016 (UTC)
@Matěj Suchánek: Since making this request I've changed the constrants of applies to jurisdiction (P1001), so this is no longer strictly necessary. It might still be a good idea for pages to diferentiate between national flags, sub-national flags, and non-government flags. But I don't know whether or not "instance of" is the correct place to do that. On some types of pages, the "instance of" property uses a very detailed value, while in other cases (like "human" and "position") we only use a general term for the instance property. --Arctic.gnome (talk) 15:43, 12 October 2016 (UTC)
This section was archived on a request by: Matěj Suchánek (talk) 14:19, 20 November 2016 (UTC)