User talk:MMABot/v2.0 Discussion

Proposal for tasks to be performed by MMABot v2.0

I am seeding this discussion with a set of tasks that MMABot v2.0 can perform. v2.0 is intended to perform all tasks of v1.0 and any tasks from this discussion that are approved by the WP:BAG. Each task will be its own subsection to allow anyone who wishes to comment on an individual task can do so. If there is a task you would like to see MMABot perform you can create a subsection for that task. Please keep in mind that my intentions with the MMABot is to help the editors of the MMA Wikiproject standardize MMA fighter pages. Also keep in mind that there are a number of policies for bots to be approved and used without being blocked. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

Remove deprecated parameter from {{dts}}

The {{dts}} template is used in all MMA record tables (or should be) for presenting the date of an event. In many cases, this template includes the deprecated "link=off" parameter. The bot should remove any instances of this deprecated parameter from the {{dts}} templates. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Partly done The code is written, needs to be tested. --TreyGeek (talk) 20:25, 18 December 2011 (UTC)
  Done Has been tested and appears to work. --TreyGeek (talk) 22:15, 22 December 2011 (UTC)

Add MMA WikiProject banner to talk pages

If an article being examined by MMABot does not include the {{WikiProject Mixed martial arts}} banner, MMABot should add it. The banner is used for a number of reporting and notifications for the project (such as prod/Afd reports). Care will need to be taken to put the banner in the right place (particularly where {{WikiProjectBannerShell}} is being used). --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Partly done When {{WikiProjectBannerShell}} or {{WikiProjectBanners}} is on the talk page the MMA Wikiproject banner is added to the end of the list of existing banners. If neither template is in use but there is a {{WikiProject Biography}} or {{WPBiography}} banner, the MMA Wikiproject banner will go beneath this banner. If Biography is not there (perhaps I should add it?) the MMA banner will be the first banner on the talk page. I just realized that in this last case the banner is the first thing on the talk page, possibly being put above other templates when maybe it shouldn't. I need to look into this more. --TreyGeek (talk) 15:52, 23 December 2011 (UTC)
  Done Scanning through a number of fighter article talk pages, I see only two other headers to avoid. After checking the cases above, if the talk page contains a {{talk header}} or {{article history}} the MMA WikiProject banner will go beneath them. --TreyGeek (talk) 17:54, 23 December 2011 (UTC)
Just added in a catch for the abbreviated version of BannerShells: {{tl:WPBS}} --TreyGeek (talk) 14:09, 27 December 2011 (UTC)

Sherdog ID links

MMA fighter articles have two places for links to the fighter's Sherdog profile. In the 'External links' section near the bottom of the article and as a parameter in {{Infobox martial artist}}. If the link is in one place but not the other, the bot can try to fix that. Note, if the link does not exist in either place, nothing will be done. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done If the external links section includes the {{sherdog}} template, but the sherdog parameter in the infobox is not filled in, the infobox will be adjusted. If the infobox parameter is filled in but there is no {{sherdog}} template in the external links section, the template will be added. If there is no external links section at all or if the infobox parameter is missing entirely, I'll get a notice from the bot that it needs to be fixed manually. --TreyGeek (talk) 23:54, 22 December 2011 (UTC)

Remove total win/loss parameters

Both {{Infobox martial artist}} and {{MMArecordbox}} can automatically calculate the total wins and losses for a fighter. However, there are still articles that explicitly include these now deprecated tags. MMABot can check these templates and remove the deprecated tags --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done Parameters are now being removed as stated above. --TreyGeek (talk) 22:26, 22 December 2011 (UTC)

Add {{BLP unsourced}} template to articles without <ref> tags

There are articles that do not cite any references through the <ref> tags. If MMABot cannot find any such tags, it will add the {{BLP unsourced}} template to the top of the article if it does not already exist. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done The bot will add the template on any articles without a <ref> tag. --TreyGeek (talk) 23:54, 22 December 2011 (UTC)

Remove fighting styles from Infobox

As per this discussion MMABot will remove any information used in the fighting style parameter of the Infobox. I do have concerns about individuals who are kickboxers, wrestlers and possibly boxers in addition to being an MMA fighter. In these cases that particular style (kickboxing, wrestling, boxing) should probably stay in the infobox. I'll need to figure out how to accurately do this. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

As more discussion on this task here is how I think I can avoid issues with kickboxers, wrestlers and boxers.
  • The martial arts infobox includes a field for wrestling to explain the fighter's "level of experience in am_ateur wrestling, eg: NCAA Division I Wrestling". Therefore, wrestling should not be listed in the style parameter as it would be redundant with this field.
  • If the article contains a [[Category]] containing the word "kickboxer", then the style parameter should contain "Kickboxing". I do worry that there are a lot of fighter articles with a kickboxing category that is incorrectly added. I lack the knowledge to confirm this but I'm not sure this is a big worry at this time. (Hopefully, someone will chime in if this is something to reconsider.)
  • Similar to kickboxers, if the article contains a category containing the word "boxer", then the style parameter should contain "Boxing". Care must be taken to ensure that looking for "boxer" doesn't get confused with "kickboxer" and add both "Kickboxing" and "Boxing" to someone who is only a kickboxer.
