Jump to content

Indic Wikisource Helpdesk/Quarry Script

From Meta, a Wikimedia project coordination wiki

Quarry Script

[edit]

script 1

[edit]

Most active users by edits on bnwikisource in given timespan with a Page: namespace or proofread pages, before run if you change the project code, you should change the Page: namespace ID, ( as bengali wikisource Page: namespace ID=104)

https://quarry.wmflabs.org/query/44040

USE bnwikisource_p;
SELECT
CONCAT("#") AS number, actor_user,
CONCAT("[[user:",actor_name,"|",actor_name,"]]") AS rev_user_text,
COUNT(actor_id) AS recent_user_editcount/*,
user_editcount*/
FROM revision
JOIN actor ON rev_actor=actor_id
JOIN page ON rev_page=page_id
WHERE page_namespace = 104
	AND actor_user IS NOT NULL
	AND rev_timestamp BETWEEN 20190101000000 AND 20201231235959
GROUP BY actor_id
ORDER BY recent_user_editcount DESC
LIMIT 500;

script 2

[edit]

https://quarry.wmflabs.org/query/44040

USE tawikisource_p;
SELECT
CONCAT("* {{target | user =",actor_name,"| site = ta.wikisource.org }}") AS rev_user_text,
COUNT(actor_id) AS recent_user_editcount
/*,user_editcount*/
FROM revision
JOIN actor ON rev_actor=actor_id
JOIN page ON rev_page=page_id
WHERE page_namespace = 250
	AND actor_user IS NOT NULL
	AND rev_timestamp BETWEEN 20200101000000 AND 20201231235959
GROUP BY actor_id
ORDER BY recent_user_editcount DESC
LIMIT 500;

script 3

[edit]

https://quarry.wmflabs.org/query/44356

USE bnwikisource_p;
SELECT
CONCAT("# {{target | user =",actor_name,"| site = bn.wikisource.org }}") AS rev_user_text,
COUNT(actor_id) AS recent_user_editcount
/*user_editcount*/
FROM revision
JOIN actor ON rev_actor=actor_id
JOIN page ON rev_page=page_id
WHERE actor_user IS NOT NULL
  AND page_namespace IN ('0','104')
  AND rev_timestamp BETWEEN 20190322000000 AND 20200430235959
GROUP BY actor_id
ORDER BY recent_user_editcount DESC
LIMIT 500;

script 4

[edit]

https://quarry.wmflabs.org/query/44376

USE enwikisource_p;
SELECT
CONCAT("# {{target | user =",actor_name,"| site = en.wikisource.org }}") AS rev_user_text,
COUNT(actor_id) AS recent_user_editcount
/*user_editcount*/
FROM revision
JOIN actor ON rev_actor=actor_id
JOIN page ON rev_page=page_id
WHERE actor_user IS NOT NULL
  AND page_namespace IN ('0','250','252','104','106')
  AND rev_timestamp BETWEEN 20190101000000 AND 20200430235959
GROUP BY actor_id
ORDER BY recent_user_editcount DESC
LIMIT 500;

Namespace Generator of All Indic Project

[edit]
Namespace Generator of All Indic Project
Wikisource Namespace Generator link Page Namespace Index namespace
English https://en.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Assamese https://as.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Bengali https://bn.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 102
Gujarati https://gu.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Hindi https://hi.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 250 252
Kannada https://kn.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Malayalam https://ml.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 106 104
Marathi https://mr.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Odia https://or.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 250 252
Punjabi https://pa.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 250 252
Sanskrit https://sa.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106
Tamil https://ta.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 250 252
Telugu https://te.wikisource.org/w/api.php?action=query&meta=siteinfo&siprop=namespaces 104 106