// CITATION CONTENT
π Language
The language parameter only accepts standard ISO codes or names recognized by MediaWiki. Values like |language=Inglese or |language=al (incorrect code for Albanian) cause articles to be categorized under CS1 maint: unrecognized language. I convert language values to their proper ISO codes β values recognized by every Wiki project in any language.
Some editors try to add language names directly in Albanian (|gjuha=, |gjuhe=, |gjuhΓ«=), but the citation module does not accept parameters in the local language. This causes categorization under CS1 errors: unsupported parameter. I convert them to the correct form.
I also normalize the variant |lang= β a synonym of |language= accepted by the module β treating it identically to |language=.
π Date
The citation module performs a basic translation of month names to the local language. In many cases this suffices, but in certain cases it deviates from Albanian orthography β which is why articles with auto-translated dates are categorized under CS1 maint: date auto-translated. I perform the full adaptation of all date types from English to Albanian, including abbreviated months (Jan β janar, Mar β mars). Besides |date=, I also normalize |orig-date= β the original publication date for republished works.
Dates written in MDY order (janar 15, 2020) are reformatted to DMY (15 janar 2020), the standard Albanian format.
Date ranges require the en dash β not the hyphen -. Incorrect usage triggers categorization under CS1 maint: date format; I make the necessary replacement. Abbreviated ranges (1990β98) are expanded to full form (1990β1998), but only when the ending is unambiguous and within the same century.
Leading zeros on day numbers (01 janar 2020 instead of 1 janar 2020) trigger a CS1 error; I remove them.
When a full date (day, month, year) is present but |year= is used instead of |date=, I make the necessary change.
When both |date= and |year= are present simultaneously and the year in |year= repeats the one in |date=, the |year= parameter is redundant β I remove it, preventing categorization under CS1 errors: redundant parameter. When the values differ, the situation requires human judgment β I leave both parameters as they are.
βοΈ Extra text
Identifier parameters have strict canonical formats. Adding extra prefixes to their values triggers CS1 errors (or maintenance categorization in some cases).
Identifier prefixes: Parameters |pmc=, |jfm= and |mr= don't need the prefixes PMC, JFM or MR β they should begin directly with digits. Parameters |isbn=, |issn= and |eissn= should not have their name as a prefix (ISBN 978-...). The |doi= parameter should contain only the DOI code (10.1000/xyz123), not URLs like |doi=https://doi.org/... or the prefix doi:. The |arxiv= parameter should not have arXiv: or the arxiv.org URL. Parameters |jstor=, |pmid=, |oclc= and |s2cid= are often set with full URLs or text prefixes β I clean them up.
Explanatory text in volume, issue, edition, pages: Setting Vol. 3 instead of just 3, No. 5 instead of 5, 3rd ed. instead of 3rd, pp. 10β15 instead of 10β15 triggers categorization under the respective CS1 error categories. I remove these extras, leaving only the core value.
The Albanian abbreviation fq. in |pages= and the suffix (ed.) / (eds.) after editor names are treated the same way.
π£ Special characters
Templates {{ndash}}, {{endash}}, {{en dash}} and {{en-dash}} produce the en dash β; templates {{mdash}}, {{emdash}}, {{em dash}} and {{em-dash}} produce the em dash β. Inside citations there's no need for these templates β I replace them directly with the actual characters.
HTML entities such as ", ', –, —, , …, «, », typographic quotes, etc. are replaced with their real characters. ASCII entities (", ') are safe everywhere within a citation; typographic entities are replaced only in parameters that don't hold URLs β this care prevents breakage in URL parameter values.
The {{URL}} template is intended for use in infoboxes, not inside citations. When I find |url={{URL|http://...}} or similar variants, I unwrap the template and leave only the bare address that CS1 expects.
π» Invisible characters
Certain Unicode control characters β invisible to the naked eye but harmful to rendering β I remove: C0 characters (U+0001 through U+001F with some exceptions), DEL (U+007F), C1 characters (U+0080 through U+009F), zero-width space (U+200B) and the replacement character (U+FFFD). Their presence in citations triggers categorization under CS1 errors: invisible character.
Special whitespace β TAB (U+0009), LF (U+000A), CR (U+000D), non-breaking space (U+00A0), hair space (U+200A) β I replace with plain spaces. These cases often involve vertically formatted citations where each parameter sits on its own line; after replacement, the formatting returns to the standard horizontal layout.
The soft hyphen (U+00AD) is replaced with a regular hyphen -.
// PARAMETER STRUCTURE
β»οΈ Deprecated parameters
The citation module is always evolving and over time some parameters begin to be considered deprecated. Using them triggers categorization under CS1 errors: deprecated parameters. The full list can be found at Module:Citation/CS1/Suggestions, under the comments old parameter name. I update them with their current replacements.
Beyond simple renames, I also handle specific deprecated values. |dead-url=yes is removed since dead is the default for |url-status=; |dead-url=no becomes |url-status=live; |dead-url=unfit and |dead-url=usurped become their |url-status= equivalents.
The value |ref=harv is no longer supported; the parameter is removed entirely when found with this value.
β¬ Empty parameters
Parameters with empty values (|param1=|param2=|) serve no function β I remove them.
Pipe characters serve to start a parameter; placing two consecutive pipes || or leaving a pipe at the end of a citation |}} constitutes an empty parameter and triggers categorization under CS1 errors: empty citation. I remove the extra pipe to fix the error.
π Wikilinks in parameters
Parameters such as |author-link=, |editor-link=, |title-link=, |series-link=, |episode-link= and similar should contain only the plain article title on Wikipedia β never wikitext links in the form [[...]]. When an editor writes |author-link=[[John Smith]] instead of |author-link=John Smith, the module flags it as an error. I fix it by removing the brackets and keeping only the intended link target; in the case of piped links [[Target|Label]], I keep only the part before the pipe, i.e. the actual article title.
π Website address
The |website= parameter is a synonym of |work= and expects the site name as a source (e.g. |website=Reuters), not its address. When editors put a URL as the value (e.g. |website=https://www.bbc.com), they're clearly confusing it with |url=. I fix it by renaming: when the value starts with http:// or https://, the parameter becomes |url= with the same value. Simple values like |website=BBC News are not touched. When |url= already exists in the citation, I leave everything untouched β the situation requires human judgment.
π¦ URL status
When the IABot archives sources, it sometimes cannot determine the status of the original address and leaves the parameter with the value |url-status=bot: unknown. I resolve it: when |archive-url= is present and not empty, I change the value to dead β assuming that the archive exists precisely because the original address has gone down; when there is no archive URL, I delete the parameter entirely.
Invalid values |url-status=yes and |url-status=true are changed to dead; |url-status=no and |url-status=false are changed to live. Values written with capital letters (Dead, Live, Unfit etc.) are normalized to lowercase β the module accepts them, but uniformity keeps the source code clean.
π¦ Archive without URL
The parameters |archive-date= and |archive-format= have no meaning without the presence of |archive-url= β setting them triggers categorization under the CS1 archive URL error category. Since there is no valid case where these parameters can exist without the archive URL, I remove them when it is missing or empty.
β Dependent parameters
Some CS1 parameters only have meaning when another specific parameter is present and not empty. When that required partner is missing, the dependent parameter serves no purpose and triggers CS1 errors.
Specifically: |format= and |url-access= require |url=; |chapter-format=, |contribution-format=, |article-format=, |entry-format=, |section-format= (and their access variants) require the corresponding chapter URL; |conference-format= requires |conference-url=; |map-format= and |map-url-access= require |map-url=; |transcript-format= requires |transcript-url=; |doi-broken-date= requires |doi=; |pmc-embargo-date= requires |pmc=; |asin-tld= requires |asin=. All these parameters are removed when their partner is missing or empty.
π©Ή Dead links
The {{dead link}} template (or variants {{dead-link}}, {{dead url}}) is a marker that editors place after a citation to indicate the address is no longer reachable. The canonical form is |url-status=dead inside the citation itself. When I find a {{dead link}} template immediately after a citation that has |url= but no |url-status=, I add |url-status=dead inside the citation and remove the external template β same meaning, less duplication.
π Formatting
I standardize citation template formatting to the compact form: no extra spaces around pipe characters |, around equals signs = or before the closing }}; multiple spaces within values are consolidated into a single one. Letter casing in the template name is preserved as-is.
Per MOS:REFPUNCT, <ref> tags should be attached directly to the preceding word without a space; also there should be no spaces between consecutive <ref> tags or within the reference content. I clean them up accordingly.
The same formatting treatment is applied to the short-form templates {{sfn}} and {{harv}} (including variants {{sfnp}}, {{sfnm}}, {{harvnb}}, {{harvtxt}}, {{harvp}}).
// SOURCE ENRICHMENT
β¨ Enrichment
Beyond fixes, I also perform citation enrichment: when a citation contains a certain identifier, I query the relevant public services for other related identifiers and add them to the citation. Each enrichment fill is logged with a distinct label in the edit summary, by type of identifier added.
PMID β DOI, PMC (via PubMed): when the citation has |pmid=, I look up the corresponding DOI and PMC from PubMed's identifier cross-reference list and add them.
OCLC β ISBN (via Open Library): when the citation has |oclc=, I retrieve the ISBN from the corresponding Open Library record and add it.
DOI β open-access URL (via Fatcat): when the citation has |doi=, I search for a free copy in Fatcat (Internet Archive Scholar) and add it as |url= β giving the reader a toll-free path to the paper.
// PAGE CONTEXT
ποΈ Empty references
Using reference tags with no content inside β forms like <ref></ref>, <ref>{{cite web}}</ref> or <ref>{{Cite web|}}</ref> β creates references that artificially inflate the source count without actually containing any content. I remove them. Named references (<ref name="x">...</ref>) are never touched, even when empty β because they may be called from elsewhere in the article as <ref name="x" /> and removing them would break those calls.
βοΈ Duplicate references
Consecutive repeated references just add duplicate numbering in the text with no added value β I remove the repetitions. If references are only partially identical (they cite the same source but with different wording or whitespace), they are not touched β that assessment requires human judgment.
βοΈ Reference quotes
<ref> tags accept unquoted attribute values (<ref name=foo>) for simple alphanumeric values. However, missing quotes cause silent breakage when the value contains spaces or special characters. I add the quotes: <ref name=foo> β <ref name="foo">. Covers all reference attributes that MediaWiki recognizes: name, group, follow, extends and dir.
π Reference headings
Different editors use different section headings for the references section. Some title it "Referenca", "ReferencΓ«", "Citime", others "Burime". The term "Referenca" is a calque from the English "References" and does not exist in Albanian dictionaries. The other two terms exist but to maintain a single standard, I convert all heading variants to "Referime". The heading level (== or ===) is preserved unchanged.
π Manual categories
CS1 categories serve to fix citation problems, to track certain features, or for statistical purposes. For these goals to work, categories should only be added automatically by the citation templates β not by hand. When an editor adds them manually ([[Category:CS1 errors: ...]]), it skews statistical accuracy and leaves the article in the category even after the error has been fixed. I remove manually added categories.
// MICROSERVICES
π Article Wizard
Articles created with the Article Wizard come with a set of instructional comments placed in HTML (<!-- Delete this comment before publishing your changes --> or the formal variant <!-- Delete this comment before you publish your changes -->) and the {{NIA}} template at the end. These are meant to be removed by the editor before publishing, but are often forgotten.
I remove both variants of the instructional comment (singular and plural), the {{NIA}} template, the intro instruction {{NIA|hyrja|β¦}} and the __NOINDEX__ that the old skeletons added (it has no effect in articles). When someone has written text inside the template, I keep the text and remove only the template. Other HTML comments in the article (that don't contain the specific Article Wizard phrase) are never touched β only those I recognize as forgotten instructions.
I visit these articles first in every cycle, even when they have no citations: I find them through the transclusions of {{NIA}} and by searching for the Article Wizard's comments and __NOINDEX__.
ποΈ Community requests
In the votes of the Administration, at the Deletion Forum, in the candidacies and re-evaluations of good and featured articles and at the Workshop, every request has its own page. Editors do one thing: they open a request, or they close it. I do the rest, from that moment until the request is over: I put it on the list of open requests, put the template of the request on its article, archive it and carry out on the article what the closing decided. Whatever is changed by hand along the way, I restore what the request still needs, as many times as it takes, for as long as the request lasts; and what is done by hand as a step of the request (a move, a deletion, a closing, an archiving) I read as such and carry on from there.
Listing (every 10 minutes): I add the pages of new requests at the top of their list, even when they were closed before I got to them; at the Administration, the candidacies that the candidates create themselves go to the list of self-nominations. From then on I follow the request: if someone takes it off the list before it is archived, I put it back in its place. I list moved requests under their new title, remove deleted ones and keep requests listed twice only once. At the Workshop, which has no archive, a closed request taken off the list is over (an approved bot first goes on the list of bots).
Templates on the articles (every 10 minutes): For as long as a request is open, its article carries the matching template ({{Faqe pΓ«r grisje}}, {{AMK}}, {{AMR}}, {{APK}} or {{APR}}). When it is missing, I add it; when someone removes it, I put it back as it was (with its reasons), every time. A page that is to be deleted keeps its template after the closing too, until it is deleted.
Closing (once a day): When a request closes, I remove its template from the article and carry out the decision: articles that pass their candidacy get {{Artikull i mirΓ«}} or {{Artikull i pΓ«rkryer}} with the date of the closing (the featured article template takes the place of the good article one), while articles that lose their status in a re-evaluation lose its template. I change the status even when someone removed the template of the request by hand, but only once per request: after that the article belongs to its editors again. If the request is reopened, I put its template back and undo what I did to the status. Once a day I also look at every article that carries the template of a closed request, even when the request is on no list; templates whose request I cannot find are only noted in my log.
Archiving (once a day): I move closed requests to their archives a week after the last edits of their pages, once they have been on their list for at least a week, and then take them off the list. An archive is a table row (good and featured articles, Administration), a page of requests (Deletion Forum, 50 per page) or, for approved bots, the list of bots. A request that decided to delete a page waits on its list until the page is deleted. Requests closed before the conditions of their vote were met are not archived: they stay on the list until someone reopens or archives them. A request that someone archived by hand but left on its list, I take off the list.
Changes by hand: To take a request off its list for good, archive it, delete its page or move it out of the request pages; a request that is only taken off the list comes back. An article that was moved is followed to its new title; one that was turned into a redirect by an edit (merged into another) is not.
I never edit the page of a request: I neither close it nor decide on it. Whether a request has been closed, and how, I learn from Module:Votes: the rules of the votes are written there and only there. On articles I touch only the template of the request and the template of the status.
π§Ή Upkeep of the hub pages
The hub pages show not only the requests but also how things stand today: which articles are still good or featured, which users still hold their rights, which bots are at work, which ambassadors are active. Once a day, after the archiving, I compare what they show with how things are today and change only what does not match.
Archives: In the archives of the candidacies and re-evaluations of good and featured articles, the "Statusi" column says whether the article has the status today; a moved article is followed to its new title, and a good article that has since become featured shows as "I pΓ«rkryer". In the archives of the Administration, the "NΓ« detyrΓ«" column says whether the user holds the rights today (after a rename too, and once rights with an end date have expired). Nothing else in the archives is touched: not the votes, the dates or the outcomes.
Status of the articles: The status of a good or featured article is a decision of the community, and it goes only through a re-evaluation. When an edit (a full rewrite, for instance) takes the status template off an article without such a decision, I put it back as it was, if that edit is at most 30 days old; older losses are only noted in my log.
Tiles: On the pages of the good and featured articles, every article with the status has its tile. An article that gains the status gets a tile under the topic that suits it according to Wikidata (you are free to change it); the tile of an article that loses the status goes; the tile of a moved article follows its new title. If many tiles would go on the same day, I remove none and log an error: that usually means a problem with the category, not with the articles.
Bots: In the list of approved bots, a bot is active for as long as it has the bot flag and has made at least one edit or logged action in the last year; otherwise I move it to the inactive ones. A bot with the flag that is on neither list I add to the list it belongs on.
Embassies: As the rules of the Embassies say, an ambassador who has made no edit for a year comes off the lists of their embassies.
Unsigned threads: On Kuvendi, Questions and Answers and the Complaints Office, threads are archived by MajavahBot by the dates of their signatures, so a thread without a single signature is never archived. A day after such a thread is opened, I add {{Unsigned}} to it, with the name of whoever opened it and the date. Nothing else on those pages is touched.
π’ Transclusion count
Module:Transclusion count shows how many times each template or module is used on the platform. To function, this module needs a bot that reads the database and writes the numbers to the /data/X subpages. I take this on.
I query the Wikimedia analytics database for templates (namespace 10) and modules (namespace 828) used more than 2,000 times. Numbers are rounded to two significant figures (or three for counts over 100,000). Each title is classified by its first letter into the corresponding alphabetical category β for Albanian this includes digraphs (Dh, Gj, Ll, Nj, Rr, Sh, Th, Xh, Zh); titles that don't start with any index letter go to the "Other" category.
// VERSION HISTORY
user-fixes.py for textual replacements.