PetScan is a tool enabling users to generate targeted lists from Wikipedia and related Wikimedia projects based on specific criteria. As a user of Cat-a-lot, I would like to integrate PetScan queries directly into Cat-a-lot for managing and categorizing Wikimedia Commons images more efficiently. Ie.
- Enter a PetScan imagelist queries when Cat-a-lot is enabled from preferences
- Fetch and display the resulting image list from PetScan as thumbnails.
- Select images from the thumbnail grid for categorization using the existing Cat-a-lot interface.
Step 1: Minimal UI
- Using userscript/Cat-a-lot script create a form on the page Special:BlankPage/Cat-a-lot that includes:
- A text input field for PetScan query ID (example: 33373583 )
- A submit button
- Upon submission:
- Load the image list from PetScan based on the provided query ID
- JSON url format: https://petscan.wmcloud.org/?psid=33373583&format=json
- Add link to prefilled PerScan query
- Example link to prefilled form: https://petscan.wmcloud.org/?psid=33373583
- Display the retrieved images as a thumbnail grid on the page Special:BlankPage/Cat-a-lot
- Default limit: 100 images
- Allow users to increase this limit
- Users select images via Cat-a-lot and perform normal categorization actions to the images.
For getting Cat-a-lot’s selection to work it will need to have:
- image grid should similar html structure than in existing pages (tms gallery, category)
- set correct CAL.searchmode value when page is loaded ( Line 1804 )
- Update findAllLabels() function (Line 432)
- Check that getMarkedLabels() works and update if needed (Line 484)
Step 2: Develop a simple UI for PetScan parameters:
- Allow defining category intersections (GET parameter name categories, format string, one categoryname per line)
- Allow defining negative categories (GET parameter name negcats , format string, one categoryname per line )
- Allow defining default category query depth (GET parameter name depth , format integer )
- PetScan query parameters from UI will override the paremeters in query ID.
The PetScan query parameters names can be found by submitting query in PetScan and then checking links in the text at the result form:
Link to a pre-filled form for the query you just ran with and without auto-run. PSID is 33374035.
This task would be starting the work for answering to T195575.


