Page MenuHomePhabricator

[summaries] Create instrument + wire-up summary UI
Closed, ResolvedPublic5 Estimated Story Points

Description

Background

If we introduce a pre-generated summary feature as an opt-in feature on a the mobile site of a production wiki, we will be able to measure a CTR greater than 4%, ensure no negative effects to session length, pageviews, or internal referrals, and use this data to decide how and if we will further scale the summary feature."

We want to know if user's find this feature useful or not.

User story

As a reader I want to tell WMF what I think of their new feature so that my voice is heard!

Requirements

Per the instrumentation spec for this experiment, the following *5 event* are logged.

Screenshot 2025-03-27 at 11.51.56 AM.png (570×620 px, 108 KB)
Screenshot 2025-03-27 at 11.50.00 AM.png (698×440 px, 130 KB)
Screenshot 2025-03-27 at 11.50.11 AM.png (396×440 px, 81 KB)
Screenshot 2025-03-27 at 2.04.34 PM.png (408×578 px, 82 KB)
Screenshot 2025-03-27 at 2.04.46 PM.png (398×570 px, 78 KB)
User lands on the page containing the summary link.User clicks on the Read summary linkThe ‘Summary’ overlay showsUser clicks on 'Yes' to the question "Was this summary helpful"User clicks on 'No' to the question "Was this summary helpful"
summary_availablesummary_activatedsummary_shownsummary_approvedsummary_disapproved

BDD

Feature: Instrumentation for article summary interaction

Scenario: Summary link is available on page
  Given I visit a mobile article page with a simple summary available
  When the summary banner renders
  Then an event of type "summary_available" is fired

Scenario: User clicks "Read summary"
  Given I see a summary banner with a "Read summary" link
  When I click the "Read summary" link
  Then an event of type "summary_activated" is fired

Scenario: Summary overlay is shown
  Given I have clicked the "Read summary" link
  When the overlay becomes visible
  Then an event of type "summary_shown" is fired

Scenario: User clicks "Yes" feedback on summary
  Given the summary overlay is visible
  When I click the "Yes" button
  Then an event of type "summary_approved" is fired

Scenario: User clicks "No" feedback on summary
  Given the summary overlay is visible
  When I click the "No" button
  Then an event of type "summary_disapproved" is fired

Test Steps

Test Case 1: Verify summary_available event

  1. Logged out: Navigate to a mobile article page where a summary is available e.g. https://en.m.wikipedia.beta.wmflabs.org/wiki/Paris
  2. Ensure that the summary banner loads successfully.
  3. Open the network tab, switch tab back and forth and verify eventlogging events fired.
  4. AC1: Confirm that a summary_available event is logged.

Test Case 2: Verify summary_activated event

  1. Click on the “Read summary” link in the banner.
  2. AC2: Confirm that a summary_activated event is logged.

Test Case 3: Verify summary_shown event

  1. Observe the summary overlay appearing after clicking “Read summary”.
  2. AC3: Confirm that a summary_shown event is logged.

Test Case 4: Verify summary_approved event

  1. In the summary overlay, click the “Yes” button to answer “Was this summary helpful?”.
  2. AC4: Confirm that a summary_approved event is logged.

Test Case 5: Verify summary_disapproved event

  1. Refresh the page or load another article with a summary.
  2. Click “Read summary” to bring up the overlay.
  3. Click the “No” button.
  4. AC5: Confirm that a summary_disapproved event is logged.

QA Results - Beta

Acceptance criteria

Communication criteria - does this need an announcement or discussion?

  • Add communication criteria

Rollback plan

Code is not in production so no rollback plan needed.

This task was created by Version 1.2.0 of the Web team task template using phabulous

Event Timeline

There are a very large number of changes, so older changes are hidden. Show Older Changes
Jdlrobson-WMF moved this task from Incoming to Q3 on the Web-Team board.
ovasileva raised the priority of this task from Medium to High.Feb 27 2025, 9:17 AM
Jdlrobson-WMF changed the task status from In Progress to Stalled.Mar 3 2025, 5:01 PM
Jdlrobson-WMF changed the task status from Stalled to Open.
Jdlrobson-WMF set the point value for this task to 2.
Jdlrobson-WMF moved this task from Q3 to Sprint Backlog on the Web-Team board.

(This is likely a sprint 5 thing since it is stalled on various other things but moving over for completeness)

Jdlrobson-WMF changed the task status from Open to Stalled.Mar 3 2025, 5:02 PM
ovasileva changed the task status from Stalled to Open.Mar 24 2025, 5:49 PM
ovasileva moved this task from Q4 to Sprint Backlog on the Web-Team board.
Jdrewniak renamed this task from Wire up user feedback buttons on simple summaries to [summaries] Create instrument + wire-up show/hide buttons.Mar 27 2025, 3:54 PM
Jdrewniak renamed this task from [summaries] Create instrument + wire-up show/hide buttons to [summaries] Create instrument + wire-up summary UI.
Jdrewniak updated the task description. (Show Details)
Jdrewniak removed the point value 2 for this task.
Jdrewniak set the point value for this task to 5.Mar 28 2025, 4:03 PM
SToyofuku-WMF subscribed.

Picking up this chunky boy while mentoring Dillon this sprint - will put down/hand off/ask for help if I realize I'm unable to handle both

Change #1129958 had a related patch set uploaded (by Jdlrobson; author: Kimberly Sarabia):

[operations/mediawiki-config@master] Stream registration for article summaries

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

