Wikidata:Contact the development team/Archive/2019/12

From Wikidata
Jump to navigation Jump to search
This page is an archive. Please do not modify it. Use the current page, even to continue an old discussion.

SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } to output lemma?

When using ?entity ?entityLabel, this gives the label for items (and properties), but nothing for lexemes. I wonder if it shouldn't output the (or a) lemma. --- Jura 10:20, 16 November 2019 (UTC)

The current way to query for lemmas is working well and doesn't require the expensibe wikibase:label service. I don't see any reason to change it. Lea Lacroix (WMDE) (talk) 08:33, 2 December 2019 (UTC)
SELECT ?entity ?entityLabel
{
    ?entity wdt:P31 wd:Q202444 .
    SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}  
LIMIT 2000
Try it!

Sample query above. It currently outputs a series of items plus L58618-S3. The items have labels, but Venuše (L58618) just lists "L58618-S3". --- Jura 09:07, 2 December 2019 (UTC)

Thanks for sharing this usecase. It is indeed annoying when the result of the query contains both Items and Lexemes. However, I don't think it causes a major break in the workflow. Lea Lacroix (WMDE) (talk) 09:35, 2 December 2019 (UTC)

VIAF as first identifier in human items

There seems to be consensus here. Could you have a look, in order to decide how to proceed? Thank you very much, --Epìdosis 17:08, 24 November 2019 (UTC)

You should be able to edit MediaWiki:Wikibase-SortedProperties, add the VIAF property in the list, and the order will be changed (maybe after purging the item pages).
Could you make sure that the RFC is officially closed before doing it, then try and let me know if it works as expected, or if you encounter issues? Lea Lacroix (WMDE) (talk) 13:54, 26 November 2019 (UTC)
@Lea Lacroix (WMDE): I've tried to add VIAF ID (P214) to MediaWiki:Wikibase-SortedProperties, but it doesn't work at all. Could you have a look? Thank you, --Epìdosis 13:31, 1 December 2019 (UTC)
External IDS properties on this page are not split like on the interface. What about removing the title and placing P214 at the top of the list? Lea Lacroix (WMDE) (talk) 07:16, 2 December 2019 (UTC)
It works. It just needs the item to be updated to take effect. --- Jura 07:27, 2 December 2019 (UTC)
You're right! Purging the page (by adding ?action=purge to the URL) works. I just tried it on Melanie (Q157293). Lea Lacroix (WMDE) (talk) 13:55, 2 December 2019 (UTC)
You are both right, either purging the item or editing it makes VIAF work. @Lea Lacroix (WMDE), Jura1: Thank you very much! --Epìdosis 15:44, 3 December 2019 (UTC)

Query for specific string with variables

SELECT * WHERE {
  BIND("Douglas Adams"@en as ?name1)  BIND(strafter(?name1, " ") as ?name)  #slow
  OPTIONAL { ?lastname wdt:P31 wd:Q101352 ; rdfs:label ?name }
}
Try it!
SELECT * WHERE {
  BIND( strlang("Adams", "en") as ?name)                                  #slow
  OPTIONAL { ?lastname wdt:P31 wd:Q101352 ; rdfs:label ?name }
}
Try it!
SELECT * WHERE {
  BIND("Adams"@en as ?name)                                               #fast
  OPTIONAL { ?lastname wdt:P31 wd:Q101352 ; rdfs:label ?name }
}
Try it!

Is there are way to get the first two queries to run as quickly as the last one? If not, there might be some bug in the way the Blazegraph executes them.

I asked the question at Wikidata:Request_a_query#Query_for_last_name, but we couldn't find a solution.

BTW, to effectively compare the three, you might need to change the string/order you execute them. Time varies a lot even for the same type of query. --- Jura 07:48, 3 December 2019 (UTC)

Suggestions for the next iteration of item value value suggestions

It might be worth doing another of the annual (?) iterations to improve the suggestions one gets when adding statements manually to Wikidata.

