####Problem
xLab currently provides a “Project and sample size” field that allows defining the size of the user sample that they would like toto be enroll fromed in each one of the wikis involved in their experiment.
This field has a couple of issues:
1) Selecting “projects” is inaccurate, since enrollment takes place on the specific domains of individual wikis (e.g., the wiki available in en.wikipedia.org wiki instead of Wikipedia as a project);
2) Project selection is based on dbnames, which aren’isn't completely user-friendly (e.g., "eswiki" instead of "Spanish Wikipedia");
3) The labelnotion of "Sample size" is an improvement from the previous "Sample rate" (see [[ https://docs.google.com/document/d/1o4RWQQM8FR9bcpGflWUeH-EeYv_Xx4HDq9sVK11TY0c/edit?tab=t.0#bookmark=id.mwymzf6t93u8 | MPIC Usability Evaluation Findings ]]), but we could make the concept even clearer if we used terminology and unitvalues more accessible for users;
4) Lastly, users can technically select the same wiki and assign traffic to it multiple times.
{F59548577}
####Suggested solution
We should improve the “Project and sample size” module, applying the following adjustments:
| Copy adjustments | UI adjustments | Validation |
| {F59548583} | {F59548582} | {F59548625} |
|1) We replace the notion of ‘project’ by ‘wiki’, and ‘sample size’ by ‘traffic’, and adjust labels, placeholders and descriptions accordingly. | 1. Ensure that there’s a vertical space of 16px between rows in the module. 2. To facilitate locating the right option, the wiki selection menu will only display a max. of 7 matches by default. The existence of further options is indicated by the scroll bar displayed by the menu. | The “Traffic (%)” field will be validated on the client side in two circumstances:
1) An error will be thrown on input if users enter a value greater than 100; everywhere in the module (see Copy adjustments)
2) Menu options display full wiki names instead of dbnames
3) ‘Sample size’ is replaced by ‘traffic’, 2) A warning will be displayed if users blur on an empty traffic field when a corresponding wiki has been selected |which is now inputted as a percentage value from 1 to 100.
4) We add error prevention measures such as disabling options that are currently selected to prevent duplication, or validating the input to the "Traffic (%)" field
5) Moreover, the update of the “Project and sample size” field to ”User traffic per wiki” justifies amending the title of the current “Sampling” section to, instead, “Traffic and variations”.
{F59548688}
Overview of changes:
| Copy adjustments | Menu adjustments | Validation
| {F59548583} | {F59551440} | {F59548625}
| Labels, placeholders and descriptions should be adjusted to reflect the switches to the notions of ‘wiki’ and ‘traffic’. | 1. To facilitate locating the right option, the wiki selection menu will only display a max. of 7 suggestions by default. The existence of further options is indicated by the scroll bar displayed by the menu. 2. The menu displays full, user-friendly wiki names. 3. To prevent users from potentially assigning traffic values to the same wiki multiple times, we could disable the menu items while selected. | The “Traffic (%)” field will be validated on the client side under two circumstances: 1) An error will be thrown on input if users enter a value greater than 100; 2) A warning will be displayed if users blur on an empty traffic field when a corresponding wiki has been selected |
Find more details in the [[ https://www.figma.com/design/Tcc2kiPAcsXVK2t6qC1QrV/Experiment-Platform---XLab?node-id=4374-48878&t=J5DNsbuccZhL5bUx-0 | Figma specifications ]]
#### Notes
- The description of the new ‘User traffic per wiki’ module includes a link to a documentation page that doesn’t exist yet. We decided to leave it in the designs and specs as a reminder of the relevance of providing more information and directions to users while filling in this field ( e.g. regarding the recommended amount of traffic they should select per wiki).
####Acceptance criteria
[] The ‘Project and sample size’ field in xLab’s experiment and instrument forms is updated to match the specifications of the ‘User traffic per wiki’ field
[] The title of the ‘Sampling’ section is updated to 'Traffic and variations'