Page MenuHomePhabricator

Treat article translation on mobile as (lead) section translation
Closed, ResolvedPublic4 Estimated Story Points

Description

  • Adjust instrumentation to capture lead section difficulty level instead of complete article difficulty level
  • Easy article suggestions on mobile should be based on lead section size

Derived Requirement

For mobile article translations in Content Translation:

  • Article translations should be treated as lead section translations.
  • Instrumentation must record the difficulty level of the lead section, not the full article.
  • Easy article suggestions shown to mobile users must be based on the lead section size, following the same criteria as section translation difficulty.
Test Steps

Test Case 1: Lead Section Instrumentation on Mobile

  1. On mobile (Minerva skin), start translating an article using Content Translation.
  2. Complete and publish the translation.
  3. Check the captured instrumentation data.
  4. ✅❓❌⬜ AC1: The event records the difficulty level of the lead section only, not the entire article.

QA Results - TestWiki

ACStatusDetails
1T403730#11386596

Related Objects

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
SBisson triaged this task as High priority.
SBisson moved this task from Backlog to In-progress on the LPL Hypothesis board.

Change #1184807 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/services/cxserver@master] Include __LEAD_SECTION__ in sourceSectionSizes

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

Change #1185101 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/extensions/ContentTranslation@master] Centralize translation difficulty logic in useTranslationSize

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

I hope this question makes sense here 🙂.

When I first tried mobile translation, I only translated the lead and found the process confusing because:

  1. I couldn’t easily find how to continue translating the rest of the article, and
  2. I was worried I had just published something without enough references nor categories, which puts an article at risk of deletion.