Here a few:

  • (1) When adding statements, we currently get suggestions from "one of constraints" on properties. The same could work when adding qualifiers (e.g. P5102#P2302 for qualifier nature of statement (P5102)). Also, it might be worth being able to restrict that by a specific constraint on the property the qualifier is being used on (see the experimental one-of qualifier value property constraint (Q52712340)).
  • (2) Similarly, units could be suggested from units in property constraints.

I'm sure we could come up with a few more. --- Jura 13:04, 10 November 2019 (UTC)

Hello, the page Wikidata:Suggester ranking input is still open for suggestions, feel free to add them there. Lea Lacroix (WMDE) (talk) 08:47, 11 November 2019 (UTC)
Sounds good. Could you update the page with more recent plans? It reads "currently" and links to an email from 2017. --- Jura 10:12, 12 November 2019 (UTC)

{{[[Template:|]]}}

Could you do an update of the page? --- Jura 13:48, 18 November 2019 (UTC)

This is under the responsibility of WMF people. Since they are currently hiring people, I will let them time to settle before pinging them again about this page. Lea Lacroix (WMDE) (talk) 13:28, 26 November 2019 (UTC)

Yes, the suggestor is maintained by the discovery team. I am already in contact with them. Please let us some space and time, there is a lot to do at the moment with onboarding new people and getting up to speed. We will reach out to the Wikidata community later and provide information about who is working on what. In general, please be patient with the development team. We have a lot to do and we definitely can't address the many requests you post on this page. Lea Lacroix (WMDE) (talk) 08:59, 6 December 2019 (UTC)
  • Take your time, but I think it would be good structure the community input for that feature in some way. It is mainly a feature for the Wikidata community and some minor tweaks can be a big overall improvement. Are you still exclusively the liaison for the Wikidata community? --- Jura 09:16, 6 December 2019 (UTC)

Suggestion: Foldable Statements

Hello all,

I'm not sure this is the right place to post such a comment, so I beg your pardon for any mistakes in advance. Even though the whole point of Wikidata is to have a computer-ready knowledge base, from time to time it is also useful to go and manually check the items here. Here goes the problem: Some itens have statements with multiple, referenced values, which is good, but it kind of makes the page harder to manually scroll. An example is the variety of biological processes associated with the protein PD-L1. Here goes the suggestion: It would be awesome to be able to fold statements in the same way that we are able to fold references (or fold code, for that matter).

It is not really a bug or a problem, but I reckon this feature would improve even more Wikidata's usability.  – The preceding unsigned comment was added by TiagoLubiana (talk • contribs).

+1. See for instance France (Q142), having very long statements, thus the page is slowly loading and the "modify" buttons do not appear quickly. If the page size is above a certain size, all statements should be presented collapsed/folded first... Bouzinac (talk) 12:55, 3 December 2019 (UTC)
 Support If voting is allowed, I would say this is indeed a required feature (other examples include population values of cities, software versions of softwares). Though, I think creating a suggestion on Phabricator will be better. John Samuel (talk) 13:00, 3 December 2019 (UTC)
I think that this would be a good usecase for a user script or a gadget (that could be enabled in the preferences by people who want to use it). Could one of you start a Phabricator ticket, giving more details about how you imagine it to work? Lea Lacroix (WMDE) (talk) 13:45, 3 December 2019 (UTC)
Here's the phabricator ticket: T239820 . John Samuel (talk) 14:21, 4 December 2019 (UTC)

Search doesn't include subtitle field?

Some titles exceed the title limit (of 250 characters,) but the property subtitle appears to not be limited as such. When splitting too-long titles into title and subtitle, one can convey all the essential info. It would, however, be helpful if searches looked at the subtitle field to find those results. Can you enable this? Trilotat (talk) 21:33, 22 November 2019 (UTC)

Do you have examples? Lea Lacroix (WMDE) (talk) 08:22, 28 November 2019 (UTC)
I think it's any subtitle. --- Jura 20:17, 28 November 2019 (UTC)
Here is the item that got me thinking about this, review of Egypt and Africa. Joyce Tyldesley. Chronicle of the Queens of Egypt from Early Dynastic Times to the Death of Cleopatra (Q58890343). Please search for any phrase in the subtitle to see what I'm describing. Thanks. Trilotat (talk) 15:21, 3 December 2019 (UTC)
Thanks for the example. Indeed, search is not browsing the subtitle and haswbstatement:"P1680=..." doesn't work well in that case.
@DCausse (WMF): Can you maybe give us some insight about what kind of content Special:Search takes in account and how difficult/relevant it would be to include the value of subtitle (P1680)? Lea Lacroix (WMDE) (talk) 16:57, 3 December 2019 (UTC)
The search keyword haswbstatement has been designed to search for codes or IDs (short strings) if we enabled it for P1680 you would have to search for haswbstatement:"P1680=the full subtitle text" which might not be very usable on text. On the other hand the engine will index all "textual" properties meaning that your search query will also search for P1680 without telling it to do so, ranking might not be perfect but if your search query is precise enough you might find it near the top, e.g. 978-0-500-05145-0. Unfortunately you don't have the possibility to filter only on this particular property. DCausse (WMF) (talk) 16:16, 5 December 2019 (UTC)
So, it appears maybe it does search the Subtitle field. Forgive me, but I didn't understand the technical parts of DCausse's reply, but I did another targeted search and found exactly what I was looking for. Strange. Sorry for the distraction. Trilotat (talk) 16:57, 5 December 2019 (UTC)
I don't think the above is/was a great sample. Part of the string was also in the labels, so it wasn't visible that it isn't indexed.
Maybe Special:Search/Snowhite A Christmas Story that doesn't find Q58183681 illustrates it better (at least as of this version of the item. --- Jura 18:47, 5 December 2019 (UTC)
Thanks for the example, indeed something stopped working properly recently and is causing all the textual properties to disappear from the search index (not only subtitle). My first example stopped to work as well and no longer finds review of Egypt and Africa. Joyce Tyldesley. Chronicle of the Queens of Egypt from Early Dynastic Times to the Death of Cleopatra (Q58890343). I filed a task to fix this issue. DCausse (WMF) (talk) 11:43, 10 December 2019 (UTC)
Sorry please scratch my comment above, for some reason I thought that we already indexed all textual properties (work done in phab:T163642) and as pointed out I was confused by my misleading example, I'll re-purpose the task attached to this question to see how we could add this data to the search index. Sorry for the confusion. DCausse (WMF) (talk) 12:33, 10 December 2019 (UTC)

Page for thumbnail

On Q75803176#P996, when displaying the thumbnail for document file on Wikimedia Commons (P996), would it be possible to display the page indicated by the qualifier file page (P7668) instead of the first page? (compare sample above). Ideally, any P7668 on a Commons property displaying images would do that. The default first page isn't necessarily the ideal one. --- Jura 06:22, 4 December 2019 (UTC)

Hello,
After discussing about it with Lydia, our assumption is that this doesn't happen often enough to be worth a specific development for now, as we have plenty of other priorities. If more people disagree and want to support thi, feel free to do it here. Maybe this could be done through a user script. Lea Lacroix (WMDE) (talk) 12:05, 9 December 2019 (UTC)
SELECT *
{
    ?item p:P996 ?st .
    ?st ps:P996 ?scan .
    ?st pq:P304 ?pqvalue .
    FILTER( contains(str(?scan), "djvu") ) 
}
Try it!

Hi Léa.

Thanks for your feedback. Sounds reasonable. People interested might be regular Wikisource+Wikidata contributors: .. @Hsarrazin:

I don't know if this is complicated to put in place or not (a few lines of code or a new module). Maybe you could add it at the right place in the phab-pipeline, so it could be done when (e.g. 2021) some tweaks in these fields are done (image thumbnail display or Wikisource support at Wikidata).

Some 120 pages current statements could use. I think they are mostly by Vieux_têtard (talkcontribslogs). Some with title page number (P4714) sometimes used by myself/Jarekt (talkcontribslogs) could use a similar feature.

Obviously, if we add document file on Wikimedia Commons (P996) statements in a more systematic way, this could go into the thousands/ten thousands. Currently, these statements are only marginally useful as the pdf/djvu-page can't easily be identified/clicked. --- Jura 12:30, 9 December 2019 (UTC)

on frwikisource, we systematically record the number for the thumbnail, but there is no easy way to transfer it on wikidata, since the info comes from the Index page, and the link on wikidata is to the Main page of a book.
but, since it is now possible to export data from Commons files, using the built-in QS script in "Book" template[1], more and more of those will be added to wikidata :)
 – The preceding unsigned comment was added by Hsarrazin (talk • contribs).

