Wikipedia:AutoWikiBrowser/General fixes
- Home
Introduction and rules - User manual
How to use AWB - Discussion
Discuss AWB, report errors, and request features - User tasks
Request or help with AWB-able tasks - Technical
Technical documentation
This is the user manual for AutoWikiBrowser.
|
Chapters: | Core · Database scanner · Find and replace · Regular expressions · General fixes |
---|
General fixes is a set of semi-automated edits that are enabled by default in AutoWikiBrowser. They are intended to be uncontroversial and require minimal human oversight; many are cosmetic and improve wikitext readability but do not affect display to readers.
This page lists the general fixes, although it may not be exhaustive. General fixes are optimised for en-wiki with some variation for other language wikis. Not all general fixes are suitable for all languages. Some general fixes are disabled on pages containing <includeonly>
or <noinclude>
.
Fix dates (FixDates)
edit
- Fixes date format errors per WP:DATE:
- Removes comma between day and year for International-format dates.
- Inserts missing comma between day and year for American-format dates.
- Sets en-dashes for date, month or year ranges (from hyphen).
- Replaces first occurrence of unlinked floruit with linked version (zeroth section only, not within templates) per WP:MOSBD.
- Fixes some formatting errors
- Replaces <br> and <p> HTML tags with ...>.
Template Redirects (TemplateRedirects)
edit
- Bypasses template redirects using those listed on Template redirects rule page, per WP:Redirect#Template redirects.
- Keeps first letter case of the redirect in the new template name, except for acronym templates (first three letters uppercase) where the template is forced to uppercase.
- Handles nested templates
Multiple issues (MultipleIssues)
edit
- Applies fixes to {{Multiple issues}} (formerly {{Article issues}}), en-wiki only
- removes template if it has no parameters.
- (old format templates) converts it to the original template if it has only one parameter (e.g. diff).
- (old format templates) removes invalid parameters such as
|date=
- merges other supported tags into it
- (old format templates) Corrects casing of exiting parameters
- Adds 2 or more single tags into new {{Multiple issues}}
- Templates are added within {{Multiple issues}} on separate lines
- When not in zeroth section, includes
|section=yes
parameter
- Removes blank lines
- (new format templates) converts to original template if only one template in {{Multiple issues}}
- Does not operate if an article level-2 section has more than one {{Multiple issues}}
Merge multiple DABLinks (Dablinks)
edit
- Cleans and merges multiple DABLinks per WP:DISAMBIG. Called by Conversions function.
- Removes about as first word of the first parameter of {{About}} e.g. {{about|about foo}} to {{about|foo}}
- Merges multiple {{About}}
- {{about|foo|a|b}}{{about|foo|c|d}} → {{about|foo|a|b|c|d}}
- {{about|foo|a|b}}{{about||c|d}} → {{about|foo|a|b|c|d}}
- {{about|foo||a}}{{about|foo||b}} → {{about|foo||a|and|b}}
- Merges multiple {{For}} into {{About}}
- {{about|foo|a|b}}{{for|c|d}}{{for|e|f}} → {{about|foo|a|b|c|d|e|f}}.
- {{about|foo|a}}{{for|b|c}} → {{about|foo|a||b|c}}
- Merges multiple {{For}}
- {{for|a|b}}{{for|c|d}} → {{about||a|b|c|d}}
- {{for|a|b|}}{{for|c|d|e}} → {{about||a|b|c|d|and|e}}
- Merges multiple {{Distinguish}}
- {{distinguish|a}}{{distinguish|b}} → {{distinguish|a|b}}
DEFAULTSORT insertion and fixes (SetDefaultSort)
edit
- Changes are not applied if the page has
<noinclude>
or<includeonly>
or{{{1}}}
in the page text - Trims whitespace, removes any pipe at start.
- Fixes comma spacing
- If article is about a person uses Surname, Name format per WP:SUR.
- Exceptions on common Arabic names included to use Full Name format per WP:SUR.
- Pages with a Surname Clarification Template from Category:Hatnote templates for names use Full Name format per WP:SUR.
- {{DEFAULTSORT: McDoe, John}} to {{DEFAULTSORT: Macdoe, John}} per WP:MCSTJR. (Check this. WP:MCSTJR contradicts: "Surnames beginning with Mac or Mc are sorted as they are spelled.")
- "Person of Place" generates sort key of "Person Of Place"; also "Person II of Place" generates "Person 02 Of Place" per WP:PEERS and WP:COP.
- Adds a DEFAULTSORT where the article title does not match the rules above.
- DEFAULTSORTs are not added or changed when the only difference is letter casing.
- NOTE: AWB does not meet all of the (various) rules on DEFAULTSORT on en-wiki; it may not meet all of the rules on other wikis either. It may never be possible to meet all of the rules. An option is provided under the Options menu to turn off all changes/insertion of DEFAULTSORT.
People Categories (FixPeopleCategories)
edit
- Adds [[Category:XXXX births]], [[Category:XXXX deaths]] etc. to articles about people where available (English Wikipedia only)
- Skips pages with 20 or more references and no births/deaths categories to avoid false positives.
- Skips pages with 15,000 characters or more that do not already have Category:Living people or a birth or death year/century category.
- Changes
{{Uncategorised}}
to{{Cat improve}}
if categories added. - Removes Category:Year of birth missing or Category:Year of birth missing (living people)
- Adds [[Category:Living people]] if page has [[Category:XXXX births]] and no living people/deaths category, taking sortkey from births category if present
- Skips if the person is dead, or thought to be dead.
- Skips if person was born > 115 years ago per Category:Living people and WP:BDP.
- If full DOB in {{birth date and age}} removes Category:Date of birth missing or Category:Date of birth missing (living people) (T150632)
Fix syntax (FixSyntax)
edit
- Performs various syntax fixes:
- Removes empty <gallery>, <center>, <blockquote>, <sub> or <sup> tags, including tags with properties
- Fixes incorrect <i /> tags.
- Fixes incorrect closing tags for <center>, <gallery>, <sub>, <sup> etc. For example, <center/>.
- Replaces HTML markup with wiki syntax (e.g. italics and bold).
- Replaces old HTML markup <strike> with <s>
- Removes appearance of multiple line break.
- Removes break line tags after maintenance tags.
- Fixes double piped links e.g. [[foo||bar]] to [[foo|bar]].
- Removes unnecessary namespace (e.g. Template:).
- Removes <br> from lists.
- Fixes most uneven bracketing on wikilinks/categories/templates/interwikis/external links/files (FixUnbalancedBrackets).
- (Partially) fixes wikilinked/external linked URL in cite template.
- Fixes incorrect <br> tags. For example, <br.>, <\br> and <br\>
- Replaces obsolete <br> tag attributes per Wikipedia:HTML5#Other_obsolete_attributes. Example
- Fixes incorrectly formatted ISBNs such as ISBN: ..., ISBN-10: ...
- Removes "ISBN" from start of
|isbn=
parameter in infoboxes
- Removes <sup> tags from ordinal numbers per WP:ORDINAL.
- Removes <small> tags inside <small>, <sup>, <sub> tags and image captions (per MOS:CAPTIONS) (not applied when article has unclosed tags).
- Moves {{dead link}} inside references per its documentation.
- Does various syntax fixes for external links/cited URLs.
- Fixes external links starting with http://http://.
- Fixes external links starting with http:://.
- Fixes external links starting without double slash.
- Removes unneeded pipes from simple external links.
- Fixes spacing before and after external links.
- Removes break from the end of Image/File descriptions.
- Simple closing bracket fixing to {{R...}} templates
Simplify links (SimplifyLinks)
edit
- Simplifies links like [[Dog|Dog]] to [[Dog]] per Wikipedia:Manual of Style (linking)#Piped links.
- Simplifies links like [[Dog|Dogs]] to [[Dog]]s per Wikipedia:Manual of Style (linking)#Piped links.
- Simplifies links like [[Dog|'''Dog''']] to '''[[Dog]]'''
- Simplifies links like [[dog|(dog)]] to ([[dog]])
Citation templates (FixCitationTemplates)
edit
- Performs various fixes to citation templates (en only):
- Renames invalid
|pg=
to|page=
(e.g. diff). - Removes empty fields where the field has already been specified elsewhere.
- Corrects common typos in
|accessdate=
,|format=
,|language=
and|publisher=
field names (e.g. diff). - Removes excess pipes.
- Removes the unneeded
|format=HTML
field - Removes
|language=
when it is English per citation templates manuals - Removes
|format=
field with null value when URL is HTML page - Removes italics for
|work=
field for book/periodical, but not website (auto italicised by template) - Removes quotes around
|title=
field since they are automatically added by template markup - Converts curly quotes to straight quotes per MOS:PUNCT and MOS:QUOTE
- Removes p. or pp. from
|page=
and|pages=
fields when nopp not set - Renames
|year=
to|date=
if the field contains an American, International or ISO date. - Changes {{cite web}} references to Google Books to use {{cite book}}
- Removes duplicated fields.
- Removes
|accessyear=
where|accessdate=
is present and contains said year - Renames deprecated parameter names, per WP:AWB/RTP
- Removes ordinals from dates per WP:MOSDATE
- Adds http:// to start of www URL when missing.
- {{Dead link}} moved from
|format=
field to after citation per Template:Dead link. - Converts newlines to spaces in citation titles when URL is present (otherwise display is incorrect).
- Renames
|authors=
to|author=
in {{cite web}}. - For {{cite journal}} only: extracts issue/number information from
|volume=
and moves to|issue=
- Converts
|id=ISSN 1234-5678
or|ID=ISSN 1234-5678
to|ISSN=1234-5678
provided|ISSN=
and|issn=
not already populated and|id=
contains valid ISSN - Formats
|ISSN=12345678
or|ISSN=1234 5678
to|ISSN=1234-5678
provided|ISSN=
is 8 digits (supported for|issn=
as well)
- Renames invalid
Redirect tagger (RedirectTagger)
edit
- Tags redirects, where appropriate, with one of
|
- Note: The method is in compliance with WP:REDCAT
Fix syntax inside redirects (FixSyntaxRedirects)
edit
- Removes carriage returns inside redirects.
- Removes unnecessary namespace (e.g. Template:).
- Checks for a <references> missing '/' to correct (e.g. diff).
- Adds {{Reflist}} if it's needed (i.e. article has references) but missing (English Wikipedia only).
- If page does not have a References section, it adds one to the appropriate place.
Duplicate Named References (DuplicateNamedReferences)
edit
- Where an article uses named references (see WP:REFNAME), duplicate copies of the same reference are condensed to the abbreviated format of <ref name="Smith" />.
- The change is subject to a minimum reference length.
- References using the same name and same reference value are condensed (this does not change the appearance of the page to the reader).
- Unnamed references with the same reference value are condensed.
- Leading and trailing whitespace is ignored when deciding if two references are the same.
- Named references are not condensed if the first declaration is in a template call, because we cannot be sure the template will display all of its parameters (and hence the reference) and do not want to create an undefined reference error
- Note: This change is fully compatible with the Harvard referencing style.
Duplicate Unnamed References (DuplicateUnnamedReferences)
edit
- Duplicate copies of the same reference are condensed by setting the references as named references (see WP:REFNAME), and condensing per Duplicate Named References logic.
- The references must be identical except for any leading or trailing whitespace.
- The change is subject to a minimum reference length.
- The references cannot be of the ibid type.
- The references cannot have a {{page needed}} template.
- The article must already have at least one named reference (to avoid a 'change in citation style' in the article per WP:CITEVAR). This means at least one named ref in short format (<ref name=a/>) as a full named ref by itself does not cause any references to display as combined.
- The reference name is derived by use of the author name, year & page where available, otherwise trans-title/title, otherwise publisher, otherwise website of URL, otherwise fields from the Harvard family of templates, otherwise full reference if short, otherwise a generic reference name of 'ReferenceA' etc.
- Note: This change is fully compatible with the Harvard referencing style.
Fix Date Ordinals/Of (FixDateOrdinalsAndOf)
editThis is a MOS and minor fix
- Performs various fixes in compliance with WP:DATE, but not on text in quotes, templates, wikilinks, etc.:
- Removes ordinals from full dates per WP:DATESNO; does not alter on the 3rd November 2008 (i.e. the plus ordinal) to avoid introducing bad grammar.
- Removes 'of' between a month and a year per WP:DATESNO.
- Removes leading zeros from the day in full dates per WP:DATESNO.
- Adds a comma if missing to full American-format dates per WP:DATEFORMAT.
- Note: This function can be disabled by disabling WP:MOS fixes under the Options menu (Option designed for third-party wikis/other language wikis that are not en-wiki).
Fix categories (FixCategories)
edit
- Sets first alphabetical character in category name to be upper case.
- Removes diacritics and trailing whitespace from category sortkeys per WP:SORTKEY.
- Removes unnecessary whitespace around category call.
- Removes the (unneeded) sort key from categories if a {{DEFAULTSORT}} entry is present with the same sort key.
- Note: The use of a single space as a category sortkey is supported.
Fix empty links and templates (FixEmptyLinksAndTemplates)
edit
- Removes empty wikilinks, category links, and template calls: e.g. empty [[]], [[Category:]], and {{}}.
Fix empty references (SimplifyReferenceTags)
edit
- Condenses reference tags in the form <ref name="blah"></ref> with <ref name="blah" />.
Fix images (FixImages)
edit
- Fix common spacing/capitalisation errors in images
- Fix whitespace around Image/File call
- Canonicalises images titles (underscore to space, URL encoding converted to Unicode etc.).
Fix main article (FixMainArticle)
editThis is a MOS fix
Fix non-breaking spaces (FixNonBreakingSpaces)
editThis is a MOS fix
- Inserts non-breaking spaces between amount and unit for common units, but not on text in quotes, templates, wikilinks, references, etc. per WP:NBSP.
- The units supported include cd (candela), cm, km, miles, feet, inches (but not "in"), grammes, hp, Hz, GHz, kHz, MHz, kg, µg, mL, dB mol, °C, °F (see also WP:UNITS for these), and page abbreviations p. and pp. (see also MOS:NDASH for these)
- Non-breaking spaces are added only before abbreviated units.
- Unspaced mm are specifically excluded, as firearms use mm when it does not refer exactly to a dimension.
- "m" is excluded due to its use as an abbreviation for million, except when it is immediately followed by a measurement in ft
- The units supported include cd (candela), cm, km, miles, feet, inches (but not "in"), grammes, hp, Hz, GHz, kHz, MHz, kg, µg, mL, dB mol, °C, °F (see also WP:UNITS for these), and page abbreviations p. and pp. (see also MOS:NDASH for these)
- Changes "invisible non-breaking spaces" given by Unicode characters with "visible non-breaking spaces" given by html entities per WP:NBSP.
- Inserts a non-breaking space between 12-clock number and a.m. or p.m. per MOS:TIME.
- Removes space and/or non-breaking space between number and percent symbol per WP:PERCENT.
- Removes space and/or non-breaking space between nonalphabetic currency symbol and number per WP:CURRENCY.
- Note: This function can be disabled by disabling WP:MOS fixes under the Options menu (Option designed for third-party wikis/other language wikis that are not en-wiki).
Fix reference tags (FixReferenceListTags)
edit
- Converts the old "references-2column" style to use {{reflist}}.
Fix temperatures (FixTemperatures)
edit
- Fixes temperatures – corrects numerous incorrect degrees symbols.
Fix whitespace in links (FixLinkWhitespace)
edit
- Removes all unnecessary leading and trailing whitespace from wikilinks and Image/File links.
- Converts double spaces to single spaces in wikilinks and Image/File links.
- Corrects
[[page# section]]
to[[page#section]]
.
FixReferenceTags (FixReferenceTags)
edit
- Performs whitespace fixes to references per WP:REFPUNC and WP:CITEFOOT:
- Remove any spaces between consecutive references.
- Ensure a space between a reference and text (reference within a paragraph).
- Remove spaces between punctuation and references (<ref> tags) per WP:CITEFOOT.
- Performs syntax fixes to named references:
- Incomplete quotes, extra quotes, curly quotes, missing quotes.
- Missing/Double equals in ref name syntax.
- Named ref with no name given.
Mdashes (Mdashes)
editThis is a MOS fix (see WP:DASH)
- Replaces hyphens with endashes:
- Time/common unit ranges.
- Dollar amount ranges.
- Age ranges.
- Text same as the title where title uses an endash.
- Two consecutive hyphens within a sentence (excluding "xn--").
- Replaces hyphen with Unicode minus in superscripted negative numbers.
- Note: This function can be disabled by disabling WP:MOS fixes under the Options menu (Option designed for third-party wikis/other language wikis that are not en-wiki).
Remove empty comments (RemoveEmptyComments)
edit
- Removes HTML comments with no content other than whitespace. This feature is disactivated as a general fix at the moment but the function is still available for use.
ReorderReferences (ReorderReferences)
edit
- Reorders consecutive named references such that they appear in numerical order e.g. [1][2][3] instead of [2][1][3].
- Applies only to consecutive references (i.e. does not affect multiple references spread out over clauses in a sentence).
- Supports the {{Rp}} template.
- Does not affect the use of reference groups.
- Note: This change is fully compatible with the Harvard referencing style and "list-defined references".
- Note: This function was removed from en.wiki in 2017
SameRefDifferentName (SameRefDifferentName)
edit
- Condenses very short named references to the <ref name="Smith" /> format (e.g. diff). It is designed to catch short reference with a trivial entry such as a number or alphabetical ordering reference that is unneeded, or simply whitespace. It operates subject to these conditions:
- The reference is very short
- The reference is named and another full reference is present with the same name.
- The reference is not to a page number.
- Corrects named references where the reference is the same but the reference name is different (e.g. diff)
- Not applied if the reference is an 'ibid' reference or similar.
- The longer reference name is used provided it is not in 'autogenerated1' or 'ReferenceA' format
References after punctuation (RefsAfterPunctuation)
edit
- Puts references after punctuation (comma, full stop, colon, semi-colon) per WP:CITEFOOT and WP:PAIC, subject to:
- Applies to en-wiki and simple-wiki only
- Requires >= 75% refs after punctuation to convert the rest.
- Whitespace before ref is cleaned when punctuation moved.
- Puts many inline templates (such as {{citation needed}}) after punctuation (comma, full stop, colon, semi-colon).
Sort meta data (MetaDataSorter)
edit
- Puts categories after page body, followed by stub templates and interwiki links per WP:FOOTER. Recognizes the common cat and interwiki header comments.
- Puts stub templates above navboxes (ru-wiki only).
- Moves {{Ibid}} to the references section (en-wiki only).
- Moves {{Wikipedia books}} to See also section per WP:SEEALSO.
- Removes commented out interwiki links (en-wiki only).
- Puts two blank lines before stubs per Wikipedia:IDEALSTUB (one blank line for ru and sl-wiki).
- Puts a single blank line between headers per WP:BODY and WP:HEAD.
- Moves the most common maintenance templates above infoboxes etc. (zeroth section only)
- Keeps {{Short pages monitor}} at the very end of article if present per its documentation
- Removes newlines inside unordered lists per WP:LISTGAP
Interwikis (Interwikis)
edit
- Removes duplicate interwikis.
- Unicodifies interwiki links.
- Sorts interwiki links alphabetically (individually selectable in menu) per Help:Interlanguage links.
- Moves interwikis at the bottom of the page after stub templates per WP:FOOTER.
- Removes self interwikis (does not remove current language links for monolingual projects such as Commons).
- Removes double colon in interwikis. For example, it changes
[[es::foo]]
to[[es:foo]]
. - Supports multiple interwiki links to same language and comments beside interwiki links.
Categories (RemoveCats)
edit
- Removes duplicate categories.
- Moves categories to correct position in article per WP:ORDER.
- Moves any {{DEFAULTSORT}} to be just above categories per WP:ORDER.
- On sl-wiki only, moves {{Lifetime}} to be just above categories.
Maintenance Tags (MoveMaintenanceTags)
edit
- Moves maintenance tags to appropriate place per WP:ORDER
- Deduplicates tags, uses earliest
|date=
if multiple tags with different|date=
values.
Deletion/Protection Tags
edit- Moves deletion/protection tags to appropriate place, above maintenance tags, per WP:ORDER
Featured list/article tags
edit- Moves {{Link FA}}/{{Link GA}} immediately above interwikis per template's documentation.
DABlinks (MoveDablinks)
edit
- Moves DABLinks at the very top of the page per WP:HNP. (en-only)
- Only moves DABLinks in the zeroth section of the article.
- Removes unneeded colon before dablink.
Portal templates (MovePortalTemplates)
edit
- Moves any {{Portal}} templates to the top of the "See also" section per WP:SEEALSO. (en-only)
- Removes duplicate portals found outside of "See also" section. (en-only)
See also (MoveSeeAlso)
edit
- Moves the "See also" section to be above the "References" section, per WP:FOOTERS. (en-only)
- Subject to the limitation that the "See also" section cannot be the last level-2 section
External links (MoveExternalLinks)
edit
- Ensures the "External links" section of an article is after the "References" section per WP:FOOTERS.
- Operates subject to the limitation that there is another section following the "References" section.
Sister links (MoveSisterLinks)
edit
- Moves sister links such as {{wiktionary}} and {{Sister project links}} to the "External links" section, if there is such a section per WP:LAYOUT. (en-only)
Bullet external links (BulletExternalLinks)
edit- Add bullet points to external links after "external links" header per Wikipedia:External links#External links section.
Cite Template Dates (CiteTemplateDates)
edit
- Performs a number of fixes to date fields within citation templates. (en-wiki only)
- Converts invalid date formats like DD-MM-YYYY, MM-DD-YYYY, YYYY-D-M, YYYY-DD-MM, YYYY_MM_DD etc. to ISO format of YYYY-MM-DD
- Removes time from citation date fields.
- Note: Not applied to {{cite podcast}} due to its non-standard use of date fields.
Bold titles (BoldTitle)
edit
- Emboldens the first occurrence of the article title, if not already bold per WP:BOLDTITLE.
- Check for any self links and no bold title, if found just convert first link to bold.
- Don't apply if bold in lead section already or some noinclude transclusion.
- Ignore date articles (date in American or international format) and articles containing {{year article header}}
- If title in bold already exists in article, or page starts with something in bold, do not change anything.
- Ignore articles with some bold in first 5% of article.
- Check that the bold added is the first bit in bold in the main body of the article.
FixLinks
editNot applied if page has an imagemap on the page or noinclude transclusion
- Performs fixes to wikilinks:
- Removes piped self-links leaving pipe.
- Delinks simple self-links per WP:OVERLINK.
- Replaces unnecessary pipe template inside wikilinks with pipe.
- Cleans up wikilinks: replace underscores, percentages and URL encoded accents/diacritics etc. (with underscore exceptions for mod_perl and size_t)
- Reformats self interwikis to be standard links. Only applies to self interwikis before other interwikis (i.e. those in body of article).
- Converts [[foo|'''foo''']] to '''[[foo|foo]]''' for bold, italics or bold and italics.
MinorFixes
editInterwiki conversions (InterwikiConversions)
edit
- Performs some interwiki conversions fixing typos: "da" instead of "dk", "no" instead of "nb", "zh" instead of "zh-tw".
English-language fixes
editTemplate conversions (Conversions)
edit
- Replaces templates such as PAGENAME,PAGENAMEE, BASEPAGENAME, BASEPAGENAMEE, etc. with magic word
- Adds dates (in 'Month YYYY' format) to undated tags/templates requiring such dates, such as {{Citation needed}}.
- Changes {{No footnotes}} to {{More footnotes}} if article has at least 1 inline citation.
- Changes {{Unreferenced}} to {{BLP unsourced}} if article has Category:Living people.
- Changes {{Unreferenced section}} to {{BLP unsourced section}} if article has Category:Living people.
- Changes {{Refimprove}} to {{BLP sources}} if article has Category:Living people.
- Changes {{Refimprove section}} to {{BLP sources section}} if article has Category:Living people.
- Changes {{Primary sources}} to {{BLP primary sources}} if article has Category:Living people.
- Changes {{Self-published}} to {{BLP self-published}} if article has Category:Living people.
- Cleans up underscores in infobox template names.
- Changes {{Template|section|...}} to {{Template section|...}} for the templates: "unreferenced", "wikify", "refimprove", "BLP sources", "expand", "BLP unsourced".
- Removes deprecated parameter
|auto=yes
from {{Unreferenced}}.
Fix People life date ranges (FixLivingThingsRelatedDates)
edit
- Replaces "John Doe (b. 1978)" with "John Doe (born 1978)" and "John Doe (d. 1978)" with "John Doe (died 1978)" in the lead section of articles per MOS:DOB.
- Replaces "John Doe (born: 1978)" with "John Doe (born 1978)" in the lead section of articles per MOS:DOB.
- Replaces "John Doe (born on February 3, 1978)" with "John Doe (born February 3, 1978)" in the lead section of articles per MOS:DOB.
- Replaces "John Doe (1978-)" with "John Doe (born 1978)" per MOS:DOB (not applied within infoboxes).
- Sets endash in born/died date range per WP:ENDASH.
Fix headings (FixHeadings)
edit
- Delinks wikilinks in headings per WP:HEAD (where article has < 6 wikilinks in headings)
- Corrects case of "References" section per WP:HEAD.
- Fixes common naming errors of "See also" and "External links" sections. For instance it renames "External link" to "External links" per WP:ELCITE and "Also see" to "See also" per WP:SEEALSO.
- Changes "Reference" to "References" and "Source" to "Sources" per WP:FNNR.
- Removes colon from end of heading names
- Removes <br/> from headings
- If no level 2 heading in article, remove a level from all headings per WP:HEAD.
- Doesn't consider the "References", "See also", or "External links" level 2 headings when counting level two headings.
- Only apply if all level 3 headings and lower are before the first of "References"/"External links"/"See also".
- Removes bold from headers per WP:HEAD as it makes a visible difference only in the article's table of contents.
- Removes bad headings from start of article such as "About", "Description", "Overview", "Definition", "Profile", "Background", "Intro", "Introduction", "Summary" etc.
- Removes heading at start of page if heading matches article title (heading not removed if not first heading)
- Fixes unbalanced levels to "See also", "External links" and "References" sections (e.g.
==External links=
becomes==External links==
) - Note: Does not alter optional spacing at start and end of heading (i.e. no conversion between
== Heading ==
and==Heading==
) - Sets one blank line before each heading per MOS:HEAD, NOT for subheadings immediately after a heading
Merge See also (MergeSeeAlso)
edit
- Merges multiple {{see also}} templates into one.
- Same for {{see also2}}.
- En-wiki only. Called by Conversions.
Merge Portals (MergePortals)
edit
- Merges multiple {{portal}} templates into a single one. En-wiki only. Called by Conversions.
- Does not merge portal templates with additional named arguments (see {{portal}} documentation).
- Does not process any portal templates if portal template within {{stack}} template.
- When merging removes duplicate portals.
- The {{portal}} templates must be in the same section of the article, or the article must not have any headings.
Mainspace tagger
editMainspace tagger skips redirects and soft redirects to wiktionary.
Tagger (Tagger)
edit
- Removes {{stub}} if article has more than 500 words (comments, categories, defaultsort and persondata are excluded from word count).
- Words in bulleted text are divided by 2 to avoid destubbing pages with big lists and little text.
- Appends {{Orphan}} if article (or its redirects) has fewer than 3 incoming links (excluding redirects) and the article is not a disambiguation one or has a set index template. Read WP:ORPHAN for more details about orphan articles.
- Orphan tagging can be limited to articles with 0 incoming links (excluding redirects) from the Options Menu. There is an option called "Restrict orphan tag addition to linkless pages".
- Removes {{Orphan}} if article has more than 2 incoming links.
- Per this request, {{Orphan}} is not removed if
|few=
is set.
- Per this request, {{Orphan}} is not removed if
- Appends {{Underlinked}} if article has 1–3 wikilinks or the number of wikilinks is smaller than 0.25% of article's size. Removes tag otherwise (comments, categories, defaultsort, Persondata, infoboxes, {{Chembox}} and {{Drugbox}} are excluded from wikilink and size count).
- Appends {{stub}} if article has at most 300 characters (comments, categories, persondata, infoboxes and {{Drugbox}} are excluded from character count). Pages that start with "Lists of..." and "List of..." are not tagged as stubs per Wikipedia talk:Stub/Archive 14#Can lists be stubs?
- Appends {{Uncategorized stub}} if article has no categories and is a stub.
- Appends {{Uncategorised}} if article has no categories, has more than 6 words outside of templates/tables/comments, and is not a stub (or renames {{improve categories}}). It removes the tag in case article has at least 1 category.
- Appends {{Dead end}} if article has no wikilinks (API call used to count mainspace links, blue and redlinks, so transcluded links are counted). Removes the tag otherwise.
- Pages with {{Centuryinbox}} are excluded from tagging
- Adds {{Ibid}} if article has references containing constructs such as ibid, op. cit. or loc. cit (per WP:IBID). (en-wiki only)
- Tags empty level-2 sections with {{Empty section}}. (en-wiki only)
- Changes {{Unreferenced}} to {{More citations needed}} if article has existing references.
Dated tags (TagUpdater)
edit
- Adds
|date=Month YYYY
to some of the most common by-date cleanup or maintenance templates (see Category:Wikipedia maintenance categories sorted by month)- Takes list from dated templates.
- Converts first letter of
|date=
to uppercase e.g.|date=may
to|date=May
. - Corrects upper case month name e.g.
|date=MAY
to|date=May
. - Corrects mixed case month name e.g.
|date=MAy
to|date=May
. (e.g. diff) - Corrects
|Date=
,|dates=
parameter typos. - Adds
|date=
when missing for Month YYYY argument. - Removes day in International date in
|date=
. - Removes comma between month and year. (e.g. diff)
Talk page general fixes
edit- Note: When making fixes to talk pages, it is helpful to also use the custom module User:Magioladitis/WikiProjects for template redirects.
General
edit- Moves {{skip to talk}}, {{talk header}} and {{GA nominee}} on the top per WP:TPL.
- Moves warning, guidelines and article history banners, etc. to their place per WP:TPL.
- Moves {{Image requested}} after WikiProjectBannerShell per WP:TPL.
- Remove Template: from template calls (zeroth section only).
WikiProjectBannerShell fixes (WikiProjectBannerShell)
edit
- Adds {{WikiProject banner shell}} if 3 or more WikiProject templates are found
- (Currently works only with WikiProject templates named "WikiProject foo" and not with their redirects, so using User:Magioladitis/WikiProjects as a custom module is helpful)
- Fixes to WikiProjectBannerShell
- If WikiProjectBannerShells or one of its redirects is found, it does the following:
- Removes any duplicated parameters if they have the same value.
- Removes
|blp=no
,|activepol=no
,|collapsed=no
- Bypasses redirects
- Adds explicit call to first unnamed parameter
|1=
if missing. - If WikiProject Biography exists inside the shell:
- with
|living=no
then removes|blp=yes
if exists - with
|living=yes
then adds|blp=yes
- with
|activepol=yes
then adds|activepol=yes
- with
|blpo=yes
then adds|blpo=yes
- with
- If {{blp}} found then removes it and adds
|blp=yes
- Moves any other WikiProjects into WikiProjectBannerShell
- (Currently works only with WikiProject templates named "WikiProject foo" and not with their redirects)
- Note: This function is applied to en.wiki only
Heading fixes
edit- Adds ==Untitled== to the first comment if it has no section header per WP:TPL.
- Fixes first comment's header level to 2 per WP:TPL.
WikiProject Biography fixes (WPBiography)
edit
- Remove diacritics from
|listas=
- Converts {{activepol}} to {{WikiProject Biography|living=yes|activepol=yes|politician-work-group=yes}}
- Removes {{blp}} from talk page if {{WikiProject Biography|living=yes}}
- Moves {{WikiProject Biography}} above any WikiProject templates if it has
|living=yes
per WP:TPL
- (Currently works only with WikiProject templates named "WikiProject foo" and not with their redirects)
- Note: This function is applied to en.wiki only
WikiProject Songs fixes (WPSongs)
edit
- Converts {{sir}} to {{WikiProject Songs|needs-infobox=yes}}
- Removes unsupported
|importance=
from {{WikiProject Songs}} - Removes
|needs-infobox=no
- Note: This function is applied to en.wiki only
WikiProject Jazz fixes (WPJazz)
edit
- If {{WikiProject Songs}} (or any of its redirects) then add
|song=yes
to {{WikiProject Jazz}} - If {{WikiProject Albums}} (or any of its redirects) then add
|album=yes
to {{WikiProject Jazz}} - Removes
|needs-infobox=no
- Note: This function is applied to en.wiki only
DEFAULTSORT fixes
edit- Replaces the {{DEFAULTSORT}} template with the same magic word.
- Moves the {{DEFAULTSORT}} magic word to the top.
Helper functions
editThis section documents some of the AWB functions that are used by the general fixes, but do not form part of the general fixes themselves.
Text hiding
editText hiding is a feature in AWB that allows syntax within articles to be hidden so that other changes are not applied to the text within that area e.g. typo fixing should not apply to image filenames, otherwise links to images could be broken.
AWB has two levels of text hiding: Hide
and HideMore
. These two functions exist in the WikiFunctions.Parse.HideText
class.
Hide
editItems hidden are:
- <source>, <syntaxhighlight>, <nowiki>, <pre>, <math>, <timeline> tags.
- HTML comments.
- (If option set) External links.
- (If option set) Image/File links including those in infobox fields on en-wiki, <imagemap> tags,
|title=
,|trans_title=
within citation templates.
HideMore
editItems hidden are:
- All those in
Hide
. - Templates, including nested templates.
- <blockquote>, <code>, <noinclude>, <includeonly> tags.
- Headings.
- (If option set) wikilinks.
- Text indented with a colon.
- <cite> and <ref> tags.
- Untemplated quotes: text in straight quotes (and equivalent smart/curly quotes)
- (If option set) text in italics.
- <p style...> tags.
IsArticleAboutAPerson
edit- Determines whether the article is a biography page (and for people with multiple pages on their career/history/publications etc., that the page is their main page)
- Criteria that return false:
- Page has category of Multiple people/Married couples/Fictional.../YYYY animal.../Fictional character/Military careers/Presidencies/...characters/... noble families
- Page is a disambiguation page
- Page contains "List of…", "Murder of…", "Deaths…", "discography", "murders", "…musical groups", "People from…", etc.
- Page begins with a two or more digit number
- Page is tagged {{in universe}}
- Page has {{Infobox musical artist}} where
|background=
is group_or_band/classical_ensemble/temporary/cover_band - Page has {{Infobox Chinese-language singer and actor}} with
|currentmembers=
or|pastmembers=
set - ...and more
- Zeroth section has a {{Main}} or {{See also}} link
- Zeroth section infobox is not a person infobox
- Multiple {{Birth date}} templates (or similar) with different dates
- Page has more than one of the common person infoboxes
- Wikilink within bold text in zeroth section and not within a template
- Page is in Category:Internet memes
- Page is in Category:Military animals
- If no criteria to return false, criteria that return true:
- Page contains {{Persondata}}
- Page has birth/death year or living people category
- Page has one of the common person infoboxes
- Page is a {{…-bio-stub}}
- Page is a {{…-politician-stub}}
- Page is a {{…-writer-stub}}
- One {{Birth date}} or {{Death date}} template in zeroth section
- Page has {{BLP sources}} or {{Refimprove BLP}}
- Note: This function is applied to en.wiki only
DeterminePredominantDateLocale
edit- Determines the predominant date format in the article text as either: American, International, YMD (YYYY-MM-DD) or undetermined.
- Follows any {{use dmy dates}}/{{use mdy dates}} template.
- If no such template, counts the number of American, International, YMD dates in article.
- If input arguments allow YMD to be considered, returns YMD if there are more YMD dates than any other.
- Otherwise, returns American or International if at least 4 of those dates and that format used at least 2:1 over the other.
- Otherwise, follows any use of
|df=y
or|mf=y
(oryes
) in the {{birth date}} family of templates. - If none of the above criteria allow a derivation, the date format is undetermined.
Persondata completion (PersonData)
edit
- Note
- Persondata is now removed.
This is not called by general fixes
- Inserts or updates Persondata only based on existing data in the article (e.g. diff)
- The Persondata template is inserted for all mainspace people biography articles without existing persondata.
- Existing persondata can be updated, but any existing field values are not overwritten.
- DATE OF BIRTH and DATE OF DEATH
- Uses birth/death fields (and aliases) from people infoboxes and/or birth/death date templates such as {{death date and age}} to derive birth & death dates.
- Sets persondata dates using the predominant date locale used in the article.
- NAME
- Sets persondata name using the article's existing {{DEFAULTSORT}}.
- PLACE OF BIRTH and PLACE OF DEATH
- Sets persondata locations based on
|placeofbirth=
and|placeofdeath=
fields (and aliases) from people infoboxes.
- Sets persondata locations based on
- ALTERNATIVE NAMES and SHORT DESCRIPTION fields are not automatically populated.