Page MenuHomePhabricator

Disambiguation Pages should not appear in Read More
Closed, ResolvedPublic

Description

Solution: Use related articles API. To get specifics on the API, contact @Jhernandez for information on implementing the new API. (he used it at the hackathon)

DO NOT REMOVE THE DISAMBIGUATUONS FROM THE CURRNT SEARCH API IMPLEMENTATION - this is a much better solution.

Disambiguation pages are not content destinations.
It feels confusing when they show up as a recommendation in the "Read More" panel.

IMG_8443.PNG (1×750 px, 171 KB)

Event Timeline

Vibhabamba assigned this task to Deskana.
Vibhabamba raised the priority of this task from to Needs Triage.
Vibhabamba updated the task description. (Show Details)

Some titles are bolded and others (Disambiguation pages and list pages) are not bolded in the read more section.
@mhurde @bearND - Is that the default styling returned from Search?

Deskana added subscribers: Dbrant, Deskana.

This would be nice. Is there an API module that lets you resolve whether a page is a disambiguation page or not? @Dbrant may know, I recall chatting to him about this recently.

Hint: when asking for query=pageprops, there's a property called "disambiguation". If this property is present in the response, then the article is a disambiguation page!

Change 210180 had a related patch set uploaded (by Mholloway):
Remove disambiguation pages and Main Page from "read more"

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

It looks like there will be some false negatives, e.g.:

https://en.wikipedia.org/wiki/Special:ApiSandbox#action=query&prop=pageprops|pageterms&format=json&titles=List%20of%20highways%20numbered%2057

The documentation says that disambiguation pages are supposed to contain the "disambiguation" pageprop, but it looks like this is not universally the case. Hopefully these are not too many in number.

Instead of following that link which apparently just shows you an empty API sandbox, just have a look here at the output I really wanted to display:

{
  "query": {
      "pages": {
          "6956070": {
              "pageid": 6956070,
              "ns": 0,
              "title": "List of highways numbered 57",
              "pageprops": {
                  "wikibase_item": "Q6623054"
              },
              "terms": {
                  "description": [
                      "Wikipedia disambiguation page"
                  ],
                  "label": [
                      "List of highways numbered 57"
                  ]
              }
          }
      }
   }
}

@Mholloway ...but that's not a disambiguation page. Where's the false negative?

Hmm, you're right. It's just got a description erroneously calling it a disambiguation page.

Change 210180 merged by Dbrant:
Remove main and disambiguation pages from "read more" section

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

@Vibhabamba does this need design signoff or can we move it along?

Fjalapeno added a subscriber: Jhernandez.

Funny enough there is an actual API for this. @Dbrant you may also want to look into to new API for getting actual related articles results rather than fixing the current search query.

Removing the iOS tag in favor of implementing: T101041