P642 label/language problem

I'm an EN language user. https://www.wikidata.org/wiki/Property:P642 has the En label "of". However when rendered through the P template - of (P642) - or viewed when used as a statement qualifier in, for example, https://www.wikidata.org/wiki/Q56661670#P31 ... it renders as "de". It should render as "of". So that's probably not a good thing. --Tagishsimon (talk) 00:02, 26 December 2019 (UTC)

Hello @Tagishsimon:, thanks for noticing. It seems to be related to an issue that we recently fixed. I could not reproduce the issue with the template (it's displayed correctly on my side), and a ?action=purge fixed your second example. Can you let me know if you encounter other/new issues? Thanks! Lea Lacroix (WMDE) (talk) 15:50, 6 January 2020 (UTC)
thanks Lea; will do. I'm getting "of" right now. I'll close this entry for now. --Tagishsimon (talk) 17:58, 6 January 2020 (UTC)
I think that this discussion is resolved and can be archived. If you disagree, don't hesitate to replace this template with your comment. --Tagishsimon (talk) 17:58, 6 January 2020 (UTC)

broken Lua's mw.wikibase.entity:getSitelink function

Any changes today, that might have broken Lua's mw.wikibase.entity:getSitelink function? Today c:Category:Pages with script errors started to fill up with files showing "Lua error in Module:Wikidata_label at line 24: attempt to call method 'getSitelink' (a nil value)" error. I do not think that error was caused by any changes to Lua code on Commons. So perhaps something went broke in mw:Extension:Wikibase Client/Lua. --Jarekt (talk) 04:53, 12 December 2019 (UTC)

Hello @Jarekt:, thanks a lot for reporting! I created a ticket for this issue. Lea Lacroix (WMDE) (talk) 12:05, 12 December 2019 (UTC)
This section was archived on a request by: Regards, ZI Jony (Talk) 16:56, 7 January 2020 (UTC)

Moved articles no longer auto-updating in WD

just in case no one has seen it and would like to inform the community of what is currently occurring.  — billinghurst sDrewth 00:46, 16 December 2019 (UTC)

Thanks for letting us know. We'll follow the progress on the ticket, it seems to be monitored by WMF's teams. If the issue happens again, please let me know. Lea Lacroix (WMDE) (talk) 08:17, 17 December 2019 (UTC)

Is it the time to update this page for 2020?--GZWDer (talk) 18:37, 17 December 2019 (UTC)

We're on it, the new roadmap will be published sometime in January. Lea Lacroix (WMDE) (talk) 16:25, 18 December 2019 (UTC)