Wikipedia:Bot policy

Robots or bots are processes that interact with Wikipedia using the editing interface(s). Bots may be completely automated processes, or human assisted processes. All actions performed by a bot are the responsibility of its operator. Some low-speed user assistance programs (e.g. Auto Wiki Browser in normal operation mode) are not considered "bots". This policy does not cover server-side scripts run by developers.

Please read the guidelines below before designing and implementing any bot on Wikipedia.

Policy
Prior to use, bots must be approved at Bots/Requests for approval. State there precisely what the bot will do, observe and participate in the discussion, and await authorization from someone in the approvals group. Approval may take up to one week. After approval you may run the bot for a short period so it can be monitored. After the trial the bot will be evaluated by someone in the approvals group and, if the approvals group determines that a "bot flag" is required, the user will be marked as a bot by a bureaucrat.

Please do not start running your bot without:


 * 1) Creating a talk page for the bot, describing its functions
 * 2) Listing it on Requests for approvals
 * 3) Getting the go-ahead from someone in the approvals group

When seeking approval on Requests for approvals, please state the following:
 * 1) Whether the bot is manually assisted (run by a human) or automatically scheduled to run
 * 2) The period, if any, we should expect it to run
 * 3) What language or program it is running
 * 4) Its purpose

Create a user page for your bot before seeking approval on BRFA:
 * 1) Describe the bot's purpose, language it uses, what program(s) it uses (pywikipedia framework, etc)
 * 2) Describe whether it is manually assisted or automatically scheduled to run
 * 3) The period, if any, we should expect it to run
 * 4) Describe who the maintainer is
 * 5) Add its user page to Category:Wikipedia bots by adding  to the top of the bot's user page

Usernames for new bots should incorporate the word "bot" so that editors realize they are dealing with an automaton, despite historical counterexamples such as Pearle. The username for the bot should also incorporate the username of the bot operator or a recognizable fragment of it.
 * 1) Administrators should block bots if they are unapproved, doing something the operator did not say they would do, messing up articles, editing too rapidly, or running anonymously. If they have a fixed IP address, bot operators may wish to post their IP address on their bot's user page so that the owner of an anonymously running bot can be found.
 * 2) While performance is generally not an issue, bots should avoid making an excessive number of requests, and be conservative in their editing speed, to minimize any effects they may have on performance.
 * 3) * Bots in trial periods should be especially careful to limit their edit rate to no more than two to three per minute so that their edits may be reviewed.
 * 4) * Unflagged bots should edit more slowly than flagged bots, as their edits are visible in users' watchlists.
 * 5) * The urgency of a task should always be considered; tasks that do not need to be completed quickly (for example, renaming categories) can and should be accomplished at a slower rate than those that do (for example, reverting vandalism). Bots doing non-urgent tasks should edit approximately once every ten seconds, while bots doing more urgent tasks may, if approved to do so, edit approximately once every four seconds. It is recommended that bots run with larger delays during peak hours (0800 – 2000 UTC), and days (middle of the week, especially Wednesdays and Thursdays) or operate during the quietest times (weekends). Ideally, bots should be run at a rate that permits human editors to review the bot's edits if the need arises.
 * 6) * Bots' editing speed can be regulated by forcing them to wait for a fixed time interval before making an edit. However, it is better to vary the editing speed based on slave database server lag, where possible, as this allows bots to edit more quickly during quiet periods while slowing them down considerably when server load is high, thereby creating a sort of self-correcting mechanism. This can be achieved quite easily by appending the "maxlag" parameter to the query string of each URL the bot requests. This accepts an integer value; if the database lag, in seconds, is higher than the specified value, an HTTP 503 status code is returned with a "Retry-After" header set; on receiving this, bots should wait for 5 seconds before retrying. If it is not, the request is served as usual. MediaWiki developers recommend a "maxlag" parameter value of 5 (seconds). Higher values mean more aggressive behaviour, lower values are nicer. An example query string would be http://en.wikipedia.org/w/index.php?title=Main_Page&maxlag=5 – try this a few times and note that when the database is experiencing lag issues, a machine-readable status page is returned instead of the request. This feature was implemented specifically for use by client–side bots and maintenance scripts.
 * 7) The operator should be at, or logged into, the machine the bot is running on to terminate it if necessary during the debugging phase, otherwise the bot is liable to be blocked without notice.
 * 8) Bots that download substantial portions of the page database are prohibited. Instead, download the database dumps. See also Mirrors and forks.
 * 9) Do not log in as your bot when replying to enquiries. Questions or concerns can be addressed at bot's talk page or the operator's talk page, but since bots can't reply, the one responsible for replying is its operator.

The burden of proof is on the bot-maker to demonstrate that the bot:
 * 1) is harmless
 * 2) is useful
 * 3) is not a server hog
 * 4) has been approved
 * 5) has appropriate community consensus for each task
 * 6) abides by all guidelines, policies and common practices

Note that according to Wikipedia:Categorization of people, certain types of person categories should not be filled/emptied using a bot. Before adding sensitive categories to articles by bot, the input should be manually checked article by article, rather than uploaded from an existing list in Wikipedia.

To help prove that a bot is harmless and useful, a trial period may be asked to demonstrate the bot. Any complaints made about the bot during the trial period require that the bot be stopped immediately, and the issue should be resolved at Wikipedia talk:Bots.

If you plan to make any modifications to your bot that expand the scope of its original purpose, please leave a note on the talk page regarding the nature of the change to assert that no one has any problems with your bot, and with such additions the bot will still be harmless and useful, and not a server hog.

Under exceptional circumstances, one or more aspects of this policy may be set aside by a consensus of administrators.

