[go: up one dir, main page]

Page MenuHomePhabricator

Introduce an API to enable editing interfaces to offer feedback about reference reliability
Open, Needs TriagePublic

Description

T337431 introduced a machine-readable list of domains (MediaWiki:BlockedExternalDomains.json) projects block from being added to a page.

This task involves the work of making said "machine-readable list of domains" accessible via API so that editing interfaces can do things like provide feedback about how reliable projects are to consider the source someone is attempting to add (e.g. T276857).

Story

As a [staff [i] or volunteer [ii]] developer motivated to improve the quality of edits people publish using MediaWiki editing interfaces, I'd value being able to offer people who are editing feedback about how reliable experienced volunteers are going to consider the source(s) they're adding, so that the people publishing said edits can decide whether they'd like to make adjustments to he source(s) they're planning to reference.

Requirements

  1. An editing interface needs to send a URL to said API
  2. Said API needs to return, to start, whether the URL it's been "passed":
    • Has been blocked by volunteers at the project in question
    • Has any notes/comments associated with it that will be presented to people within Citoid (T347531). See T347531#9318193 for why this requirement as been removed.
  3. The API "architecture" needs to support a future wherein a source can prompt a range of feedback messages to be presented within editing interfaces:
    • Block
    • Warn:
    • Inform
    • Reward
  4. The API will need to "call" / check against both MediaWiki:Spam-blacklist and MediaWiki:BlockedExternalDomains.json. See T347531#9318193.

Proposed API

In terms of how we present the proposal in a way other people can easily engage with/evaluate, maybe we can draw inspiration from what @Catrope did in T349423.

Open questions

  • 1. What source list(s) (e.g. MediaWiki:BlockedExternalDomains.json, MediaWiki:Spam-blacklist, etc.) will the API initially support?
    • The initial patch checks only MediaWiki:BlockedExternalDomains.json. Investigation of passing domains to MediaWiki:Spam-blacklist is underway.
  • 2. What – if anything – limits our ability to expand the "source lists" "1." refers to over time?
  • 3. To what extent – if any – should the API specify what call(s) to action an editing interface ought to present based on the reliability of the source it's been "passed"?
  • 4. Is a distinct "field" needed within the API to hold the messages volunteers would like people to be shown within Citoid (via T347531) when attempting to cite a given source?

i. E.g. Members of the Editing and Community Tech Teams
ii. E.g. volunteers working on reference reliability scripts and gadgets: @suffusion_of_yellow (wikilint.js), @Headbomb (User:Headbomb/unreliable), @Novem_Linguae (CiteHighlighter.js), @SuperHamster (CiteUnseen.js), @Mathglot (T327330#8607428)

Related Objects

Event Timeline

ppelberg renamed this task from Introduce an API to enable editing interfaces to interact with Special:BlockedExternalDomains to Introduce an API to enable editing interfaces to offer feedback about reference reliability .Oct 18 2023, 11:19 PM
ppelberg updated the task description. (Show Details)
ppelberg added a subscriber: MusikAnimal.
ppelberg updated the task description. (Show Details)

Next steps

  • Editing Engineering to propose an initial approach and for us (staff + volunteers) to discuss its viability
ppelberg updated the task description. (Show Details)
ppelberg added a subscriber: Catrope.
ppelberg added a subscriber: Novem_Linguae.
ppelberg removed a subscriber: Novem_Linguae.

Change 975062 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/VisualEditor@master] [WIP] Introduce ApiEditCheckReferenceUrl

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

ppelberg added a subscriber: Novem_Linguae.

Update: 28 Nov
Per what @Esanders and I talked about offline, next step is to investigate the technical feasibility of passing domains to MediaWiki:Spam-blacklist.

Update: 28 Nov
Per what @Esanders and I talked about offline, next step is to investigate the technical feasibility of passing domains to MediaWiki:Spam-blacklist.

Why should only domains be passed to MediaWiki:Spam-blacklist? What makes MediaWiki:Spam-blacklist more powerful than MediaWiki:BlockedExternalDomains.json is exactly that it operates on full URLs, not on domain names. For example, https://en.wikipedia.org/wiki/MediaWiki:Spam-blacklist contains the following entry:

\byoutube\.com/watch\?v=(?:_cyR-XJtPN|9JDLl1CMuNs|cmdkmm1ohha|eAaQNACwaLw|edikv0zbAlU|gdsUmAZFaVA)

There’s no way you’ll correctly match it if you only pass youtube.com to the API endpoint.


Once the API is able to handle both MediaWiki:Spam-blacklist and MediaWiki:BlockedExternalDomains.json, maybe could it be exposed in Lua as well? See T350480#9306721.

Test wiki created on Patch demo by ESanders (WMF) using patch(es) linked to this task:
https://patchdemo.wmflabs.org/wikis/97c4358d77/w

Change 975062 merged by jenkins-bot:

[mediawiki/extensions/VisualEditor@master] Introduce ApiEditCheckReferenceUrl

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

The initial API has been implemented, it returns "blocked" or "allowed" for a given URL based on MediaWiki:Spam-blacklist and MediaWiki:BlockedExternalDomains.json.

Test wiki on Patch demo by ESanders (WMF) using patch(es) linked to this task was deleted:

https://patchdemo.wmflabs.org/wikis/97c4358d77/w/

This comment was removed by ppelberg.