Page MenuHomePhabricator

Markers added by QID to have auto-generated title and description
Closed, DeclinedPublic5 Estimated Story Points

Description

Requirements

  • Auto-generate title and description for markers added by QID, so that the standard Kartographer pop-up appears when clicked on in dynamic maps
    • Title: [Wikidata item label]
    • If an article exists on the same wiki as where the map is shown, make the title a link to the article page.
    • Description: [if existing in language, use wikidata item description. if existing, use wikidata image]
  • On hover, tooltip should show the title (same as current behavior for pop-ups)
  • Language: Use default language of the wiki
  • Enable overwriting the auto-generated popups with manually entered user data

Note: similar to what we did here T304078

Mock

QID auto title and description.png (616×449 px, 275 KB)

Note: use current default styling. Any styling updates would be made in follow-up tickets.

Technical implementation

There is already this feature that displays title, link, description and image for query input, when all the needed data is defined in the query. This is already working for geopoints as well. But this requires the user to know the correct wording for the parameters and query them manually.

We can make an automated query for the needed data that would be created when a user enters an ids for (both geoshapes and) geopoints (POC). We can do this automatically or make this a setting the user can define, e.g. autofill: true or similar. Or the user could define data that should be displayed (see example below).

<mapframe text="Geopoint with QID as input" width="400" height="300" align="left">
{
  "type": "ExternalData",
  "service": "geopoint",
  "autofill": ["title", "description", "link", "image"],
  "ids": "Q1431922"
}
</mapframe>

Open questions

  • Data source: sparql vs. wikidata api, see also T302291

POC (to review)

Query in wikidata query service

Screenshot from 2022-07-29 16-07-09.png (1×1 px, 1 MB)

Next steps

  • Make this work for all geo elements (geoshapes and geolines)

Optional next steps (in case of user feedback)

  • Add a setting for opt-out or let user choose which elements should be displayed

Event Timeline

ECohen_WMDE renamed this task from [Stub] Markers added by QID to have auto-generated title and description to Markers added by QID to have auto-generated title and description.May 5 2022, 3:37 PM
ECohen_WMDE created this task.
thiemowmde renamed this task from Markers added by QID to have auto-generated title and description to POC: Markers added by QID to have auto-generated title and description.May 11 2022, 12:35 PM
thiemowmde updated the task description. (Show Details)
thiemowmde moved this task from Ready for story time to In sprint on the WMDE-GeoInfo-FocusArea board.
thiemowmde set the point value for this task to 5.May 13 2022, 1:45 PM

Change 818166 had a related patch set uploaded (by Svantje Lilienthal; author: Svantje Lilienthal):

[mediawiki/services/kartotherian@master] POC: Markers added by QID to have auto-generated title, description and image

https://gerrit.wikimedia.org/r/818166

Reviewing open questions:

Should we make this work for all geo elements (geoshapes and geolines)?

Ideally it would work the same for these as well, but it would need to be added in a way so that it doesn't override any existing user-added labels. TBD by @Lena_WMDE if we expand scope to include this

Should this be a setting? (details see above)

Could this be added as a parameter to the mapframe syntax? I'm not sure of the benefits of this. I think much more important is the possibility to override. Will also discuss with Lena.

Language (for item label and description)

Use default language of the wiki since it would be part of the content, not part of the interface. If not available, then use interface language. If neither is available then use existing fall back patterns. I've heard these discussed by other ux designers before so I know that they exist, though I don't remember exactly where. Let me know if you have trouble tracking it down and I can reach out to WMF designers.

UX: is there a way for the user to overwrite the auto-generated version if they would like it to say something else?

Ideally, there should be a way. I found an example of a user who did this with a geoshape SPARQL query. Is it done in the same way as we are planning? If it's not possible to add individually, let's discuss. The whole reason to add the auto-descriptions is because of how difficult it would be to add a custom one for each point. If it's not possible, then we are already improving the situation. If they can do both, then even better.

Thanks for the review @ECohen_WMDE. I updated the ticket description accordingly.

lilients_WMDE renamed this task from POC: Markers added by QID to have auto-generated title and description to Markers added by QID to have auto-generated title and description.Aug 10 2022, 1:37 PM
lilients_WMDE removed lilients_WMDE as the assignee of this task.
lilients_WMDE updated the task description. (Show Details)
lilients_WMDE subscribed.
Lena_WMDE closed this task as Declined.EditedAug 25 2022, 7:44 AM

Declined due to potential increase in traffic on WDQS to apply this to shapes and lines (T315532#8178218).