Property talk:P424

Latest comment: 2 years ago by Liuxinyu970226 in topic target link

Documentation

Wikimedia language code
identifier for a language or variant as used by Wikimedia projects
RepresentsWikimedia language code (Q21468732)
Data typeString
Domain
According to statements in the property:
languoid (Q17376908), Wikimedia Foundation project (Q14827288), Wikimedia multilingual project main page (Q21450877), Wikimedia project chat in specific languages (Q21469493), orthography (Q43091), language identifier (Q2092812) or writing system (Q8192)
When possible, data should only be stored as statements
Allowed values
According to this template: typically a 2 or 3-lowercase letter group
According to statements in the property:
([a-z]{2,3}(-[a-z]+){0,2}|simple)
When possible, data should only be stored as statements
ExampleDutch (Q7411)nl
no linguistic content (Q22282939)zxx
multiple languages (Q20923490)mul
undetermined language (Q22282914)und
language without a specific language code (Q22283016)mis
Japanese (Q5287)ja
Alsatian (Q8786)gsw-fr
Punjabi (Q58635)pa
pnb
Traditional Chinese (Q18130932)zh-hant
Turkish (Q256)tr
Simplified Chinese (Q13414913)zh-hans
Source When possible, data should only be stored as statements
Formatter URLhttps://codelookup.toolforge.org/$1
Robot and gadget jobsFormat validation should allow:
Tracking: usageCategory:Pages using Wikidata property P424 (Q106828821)
See alsoWikidata language code (P9753)
ListsHelp:Wikimedia language codes/lists/all
  • Items with the most statements of this property
  • Count of items by number of statements (chart)
  • Count of items by number of sitelinks (chart)
  • Items with the most identifier properties
  • Items with no other statements
  • Most recently created items
  • Items with novalue claims
  • Items with unknown value claims
  • Usage history (total)
  • Chart by item creation date
  • Database reports/Constraint violations/P424
  • Map
  • Random list
  • Proposal discussionProposal discussion
    Current uses
    Total6,732
    Main statement2,04530.4% of uses
    Qualifier4,63068.8% of uses
    Reference570.8% of uses
    Search for values
    [create Create a translatable help page (preferably in English) for this property to be included here]
    Format “(|[a-z]{2,3}(-[a-z]+){0,2}|simple): value must be formatted using this pattern (PCRE syntax). (Help)
    Exceptions are possible as rare values may exist. Exceptions can be specified using exception to constraint (P2303). Known exceptions: Crimean Tatar Latin alphabet (Q38893333), Hindko (Q382273), Pakistan Sign Language (Q22964057)
    List of violations of this constraint: Database reports/Constraint violations/P424#Format, SPARQL
    Allowed entity types are Wikibase item (Q29934200), Wikibase property (Q29934218): the property may only be used on a certain entity type (Help)
    Exceptions are possible as rare values may exist. Exceptions can be specified using exception to constraint (P2303).
    List of violations of this constraint: Database reports/Constraint violations/P424#Entity types
    Scope is as main value (Q54828448), as qualifier (Q54828449): the property must be used by specified way only (Help)
    Exceptions are possible as rare values may exist. Exceptions can be specified using exception to constraint (P2303).
    List of violations of this constraint: Database reports/Constraint violations/P424#Scope, SPARQL
     
    This property is being used by:

    Please notify projects that use this property before big changes (renaming, deletion, merge with another property, etc.)

    See Property talk:P424/list

    Should this link somewhere ? edit

    With MediaWiki:Gadget-AuthorityControl.js, it's possible to have the string link somewhere.

    Shall we use this to link to Wikipedia? Sample: on Japanese "ja" would link as ja. --  Docu  at 15:49, 14 April 2013 (UTC)Reply

    format pattern edit

    i changed the pattern from ([a-z-][a-z][a-z]?(-x)?(-[a-z][a-z]+)?|simple) to ([a-z-][a-z][a-z]?(-x|-min)?(-[a-z][a-z]+)?|simple) for zh-min-nan --Akkakk 00:28, 4 June 2013 (UTC)Reply

    I generalized it, from: ([a-z-][a-z][a-z]?(-x|-min)?(-[a-z][a-z]+)?|simple)
    to:([a-z]{2,3}(-[a-z][a-z-]*)?|simple)
    LaddΩ chat ;) 13:04, 4 March 2014 (UTC)Reply

    Qualifier for definition edit

    Currently this property has two functions:

    • 1. link to the item that describes what language, languoid, writing system, etc. a specific code refers to. Sample: Q2087886
    • 2. determine the WMF language code of an item. Sample: Q8937989

    As there is no easy way to select (1.), I'd add a qualifier to these statements, e.g. P794 (P794): definition (Q101072).
    --- Jura 05:43, 21 January 2016 (UTC)Reply

    Use of "ru" on Old East Slavic (Q35228) and "fr" Middle French (Q1473289) edit

    Russian (Q7737) seems to describe more closely "ru" and French (Q150) "fr", so I removed it from the above.
    --- Jura 06:03, 21 January 2016 (UTC)Reply

    Use of "el" for Medieval Greek (Q36387) and Greek (Q9129) edit

    "el" seems to be just for Modern Greek (Q36510). Is this correct? I replaced the others with "mis".
    --- Jura 17:55, 28 January 2016 (UTC)Reply

    New WMF language codes available: "und", "mis", "zxx", "mul" edit

    See Property_talk:P1684#New WMF language codes available: "und", "mis", "zxx", "mul".
    --- Jura 17:55, 28 January 2016 (UTC)Reply

    Inclusion in new language/projects template of Language committee at Meta edit

    At meta:Template talk:New wiki request, I suggest to include the item of the language into the template used there. It would display information about the language (and the WMF code) when new projects or languages are discussed.
    --- Jura 11:31, 31 January 2016 (UTC)Reply

    English description edit

    @Jura1: In the description of how to use this, you added two things:

    "The single item that describes the language best should use it with the qualifier P794 ("as") with value Q22283033 ("primary definition").". Why? We have the preferred rank for marking the preferred value, we shouldn't be using qualifiers to emulate that feature.

    "Languages without a code can use "mis".". Why? We have the special value "no value" to say that there is no code for it, we shouldn't be using an actual string to emulate that feature either.

    - Nikki (talk) 18:48, 15 February 2016 (UTC)Reply

    Did you have a look at the two previous threads about these? To help us stay focused, it might be better to comment there.
    --- Jura 06:45, 16 February 2016 (UTC)Reply

    Clarifying the scope of this property edit

    First: the description says "Wikimedia language code", but formatter URL (P1630) "https://$1.wikipedia.org" seems to indicate it's limited to Wikipedias. Is this right? Next, for sites like Norwegian Wikipedias (Q191769), where the content language code ("nb") differs from the site prefix ("no.wikipedia.org") for historical reasons, should "nb" or "no" be used? If this property only is intended for creating links to Wikipedia, "no" is okay, but if it's also intended for e.g. determining the language for getting labels from Wikidata, it's not. Danmichaelo (talk) 06:24, 22 May 2016 (UTC)Reply

    • If you find the formatter url problematic, you might want to change or remove it.
      --- Jura 06:45, 22 May 2016 (UTC)Reply
    • Actually the Wikimedia code for "Norwegian" is effectively "no", even if it's deprecated in BCP47 in favor of "nb" or "nn". So the format is valid, as long as it is used to refer to Wikipedia, not for Wiktionary or other other projects that would use another URL. The same applies to the Wikimedia codes "simple", "zh-classical", "fiu-vro". They are not all valid according to BCP47, but they are "supported" by MediaWiki. As well "nrm" is still the Wikimedia code for Norman (to link to wikis), even if in BCP47 it should be "nrf".
    Don't confuse Wiki language codes (which are unparsable) with standard BCP 47 codes (that are parsable) used to classify translations in Wiktionary, i.e. in the content (that should all be BCP47), or to be used in the "lang=" attribute of HTML elements, or the "lang()" selector in CSS, or the "xml:lang=" pseudo-attribute in XML, or in all standards of the web, or in localisation codes in standard C/C++ or in ICU and other BCP47-conforming libraries.
    Wikimedia codes should be used only in WMF domain names for wikis, or in interwikis prefixes used from WMF wikis (they are still used also for "?uselang" to select a MediaWiki UI translation, but this should change independantly of the domain names/interwikis codes/internal wiki database names. Everywhere else we should replace them (e.g. "simple" would become "en-x-simple", "nrm" would become "nrf", "zh-classical" would become "lzh", "zh-min-nan" is still valid in BCP47 but it is deprecated and should be replaced now by "nan").
    Note that "sh" (Serbo-Croatian) is still valid in BCP47 even if it's now just a macrolanguage and if it has been dropped from ISO 639, and other ISO 639/BCP47 language codes are now prefered. Verdy p (talk) 20:18, 14 June 2017 (UTC)Reply
    @Verdy_p:「"sh" (Serbo-Croatian) is still valid in BCP47」 please allow me to laugh for 3 days...
    In this claim, the sh.wikipedia.org should originally be hs.wikipedia.org isn't it? --Liuxinyu970226 (talk) 11:28, 16 July 2017 (UTC)Reply
    This is perfectly TRUE. Not a laugh. Even if the code was withdrawn from ISO 639, it is standard in BCP 47 and has NOT been removed from the normative IANA registry of language subtags in BCP 47.
    This IANA registry effectively contains:
    %%
    Type: language
    Subtag: sh
    Description: Serbo-Croatian
    Added: 2005-10-16
    Scope: macrolanguage
    Comments: sr, hr, bs are preferred for most modern uses
    So you were confused between ISO 639 (which we actually don't use as it is unstable), and BCP 47 (which is THE standard actually used on the web and in all localization data; ISO 639 is now only used for bibliographic purposes by librarians for their archiving purpose (but with much more limited goals, with simplified classification), which change their mind and were unable to design a stable standard and unable to properly and precisely tag languages of the world) Serbo-Croatian remains a perfectly valid "macro-language" for BCP47, exactly like Chinese that was not withdrawn of course. ISO 639 should have been withdrawn completely: many librarians (including official national libraries) have stopped using or supporting it, in favor of BCP 47 which is much more precise.
    So sorry @Liuxinyu970226:, but I had to correct your evident ignorance and confusion. Verdy p (talk) 16:12, 16 July 2017 (UTC)Reply
    Oh I see, there was an unwanted typo, with an inversion of letters. I did not want to say that "sh.wikipedia" would have to be renamed hs.wikipedia, but wanted to say that it was perfectly valid, and that localized data in Serbo-Croatian does not have to be removed (especially for non-current "modern" uses where sr, hr, bs were not separated some years ago for political reasons).
    Verdy p (talk) 16:27, 16 July 2017 (UTC)Reply

    Why P794Q22283033 ? edit

    Note that there's an on-going discussion on deletion of P794: Wikidata:Properties_for_deletion#P794. --Liuxinyu970226 (talk) 11:30, 16 July 2017 (UTC)Reply

    @Nikki, Jura1: ^^ --Liuxinyu970226 (talk) 22:12, 19 August 2017 (UTC)Reply

    This is now deleted, so no more questions here. --Liuxinyu970226 (talk) 14:44, 25 November 2017 (UTC)Reply

    Wiktionary et al. edit

    This property is used in Wikitionary items, for example French Wiktionary (Q22001373), and the language code is parsed into a link pointing to French Wikipedia. Is this a desired behaviour? Emijrp (talk) 14:41, 18 July 2017 (UTC)Reply

    zh-hk, zh-mo, zh-sg, zh-tw, zh-cn edit

    We currently use the above for label languages, but these haven't been added to any items with P424 [1]. For completeness sake, it would be good if items would be created or these added to existing items.
    --- Jura 11:06, 7 September 2017 (UTC)Reply

    target link edit

    I think, linking to Wikipedia is a bad idea, as not all of languages that uses this property are having their Wikipedias, e.g. Sakizaya (Q718269) doesn't have, so is there any possible replacements available? --Liuxinyu970226 (talk) 12:04, 28 January 2018 (UTC)Reply

    I agree, I would support replacing the formatter URL with something else. − Pintoch (talk) 12:52, 4 June 2019 (UTC)Reply
    One suggestion: Can @SPQRobin:'s codelookup be used? (https://tools.wmflabs.org/robin/?tool=codelookup&code=$1) --Liuxinyu970226 (talk) 02:02, 28 January 2020 (UTC)Reply
    Changed to https://robin.toolforge.org/?tool=codelookup&code=$1. --Liuxinyu970226 (talk) 03:34, 5 August 2021 (UTC)Reply

    topics on the language codes/lists/all page edit

    Curious if the language Wikimedia language code (P424) and its Help_talk:Wikimedia_language_codes/lists/all pages are being monitored where everal issues were noted. Thank you. jshieh (talk) 15:34, 22 February 2021 (UTC)Reply

    Return to "P424" page.