If anyone has any suggestions or comments on this task, please do so. --TreyGeek (talk) 22:41, 22 December 2011 (UTC)
  Done MMABot now works as described above.

Unlink red-linked fighters and events in record table

In MMA record history tables, any fighter name or event that is "red linked" should be de-linked. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done For fighters the bot parses the opponent field and compares the target article with the master list of MMA fighter articles I have stored locally. If the target article is not in my master list, I delink the fighter's name. Care is taken that if the fighter's name includes a pipe to rename the link, when delinking I keep the renamed portion of the link (thus "[[TreyGeek (fighter)|Trey Geek]]" becomes "Trey Geek").
For events the bot parses the event field similarly to fighters and checks Wikipedia to see if the article exists. If the article does not exist, the event's name is delinked similarly to fighters. --TreyGeek (talk) 18:39, 23 December 2011 (UTC)

Convert variations of "US" to "United States"

In the past I've noticed many variations of "United States" in the location column of record history tables. MMABot should replace instances of "US", "USA", "U.S.", "U.S.A.", and "United States of America" to "United States". I am interested to hear if there are other variations that need to be caught as well. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Partly done This has been coded with the variations listed above, but has not been tested. --TreyGeek (talk) 20:25, 18 December 2011 (UTC)
  Done Has been tested to work with the variations listed above. The possibility exists that there are odd corner-cases that may cause problems, but I'll try to do more testing and keep an eye out if/when MMABot performs this task on live articles. --TreyGeek (talk) 22:15, 22 December 2011 (UTC)

Delink country names

As per WP:OVERLINK the names of countries (ie "United States", "England", "Brazil", etc) should not be wiki-linked. In the MMA record history table location column, instances of country names should be delinked. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Doing...To determine what is a country that should be delinked, I've compiled a list of countries to reference from List of sovereign states. --TreyGeek (talk) 00:37, 24 December 2011 (UTC)
  Done Countries, when displayed alone, that are in the article above are delinked by MMABot. The bot also checks to see if a city/country combination (ie "London, England") that is linked together and is redirected (ie to "London"), the target article is kept as a link and the country is delinked (London, England becomes London, England). --TreyGeek (talk) 23:30, 24 December 2011 (UTC)

Remove future fights from fight record table

As per the following discussions: 1, 2, and 3; MMABot will remove future fights from a fighter's record table. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done For each row I check the date field. If the date specified is later than the current date then I remove that row from the table. May want to consider changing it to check if the date is further out than a day or two to reduce edit wars (or not run the bot a day or two before a scheduled fight card). That can be worried about later. --TreyGeek (talk) 21:19, 28 June 2011 (UTC)

Fix fighter links going to wrong article

There as a previous request to check the linked fighters in the fight record table. If the destination of the link does not go to an MMA fighter, the link needs to be fixed. I'll propose how to accomplish this in a little bit. --TreyGeek (talk) 20:58, 17 December 2011 (UTC)

  Done I'm making use of my local fighter article list. If the name in the opponent column partially matches one of the fighter article titles, the name will be correctly wikilinked. Ex: "Patrick Barry" becomes "Patrick Barry" and "Roy Nelson" becomes "Roy Nelson". --TreyGeek (talk) 16:52, 26 December 2011 (UTC)

Delink organization names in fight record table

The MMA WikiProject guidelines for fight record tables says that organizations should not be wiki-linked in the table. The bot will delink any organization in the event column of the record table. (Details to follow) --TreyGeek (talk) 21:09, 22 December 2011 (UTC)

  Doing... I'll be using the organizations listed in the {{MMA organizations}} as the list of organizations to delink if it appears in its entirety in the event column. --TreyGeek (talk) 01:57, 25 December 2011 (UTC)
  Done If an organization is linked in the event column that appears in the organization list mentioned previously it is delinked. --TreyGeek (talk) 00:42, 26 December 2011 (UTC)

Bug tracking on MMABot v2 trial period

Incorrect location of WP:MMA Banner

The bot placed the WP:MMA banner on a talk page above the talk header template [1].

  Fixed A different talk header template was used here than what was expected. MMABot will now recognize both {{talk header}} and {{talkheader}}. --TreyGeek (talk) 04:48, 9 January 2012 (UTC)

Incorrect removal of country

The bot removed the country (Australia) from several locations that contained a renamed city, state pair [2]. --TreyGeek (talk) 04:48, 9 January 2012 (UTC)

  Fixed Long story short, the bot was incorrectly rewriting locations that included a renamed link, regardless of the location. It now only rewrites renamed links for US city/state pairs (ex: [[Austin, Texas|Austin]], [[Texas]] becomes [[Austin, Texas]]) and leaves non-US renamed locations alone. Therefore, it leaves the links as cited above alone as shown here: [3]. --TreyGeek (talk) 05:06, 9 January 2012 (UTC)

Incorrect removal of state

The bot removed a state (Nevada) the followed a renamed city link, but kept the country [4]. --TreyGeek (talk) 04:48, 9 January 2012 (UTC)

  •   Fixed Turns out this was another corner case of the situation described in the previous section. It will leave this version of renamed links alone as shown here: [5]. --TreyGeek (talk) 05:15, 9 January 2012 (UTC)