Wikipedia:Bots/Requests for approval/ElliBot


 * The following discussion is an archived debate. Please do not modify it. To request review of this BRFA, please start a new section at Bots/Noticeboard. The result of the discussion was

ElliBot
Operator:

Time filed: 14:46, Saturday, January 23, 2021 (UTC)

Automatic, Supervised, or Manual: automatic

Programming language(s):

Source code available:

Function overview: Automatically apply redirect category shell templates to redirects with Wikidata, and remove redundant Wikidata redirect templates.

Links to relevant discussions (where appropriate):

Edit period(s): one time run

Estimated number of pages affected: 50,000-100,000

Exclusion compliant (Yes/No): Yes

Already has a bot flag (Yes/No): No

Function details: I recently modified Redirect category shell to automatically detect Wikidata links and apply the template Wikidata redirect if they exist. This was previously already done with protection levels, and there is no reason that Wikidata redirect should not also be applied.

There are currently 100,000 redirects in the category Category:Redirects connected to a Wikidata item, which is applied by the software. There are currently 30,000 redirects in the category Category:Wikidata redirects. Nearly all of these were put into that category by applying Wikidata redirect manually, meaning they will need the tag removed (as it will be a duplicate).

Many of the remaining 70,000 pages will need the template rcat shell added. As the change to Redirect category shell was recent, many redirects connected to Wikidata items, without Wikidata redirect, but with Redirect category shell, have not been added to Category:Wikidata redirects. The difference in count between Category:Wikidata redirects and Category:Redirects connected to a Wikidata item is the number of pages that will be modified.

The edits will be carried out with AWB running as an automated bot. There is very low risk of disruption in this task, though the number of edits is significant. Using AWB, this bot can also carry out other generic fixes to redirects, though this is not a significant part of its functions.

A somewhat similar failed request was Bots/Requests for approval/TomBot, but that that request was for a bot that would edit ~30-60x more pages, with less benefit overall. This is a much more narrow and useful request.

