Wiktionary:Normalization of entries

From Wiktionary, the free dictionary
Jump to navigation Jump to search

This is a list of aspects that govern how the wikitext behind an entry should be formatted. They are invisible to the readers, e.g., following these rules makes no difference to how a user sees the page, but they do make the pages conform more to a standard format reflecting what we think of as best for the wikitext. Issues such as where to put blank lines and how many, whether to put spaces inside the == ==, or after asterisks in lists.

These norms are mandatory for bots only, so that any changes made by bots must conform to this policy. This applies to the part of a page that the bots edit, not to the entire page.[2] Editors other than bots can treat these norms as guidelines, while they are encouraged to use this format and correct pages which deviate from it.

Some edits are tagged with “WT:NORM” by an experimental filter. This means that the wikitext of the page violates one of these rules. It does not mean that the edit is bad, though bad edits will sometimes trigger the filter.

Example entry

==English==

===Noun===
{{en-noun}}

# Noun sense.

====Synonyms====
* synonym

==Portuguese==

(...)

List of norms

General

  1. No non-newline whitespace at the start or end of a line. Consequently, no lines consisting only of non-newline whitespace.
  2. Not more than 1 blank line in a row.
  3. No tab characters.
  4. The template {{also}} on its own line.[3]

Templates

  1. No leading or trailing whitespace or underscores in template names.
  2. No leading or trailing whitespace in parameter names and values.
  3. Line breaks are not allowed in parameter names.[4]
  4. For templates with many or long parameter values, line breaks are allowed at the end of a template’s name or a parameter’s value, for the purpose of making the wikitext easier to read. Example about {{ru-decl-noun-irreg}}:[4]
{{ru-decl-noun-irreg
|пау́к-во́лк|пауки́-во́лки
|паука́-во́лка|пауко́в-волко́в
|пауку́-во́лку|паука́м-волка́м
|паука́-во́лка|пауко́в-волко́в
|пауко́м-во́лком|паука́ми-волка́ми
|о пауке́-во́лке|о паука́х-волка́х
}}

Headings

  1. One blank line before all headings, including between two headings, except for before the first language heading.
  2. No blank line after any heading except when another heading immediately follows.
  3. No whitespace between = and heading title, i.e. ==English== and ===Noun===, not == English == or === Noun ===.
  4. The final = of a heading must be immediately followed by a newline: no content after a heading on the same line, including spaces, tabs and comments (such as ==Old English== <!-- also known as Anglo-Saxon -->).
  5. No blank lines between the first language heading and any preceding content.[5]
  6. One blank line between language sections.

Lists

  1. One space after a sequence of #, *, :, or ; at the start of a line.

Headword lines

  1. Headword lines should always use templates, such as {{en-noun}} or {{head}}, not just wikitext, as in '''example'''.[6]
  2. One blank line after the headword line.
  1. No spaces between a linked term and the opening or closing brackets, or between a linked term and the pipe. ([[example|examples]], not [[ example | examples ]])[7]

Inflection tables

  1. Each inflection table on its own line.[3]

Translation sections

  1. One blank line between each translation block (i.e. between {{trans-bottom}} and {{trans-top}}).
  2. Language names should be spelled out, not generated by templates. For example, don’t use a template that converts “en” into “English” and “fr” into “French”.
  3. Each of the following templates on its own line:
    {{trans-top}}, {{trans-bottom}}, {{trans-see}}, {{checktrans-top}}[3]

See example:

====Translations====
{{trans-top|gloss}}
* Japanese: {{t|ja|...}}
* Portuguese: {{t|pt|...}}
{{trans-bottom}}

{{trans-top|gloss}}
{{trans-bottom}}

Categories

  1. Entries should be categorized into part-of-speech categories (like Category:English nouns) using the headword-line templates, not using manual category links.[6]
  2. These rules do not affect templates, even if the sole purpose of a template is categorizing the entry.
  3. Each category on its own line.[8]
  4. Categories are placed at the end of each language section.[8]
  5. Each template whose only purpose is categorization on its own line.[3]
  6. No blank lines between two categories.
  7. No spaces:
    1. Between “[[” and “Category”.
    2. Between “Category” and “:”.
    3. Between “:” and the category name.
    4. Between the category name and “]]”.

Incorrect spacing:

[[ Category : English nouns ]]

Correct spacing:

[[Category:English nouns]]

Modules

  1. No module invocations ({{#invoke:}}). Modules should be wrapped up in templates.

References