Page MenuHomePhabricator

Improve perceived performance of the limit for fast unreviewed translations
Open, MediumPublic

Description

A new limit to prevent the publication of fast unreviewed translations (T331023) was created. This is intended to prevent cases where users publish translations at a fast-pace without enough time to review their contents, which has been an issue in some contests and similar events.

As mentioned in T331023#10088279, the initial implementation makes the Confirm step (T276221) to become unresponsive after the user taps on the button to start translating. This is produced because (a) checking the data on the previously published translation takes some time, and (b) the wait is not communicated to the users. This ticket proposes to explore how to improve both fronts. Some initial ideas listed below:

Reduce the (perceived) waiting

  • Move on as soon as possible. The complete calculation for the limit requires checking the number of paragraphs of the last published article and the time it was started. Given that the maximum waiting period we ask users for is fixed (10min), we can use that to our advantage and move on as soon as we are sure the translation was started earlier. For example, if the start time (or the publish time) of the previous translation is more than 10min ago, we don't need to request more data about the translation. The published time can be a useful approximation to the start time (since a translation published 10min ago could not have been started more recently). Similarly, as part of the calculations for "Your impact" module in the dashboard that shows the translations published in the last 30 days for the user we can be sure that users with 0 translations published in the last 30 days will be able to start a new one immediately.
  • Start the calculation earlier. As soon as the user gets to the Confirmation step, this calculation can be started.
  • Reuse the calculation. For a user that is allowed to start a new translation, the situation will remain the same as long as the user does not publish a new translation where it has to be reevaluated for new translations. We can avoid making the calculations again when we know the previous result is still valid.

Communicate the waiting

  • After the user taps the confirmation button, it should become disabled.
  • If the loading exceeds a few milliseconds, a Codex Inline Progress bar can be shown attached to one of the parts of the Confirm step. Placement and alternatives to be explored.

Event Timeline

Confirmation step.png (2×3 px, 842 KB)

Initial state:

  • Button text: "Select section to translate"
  • Button state: Enabled, color: Decision tokens/background-color/progressive
  • User taps "Select section to translate" button

Processing state:

  • Button text changes to: "Checking recent activity..."
  • Button state: Slightly dimmed, color: Option Tokens/Blue/400 (#6D8AF2)

Outcome A: user not eligible for translation

  • Display "Review your last translation" dialog
  • If user clicks "Review translation":
    • Close dialog
    • Redirect to previous translation for review
  • If user clicks "Close":
    • Close dialog
    • Return to main screen with modified button state

Outcome B: User eligible for translation

  • close "Checking recent activity..." button
  • proceed to section selection interface
  • allow user to choose which sections to translate
  • once selection is made, begin translation process

Post-dialog button state(for outcome A)

  • Button text: "Next translation in: MM:SS"
  • Button state: Disabled, color: Decision Tokens/background-color/disabled
  • Timer: Countdown from 10:00, updates every second
  • Ensure clock icon is visible next to countdown text

Timer Completion:

  • When timer reaches 00:00, change button to “Select section to translate”

Technical Considerations:

  • Use ellipsis (...) or truncate text if necessary to maintain button width
  • Ensure the timer persists if user navigates away and returns

Button base width:

  • Use the english version of "Select section to translate" as the baseline for button width.
  • Set a maximum width (e.g., 120% of the base width) to prevent excessive stretching.
  • If text exceeds the maximum width:
    • Truncate text and add ellipsis (...) at the end.
  • For disabled button with limited space, use this truncation hierarchy:
    • "Next in: MM:SS" with clock icon

Thanks for sharing your exploration @SGautam_WMF.
The general direction proposed makes sense. Here are some thoughts:

  1. I think that using the button as shown in the proposal works well to communicate the waiting without adding additional complexity.
  2. The last step provides no easy way to access the path to review the article, since the previous dialog is unreachable then. At this point, we want users to use the time to review their translation, not wait for the time to pass to start the new one. I was wondering whether simply returning to the first step from the dialog could be more effective for this.
  3. On the second step, the button text (Checking recent activity) makes sense for the scenario where the user gets to the dialog, since the information in the dialog complements the button label well. However, for users reaching the translation editor, it may be a bit unclear why their "recent activity" was being checked. Maybe something along the lines of "Checking contents..." can apply better to both cases.
  4. On the second step, the color adjustment makes sense, but this represents a new one-off state for the button component. We can consider whether any of the existing states could make sense (conceptually and visually), and ping Design Systems team in case the new one is needed for them to be aware of this use case.
  5. Side note: The main call to action in the Confirm step can be "Select section to translate" (for articles that do exist in the target wiki and can be expanded) or "Start translation" (for articles that do not exist in the target wiki). So the width of the button will depend on the case.

Thanks Pau for all the thoughtful feedback.

The last step provides no easy way to access the path to review the article, since the previous dialog is unreachable then. At this point, we want users to use the time to review their translation, not wait for the time to pass to start the new one. I was wondering whether simply returning to the first step from the dialog could be more effective for this.

What do we mean by first step here?

On the second step, the button text (Checking recent activity) makes sense for the scenario where the user gets to the dialog, since the information in the dialog complements the button label well. However, for users reaching the translation editor, it may be a bit unclear why their "recent activity" was being checked. Maybe something along the lines of "Checking contents..." can apply better to both cases.

Thanks, we can go with "checking contents", I was even thinking even just using "Processing..." or "Please wait..." is enough but that might not be enough to set the content when we translate it. Other option I liked was "Processing translation request..." but I dropped it due to its length.

On the second step, the color adjustment makes sense, but this represents a new one-off state for the button component. We can consider whether any of the existing states could make sense (conceptually and visually), and ping Design Systems team in case the new one is needed for them to be aware of this use case.

I asked a clarifying question to DST. Lets see what they recommend.

Side note: The main call to action in the Confirm step can be "Select section to translate" (for articles that do exist in the target wiki and can be expanded) or "Start translation" (for articles that do not exist in the target wiki). So the width of the button will depend on the case.

Nice suggestion.

Thanks Pau for all the thoughtful feedback.

The last step provides no easy way to access the path to review the article, since the previous dialog is unreachable then. At this point, we want users to use the time to review their translation, not wait for the time to pass to start the new one. I was wondering whether simply returning to the first step from the dialog could be more effective for this.

What do we mean by first step here?

I was referring to the sequence of steps illustrated in the mockup you shared. To clarify, I added labels and the arrows to illustrate a potentially simplified workflow.

Confirmation_step.png (2×3 px, 1 MB)

Side note: The main call to action in the Confirm step can be "Select section to translate" (for articles that do exist in the target wiki and can be expanded) or "Start translation" (for articles that do not exist in the target wiki). So the width of the button will depend on the case.

Nice suggestion.

To clarify, the different labels ("Select section to translate" and "Start translation" ) are already implemented. I wanted to share this, since the proposal mentions aspects such as: Use the english version of "Select section to translate" as the baseline for button width., but the original button may say "Start translation" instead in some cases.

@Pginer-WMF could you please re-share the image? it seems like some format issue over there.