In my case, this wasn’t a problem (the lead had references [which is rare in English], @SGill guided me on how to add more sections, and I[[ https://es.wikipedia.org/w/index.php?title=Sat_Sri_Akaal&oldid=168133214 | have HotCat enabled ]]), but for newer contributors, these hurdles could be significant.

Would it make sense for this task to also consider:

  1. how users discover the option to keep translating after the lead, and
  2. safeguards around publishing a lead without categories or references?
  3. or perhaps being published with a default "Under construction" template?
SBisson changed the task status from Open to In Progress.Sep 5 2025, 3:27 PM
SBisson moved this task from In-progress to Needs Code Review on the LPL Hypothesis board.
SBisson moved this task from Needs Code Review to In-progress on the LPL Hypothesis board.

@SEgt-WMF thanks for taking the time to comment here

Would it make sense for this task to also consider:

The current task has a very limited scope to avoid a measurement issue in the context of WE2.1.2. We cannot really add scope to it at the moment but I am capturing your comments in phabricator for the team to consider.

  1. how users discover the option to keep translating after the lead, and

T241592: Section Translation: Show follow-up options after publishing

  1. safeguards around publishing a lead without categories or references?

T403857: Warn before publishing a new article without categories or references

  1. or perhaps being published with a default "Under construction" template?

I'm not exactly sure how the "under construction" template is used. Are you suggesting something like adding that template while the user is guided through translating several sections and removing it the end of their editing session or simply adding it by default to all new articles creating by translating the lead section on mobile, or something else? Feel free to create a new task for it under ContentTranslation and put as much details as you like about how it think it could work. Thanks

Change #1184807 merged by jenkins-bot:

[mediawiki/services/cxserver@master] Include __LEAD_SECTION__ in sourceSectionSizes

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

Change #1185861 had a related patch set uploaded (by KartikMistry; author: KartikMistry):

[operations/deployment-charts@master] Update cxserver to 2025-09-08-084009-production

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

Change #1185861 merged by jenkins-bot:

[operations/deployment-charts@master] Update cxserver to 2025-09-08-084009-production

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

Mentioned in SAL (#wikimedia-operations) [2025-09-08T09:11:29Z] <kart_> Updated cxserver to 2025-09-08-084009-production (T403730)

Change #1186558 had a related patch set uploaded (by Nik Gkountas; author: Nik Gkountas):

[research/recommendation-api@master] add filtering based on lead section size for article suggestions

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

Change #1185101 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] Centralize translation difficulty logic in useTranslationSize

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

Change #1186643 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/extensions/ContentTranslation@master] Request lead section size article suggestion filtering on mobile

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

Change #1186643 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] Request lead section size article suggestion filtering on mobile

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

Change #1186648 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/extensions/ContentTranslation@master] CX3 Build 1.0.0+20250909

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

Change #1186650 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/extensions/ContentTranslation@wmf/1.45.0-wmf.18] CX3 Build 1.0.0+20250909

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

Change #1186558 merged by jenkins-bot:

[research/recommendation-api@master] add filtering based on lead section size for article suggestions

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

Change #1186961 had a related patch set uploaded (by KartikMistry; author: KartikMistry):

[operations/deployment-charts@master] Update Recommendation API to 2025-09-10-080042-production

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

Change #1186648 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] CX3 Build 1.0.0+20250909

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

Change #1186961 merged by jenkins-bot:

[operations/deployment-charts@master] Update Recommendation API to 2025-09-10-080042-production

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

Change #1186650 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@wmf/1.45.0-wmf.18] CX3 Build 1.0.0+20250909

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

Mentioned in SAL (#wikimedia-operations) [2025-09-10T13:54:25Z] <kartik@deploy1003> sbisson, kartik: Backport for [[gerrit:1186650|CX3 Build 1.0.0+20250909 (T374886 T394998 T399122 T399125 T399133 T403730 T404045 T404093)]] synced to the testservers (see https://wikitech.wikimedia.org/wiki/Mwdebug). Changes can now be verified there.

Mentioned in SAL (#wikimedia-operations) [2025-09-10T14:12:05Z] <kartik@deploy1003> Finished scap sync-world: Backport for [[gerrit:1186650|CX3 Build 1.0.0+20250909 (T374886 T394998 T399122 T399125 T399133 T403730 T404045 T404093)]] (duration: 24m 08s)

@SBisson Confirmed the event records the difficulty level of the lead section only, not the entire article, as seen in the videos below. I will move this to Sign-Off. Thanks for all your work!

Test Result - TestWiki

Status: ✅ PASS
Environment: TestWiki
OS: macOS Tahoe 26.0
Browser: Chrome 140
Device: MBA
Emulated Device: iPhone SE

Test Artifact(s):
https://test.wikipedia.org/w/index.php?title=Special:ContentTranslation&filter-type=automatic&filter-id=previous-edits&active-list=suggestions&from=en&to=fr&page=Er%20jing%20tiao#/sx/sentence-selector
https://test.wikipedia.org/w/index.php?title=Special:ContentTranslation&from=en&to=es&page=Task%20(miniseries)&filter-type=automatic&filter-id=previous-edits#/sx/sentence-selector

Test Steps

Test Case 1: Lead Section Instrumentation on Mobile

  1. On mobile (Minerva skin), start translating an article using Content Translation.
  2. Complete and publish the translation.
  3. Check the captured instrumentation data.
  4. AC1: The event records the difficulty level of the lead section only, not the entire article.
FR- Quick TranslationES-Normal
GMikesell-WMF updated the task description. (Show Details)
GMikesell-WMF moved this task from Needs QA to Design Signoff on the LPL Hypothesis board.

This task should not be closed as resolved, as easy suggestions on mobile are not really based on the lead section size, but still take into account the article size. In the example below (el production wiki with a "newcomer" user,), we can see the "Jermaine Jackson" article that is missing the "Quick translation" indicator, although its lead section size falls in the "easy" size range (1000 < lead section = 3521 < 4000). This happens because instead of the lead section size, the article size is taken into account, which falls in the "medium" range (10000 < article size = 38845 < 40000). Moving this task back to "In-progress"

Screenshot 2025-11-07 at 17.42.46.png (923×1 px, 376 KB)

ngkountas moved this task from Product Signoff to In-progress on the LPL Hypothesis board.

Change #1203199 had a related patch set uploaded (by Nik Gkountas; author: Nik Gkountas):

[research/recommendation-api@master] collection recs: fix lead section size filtering

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

Change #1203200 had a related patch set uploaded (by Nik Gkountas; author: Nik Gkountas):

[research/recommendation-api@master] search recs: do not add lead_section_size when no lead_section URL param

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

Change #1203201 had a related patch set uploaded (by Nik Gkountas; author: Nik Gkountas):

[research/recommendation-api@master] popular recs: do not add lead_section_size when no lead_section URL param

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

Change #1203203 had a related patch set uploaded (by Nik Gkountas; author: Nik Gkountas):

[mediawiki/extensions/ContentTranslation@master] CX: Fix easy article suggestions for newcomers

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

Change #1203199 merged by jenkins-bot:

[research/recommendation-api@master] collection recs: fix lead section size filtering

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

Change #1203200 merged by jenkins-bot:

[research/recommendation-api@master] search recs: do not add lead_section_size when no lead_section URL param

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

Change #1203201 merged by jenkins-bot:

[research/recommendation-api@master] popular recs: do not add lead_section_size when no lead_section URL param

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

Change #1203203 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] CX: Fix easy article suggestions for newcomers

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

Change #1203534 had a related patch set uploaded (by Sbisson; author: Sbisson):

[mediawiki/extensions/ContentTranslation@master] CX3 Build 1.0.0+20251110

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

Change #1203534 merged by jenkins-bot:

[mediawiki/extensions/ContentTranslation@master] CX3 Build 1.0.0+20251110

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

Change #1204868 had a related patch set uploaded (by KartikMistry; author: KartikMistry):

[operations/deployment-charts@master] Update Recommendation API to 2025-11-10-154629-production

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

Change #1204868 merged by jenkins-bot:

[operations/deployment-charts@master] Update Recommendation API to 2025-11-10-154629-production

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

Mentioned in SAL (#wikimedia-operations) [2025-11-13T14:50:09Z] <kart_> Update Recommendation API to 2025-11-10-154629-production (T403730)

This task should not be closed as resolved, as easy suggestions on mobile are not really based on the lead section size, but still take into account the article size. In the example below (el production wiki with a "newcomer" user,), we can see the "Jermaine Jackson" article that is missing the "Quick translation" indicator, although its lead section size falls in the "easy" size range (1000 < lead section = 3521 < 4000). This happens because instead of the lead section size, the article size is taken into account, which falls in the "medium" range (10000 < article size = 38845 < 40000). Moving this task back to "In-progress"

Screenshot 2025-11-07 at 17.42.46.png (923×1 px, 376 KB)

@SBisson @ngkountas Easy suggestions ( < 4000) on mobile are now based on the lead section size, for "newcomers", per screenshot below. I will move this to Sign-off. Thanks for all your work!

2025-11-18_14-55-50.png (1×1 px, 604 KB)

GMikesell-WMF updated the task description. (Show Details)
GMikesell-WMF updated Other Assignee, removed: GMikesell-WMF.
GMikesell-WMF moved this task from Needs QA to Design Signoff on the LPL Hypothesis board.