Discussion
ProcrastinatingReader (talk) 16:01, 23 January 2021 (UTC)
 * 1) Any prior discussions on doing this that you're aware of, which establish broader consensus for this task?
 * 2) Will this BRFA cause Template:Wikidata redirect to become redundant? If I understand correctly, this task will orphan all of its transclusions? If so, and especially if there's no prior discussion, I suggest sending that template to TfD (and then this bot task can be technically implementing that TfD). That would be one way to test the wider consensus for this task, too.
 * There are no discussions I know of establishing consensus around this particular task. Wikidata redirect will not become redundant for two reasons. redirect category shell transcludes it. However, this usage could be subst, of course. The other usage is in cross-Wiki (such as to Wiktionary) and category redirects, the "soft" usage. The "hard" usage could be deprecated from the template, however (they are implemented slightly differently, with an automatic switch). Elliot321 (talk &#124; contribs) 16:20, 23 January 2021 (UTC)
 * To begin with, I'd say stylistically this presentation is inferior. See eg here. The one on the top (caused by the edit) doesn't look as good as the manual one & looks slightly out of place with the plaintext.
 * If the rcat shell has to be manually added by bot, is there really a point to this? Why not have a bot add Wikidata redirect to pages in Category:Redirects connected to a Wikidata item? ProcrastinatingReader (talk) 00:39, 24 January 2021 (UTC)
 * Sorry - that was due to my changes being misunderstood and reverted. If you check now, you can see the way they were intended to look.
 * The reason for adding redirect category shell over wikidata redirect is for automatic detection. If the link on Wikidata is removed, no update on Wikipedia is necessary (likewise, if a link on Wikidata is added to one using the shell, no update is necessary). Elliot321 (talk &#124; contribs) 07:52, 24 January 2021 (UTC)
 * Okay, makes sense. I'd suggest dropping a link to this BRFA from the template talk pages for the two templates, to allow some time for comments. ProcrastinatingReader (talk) 09:37, 24 January 2021 (UTC)
 * Done. Elliot321 (talk &#124; contribs) 10:08, 24 January 2021 (UTC)

So the idea is that should add the Wikidata box by checking for the connected item. Manually adding the template wouldn't be necessary then because the software can already detect if a page is connected to a Wikidata item. Is that correct? --PhiH (talk) 13:20, 24 January 2021 (UTC)
 * pretty much. The shell will automatically detect a link to Wikidata, and if found, transclude the template. Therefore, this bot will remove the redundant manual transclusions of the template, and add the shell to automatically transclude on any redirect linked to Wikidata. Elliot321 (talk &#124; contribs) 15:36, 24 January 2021 (UTC)

If I understand what changed with wikidata redirect and redirect category shell correctly, redirects that only have wikidata redirect will be changed to an empty redirect category shell, which then results in an error. This means that manual inspection is needed to determine another redirect category to apply, which obviously this Bot task cannot do. —seav (talk) 01:02, 25 January 2021 (UTC)
 * FYI, an empty Rcat shell results in sorting the redirect to the category, which is monitored by editors who will then tag the redirect with appropriate categories.  P.I. Ellsworth    ed.  put'r there 03:41, 25 January 2021 (UTC)
 * Would that be a problem then, ? Filling the cat up with some tens of thousands of pages? ProcrastinatingReader (talk) 08:12, 25 January 2021 (UTC)
 * An empty RCAT shell with a Wikidata item doesn't need to be categorised in Category:Miscellaneous redirects because it generates the Template:Wikidata redirect. I didn't check if that is implemented yet. A page with that template and no Wikidata item is a problem as well. They just move from one tracking category to another. --PhiH (talk) 08:44, 25 January 2021 (UTC)
 * Why doesn't it need to be categorised into misc redirects? Having a Wikidata item connected/existing isn't really an explanation of why there's a redirect on enwiki. Surely the redirect still needs to be categorised? ProcrastinatingReader (talk) 09:06, 25 January 2021 (UTC)
 * the redirect category shell template should not be applied without any categories by a bot as the Category:Miscellaneous redirects should be filled manually. Consequently, I don't plan to do that with this bot. I can manually categorize the redirects that do not have any categories.
 * (though, a tracking category for uncategorized redirects that can be applied by a bot would probably be useful. I don't feel like gaining consensus for that, though, as that would likely be much more contentious than this proposal) Elliot321 (talk &#124; contribs) 11:37, 25 January 2021 (UTC)
 * I think my point is easier to demonstrate with an example, or I’m mistaken about exactly what is proposed here. Can you make 5 edits as a demonstration, either with the bot or by hand if you don’t have the bot coded yet? ProcrastinatingReader (talk) 12:10, 25 January 2021 (UTC)
 * Maybe a page demonstrating what changes would be made would be more useful, since there are a few differing cases here? Elliot321 (talk &#124; contribs) 03:46, 26 January 2021 (UTC)
 * An actual edit or two of each case would be preferable, as that's the least confusing way to see what is actually proposed. ProcrastinatingReader (talk) 09:57, 26 January 2021 (UTC)
 * But you want to add an empty RCAT shell to pages that currently only use Wikidata redirect, don't you? Should they be added to Category:Miscellaneous redirects if they are connected to a Wikidata item or not? --PhiH (talk) 12:32, 25 January 2021 (UTC)
 * I can manually categorize the pages currently in that situation. Elliot321 (talk &#124; contribs) 03:46, 26 January 2021 (UTC)
 * It's not about manual categorisation. We are discussing whether the category should be added by the RCAT shell when the redirect is connected to a Wikidata item. --PhiH (talk) 14:19, 26 January 2021 (UTC)
 * as long as there is at least one rcat template within the Rcat shell, such as the "Wikidata redirect" template, then the redirect would not be sorted to . As the proposer suggests, that would not be a problem. The proposer appears to know that a bot should not add an empty Rcat shell to redirects, which would bloat the Misc. redirects category.  P.I. Ellsworth   ed.  put'r there 15:35, 25 January 2021 (UTC)

I think there are multiple cases we have to discuss, feel free to comment below.
 * 1) Redirects that already use the RCAT shell
 * This should be uncontroversial: Where Wikidata redirect is used it gets removed and the template is transcluded by the RCAT shell.
 * 1) Redirects without the RCAT shell…
 * 2) …that use Wikidata redirect and are connected to a Wikidata item
 * The template gets removed and the RCAT shell is added. Should the RCAT shell be programmed to add these pages to Category:Miscellaneous redirects?
 * 1) …that don't use Wikidata redirect and are connected to a Wikidata item
 * The RCAT shell is added. Same question as above arises.
 * 1) …that use Wikidata redirect and are not connected to a Wikidata item
 * The template gets removed. Adding the RCAT shell would cause them to be added to Category:Miscellaneous redirects. Currently these pages are tracked in Category:Unlinked Wikidata redirects. Before this bot task begins someone should work through this list and add the pages on Wikidata if necessary.

--PhiH (talk) 14:46, 26 January 2021 (UTC)

If I understand correctly, this bot will add the Rcat shell along with an internal Wikidata redirect tag when it senses any redirect that is already itemized on Wikidata. If that is what happens, then the redirect will not be sorted to the Misc. redirects category. I also sense a possible challenge where the NASTRO comment template is applied. One of many examples is at. Would this bot do anything to those many redirects? I actually like the idea of more Rcat shell transclusions. I wonder if the bot will continue checking for new redirects that become connected to a Wikidata item?  P.I. Ellsworth   ed.  put'r there 21:57, 26 January 2021 (UTC)
 * The bot won't touch the NASTRO comment redirects, since it has no need to.
 * I could run this after the main clean-up job (probably a weekly run would be sufficient). Elliot321 (talk &#124; contribs) 05:25, 27 January 2021 (UTC)
 * NASTRO comment applies the Rcat shell and so would auto-apply the Wikidata redirect template. There will then be two renditions of Wikidata redirect. Won't one of them have to be removed?  P.I. Ellsworth   ed.  put'r there 18:49, 27 January 2021 (UTC)
 * NASTRO comment applies the Rcat shell and so would auto-apply the Wikidata redirect template. There will then be two renditions of Wikidata redirect. Won't one of them have to be removed?  P.I. Ellsworth   ed.  put'r there 18:49, 27 January 2021 (UTC)


 * I thought the point of this bot is that these edits wouldn't be necessary anymore. Here you said If the link on Wikidata is removed, no update on Wikipedia is necessary (likewise, if a link on Wikidata is added to one using the shell, no update is necessary) --PhiH (talk) 19:00, 27 January 2021 (UTC)
 * A weekly run would handle any new redirects that have been created. Editors LOVE to create new redirects; however, they generally leave it up to bots and Wikignomes to categorize their new redirects.  P.I. Ellsworth   ed.  put'r there 17:11, 28 January 2021 (UTC)
 * That sounds reasonable. I hadn't thought about completely new pages. --PhiH (talk) 17:29, 28 January 2021 (UTC)
 * "Redirects that already use the RCAT shell: This should be uncontroversial": Have you thought about the cases where the rcat shell only contains the Wikidata rcat? 𝟙𝟤𝟯𝟺𝐪𝑤𝒆𝓇𝟷𝟮𝟥𝟜𝓺𝔴𝕖𝖗𝟰 (𝗍𝗮𝘭𝙠) 21:25, 16 February 2021 (UTC)

Also curious as to why AWB is used? Don't get me wrong; I love AWB. However it's not known for its speed or lack of clunkiness. According to the manual, So why not make a non-AWB bot to do the task?  P.I. Ellsworth   ed.  put'r there 22:14, 26 January 2021 (UTC)
 * Mainly because I know AWB and regex better than I know any other frameworks to interface with Wikipedia. I could write custom code, if that would be preferred. Elliot321 (talk &#124; contribs) 05:26, 27 January 2021 (UTC)
 * I was just curious, so it would be up to you, of course. I just know how it drives me crazy sometimes when I have to stop in the middle of something, log out of AWB, log in to Wikipedia just to check notifications, log back out and into AWB to commence. That happens with non-bot-auto work as well.  P.I. Ellsworth   ed.  put'r there 18:53, 27 January 2021 (UTC)
 * Um... you don't have to log out of AWB to reset the counter. Also, technically you don't have to log out of Wikipedia either if you log in to the bot account in private mode. Primefac (talk) 13:44, 8 March 2021 (UTC)

So just to clarify what I'm waiting on: An actual edit or two of each case would be preferable, as that's the least confusing way to see what is actually proposed. After that, it'll be more clear to have the discussion on which edits are good and which need further discussion. ProcrastinatingReader (talk) 15:32, 13 February 2021 (UTC)
 * Re: the message above. Primefac (talk) 13:44, 8 March 2021 (UTC)
 * thanks for the ping. I've actually expanded the scope of what I'm intending to do here a bit (see User:Elli/rcat standardization) - and planning on getting consensus for the changes elsewhere first, before going through with this, so if I could put this request on hold or something that would be ideal (sorry, I'm not sure exactly how this type of situation works, but getting approval for the narrow task of shelling and removing one rcat doesn't really make sense given my goal to deal with ~20 of them). Elli (talk &#124; contribs) 18:38, 8 March 2021 (UTC)
 * Just comment out the template when you're ready to go (no harm in having it sit here for a while). Primefac (talk) 19:29, 8 March 2021 (UTC)
 * This very productive discussion probably should have happened somewhere else prior to the BRFA being filed. Maybe this BRFA should be withdrawn pending a full discussion and manual demonstration of various test cases, and then resubmitted with a link to that discussion and a better explanation of the task. – Jonesey95 (talk) 02:25, 7 December 2021 (UTC)
 * Just to follow up here: do you still intend to go through with this BRFA? ProcrastinatingReader (talk) 01:07, 8 November 2021 (UTC)
 * yes, just been busy with other stuff and not completely sure of the technical details yet. I'll try to follow up on that soon-ish. Elli (talk &#124; contribs) 01:10, 8 November 2021 (UTC)


 * I have another proposal: Bot requests. Why my proposal is better:
 * 1) it keeps Qids ("Q" number), thus we can track if someone moves the redirect to another wikidata entry.
 * 2) it does not mess up with RCAT which is only for categories. Heanor (talk) 18:20, 8 February 2022 (UTC)

Marking as expired since it's been about 15 months, but feel free to reopen if you intend to continue. ProcrastinatingReader (talk) 15:52, 21 April 2022 (UTC)
 * The above discussion is preserved as an archive of the debate. Please do not modify it. To request review of this BRFA, please start a new section at Bots/Noticeboard.