Spell-checking bots
There should be no bots that attempt to fix spelling mistakes in an unattended fashion. It is not technically possible to create such a bot that would not make mistakes, as there will always be places where non-standard spellings are in fact intended. Manually-assisted spell-checking bots are acceptable, so long as they include international spell checking and not only country-specific spell checking. Statistic-generating spell-checking bots, which generate statistics on common misspellings, are also acceptable.

Maintenance reports that list possible misspellings are welcome. See Typo for existing efforts and a list of existing interactive spell-checking tools.

Interwiki bots
If using the pywikipedia framework:
 * Please run the latest version
 * Update on a daily basis

Bot operators must be reasonably familiar with the languages that they are linking from and to, in order to confirm that interwiki linkings between the two encyclopedias are done correctly.

Exceptions to this are bot developers, those working very closely with bot developers, or users that have proven themselves as harmless and useful to the community.
 * Interlanguage links
 * Interwiki bot FAQ
 * Interwiki bot
 * Interwiki sorting order (See & vote: 2867)

Problems with a specific bot
If you spot a problem or have a complaint about a specific bot, take your query to the bot operator's talk page. If you think the problem is serious and would like greater input, leave a short note at Administrators' noticeboard pointing to the discussion at the operator's talk page. An administrator can block on sight any bot that appears to be out of control.

Good form
Bot operators are encouraged (but not required) to:
 * Publish the source code of their bot (unless it's a clone)
 * Program his or her bot to stop editing if someone leaves a message on its talk page. This can be checked by looking for the "You have new messages..." banner in the HTML for the edit form.
 * Program his or her bot to stop editing if they detect that they have logged out. This can be acomplished by checking the value of wgUserName in any retrieved wiki pages. Bots running anonymously may be blocked.
 * Be compliant with the bots opt-in/opt-out facility.

Repairing damage
If, despite all efforts and review, a bot is found to have caused unintentional damage, it is the responsibility of the bot operator to repair it. Note that this could require either lots of manual work, or the creation (and perhaps approval) of a new bot. If you are not prepared to clean up after your bot if it misbehaves, you should not run it. There is, of course, no reason that help cannot be asked for or offered.

Assisted bots
Assisted bots are defined as any software that allows rapid editing of articles, while not saving any changes without some human interaction. Typical assisted jobs include those which are repetitive, but cannot be done fully automatically e.g. disambig repair, stub sorting and typo fixing.
 * Assisted bots don't necessarily need bot approval, though some software has built in approval detection, whereby approval from some subset of "trusted" users is required (developers are permitted to build in approval mechanisms). If you have any doubts, it is safer to go through the approval process.
 * A separate account is advised if many edits are going to be made.
 * Always make extra sure there is consensus before making a large series of edits.
 * Assert that software is being used to perform the edit, if this is not already clear. This can be accomplished by a message on the account's userpage, if a separate account is being used, or in the edit summary. It may also be desirable to identify the specific software being used.

Wiki integration bots
Below is a list of bots on other systems or solutions that extend system-specific functionality with Wiki integrations.
 * Wikibot auto links 'wikitagged' words in Joomla contents with Wikipedia.

af:Wikipedia:Robot als:Wikipedia:Bötli ar:ويكيبيديا:بوت an:Wikipedia:Bots az:Vikipediya:Botlar be:Вікіпэдыя:Робаты bs:Wikipedia:Bot br:Wikipedia:Bot bg:Уикипедия:Бот ca:Viquipèdia:Bots cs:Wikipedie:Bot da:Wikipedia:Bots de:Wikipedia:Bots el:Βικιπαίδεια:Bots es:Wikipedia:Bot eo:Vikipedio:Roboto eu:Wikipedia:Bot-ak fa:ویکی‌پدیا:اتحادیهٔ کارگری ربات‌ها fr:Wikipédia:Bot gl:Wikipedia:Bots ko:위키백과:봇 hak:Wikipedia:Kî-hi-ngìn hy:Wikipedia:Բոտ hr:Wikipedija:Botovi id:Wikipedia:Bot is:Wikipedia:Vélmenni it:Wikipedia:Bot he:ויקיפדיה:בוט jv:Wikipedia:Bot ka:ვიკიპედია:ბოტები ht:Wikipedia:Bòt lad:Wikipedia:Bot/Permesos la:Vicipaedia:Bot lb:Wikipedia:Bot ln:Wikipedia:Bot hu:Wikipédia:Botok mi:Wikipedia:Karetao ms:Wikipedia:Bot mo:Wikipedia:Бот nl:Wikipedia:Bots ja:Wikipedia:Bot mi:Wikipedia:Karetao no:Wikipedia:Roboter nn:Wikipedia:Robotar oc:Wikipèdia:Bòt nds:Wikipedia:Bots pl:Wikipedia:Boty pt:Wikipedia:Coordenação robótica ksh:Wikipedia:Bots ro:Wikipedia:Bot rmy:Vikipidiya:Bot ru:Википедия:Бот si:Wikipedia:Bots simple:Wikipedia:Bots sk:Wikipédia:Bot sl:Wikipedija:Boti sq:Wikipedia:Botët sr:Википедија:Ботови su:Wikipedia:Bot fi:Wikipedia:Botit sv:Wikipedia:Robotar te:వికీపీడియా:Bot th:วิกิพีเดีย:บอต vi:Wikipedia:Robot tg:Википедиа:Ботҳо tr:Vikipedi:Botlar uk:Довідка:Роботи vec:Wikipedia:Bot vls:Wikipedia:Robot yi:װיקיפּעדיע:באט zh-yue:Wikipedia:機械人政策 zh:Wikipedia:机器人