Page MenuHomePhabricator

Load Wikidata descriptions in popups when RESTBase doesn't support a text extract
Closed, DuplicatePublic

Description

RESTBase is able to provide Wikidata descriptions as part of a request to get the page summary.

For example, this is the extract from Obama's page:

"Barack Hussein Obama II (US /bəˈrɑːk huːˈseɪn oʊˈbɑːmə/ bə-RAHK hoo-SAYN oh-BAH-mə; born August 4, 1961) is an American politician who served as the 44th President of the United States from 2009 to 2017. He was the first African American to serve as president, as well as the first born outside the contiguous United States. He previously served in the U.S. Senate representing Illinois from 2005 to 2008, and in the Illinois State Senate from 1997 to 2004.
Obama was born in Honolulu, Hawaii, two years after the territory was admitted to the Union as the 50th state. He grew up mostly in Hawaii, but also spent one year of his childhood in Washington State and four years in Indonesia."

And this is the description:

"44th President of the United States of America"

Some pages may not have extracts, but have descriptions. For those pages it would be nice to at least show a description. It doesn't cost anything extra from performance stand-point to do so. The question is should we?

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJan 26 2017, 5:48 PM
ovasileva triaged this task as High priority.Jan 30 2017, 3:21 PM
ovasileva moved this task from Incoming to Upcoming on the Readers-Web-Backlog board.

Some pages may not have extracts, but have descriptions.

What are the circumstances when that happens? The page should be really weird or empty for that to happen because the extract is basically just the beginning of the article cut after 5 sentences.

I suppose one case is where an article doesn't have a lead section (but has other sections). Correct me if I'm wrong, I think an extract comes from the lead section only.

Another case is that an extracted HTML is stripped out and doesn't return any text because of removed classes

ovasileva lowered the priority of this task from High to Medium.Feb 1 2017, 6:40 PM
Jdlrobson renamed this task from Should we use Wikidata descriptions in popups when RESTBase doesn't support a text extract? to Load Wikidata descriptions in popups when RESTBase doesn't support a text extract.Feb 2 2017, 6:39 PM
Jdlrobson added a subscriber: Jdlrobson.

Updated title since it makes it look like a spike when it isn't. It's actionable, we just need to decide whether to decline or resolve.

phuedx added a subscriber: phuedx.

This is also applicable when we using the MediaWiki API.

Restricted Application removed a subscriber: Liuxinyu970226. · View Herald TranscriptJun 6 2017, 10:40 PM