Change #1141899 had a related patch set uploaded (by Stoyofuku-wmf; author: Stoyofuku-wmf):

[mediawiki/extensions/ArticleSummaries@master] Add hooks for instrumentation

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

Change #1141901 had a related patch set uploaded (by Stoyofuku-wmf; author: Stoyofuku-wmf):

[mediawiki/extensions/WikimediaEvents@master] Add instrumentation for summaries mobile pilot overlay

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

Loren has grabbed this ticket but hasn't done much yet. Still getting metrics platform to run locally. Today will look at merge conflicts and respond to Jon's feedback.

Got everything working locally. Had to debug some issues after resolving merge conflicts. Everything seems to be working well while testing it. I responded to Jon's comment. Only issue let is failing QUnit tests.

Change #1141899 merged by jenkins-bot:

[mediawiki/extensions/ArticleSummaries@master] Add hooks for instrumentation

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

Next step is to backport: https://gerrit.wikimedia.org/r/c/operations/mediawiki-config/+/1129958?usp=search
@LMora-WMF please coordinate with the team to work out who should do that!

Also how do we want @Edtadros to test this? Do we want to wait on T392520: Deploy extension:ArticleSummaries to beta cluster or do a specific QA task ?

Jdlrobson-WMF lowered the priority of this task from High to Medium.May 13 2025, 5:15 PM

Change #1141901 merged by jenkins-bot:

[mediawiki/extensions/WikimediaEvents@master] Add instrumentation for summaries mobile pilot overlay

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

Change #1129958 merged by jenkins-bot:

[operations/mediawiki-config@master] Stream registration for article summaries

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

Mentioned in SAL (#wikimedia-operations) [2025-05-13T20:24:56Z] <jforrester@deploy1003> Started scap sync-world: Backport for [[gerrit:1129958|Stream registration for article summaries (T389097 T387406)]]

Mentioned in SAL (#wikimedia-operations) [2025-05-13T20:31:22Z] <jforrester@deploy1003> ksarabia, jforrester: Backport for [[gerrit:1129958|Stream registration for article summaries (T389097 T387406)]] synced to the testservers (https://wikitech.wikimedia.org/wiki/Mwdebug)

Mentioned in SAL (#wikimedia-operations) [2025-05-13T20:38:09Z] <jforrester@deploy1003> Finished scap sync-world: Backport for [[gerrit:1129958|Stream registration for article summaries (T389097 T387406)]] (duration: 13m 12s)

We need to enable this on the beta cluster but once that's done you should be able to QA.

Edtadros updated the task description. (Show Details)
Slack-bot changed the task status from Open to In Progress.May 20 2025, 7:09 PM
NBaca-WMF changed the task status from In Progress to Open.May 20 2025, 7:10 PM
NBaca-WMF subscribed.

Oops sorry, over-active bot!

Test Steps

Status: ✅ PASS
Environment: Beta
OS: macOS
Browser: Chrome
Device: MS MBA

@Jdlrobson-WMF, The events don't have the action_subtype that or really any other value that matches what is specified in the description.

Per T387406#10842313 see the worksheet for the accurate spec.

Test Case 1: Verify summary_available event

  1. Logged out: Navigate to a mobile article page where a summary is available e.g. https://en.m.wikipedia.beta.wmflabs.org/wiki/Paris
  2. Ensure that the summary banner loads successfully. (run mw.hook('ext.articleSummaries.cta.open').fire(); )
  3. Open the network tab, switch tab back and forth and verify eventlogging events fired.
  4. ✅ AC1: Confirm that a summary_available event is logged.

Worksheet cell E23

screenshot 334.png (1×1 px, 377 KB)

Test Case 2: Verify summary_activated event

  1. Click on the “Read summary” link in the banner.
  2. ✅ AC2: Confirm that a summary_activated event is logged.

Worksheet cell E24

screenshot 335.png (1×1 px, 415 KB)

Test Case 3: Verify summary_shown event

  1. Observe the summary overlay appearing after clicking “Read summary”.
  2. ✅ AC3: Confirm that a summary_shown event is logged.

Worksheet cell E27

screenshot 336.png (1×1 px, 482 KB)

Test Case 4: Verify summary_approved event

  1. In the summary overlay, click the “Yes” button to answer “Was this summary helpful?”.
  2. ✅ AC4: Confirm that a summary_approved event is logged.

Worksheet cell E28

screenshot 337.png (1×1 px, 479 KB)

Test Case 5: Verify summary_disapproved event

  1. Refresh the page or load another article with a summary.
  2. Click “Read summary” to bring up the overlay.
  3. Click the “No” button.
  4. ✅ AC5: Confirm that a summary_disapproved event is logged.

Worksheet cell E29

screenshot 338.png (1×1 px, 482 KB)

@Jdlrobson-WMF, The events don't have the action_subtype that or really any other value that matches what is specified in the description.

Please use the associated spreadsheet as the source of truth (https://docs.google.com/spreadsheets/d/1DwTaegjvhTqnfzxmt2SIg4nEGg8fplWY7HKtEAU_Rks/edit?gid=0#gid=0)

For example this one (AC5) seems to match with L29 ?

Screenshot 2025-05-20 at 5.26.47 PM.png (612×1 px, 239 KB)

Thanks @Jdlrobson-WMF, I've updated the ticket as a pass and referenced the worksheet cell containing the correct spec.

Jdlrobson-WMF claimed this task.