Wikifunctions
wikifunctionswiki
https://www.wikifunctions.org/wiki/Wikifunctions:Main_Page
MediaWiki 1.45.0-wmf.4
first-letter
Media
Special
Talk
User
User talk
Wikifunctions
Wikifunctions talk
File
File talk
MediaWiki
MediaWiki talk
Template
Template talk
Help
Help talk
Category
Category talk
TimedText
TimedText talk
Module
Module talk
Translations
Translations talk
Z160
0
60
191285
172794
2025-06-06T13:31:55Z
Phatarapum
13357
ตรวจทาน
191285
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z160"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z60",
"Z17K2": "Z160K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "natural language"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1851",
"Z11K2": "ภาษาธรรมชาติ"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "bahasa alami"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "স্বাভাবিক ভাষা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Asụsụ eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "linguagem natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "limbă naturală"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Lingua naturale"
}
]
}
}
],
"Z8K2": "Z60",
"Z8K3": [
"Z20"
],
"Z8K4": [
"Z14",
"Z260"
],
"Z8K5": "Z160"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Validate natural language"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "natürliche Sprache prüfen"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1157",
"Z11K2": "natuurlijke taal valideren "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1851",
"Z11K2": "ตรวจสอบภาษาธรรมชาติ"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "Validasi bahasa alami"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "স্বাভাবিক ভাষা বৈধকরন"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "επικύρωση φυσικής γλώσσας"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Kwadoro asụsụ eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "Validar linguagem natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "Validează limba naturală"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Valida lingua naturale"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"อีสาน"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "แสงสะท้อนจากก้อนเมฆทำให้เราสบายใจได้"
}
]
}
}
myc0e6h4cjx0zf241dgf4i96cf54shm
191286
191285
2025-06-06T13:52:56Z
Dv103
11127
Reverted vandalism
191286
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z160"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z60",
"Z17K2": "Z160K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "natural language"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1851",
"Z11K2": "ภาษาธรรมชาติ"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "bahasa alami"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "স্বাভাবিক ভাষা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Asụsụ eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "linguagem natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "limbă naturală"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Lingua naturale"
}
]
}
}
],
"Z8K2": "Z60",
"Z8K3": [
"Z20"
],
"Z8K4": [
"Z14",
"Z260"
],
"Z8K5": "Z160"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Validate natural language"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "natürliche Sprache prüfen"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1157",
"Z11K2": "natuurlijke taal valideren "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1851",
"Z11K2": "ตรวจสอบภาษาธรรมชาติ"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "Validasi bahasa alami"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "স্বাভাবিক ভাষা বৈধকরন"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "επικύρωση φυσικής γλώσσας"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Kwadoro asụsụ eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "Validar linguagem natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "Validează limba naturală"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Valida lingua naturale"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
8y5556pbk15o0vkrqjzb68oxo43f31v
Wikifunctions:Suggest a function
4
1176
191268
191264
2025-06-06T12:11:19Z
Denny
81
/* Gregorian calendar date */ Z24936
191268
wikitext
text/x-wiki
Do you have an idea for a new function? Suggest it here! It may help to refer to [[Wikifunctions:Glossary|our glossary]].
You can [https://www.wikifunctions.org/wiki/Special:CreateZObject?zid=Z8 create a function] right away if you have the user-rights.
If a function requires a new type, consider [[WF:TP|proposing it]].
Note that for now '''we only support a limited number of types as input and output types''' of functions. More types are coming in the next few months. For the full list, see [[WF:Type]].
Once created, consider adding new Functions to the [[Wikifunctions:Catalogue|catalogue]]. [[Category:Maintenance]]
== Proposed functions requiring only available types (string, Boolean, Natural number, list) ==
=== String ===
==== String character discard functions ====
* remove stereochemical specificity in [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string, like e/z isomers
** already fulfilled by someone else at: [[Z11815]]
* simplify [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string according to some basic simplifications
** {{Partly done}}, see [[Z19380]]. There's testcases, and I (or someone else) can get around to the coding later. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 10:21, 26 October 2024 (UTC)
*** {{Done}} completely, still at [[Z19380]]. Another user helpfully wrote a python script that passed 1 of my test cases between October and now. I just re-wrote the script to pass all 3 test cases, and also created a JavaScript version. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:43, 10 January 2025 (UTC)
==== String character replacement functions ====
==== String search functions ====
==== String escaping and unescaping functions ====
==== String encoding and decoding functions ====
* Unicode normalising functions (there are several types of normalisation)
* [[wikidata:Q47467628|Backslash-U with delimiters ASCII encoding of Unicode encode]]
** Can someone elaborate on this? No example cases were given on the document, and backslash-U with delimiters is anyway not that prevalent as far as I have seen. [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 15:24, 26 December 2023 (UTC)
** {{Done}}, see [[Z21486]]. I've made 5 test cases (achieving 100% coverage) and implementations in both JavaScript and Python, which passes all test cases. Support for both the Basic Multilingual Plane (BMP) and supplementary characters (using surrogate pairs). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 02:49, 10 January 2025 (UTC)
* [[wikidata:Q47467628|XML and HTML ASCII encoding of Unicode encode]]
** {{Done}}, see [[Z21503]]. Again, I've also made 5 test cases which cover a wide variety of Unicode characters, and implementations in JS and Python (which pass all the tests). As before successful support for both the Basic Multilingual Plane (BMP) and supplementary characters (this time '''not using''' surrogate pairs, as is customary for HTML/XML encoding). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:30, 10 January 2025 (UTC)
* [https://html.spec.whatwg.org/#named-character-references HTML named character encode]
* [[wikidata:Q47466379|Punycode encode]] - [[Z10178]] (part only, not whole url); see also [[Z10185]]
* [[:en:Unified_English_Braille|Unified English Braille encode]] (discarding invalid characters?)
** {{Done}}, see [[Z21514]]. 6 test cases this time, and support for both letters and numbers, with implementations in JS and Python (both passing all the tests). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 06:00, 10 January 2025 (UTC)
==== String presentation functions ====
* add [[:en:Quotation_mark|locale-specific quotation marks]] to string
** Shouldn't the output depend on the locale? See [[mw:Extension:Scribunto/Lua_reference_manual#mw.language:formatNum|mw.language:formatNum]]. —[[User:Dexxor|Dexxor]] ([[User talk:Dexxor|talk]]) 17:15, 4 September 2023 (UTC)
==== String colour notation functions ====
* [[:en:Complementary_colors|complementary colour]] in RGB colour model ("#FF0000" ⇒ "#00FFFF")
** Any specification on invalid inputs? [[User:MilkyDefer|<span style="color:#09C">Milky</span>]][[User talk:MilkyDefer|'''<span style="color:#F09">Defer</span>''']] 11:22, 5 August 2023 (UTC)
*:Great question. I don't think there is a position documented on Wikifunctions for how to handle invalid input to a function. Can we throw exceptions? Return null? [[User:Dhx1|Dhx1]] ([[User talk:Dhx1|talk]]) 13:23, 6 August 2023 (UTC)
*::This shouldn't be a string function. This should be a type that represents a RGB color (with corresponding validation function (hopefully it can just be three unsigned 8bit integers)) and a function that returns the complementary color. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 12:38, 7 August 2023 (UTC)
** Work on the color type has been stalled for over a year. But this task is {{Done}}, I have made [[Z21554]], that uses string hex codes (with or without the initial # and supporting short hex format). This is probably the most optimal format, as I can imagine this function being used on-wiki for thing like the style parameter (CSS) of MediaWiki tags, or of templates etc. There's 5 testcases I've made, which are passed by both my JS and Python versions. :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:39, 11 January 2025 (UTC)
==== String notation validation checks ====
* check if string is an [[:en:International_Chemical_Identifier]]
** {{Partly done}} see [[Z21539]]. Supports the verification of the chemical formula and the stereochemical layer. There are 13 testcaes that I've written, all of which are passed by my JavaScript implementation. Note that a python implementation is not possible as the regex module is not available in Wikifunctions. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
** To do:
*** Needs to verify the hydrogen and connection sections of the main layer
*** Support the charge layer
*** Support the isotopic layer
**[[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
***{{ping|MolecularPilot}} A python impl. is infact possible. I created a basic direct translation at [[Z22823]]. Some tests are failing as the regex needs a bit of sorting out, out of scope for me, but you can give it a try! Keep in mind that you need to escape any \ with a \\ just before saving per [[Wikifunctions:Python_implementations#Known_limitations_as_of_October_2024]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:14, 26 February 2025 (UTC)
* check if string is a [[:en:SMILES_arbitrary_target_specification|SMILES arbitrary target specification (SMARTS) notation]]
* check if string is an [[:en:ABC_notation|ABC notation]]
* check if string is a [[:en:LilyPond|LilyPond notation]]
* {{Doing}} check if string is a [[:en:Portable_Game_Notation|portable game notation]] for a chess game ([[Z15867]], figuring out how to add newlines to the test input)
* [[Z14643]] check if string is [[:en:Forsyth–Edwards Notation|Forsyth–Edwards Notation]] for a chess position
* check if string is a [[:en:UIC_classification_of_locomotive_axle_arrangements|UIC classification of locomotive axle arrangements notation]]
* check if a string is a valid [[:en:ISBN|ISBN]]-13 (probably just a simple variant of [[Z10821]], dropping/validating the hyphens)
** {{Done}} at [[Z23561]]. Note than ISBN-13 starts with only 978/979, a differing factor from EAN. I have added that in the func and tests as well. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 12:53, 26 March 2025 (UTC)
* check if a string is a valid [[:en:Digital_object_identifier|DOI]]
** Something about implementation difficulties: https://stackoverflow.com/questions/27910/finding-a-doi-in-a-document-or-page [[User:Alexander-Mart-Earth|Alexander-Mart-Earth]] ([[User talk:Alexander-Mart-Earth|talk]]) 14:28, 21 December 2023 (UTC)
* check if a string is a valid [[:en:ISWN|ISWN]]
** {{Done}}, see [[Z21562]]. Contains 6 test cases that I made, all of which are passed by my Python and JavaScript implementations. It supports both just numbers, and a string containing the "separator" symbols (like ., - and /). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 07:32, 11 January 2025 (UTC)
==== String validation checks ====
* {{doing}} check if string is in [[:en:Camel_case|lower camel case]]
* check if string is a valid ISO 3166 country code
* check if string is a valid ISO 8601 date/time (2023-08-03 ⇒ true; 2023-02-30 ⇒ false; 2023-08-03 15:00:00.000 ⇒ true; 2023-08-03 25:00:00.000 ⇒ false)
** {{Done|by=Philipnelson99}} at [[Z14206]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:23, 26 February 2025 (UTC)
* check if string is a valid [[:en:ISO_8601#EDTF|EDTF]] date/time
* {{doing}} check if string is a valid email address (watch out, see [https://github.com/kdeldycke/awesome-falsehood#emails this list of falsehoods] about email addresses to create unit tests - email addresses are more complicated than they seem) — [[Z10410]] creating test cases in progress. Currently it is stuck on figuring out what exactly is a valid emaill address. Nearly every errata for [[RFC:3696]] is about that.
* {{doing}} check if string is a valid [[d:Help:Items|Wikidata item]] — [[Z10696]] (possibly stuck on [[phab:T343593]]?)
====String analysis functions====
*Word frequency counting. Provide a list of words and their frequencies.
**{{Done}}, see [[Z21593]]. Providing a list of words and frequencies would require a new type, so instead it requires the sentence and the word you want to count, and returns the occurrences. Hyphenated words are not considered a match of their components, i.e. "fast-forward" is a match of "fast-forward" but nether "fast" nor "forward", I think this is the optimal behaviour but if someone disagrees we can change it. There is a JS implementation that I made which bases all of my 4 test cases. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:41, 12 January 2025 (UTC)
*:@[[User:MolecularPilot|MolecularPilot]] And I have added a Python implementation at [[Z22473]]. I would appreciate if you could attach it! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 08:13, 15 February 2025 (UTC)
*::Cool, thank you so much for doing it! Someone's already beat me to it re attaching it, but great work! :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 21:33, 16 February 2025 (UTC)
==== Monolingual text ====
==== String Wikitext operations ====
...
=== Natural number ===
* rectified linear unit (ReLU) - https://www.wikifunctions.org/view/en/Z13909
=== Integer===
* {{Done}} - multiply vectors ([[Z21903]], [[Z20659]])
=== Byte ===
See [[Wikifunctions:Catalogue/Boolean operations#Byte functions|existing Byte functions]] in catalogue.
* next byte without overflow: byte → byte
* previous byte without overflow: byte → byte
* next byte by Gray code: byte → byte
* previous byte by Gray code: byte → byte
* get nth bit as Boolean: byte, natural number → boolean
* highest bit set: byte → boolean
* lowest bit set: byte → boolean
* all bits set: byte → boolean
* no bits set: byte → boolean
* set nth bit: byte, natural number → byte
* clear nth bit: byte, natural number → byte
* switch nth bit: byte, natural number → byte
* add bytes without overflow: byte, byte → byte
* subtract bytes without overflow: byte, byte → byte
* multiply bytes without overflow: byte, byte → byte
* clamped add bytes: byte, byte → byte
* clamped subtract bytes: byte, byte → byte
* clamped multiply bytes: byte, byte → byte
* add bytes with overflow: byte, byte → byte
* subtract bytes with overflow: byte, byte → byte
* multiply bytes with overflow: byte, byte → byte
* modulo bytes: byte, byte → byte
* byte division: byte, byte → byte
* reverse: byte → byte
* right shift: byte → byte
* left shift: byte → byte
* right shift by n: byte, natural number → byte
* left shift by n: byte, natural number → byte
* right shift as ring: byte → byte
* left shift as ring: byte → byte
* right shift by n as ring: byte, natural number → byte
* left shift by n as ring: byte, natural number → byte
* how many bits set: byte → natural number
=== Unicode code point ===
See [[Wikifunctions:Catalogue/Character operations#Unicode code points|existing code point functions in catalogue]].
* Codepoint to list of bytes for UTF-8
* Codepoint to list of bytes for UTF-16
* Codepoint to list of bytes for UTF-32
===Object===
=== List ===
==== Basic list/iterable functions ====
* group
* [[w:Circular shift]]
==== Complex list functions ====
* zip lists together: for [ A .. Z ] and [ 1 .. 26 ] return [ [ A, 1 ], [ B, 2 ], .. ]
** Unsure what happens if input lists are of different lengths.
** If possible this function should be able to zip more than 2 lists together... 3, 4, n? Perhaps the input should be list(list, list, list, list, ..).
*{{Z+|Z19198}}
==== CSV list operations ====
* list of strings to csv
: number -> list of decimal digits<br>number -> list of binary digits<br>number -> list of digits in base provided [[User:Well very well|Well very well]] ([[User talk:Well very well|talk]]) 11:20, 18 May 2024 (UTC)
=== Functions with functions as arguments ===
* sort, by a given function
* test whether certain functions have specific properties of [[:w:Homogeneous_relation|homogeneous relations]] for particular lists/sets
* remove first element matching filter from list
=== Biology ===
==== Taxon functions ====
* Wikidata item representing taxon rank ({{Q|P31}} {{Q|Q427626}}) is at genus level or below
** Should(?) be possible with the current Wikidata functionality, from what I understand. See [[:Wikifunctions:Project chat#Taxon rank function(s)]] for a more detailed explanation. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 23:27, 16 May 2025 (UTC)
=== Gregorian calendar date ===
See [[Wikifunctions:Catalogue/Date operations#Gregorian calendar dates|catalogue of calendar date functions]] for existing functions.
* Create a reading function for Dagbani that handles all the possible formats (both the English-linke and the traditional ones, both the Gregorian and the Hijra calendars). [https://docs.google.com/document/d/1u7-ZeY7NHt75JICUPAYky3-7KgkvauD_W3fBjmvpFO0/edit?tab=t.0#heading=h.gf6hp9o3gi0j] [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 15:43, 31 May 2025 (UTC)
* year from date: date → year
* era from date: date → era
* before / sooner / earlier: date, date → boolean
* after / later: date, date → boolean
* same month: date, date → boolean
* same day of the month: date, date → boolean
* same day of the year: date, date → boolean
* same calendar year: date, date → boolean
* same day of the week: date, date → boolean
* within a year: date, date → boolean
* within a week: date, date → boolean
* within n days: date, date → boolean
* {{Z+|Z24918}}
* months between: date, date → natural number
* weeks between: date, date → natural number
* previous day: date → date
* n days later: date, natural number → date
* n days earlier: date, natural number → date
* n weeks later: date, natural number → date
* n weeks earlier: date, natural number → date
* n months later: date, natural number → date
* n months earlier: date, natural number → date
* n years later: date, natural number → date
* n months later: date, natural number → date
* Julian day number to date: integer → date
* how many leap days passed between two dates: date, date → natural number
* how many weekdays between two dates: date, date, day of the week → natural number
* is it easter: date → boolean
* days until next easter: date → natural number
* days since last easter: date → natural number
* day number of the year: date → natural number
* days until the end of the year: date → natural number
* is proleptic: date → boolean
* within Pythons date implementation: date → boolean
* within JavaScript's date implementation: date → boolean
* next time a day of the year is on a specific weekday: date, day of the week → date
* next time a day of the month is on a specific weekday: date, natural number, day of the week → date
* next Friday the 13th: date → date
* first weekday of the month: date, day of the week → date
* last weekday of the month: date, day of the week → date
* nth weekday of the month: date, day of the week, natural number → date
== Morphological functions ==
morphology is the part of linguistics that studies how language parts are 'shaped' and change diachronically and when inflected. Hausa, Igbo, Malayalam, Bangla/Bengali and Dagbani are [[d:Wikidata:Lexicographical data/Focus languages|focus languages]] for Wikidata's lexicographic dataset, which is an important aspect of [[WF:glossary#Abstract Wikipedia|Abstract Wikipedia]].
=== mul - Multiple languages ===
* inputs: natural number (new numeric type) and language Z-number; output: 'singular', 'dual', 'paucal', 'plural', etc. as string
*: {{doing}}: {{Z|15977}}
=== ase - American Sign Language ===
* string: Stokoe to ase-[https://github.com/sutton-signwriting/core Sgnw] and vice-versa (consult {{ping|Slevinski}} as to best approach)
=== bn - Bangla ===
=== cy - Welsh ===
[[w:en:colloquial Welsh morphology]]
=== dag - Dagbani ===
=== de - German ===
* tense * person * number for each verb
** tenses: present, past, ...?
** person: first, second, third
** number: singular, plural
** {{doing}} third person singular present
** second person singular preterite
=== en - English ===
* [[Z11390]] Verb -> agent noun, e.g. "dance"->"dancer"
* Join English morphemes (extends [[Z13254]] to cases like re + en + able + er + s → re-enablers. [[Z13254]] will correctly join re-enable + ers or re- + enablers, but re + enablers → “renablers” (incorrect). [[Z13275]] tests the Reduce function to produce “detoxification” from a list of four morphemes (orchestrator limit exceeded with five). I doubt we’ll want to derive “toxify” from “toxic”, however.
* Derive lemmas from a form. This is envisaged as the converse of Join English morphemes. The focus would be identifying the base form (the lexeme’s lemma) rather than further segmenting the lemma. For example, “underlay” should return “underlie” (for which it is the past participle) and the noun “underlay” (for which it is the lemma) and (perhaps) the verb “underlay”, which might be the tendency of an unproductive hen or the activity of a carpet-fitter. As this is a purely functional converse, every string will have itself as a possible lemma.
* Generate [[:w:Numeral_prefix|Numerical prefixes]] of various kinds from a natural number input.
* {{Z+|Z19499}}
'''<big>eu - Basque</big>'''
* Basque language declension system in rather regular based on suffixes.
** Here a few examples for Basque declension:
*** {{Z+|Z18541}}
*** {{Z+|Z18670}}
**Before implementing all of them, we may propose an overall classification that eases both the implementation and the future usage of the functions. Here a first try based on bibliography from the [https://www.euskaltzaindia.eus/index.php?option=com_ebe&view=bilaketa&task=pdf&Itemid=1161&atala=deklinabide-taulak Basque Language Academy]:
***Personal pronouns: they can be treated as exceptions (e.g. "zuek -> zuei", etc.) together with proper noun declension, or as a separate case.
***Determiners: they can be treated as exceptions (e.g. "hau" -> "honek", etc) together with common noun declension, or as a separated case
***Grammatical cases:
****Absolutive ("Nor"): indefinite, singular and plural
****Ergative ("Nork"): indefinite, singular and plural
****Dative ("Nori"): indefinite, singular and plural
***Place and Time: we must distinguish animate (AN) and inanimate (IN)
****Inessive IN ("Non"): indefinite, singular and plural
****Inessive AN ("Norengan"): indefinite, singular and plural - It could be a composition of "Noren" + "-gan"
****Place and time ("Nongo"): indefinite, singular and plural
****Allative IN ("Nora"): indefinite, singular and plural
****Allative AN ("Norengana"): indefinite, singular and plural - It could be a composition of "Noren/Norengan" + "-gan/-a"
****Finished Allative AN ("Noraino"): indefinite, singular and plural - It could be a composition of "Nora" + "-ino"
****Finished Allative AN ("Norengainaino"): indefinite, singular and plural - It could be a composition of "Noregana" + "-ino"
****Right way Allative IN ("Noratz"): indefinite, singular and plural - It could be a composition of "Nora" + "-ntz"
****Right way Allative AN ("Norenganantz"): indefinite, singular and plural - It could be a composition of "Norengana" + "-ntz"
****Ablative IN ("Nondik"): indefinite, singular and plural
****Ablative AN ("Norengandik"): indefinite, singular and plural
***Rest of the cases:
****Partitive ("Zerik"): indefinite
****Possessive ("Noren"): indefinite, singular and plural
****Sociative ("Norekin"): indefinite, singular and plural
****Instrumental ("Zerez"): indefinite, singular and plural
****Motivative ("Zerengatik"): indefinite, singular and plural
****Destinative ("Norentzat"): indefinite, singular and plural - It could be a composition of "Noren" + "-tzat"
***Special case:
****Prolative ("Nortzat"): indefinite
***To take into consideration:
****Together with animate and inanimate classification, we should also consider if the noun is a proper noun ("izen berezia"). We can identify that automatically (e.g. check if written in Title case, but this may not be always possible like in the beginning of sentences), but a dedicated function may be preferred (or a boolean to the generic function saying it is a proper noun).
****The main distinction is between noun ending by vowel or consonant that can be easily computed
=== fr - French ===
* [[Z11590]] Masculine adjective -> feminine, e.g. "exact"->"exacte"
* Conjugated verb => Infinitive, e.g. "alla" => "aller", "mordit" => "mordre"
=== ha - Hausa ===
A notated demo sentence ("Aishà taa jeefar dà kàren Indoo" ― "Aisha threw away Indo's dog") is available at http://intent.xigt.org
=== ig - Igbo ===
=== ldn - Láadan ===
section moved to [[WF:human languages/Z1882]]
=== ml - Malayalam ===
===kcg - Tyap===
* Tyap has six determiners/definite articles which determine the pronoun, number (1-5), etc. forms used.
** ka & wu (basically for singular nouns and adjectives with a few exceptions)
** hu & ji (for singular and plural nouns and adjectives)
** ba & na (mainly for plural nouns.
*** Determiners come after nouns.
*** When an adjective comes before a noun, the determiner used is that of the adjective. E.g., a̱sham (ka) - (the) beautiful, kyang (hu) - (the) thing = a̱sham kyang (ka) - (the) beautiful thing.
* Tyap has a non-uniform noun class system used for noun pluralization and conversion from one part of speech to another. E.g., a̱bwom (song) and bwom (to sing), a̱fufwuo (ears) and fufwuo (ear).
* Affixation: Prefixes exist but suffixes hardly are found.
== Proposed functions requiring future types ==
'''Note these functions cannot be implemented properly until the needed types are requested and approved.'''
If one wishes to nevertheless attempt to define and implement them,
* the functions and implementations should indicate prominently in their labels that their input/output types must be adjusted once support for the appropriate replacement types become available; ''and''
* the functions should ''not'' be used in the implementations of any other functions, as the later adjustment of input/output types to appropriate replacements will break those implementations.
=== String manipulation functions ===
=== String analysis functions ===
* count distance between two letters in given alphabet (default to 26-charcater western alphabet. case insensitive. e.g. "a" & "A" ⇒ 0; "K" & "N" ⇒ 3)
=== String encoding and decoding functions ===
(would be better with types representing a stream of bytes)
* [[wikidata:Q113486941|BASE45 encode]]
* [[wikidata:Q113486941|BASE45 decode]]
* Hexadecimal UTF-8 encode ("ABC ₤" ⇒ "41 42 43 20 E2 82 A4")
* Hexadecimal UTF-8 decode ("41 42 43 20 E2 82 A4" ⇒ "ABC ₤")
* Decimal UTF-8 encode ("ABC ₤" ⇒ "65 66 67 32 226 130 164")
* Decimal UTF-8 decode ("65 66 67 32 226 130 164" ⇒ "ABC ₤")
* Octal UTF-8 encode ("ABC ₤" ⇒ "101 102 103 40 342 202 244")
* Octal UTF-8 decode ("101 102 103 40 342 202 244" ⇒ "ABC ₤")
* Binary UTF-8 encode ("ABC ₤" ⇒ "01000001 01000010 01000011 00100000 11100010 10000010 10100100")
* Binary UTF-8 decode ("01000001 01000010 01000011 00100000 11100010 10000010 10100100" ⇒ "ABC ₤")
* Unicode code point encode ("ABC ₤" ⇒ "41 42 43 20 20A4") - [[Z10785]]
* Unicode code point decode ("41 42 43 20 20A4" ⇒ "ABC ₤")
* Create regular expression object/string (i.e: "test" & "i" to /test/i)
=== Natural language functions ===
* Choose singular or plural based on number (e.g. singularOrPlural("person",6") -> "people")
** Note that there are also dual and other [[:w:grammatical number|grammatical number]]s in other languages. [[User:魔琴|魔琴]] ([[User talk:魔琴|talk]]) 18:54, 26 October 2023 (UTC)
** relevant interwiki link: [[d:WD:property proposal/plural forms]] [[User:Arlo Barnes|Arlo Barnes]] ([[User talk:Arlo Barnes|talk]]) 04:15, 9 February 2024 (UTC)
=== Cryptographic hash functions ===
(would be better with types representing a stream of bytes)
* {{todo}} [[wikidata:Q47477417|MD2]] - [[Z10135]]
* {{todo}} [[wikidata:Q47462255|MD4]] - [[Z10136]]
* {{todo}} [[wikidata:Q27036232|MD5]] - [[Z10137]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-128]] - [[Z10138]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-160]] - [[Z10139]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-160]] - [[Z10140]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-256]] - [[Z10141]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-384]] - [[Z10142]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-512]] - [[Z10143]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-128]] - [[Z10144]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-160]] - [[Z10145]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-224]] - [[Z10146]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-256]] - [[Z10147]]
* {{todo}} [[wikidata:Q47465971|SHA-224]] - [[Z10149]]
* {{todo}} [[wikidata:Q47465971|HMAC-SHA-256]]
* {{todo}} [[wikidata:Q87486893|SHAKE-128]] - [[Z10150]]
* {{todo}} [[wikidata:Q87486893|SHAKE-256]] - [[Z10151]]
=== Colour functions ===
* return colour contrast ratio (per [https://webaim.org/articles/contrast/]) of two RGB colours (provided as strings e.g. "#FF0000")
=== Date, time, and calendric functions ===
Note: 'time' type not yet supported, use 'string' (or for strictly numeric values, 'natural number')
==== Bengali calendar ====
{{z+|12926}}
==== Chinese calendar ====
==== French Republican Calendar ====
decimalises and secularises the Gregorian
* day names: {{Z+|13006}}{{not done}} '''yet'''
==== Gregorian ====
widely used calendar derived from the Julian, basis for [[xkcd:1179|ISO 8601]]
* date to ISO week number {{q|2110154}}
* string to date
* date to ISO 8601 string
*: {{done}}, see {{z|21842}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 18:47, 21 January 2025 (UTC)
* date to year (yyyy)
* date to month of the year (1-12)
* date to month name (January-December)
* date to day of the month (1-31)
* date to hour of the day (0-23)
* date to minutes (0-59)
* date to seconds (0-59)
Named Day from Date or day of year ; Input type : Date ; Output Type : String. ; The initial use case was automated population of On The Day, based on various collections of Holidays, festival days and observances. ? [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
:So If you gave it 2025-05-01 It said "All Fools Day" etc.. Possibly an additional input of enumrated type to indicate which data set to pull holidays, fesitvals and observances from.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
Diary/calander Header function - Using the above and other date functions, generates a data set from a given date. Hence if you give it 2003-05-01 you get back a JOSN set contianing the {Day of week:String, Day in the Month, Observances} etc. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
==== Holocene calendar ====
* [[w:en:Holocene calendar#Conversion]]
*: {{done}}, see {{z|21913}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 13:30, 25 January 2025 (UTC)
==== Indian national calendar ====
==== Islamic ====
a Lunar calendar, also called Hijri
==== Julian ====
mostly used by astronomers, some historians, and some Orthodox Christian denominations
==== Mesoamerican calendars ====
including civil and clerical forms
==== Persian ====
also called Jalali
==== Thai calendar ====
==== Hebrew calendar ====
==== Darian calendar ====
Proposed time-keeping system for Mars, requires Julian Date/Time to calculate.
=== Basic numerical functions ===
* round up ("1.289" & "2" ⇒ "1.29"; "5678" & "2" ⇒ "5700")
*: So if the number is floating point, round to n decimal places, and if not, round to n significant figures. Is that right? [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 19:36, 24 December 2023 (UTC)
* round down
* return integer value (5678.678 ⇒ 5678)
* {{Z+|Z13587}} (23 ⇒ "twenty-three")
* Convert money from US$ to anything else
** requires source of conversion rates, which is a hole in function-likeness
* Arabic numeral to Etruscan numeral
* Etruscan numeral to Arabic numeral
* floor and ceiling functions, based on defined standards.
=== Data serialization functions ===
* parse a string as [[:en:JSON|JSON]]
* extract string from JSON object based on [[:d:Q121208951|JSONPath]] (<code>{"name":"Alice"}</code>, "$.name" ⇒ "Alice")
*:Why not first convert a JSON string to an object, and then have a function that extracts fields based on JSONPath? Doing Stringly-typed things like this proposal as defined isn't a good idea. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 16:16, 5 August 2023 (UTC)
*::This seems to be a good idea, thanks! I moved and splitted the proposal accordingly. --[[User:1-Byte|1-Byte]] ([[User talk:1-Byte|talk]]) 09:51, 6 August 2023 (UTC)
*:: is it okay to go ahead to create this 'extract string from JSON object based on JSONPath' as a function ? [[User:Dolphyb|Dolphyb]] ([[User talk:Dolphyb|talk]]) 16:14, 15 February 2024 (UTC)
=== Basic list/iterable functions requiring numeric types ===
* Sum the elements of a numeric list - [[Z14038]]
* Product of the elements of a numeric list
* {{Z+|Z12676}}
* Slice of list elements: for the supplied list, return a list of elements that are at indexes between a supplied range n:m
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Remove slice of elements from list: return the supplied list with elements between a supplied range of indexes removed
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Every nth element of list: returns every nth element of the supplied list
* Remove every nth element of list: removes every nth element of the supplied list -
* sample n objects from list (return up to n [[Wikifunctions:Determinism|random]] objects from the list)
* Jaccard similarity coefficient (see https://en.wikipedia.org/wiki/Jaccard_index)
=== Geodetics functions ===
[[w:en:planetary coordinate system]], [[w:en:well-known text representation of coordinate reference systems]]
==== Earth ====
* convert coordinates outside of the ranges (-180, 180) for longitude and (-90, 90) for latitude to a canonical form
==== Mars ====
* convert coordinates outside of the ranges [0, 360) for longitude and (-90, 90) for latitude to a canonical form
=== Unit conversion functions ===
* {{Z+|15560}}
=== Conversion function : 2D Cartesian to 2D Polar ===
Input : matrix [x,y]
Output: matrix [θ,r]
Short text : Polar conversion of x,y to a polar space centred at 0,0 in the Cartesian.
Constraints: x,y,r are reals (float64), θ lies in the range -π<0<π (Sign determined in relation to standards used in STEM applications.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
:The companion could also be provided. As I never did Geodetic functions, I am not sure how Lat, Long to map projection would work , but useful. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
=== Trignometric Functions ===
* sine, cosine,
*: Input : float64 Angle in radians.
*: Output : float64 desired trignometric value
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:40, 26 March 2025 (UTC)
==== Function Proposal : Decimalise angle of the form ('1:x' or '1 in x') to % (in 100) or ‰ (in 1000) ====
*Suggested name: gardient_decimal.
*Input type: Integer ( The 1 is implied.). Lower Bound +1: Upper Bound: 1000 (for most practical situations?)
*Output type: Real/float 64.
Proposer: [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:05, 28 March 2025 (UTC)
===Color Functions===
==== Colorspace Conversion ====
x,y,Y to sRGB (Illuminant D65).
Input : 3tuple of float64,
Output: 3 tuple of integer, where 0>=r<=255, 0>=g<=255 0>=b<=255.
Convert a color specfied as 3 float64 values, from x,y,Y colorspace to sRGB or raise an "Out of Gaumt" exception.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:09, 7 April 2025 (UTC)
==== Spectral Approximate from sRGB or XYZ values. ====
I'd like to see the techniques detailed here: http://scottburns.us/reflectance-curves-from-srgb/ implemented in Wikifunctions as the provided spreadhseet later in the paper doesn't appear to work with Libre Office. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:32, 2 June 2025 (UTC)
==== Subtractive color mix (Pigment style) ====
Implement the mixing function from Spectral.js (https://github.com/rvanwijnen/spectral.js/blob/3.0.0/spectral.js )(MIT license), to allow 2 or more sRGB triplets to be mixed like pigment colors. This is different from the subtract colors function implemented previously.
=== Music Functions ===
It would be nice to have '''12 equal temperament pitch class''' and '''12 equal temperament pitch''' types, as they would be useful for calculating harmonies and melodies. The pitch classes could be stored as natural numbers from 0 to 11, and represented with symbols C, C♯, D, ..., B. The pitches could be stored as integers with -1 being B3, 0 being C4, 1 being C♯4, etc. Over time, we could expand the pitch class and pitch types to other temperaments and just intonation. As I'm new to Wikifunctions and my coding skills are next to zero, this is just a suggestion to the community. (edited) [[User:CaffeineP|CaffeineP]] ([[User talk:CaffeineP|talk]]) 14:48, 9 April 2025 (UTC)
:Yes… There are some notational challenges because of enharmonics as well as naming conventions varying by language/culture, so English A♯ is equivalent to German B and English B♭, for example. Ideally, I would want the (English) pitch class that is five semitones higher than G♭ to be displayed as C♭ rather than B.
:Also, given some reference pitch like A4 = 440 Hz, we should be able to return the frequency in hertz of a given pitch and, conversely, the nearest pitch for a given frequency and its offset in cents (or whatever). The computation is a lot simpler than representing the result (or capturing how the result should be represented)! [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 20:08, 9 April 2025 (UTC)
* '''12-ET Pitch Class of a Pitch''': Return the 12 equal temperament pitch class of a given 12 equal temperament pitch. For example, C4 returns C.
* '''12-ET Pitch based on Pitch Class''': Return a 12 equal temperament pitch based on a given 12 equal temperament pitch class and a given integer. For example, C and 4 return C4.
* '''Interval between 12-ET Pitch Classes in Semitones''': Get the interval in semitones between two 12 equal temperament pitch classes, always assuming that the first is lower than (or the same as) the second, and the interval is less than an octave. For example, C and B return 11, while B and C return 1.
* '''Interval between 12-ET Pitches in Semitones''': Get the interval in semitones between two 12 equal temperament pitches. For example, C4 and B3 return -1, while C3 and B4 return 23.
* '''Raise 12-ET Pitch Class by Semitones''': Get a new 12 equal temperament pitch class through raising a given pitch class by the provided number of semitones. For example, raising B by 1 semitone returns C.
* '''Lower 12-ET Pitch Class by Semitones''': Same as above, but lower the pitch class instead of raising it.
* '''Raise 12-ET Pitch by Semitones''': Get a new 12 equal temperament pitch through raising a given pitch by the provided number of semitones. For example, raising B3 by 1 semitone returns C4.
* '''Lower 12-ET Pitch by Semitones''': Same as above, but lower the pitch instead of raising it.
* '''Frequency of a 12-ET Pitch''': Return a float64 frequency in Hz based on the provided 12 equal temperament pitch (and possibly a reference pitch with its frequency; if not provided, take default A4 = 440 Hz).
* '''Approximate 12-ET Pitch Class based on Frequency''': Return a 12 equal temperament pitch class approximately based on the provided frequency in Hz.
* '''Approximate 12-ET Pitch based on Frequency''': Return a 12 equal temperament pitch approximately based on the provided frequency in Hz.
=== SVG Functions ===
I would be nice to generate SVG (a XML-based vector image format which is basically a long string), it could allow to replace a lot of images on Commons or templates/tools. Here some examples:
* create simple forms,
* create graphs (line graph/bar graph for population or for production, elections diagrams like [[:File:1900Hawaii.svg]], etc.),
* create more complex visualisation like genealogical trees,
* create coat of arms (?),
* etc.
Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 10:47, 23 April 2025 (UTC)
:@[[User:VIGNERON|VIGNERON]]: Eventually that is something we might support, but there'll be nothing any time soon. It has a number of complex security and scalability concerns, sadly. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 13:21, 23 April 2025 (UTC)
::{{ping|Jdforrester (WMF)}} thanks. I talked about it for the last Corner but I wanted to leave a record here, if we have time, maybe I'll use that time to write some things to prepare (like listing templates and tools on the Wikimedia projects that generate SVG or visualisations). Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 15:28, 23 April 2025 (UTC)
:::Of course! I've explicitly added a section on this here: [[Wikifunctions:Embedded function calls#Non-text output]] — hope that helps assure you that we're thinking about it. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 21:40, 23 April 2025 (UTC)
== Object / type / function functions ==
*{{Z+|Z17893}}
*{{Z+|Z21180}}
*{{Z+|Z21182}}
*{{Z+|Z21193}}
== External function lists ==
* [[WF:importing]]
cnybj9gi0m50onzj83417uz0mbux09x
191283
191268
2025-06-06T12:53:03Z
Dv103
11127
/* Gregorian calendar date */
191283
wikitext
text/x-wiki
Do you have an idea for a new function? Suggest it here! It may help to refer to [[Wikifunctions:Glossary|our glossary]].
You can [https://www.wikifunctions.org/wiki/Special:CreateZObject?zid=Z8 create a function] right away if you have the user-rights.
If a function requires a new type, consider [[WF:TP|proposing it]].
Note that for now '''we only support a limited number of types as input and output types''' of functions. More types are coming in the next few months. For the full list, see [[WF:Type]].
Once created, consider adding new Functions to the [[Wikifunctions:Catalogue|catalogue]]. [[Category:Maintenance]]
== Proposed functions requiring only available types (string, Boolean, Natural number, list) ==
=== String ===
==== String character discard functions ====
* remove stereochemical specificity in [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string, like e/z isomers
** already fulfilled by someone else at: [[Z11815]]
* simplify [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string according to some basic simplifications
** {{Partly done}}, see [[Z19380]]. There's testcases, and I (or someone else) can get around to the coding later. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 10:21, 26 October 2024 (UTC)
*** {{Done}} completely, still at [[Z19380]]. Another user helpfully wrote a python script that passed 1 of my test cases between October and now. I just re-wrote the script to pass all 3 test cases, and also created a JavaScript version. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:43, 10 January 2025 (UTC)
==== String character replacement functions ====
==== String search functions ====
==== String escaping and unescaping functions ====
==== String encoding and decoding functions ====
* Unicode normalising functions (there are several types of normalisation)
* [[wikidata:Q47467628|Backslash-U with delimiters ASCII encoding of Unicode encode]]
** Can someone elaborate on this? No example cases were given on the document, and backslash-U with delimiters is anyway not that prevalent as far as I have seen. [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 15:24, 26 December 2023 (UTC)
** {{Done}}, see [[Z21486]]. I've made 5 test cases (achieving 100% coverage) and implementations in both JavaScript and Python, which passes all test cases. Support for both the Basic Multilingual Plane (BMP) and supplementary characters (using surrogate pairs). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 02:49, 10 January 2025 (UTC)
* [[wikidata:Q47467628|XML and HTML ASCII encoding of Unicode encode]]
** {{Done}}, see [[Z21503]]. Again, I've also made 5 test cases which cover a wide variety of Unicode characters, and implementations in JS and Python (which pass all the tests). As before successful support for both the Basic Multilingual Plane (BMP) and supplementary characters (this time '''not using''' surrogate pairs, as is customary for HTML/XML encoding). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:30, 10 January 2025 (UTC)
* [https://html.spec.whatwg.org/#named-character-references HTML named character encode]
* [[wikidata:Q47466379|Punycode encode]] - [[Z10178]] (part only, not whole url); see also [[Z10185]]
* [[:en:Unified_English_Braille|Unified English Braille encode]] (discarding invalid characters?)
** {{Done}}, see [[Z21514]]. 6 test cases this time, and support for both letters and numbers, with implementations in JS and Python (both passing all the tests). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 06:00, 10 January 2025 (UTC)
==== String presentation functions ====
* add [[:en:Quotation_mark|locale-specific quotation marks]] to string
** Shouldn't the output depend on the locale? See [[mw:Extension:Scribunto/Lua_reference_manual#mw.language:formatNum|mw.language:formatNum]]. —[[User:Dexxor|Dexxor]] ([[User talk:Dexxor|talk]]) 17:15, 4 September 2023 (UTC)
==== String colour notation functions ====
* [[:en:Complementary_colors|complementary colour]] in RGB colour model ("#FF0000" ⇒ "#00FFFF")
** Any specification on invalid inputs? [[User:MilkyDefer|<span style="color:#09C">Milky</span>]][[User talk:MilkyDefer|'''<span style="color:#F09">Defer</span>''']] 11:22, 5 August 2023 (UTC)
*:Great question. I don't think there is a position documented on Wikifunctions for how to handle invalid input to a function. Can we throw exceptions? Return null? [[User:Dhx1|Dhx1]] ([[User talk:Dhx1|talk]]) 13:23, 6 August 2023 (UTC)
*::This shouldn't be a string function. This should be a type that represents a RGB color (with corresponding validation function (hopefully it can just be three unsigned 8bit integers)) and a function that returns the complementary color. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 12:38, 7 August 2023 (UTC)
** Work on the color type has been stalled for over a year. But this task is {{Done}}, I have made [[Z21554]], that uses string hex codes (with or without the initial # and supporting short hex format). This is probably the most optimal format, as I can imagine this function being used on-wiki for thing like the style parameter (CSS) of MediaWiki tags, or of templates etc. There's 5 testcases I've made, which are passed by both my JS and Python versions. :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:39, 11 January 2025 (UTC)
==== String notation validation checks ====
* check if string is an [[:en:International_Chemical_Identifier]]
** {{Partly done}} see [[Z21539]]. Supports the verification of the chemical formula and the stereochemical layer. There are 13 testcaes that I've written, all of which are passed by my JavaScript implementation. Note that a python implementation is not possible as the regex module is not available in Wikifunctions. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
** To do:
*** Needs to verify the hydrogen and connection sections of the main layer
*** Support the charge layer
*** Support the isotopic layer
**[[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
***{{ping|MolecularPilot}} A python impl. is infact possible. I created a basic direct translation at [[Z22823]]. Some tests are failing as the regex needs a bit of sorting out, out of scope for me, but you can give it a try! Keep in mind that you need to escape any \ with a \\ just before saving per [[Wikifunctions:Python_implementations#Known_limitations_as_of_October_2024]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:14, 26 February 2025 (UTC)
* check if string is a [[:en:SMILES_arbitrary_target_specification|SMILES arbitrary target specification (SMARTS) notation]]
* check if string is an [[:en:ABC_notation|ABC notation]]
* check if string is a [[:en:LilyPond|LilyPond notation]]
* {{Doing}} check if string is a [[:en:Portable_Game_Notation|portable game notation]] for a chess game ([[Z15867]], figuring out how to add newlines to the test input)
* [[Z14643]] check if string is [[:en:Forsyth–Edwards Notation|Forsyth–Edwards Notation]] for a chess position
* check if string is a [[:en:UIC_classification_of_locomotive_axle_arrangements|UIC classification of locomotive axle arrangements notation]]
* check if a string is a valid [[:en:ISBN|ISBN]]-13 (probably just a simple variant of [[Z10821]], dropping/validating the hyphens)
** {{Done}} at [[Z23561]]. Note than ISBN-13 starts with only 978/979, a differing factor from EAN. I have added that in the func and tests as well. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 12:53, 26 March 2025 (UTC)
* check if a string is a valid [[:en:Digital_object_identifier|DOI]]
** Something about implementation difficulties: https://stackoverflow.com/questions/27910/finding-a-doi-in-a-document-or-page [[User:Alexander-Mart-Earth|Alexander-Mart-Earth]] ([[User talk:Alexander-Mart-Earth|talk]]) 14:28, 21 December 2023 (UTC)
* check if a string is a valid [[:en:ISWN|ISWN]]
** {{Done}}, see [[Z21562]]. Contains 6 test cases that I made, all of which are passed by my Python and JavaScript implementations. It supports both just numbers, and a string containing the "separator" symbols (like ., - and /). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 07:32, 11 January 2025 (UTC)
==== String validation checks ====
* {{doing}} check if string is in [[:en:Camel_case|lower camel case]]
* check if string is a valid ISO 3166 country code
* check if string is a valid ISO 8601 date/time (2023-08-03 ⇒ true; 2023-02-30 ⇒ false; 2023-08-03 15:00:00.000 ⇒ true; 2023-08-03 25:00:00.000 ⇒ false)
** {{Done|by=Philipnelson99}} at [[Z14206]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:23, 26 February 2025 (UTC)
* check if string is a valid [[:en:ISO_8601#EDTF|EDTF]] date/time
* {{doing}} check if string is a valid email address (watch out, see [https://github.com/kdeldycke/awesome-falsehood#emails this list of falsehoods] about email addresses to create unit tests - email addresses are more complicated than they seem) — [[Z10410]] creating test cases in progress. Currently it is stuck on figuring out what exactly is a valid emaill address. Nearly every errata for [[RFC:3696]] is about that.
* {{doing}} check if string is a valid [[d:Help:Items|Wikidata item]] — [[Z10696]] (possibly stuck on [[phab:T343593]]?)
====String analysis functions====
*Word frequency counting. Provide a list of words and their frequencies.
**{{Done}}, see [[Z21593]]. Providing a list of words and frequencies would require a new type, so instead it requires the sentence and the word you want to count, and returns the occurrences. Hyphenated words are not considered a match of their components, i.e. "fast-forward" is a match of "fast-forward" but nether "fast" nor "forward", I think this is the optimal behaviour but if someone disagrees we can change it. There is a JS implementation that I made which bases all of my 4 test cases. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:41, 12 January 2025 (UTC)
*:@[[User:MolecularPilot|MolecularPilot]] And I have added a Python implementation at [[Z22473]]. I would appreciate if you could attach it! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 08:13, 15 February 2025 (UTC)
*::Cool, thank you so much for doing it! Someone's already beat me to it re attaching it, but great work! :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 21:33, 16 February 2025 (UTC)
==== Monolingual text ====
==== String Wikitext operations ====
...
=== Natural number ===
* rectified linear unit (ReLU) - https://www.wikifunctions.org/view/en/Z13909
=== Integer===
* {{Done}} - multiply vectors ([[Z21903]], [[Z20659]])
=== Byte ===
See [[Wikifunctions:Catalogue/Boolean operations#Byte functions|existing Byte functions]] in catalogue.
* next byte without overflow: byte → byte
* previous byte without overflow: byte → byte
* next byte by Gray code: byte → byte
* previous byte by Gray code: byte → byte
* get nth bit as Boolean: byte, natural number → boolean
* highest bit set: byte → boolean
* lowest bit set: byte → boolean
* all bits set: byte → boolean
* no bits set: byte → boolean
* set nth bit: byte, natural number → byte
* clear nth bit: byte, natural number → byte
* switch nth bit: byte, natural number → byte
* add bytes without overflow: byte, byte → byte
* subtract bytes without overflow: byte, byte → byte
* multiply bytes without overflow: byte, byte → byte
* clamped add bytes: byte, byte → byte
* clamped subtract bytes: byte, byte → byte
* clamped multiply bytes: byte, byte → byte
* add bytes with overflow: byte, byte → byte
* subtract bytes with overflow: byte, byte → byte
* multiply bytes with overflow: byte, byte → byte
* modulo bytes: byte, byte → byte
* byte division: byte, byte → byte
* reverse: byte → byte
* right shift: byte → byte
* left shift: byte → byte
* right shift by n: byte, natural number → byte
* left shift by n: byte, natural number → byte
* right shift as ring: byte → byte
* left shift as ring: byte → byte
* right shift by n as ring: byte, natural number → byte
* left shift by n as ring: byte, natural number → byte
* how many bits set: byte → natural number
=== Unicode code point ===
See [[Wikifunctions:Catalogue/Character operations#Unicode code points|existing code point functions in catalogue]].
* Codepoint to list of bytes for UTF-8
* Codepoint to list of bytes for UTF-16
* Codepoint to list of bytes for UTF-32
===Object===
=== List ===
==== Basic list/iterable functions ====
* group
* [[w:Circular shift]]
==== Complex list functions ====
* zip lists together: for [ A .. Z ] and [ 1 .. 26 ] return [ [ A, 1 ], [ B, 2 ], .. ]
** Unsure what happens if input lists are of different lengths.
** If possible this function should be able to zip more than 2 lists together... 3, 4, n? Perhaps the input should be list(list, list, list, list, ..).
*{{Z+|Z19198}}
==== CSV list operations ====
* list of strings to csv
: number -> list of decimal digits<br>number -> list of binary digits<br>number -> list of digits in base provided [[User:Well very well|Well very well]] ([[User talk:Well very well|talk]]) 11:20, 18 May 2024 (UTC)
=== Functions with functions as arguments ===
* sort, by a given function
* test whether certain functions have specific properties of [[:w:Homogeneous_relation|homogeneous relations]] for particular lists/sets
* remove first element matching filter from list
=== Biology ===
==== Taxon functions ====
* Wikidata item representing taxon rank ({{Q|P31}} {{Q|Q427626}}) is at genus level or below
** Should(?) be possible with the current Wikidata functionality, from what I understand. See [[:Wikifunctions:Project chat#Taxon rank function(s)]] for a more detailed explanation. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 23:27, 16 May 2025 (UTC)
=== Gregorian calendar date ===
See [[Wikifunctions:Catalogue/Date operations#Gregorian calendar dates|catalogue of calendar date functions]] for existing functions.
* Create a reading function for Dagbani that handles all the possible formats (both the English-linke and the traditional ones, both the Gregorian and the Hijra calendars). [https://docs.google.com/document/d/1u7-ZeY7NHt75JICUPAYky3-7KgkvauD_W3fBjmvpFO0/edit?tab=t.0#heading=h.gf6hp9o3gi0j] [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 15:43, 31 May 2025 (UTC)
* year from date: date → year
* era from date: date → era
* before / sooner / earlier: date, date → boolean
* after / later: date, date → boolean
* same month: date, date → boolean
* same day of the month: date, date → boolean
* same day of the year: date, date → boolean
* same calendar year: date, date → boolean
* same day of the week: date, date → boolean
* within a year: date, date → boolean
* within a week: date, date → boolean
* within n days: date, date → boolean
* {{Z+|Z24918}}
* months between: date, date → natural number
* weeks between: date, date → natural number
* previous day: date → date
* n days later: date, natural number → date
* n days earlier: date, natural number → date
* n weeks later: date, natural number → date
* n weeks earlier: date, natural number → date
* n months later: date, natural number → date
* n months earlier: date, natural number → date
* n years later: date, natural number → date
* n months later: date, natural number → date
* Julian day number to date: integer → date
* how many leap days passed between two dates: date, date → natural number
* how many weekdays between two dates: date, date, day of the week → natural number
* is it easter: date → boolean
* days until next easter: date → natural number
* days since last easter: date → natural number
* day number of the year: date → natural number
* days until the end of the year: date → natural number
* is proleptic: date → boolean
* within Pythons date implementation: date → boolean
* within JavaScript's date implementation: date → boolean
* next time a day of the year is on a specific weekday: date, day of the week → date
* next time a day of the month is on a specific weekday: date, natural number, day of the week → date
* next Friday the 13th: date → date
* first weekday of the month: date, day of the week → date
* last weekday of the month: date, day of the week → date
* nth weekday of the month: date, day of the week, natural number → date
* nth working days after: date, list of wikidata item references (list of holidays) → date
== Morphological functions ==
morphology is the part of linguistics that studies how language parts are 'shaped' and change diachronically and when inflected. Hausa, Igbo, Malayalam, Bangla/Bengali and Dagbani are [[d:Wikidata:Lexicographical data/Focus languages|focus languages]] for Wikidata's lexicographic dataset, which is an important aspect of [[WF:glossary#Abstract Wikipedia|Abstract Wikipedia]].
=== mul - Multiple languages ===
* inputs: natural number (new numeric type) and language Z-number; output: 'singular', 'dual', 'paucal', 'plural', etc. as string
*: {{doing}}: {{Z|15977}}
=== ase - American Sign Language ===
* string: Stokoe to ase-[https://github.com/sutton-signwriting/core Sgnw] and vice-versa (consult {{ping|Slevinski}} as to best approach)
=== bn - Bangla ===
=== cy - Welsh ===
[[w:en:colloquial Welsh morphology]]
=== dag - Dagbani ===
=== de - German ===
* tense * person * number for each verb
** tenses: present, past, ...?
** person: first, second, third
** number: singular, plural
** {{doing}} third person singular present
** second person singular preterite
=== en - English ===
* [[Z11390]] Verb -> agent noun, e.g. "dance"->"dancer"
* Join English morphemes (extends [[Z13254]] to cases like re + en + able + er + s → re-enablers. [[Z13254]] will correctly join re-enable + ers or re- + enablers, but re + enablers → “renablers” (incorrect). [[Z13275]] tests the Reduce function to produce “detoxification” from a list of four morphemes (orchestrator limit exceeded with five). I doubt we’ll want to derive “toxify” from “toxic”, however.
* Derive lemmas from a form. This is envisaged as the converse of Join English morphemes. The focus would be identifying the base form (the lexeme’s lemma) rather than further segmenting the lemma. For example, “underlay” should return “underlie” (for which it is the past participle) and the noun “underlay” (for which it is the lemma) and (perhaps) the verb “underlay”, which might be the tendency of an unproductive hen or the activity of a carpet-fitter. As this is a purely functional converse, every string will have itself as a possible lemma.
* Generate [[:w:Numeral_prefix|Numerical prefixes]] of various kinds from a natural number input.
* {{Z+|Z19499}}
'''<big>eu - Basque</big>'''
* Basque language declension system in rather regular based on suffixes.
** Here a few examples for Basque declension:
*** {{Z+|Z18541}}
*** {{Z+|Z18670}}
**Before implementing all of them, we may propose an overall classification that eases both the implementation and the future usage of the functions. Here a first try based on bibliography from the [https://www.euskaltzaindia.eus/index.php?option=com_ebe&view=bilaketa&task=pdf&Itemid=1161&atala=deklinabide-taulak Basque Language Academy]:
***Personal pronouns: they can be treated as exceptions (e.g. "zuek -> zuei", etc.) together with proper noun declension, or as a separate case.
***Determiners: they can be treated as exceptions (e.g. "hau" -> "honek", etc) together with common noun declension, or as a separated case
***Grammatical cases:
****Absolutive ("Nor"): indefinite, singular and plural
****Ergative ("Nork"): indefinite, singular and plural
****Dative ("Nori"): indefinite, singular and plural
***Place and Time: we must distinguish animate (AN) and inanimate (IN)
****Inessive IN ("Non"): indefinite, singular and plural
****Inessive AN ("Norengan"): indefinite, singular and plural - It could be a composition of "Noren" + "-gan"
****Place and time ("Nongo"): indefinite, singular and plural
****Allative IN ("Nora"): indefinite, singular and plural
****Allative AN ("Norengana"): indefinite, singular and plural - It could be a composition of "Noren/Norengan" + "-gan/-a"
****Finished Allative AN ("Noraino"): indefinite, singular and plural - It could be a composition of "Nora" + "-ino"
****Finished Allative AN ("Norengainaino"): indefinite, singular and plural - It could be a composition of "Noregana" + "-ino"
****Right way Allative IN ("Noratz"): indefinite, singular and plural - It could be a composition of "Nora" + "-ntz"
****Right way Allative AN ("Norenganantz"): indefinite, singular and plural - It could be a composition of "Norengana" + "-ntz"
****Ablative IN ("Nondik"): indefinite, singular and plural
****Ablative AN ("Norengandik"): indefinite, singular and plural
***Rest of the cases:
****Partitive ("Zerik"): indefinite
****Possessive ("Noren"): indefinite, singular and plural
****Sociative ("Norekin"): indefinite, singular and plural
****Instrumental ("Zerez"): indefinite, singular and plural
****Motivative ("Zerengatik"): indefinite, singular and plural
****Destinative ("Norentzat"): indefinite, singular and plural - It could be a composition of "Noren" + "-tzat"
***Special case:
****Prolative ("Nortzat"): indefinite
***To take into consideration:
****Together with animate and inanimate classification, we should also consider if the noun is a proper noun ("izen berezia"). We can identify that automatically (e.g. check if written in Title case, but this may not be always possible like in the beginning of sentences), but a dedicated function may be preferred (or a boolean to the generic function saying it is a proper noun).
****The main distinction is between noun ending by vowel or consonant that can be easily computed
=== fr - French ===
* [[Z11590]] Masculine adjective -> feminine, e.g. "exact"->"exacte"
* Conjugated verb => Infinitive, e.g. "alla" => "aller", "mordit" => "mordre"
=== ha - Hausa ===
A notated demo sentence ("Aishà taa jeefar dà kàren Indoo" ― "Aisha threw away Indo's dog") is available at http://intent.xigt.org
=== ig - Igbo ===
=== ldn - Láadan ===
section moved to [[WF:human languages/Z1882]]
=== ml - Malayalam ===
===kcg - Tyap===
* Tyap has six determiners/definite articles which determine the pronoun, number (1-5), etc. forms used.
** ka & wu (basically for singular nouns and adjectives with a few exceptions)
** hu & ji (for singular and plural nouns and adjectives)
** ba & na (mainly for plural nouns.
*** Determiners come after nouns.
*** When an adjective comes before a noun, the determiner used is that of the adjective. E.g., a̱sham (ka) - (the) beautiful, kyang (hu) - (the) thing = a̱sham kyang (ka) - (the) beautiful thing.
* Tyap has a non-uniform noun class system used for noun pluralization and conversion from one part of speech to another. E.g., a̱bwom (song) and bwom (to sing), a̱fufwuo (ears) and fufwuo (ear).
* Affixation: Prefixes exist but suffixes hardly are found.
== Proposed functions requiring future types ==
'''Note these functions cannot be implemented properly until the needed types are requested and approved.'''
If one wishes to nevertheless attempt to define and implement them,
* the functions and implementations should indicate prominently in their labels that their input/output types must be adjusted once support for the appropriate replacement types become available; ''and''
* the functions should ''not'' be used in the implementations of any other functions, as the later adjustment of input/output types to appropriate replacements will break those implementations.
=== String manipulation functions ===
=== String analysis functions ===
* count distance between two letters in given alphabet (default to 26-charcater western alphabet. case insensitive. e.g. "a" & "A" ⇒ 0; "K" & "N" ⇒ 3)
=== String encoding and decoding functions ===
(would be better with types representing a stream of bytes)
* [[wikidata:Q113486941|BASE45 encode]]
* [[wikidata:Q113486941|BASE45 decode]]
* Hexadecimal UTF-8 encode ("ABC ₤" ⇒ "41 42 43 20 E2 82 A4")
* Hexadecimal UTF-8 decode ("41 42 43 20 E2 82 A4" ⇒ "ABC ₤")
* Decimal UTF-8 encode ("ABC ₤" ⇒ "65 66 67 32 226 130 164")
* Decimal UTF-8 decode ("65 66 67 32 226 130 164" ⇒ "ABC ₤")
* Octal UTF-8 encode ("ABC ₤" ⇒ "101 102 103 40 342 202 244")
* Octal UTF-8 decode ("101 102 103 40 342 202 244" ⇒ "ABC ₤")
* Binary UTF-8 encode ("ABC ₤" ⇒ "01000001 01000010 01000011 00100000 11100010 10000010 10100100")
* Binary UTF-8 decode ("01000001 01000010 01000011 00100000 11100010 10000010 10100100" ⇒ "ABC ₤")
* Unicode code point encode ("ABC ₤" ⇒ "41 42 43 20 20A4") - [[Z10785]]
* Unicode code point decode ("41 42 43 20 20A4" ⇒ "ABC ₤")
* Create regular expression object/string (i.e: "test" & "i" to /test/i)
=== Natural language functions ===
* Choose singular or plural based on number (e.g. singularOrPlural("person",6") -> "people")
** Note that there are also dual and other [[:w:grammatical number|grammatical number]]s in other languages. [[User:魔琴|魔琴]] ([[User talk:魔琴|talk]]) 18:54, 26 October 2023 (UTC)
** relevant interwiki link: [[d:WD:property proposal/plural forms]] [[User:Arlo Barnes|Arlo Barnes]] ([[User talk:Arlo Barnes|talk]]) 04:15, 9 February 2024 (UTC)
=== Cryptographic hash functions ===
(would be better with types representing a stream of bytes)
* {{todo}} [[wikidata:Q47477417|MD2]] - [[Z10135]]
* {{todo}} [[wikidata:Q47462255|MD4]] - [[Z10136]]
* {{todo}} [[wikidata:Q27036232|MD5]] - [[Z10137]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-128]] - [[Z10138]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-160]] - [[Z10139]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-160]] - [[Z10140]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-256]] - [[Z10141]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-384]] - [[Z10142]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-512]] - [[Z10143]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-128]] - [[Z10144]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-160]] - [[Z10145]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-224]] - [[Z10146]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-256]] - [[Z10147]]
* {{todo}} [[wikidata:Q47465971|SHA-224]] - [[Z10149]]
* {{todo}} [[wikidata:Q47465971|HMAC-SHA-256]]
* {{todo}} [[wikidata:Q87486893|SHAKE-128]] - [[Z10150]]
* {{todo}} [[wikidata:Q87486893|SHAKE-256]] - [[Z10151]]
=== Colour functions ===
* return colour contrast ratio (per [https://webaim.org/articles/contrast/]) of two RGB colours (provided as strings e.g. "#FF0000")
=== Date, time, and calendric functions ===
Note: 'time' type not yet supported, use 'string' (or for strictly numeric values, 'natural number')
==== Bengali calendar ====
{{z+|12926}}
==== Chinese calendar ====
==== French Republican Calendar ====
decimalises and secularises the Gregorian
* day names: {{Z+|13006}}{{not done}} '''yet'''
==== Gregorian ====
widely used calendar derived from the Julian, basis for [[xkcd:1179|ISO 8601]]
* date to ISO week number {{q|2110154}}
* string to date
* date to ISO 8601 string
*: {{done}}, see {{z|21842}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 18:47, 21 January 2025 (UTC)
* date to year (yyyy)
* date to month of the year (1-12)
* date to month name (January-December)
* date to day of the month (1-31)
* date to hour of the day (0-23)
* date to minutes (0-59)
* date to seconds (0-59)
Named Day from Date or day of year ; Input type : Date ; Output Type : String. ; The initial use case was automated population of On The Day, based on various collections of Holidays, festival days and observances. ? [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
:So If you gave it 2025-05-01 It said "All Fools Day" etc.. Possibly an additional input of enumrated type to indicate which data set to pull holidays, fesitvals and observances from.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
Diary/calander Header function - Using the above and other date functions, generates a data set from a given date. Hence if you give it 2003-05-01 you get back a JOSN set contianing the {Day of week:String, Day in the Month, Observances} etc. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
==== Holocene calendar ====
* [[w:en:Holocene calendar#Conversion]]
*: {{done}}, see {{z|21913}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 13:30, 25 January 2025 (UTC)
==== Indian national calendar ====
==== Islamic ====
a Lunar calendar, also called Hijri
==== Julian ====
mostly used by astronomers, some historians, and some Orthodox Christian denominations
==== Mesoamerican calendars ====
including civil and clerical forms
==== Persian ====
also called Jalali
==== Thai calendar ====
==== Hebrew calendar ====
==== Darian calendar ====
Proposed time-keeping system for Mars, requires Julian Date/Time to calculate.
=== Basic numerical functions ===
* round up ("1.289" & "2" ⇒ "1.29"; "5678" & "2" ⇒ "5700")
*: So if the number is floating point, round to n decimal places, and if not, round to n significant figures. Is that right? [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 19:36, 24 December 2023 (UTC)
* round down
* return integer value (5678.678 ⇒ 5678)
* {{Z+|Z13587}} (23 ⇒ "twenty-three")
* Convert money from US$ to anything else
** requires source of conversion rates, which is a hole in function-likeness
* Arabic numeral to Etruscan numeral
* Etruscan numeral to Arabic numeral
* floor and ceiling functions, based on defined standards.
=== Data serialization functions ===
* parse a string as [[:en:JSON|JSON]]
* extract string from JSON object based on [[:d:Q121208951|JSONPath]] (<code>{"name":"Alice"}</code>, "$.name" ⇒ "Alice")
*:Why not first convert a JSON string to an object, and then have a function that extracts fields based on JSONPath? Doing Stringly-typed things like this proposal as defined isn't a good idea. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 16:16, 5 August 2023 (UTC)
*::This seems to be a good idea, thanks! I moved and splitted the proposal accordingly. --[[User:1-Byte|1-Byte]] ([[User talk:1-Byte|talk]]) 09:51, 6 August 2023 (UTC)
*:: is it okay to go ahead to create this 'extract string from JSON object based on JSONPath' as a function ? [[User:Dolphyb|Dolphyb]] ([[User talk:Dolphyb|talk]]) 16:14, 15 February 2024 (UTC)
=== Basic list/iterable functions requiring numeric types ===
* Sum the elements of a numeric list - [[Z14038]]
* Product of the elements of a numeric list
* {{Z+|Z12676}}
* Slice of list elements: for the supplied list, return a list of elements that are at indexes between a supplied range n:m
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Remove slice of elements from list: return the supplied list with elements between a supplied range of indexes removed
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Every nth element of list: returns every nth element of the supplied list
* Remove every nth element of list: removes every nth element of the supplied list -
* sample n objects from list (return up to n [[Wikifunctions:Determinism|random]] objects from the list)
* Jaccard similarity coefficient (see https://en.wikipedia.org/wiki/Jaccard_index)
=== Geodetics functions ===
[[w:en:planetary coordinate system]], [[w:en:well-known text representation of coordinate reference systems]]
==== Earth ====
* convert coordinates outside of the ranges (-180, 180) for longitude and (-90, 90) for latitude to a canonical form
==== Mars ====
* convert coordinates outside of the ranges [0, 360) for longitude and (-90, 90) for latitude to a canonical form
=== Unit conversion functions ===
* {{Z+|15560}}
=== Conversion function : 2D Cartesian to 2D Polar ===
Input : matrix [x,y]
Output: matrix [θ,r]
Short text : Polar conversion of x,y to a polar space centred at 0,0 in the Cartesian.
Constraints: x,y,r are reals (float64), θ lies in the range -π<0<π (Sign determined in relation to standards used in STEM applications.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
:The companion could also be provided. As I never did Geodetic functions, I am not sure how Lat, Long to map projection would work , but useful. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
=== Trignometric Functions ===
* sine, cosine,
*: Input : float64 Angle in radians.
*: Output : float64 desired trignometric value
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:40, 26 March 2025 (UTC)
==== Function Proposal : Decimalise angle of the form ('1:x' or '1 in x') to % (in 100) or ‰ (in 1000) ====
*Suggested name: gardient_decimal.
*Input type: Integer ( The 1 is implied.). Lower Bound +1: Upper Bound: 1000 (for most practical situations?)
*Output type: Real/float 64.
Proposer: [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:05, 28 March 2025 (UTC)
===Color Functions===
==== Colorspace Conversion ====
x,y,Y to sRGB (Illuminant D65).
Input : 3tuple of float64,
Output: 3 tuple of integer, where 0>=r<=255, 0>=g<=255 0>=b<=255.
Convert a color specfied as 3 float64 values, from x,y,Y colorspace to sRGB or raise an "Out of Gaumt" exception.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:09, 7 April 2025 (UTC)
==== Spectral Approximate from sRGB or XYZ values. ====
I'd like to see the techniques detailed here: http://scottburns.us/reflectance-curves-from-srgb/ implemented in Wikifunctions as the provided spreadhseet later in the paper doesn't appear to work with Libre Office. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:32, 2 June 2025 (UTC)
==== Subtractive color mix (Pigment style) ====
Implement the mixing function from Spectral.js (https://github.com/rvanwijnen/spectral.js/blob/3.0.0/spectral.js )(MIT license), to allow 2 or more sRGB triplets to be mixed like pigment colors. This is different from the subtract colors function implemented previously.
=== Music Functions ===
It would be nice to have '''12 equal temperament pitch class''' and '''12 equal temperament pitch''' types, as they would be useful for calculating harmonies and melodies. The pitch classes could be stored as natural numbers from 0 to 11, and represented with symbols C, C♯, D, ..., B. The pitches could be stored as integers with -1 being B3, 0 being C4, 1 being C♯4, etc. Over time, we could expand the pitch class and pitch types to other temperaments and just intonation. As I'm new to Wikifunctions and my coding skills are next to zero, this is just a suggestion to the community. (edited) [[User:CaffeineP|CaffeineP]] ([[User talk:CaffeineP|talk]]) 14:48, 9 April 2025 (UTC)
:Yes… There are some notational challenges because of enharmonics as well as naming conventions varying by language/culture, so English A♯ is equivalent to German B and English B♭, for example. Ideally, I would want the (English) pitch class that is five semitones higher than G♭ to be displayed as C♭ rather than B.
:Also, given some reference pitch like A4 = 440 Hz, we should be able to return the frequency in hertz of a given pitch and, conversely, the nearest pitch for a given frequency and its offset in cents (or whatever). The computation is a lot simpler than representing the result (or capturing how the result should be represented)! [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 20:08, 9 April 2025 (UTC)
* '''12-ET Pitch Class of a Pitch''': Return the 12 equal temperament pitch class of a given 12 equal temperament pitch. For example, C4 returns C.
* '''12-ET Pitch based on Pitch Class''': Return a 12 equal temperament pitch based on a given 12 equal temperament pitch class and a given integer. For example, C and 4 return C4.
* '''Interval between 12-ET Pitch Classes in Semitones''': Get the interval in semitones between two 12 equal temperament pitch classes, always assuming that the first is lower than (or the same as) the second, and the interval is less than an octave. For example, C and B return 11, while B and C return 1.
* '''Interval between 12-ET Pitches in Semitones''': Get the interval in semitones between two 12 equal temperament pitches. For example, C4 and B3 return -1, while C3 and B4 return 23.
* '''Raise 12-ET Pitch Class by Semitones''': Get a new 12 equal temperament pitch class through raising a given pitch class by the provided number of semitones. For example, raising B by 1 semitone returns C.
* '''Lower 12-ET Pitch Class by Semitones''': Same as above, but lower the pitch class instead of raising it.
* '''Raise 12-ET Pitch by Semitones''': Get a new 12 equal temperament pitch through raising a given pitch by the provided number of semitones. For example, raising B3 by 1 semitone returns C4.
* '''Lower 12-ET Pitch by Semitones''': Same as above, but lower the pitch instead of raising it.
* '''Frequency of a 12-ET Pitch''': Return a float64 frequency in Hz based on the provided 12 equal temperament pitch (and possibly a reference pitch with its frequency; if not provided, take default A4 = 440 Hz).
* '''Approximate 12-ET Pitch Class based on Frequency''': Return a 12 equal temperament pitch class approximately based on the provided frequency in Hz.
* '''Approximate 12-ET Pitch based on Frequency''': Return a 12 equal temperament pitch approximately based on the provided frequency in Hz.
=== SVG Functions ===
I would be nice to generate SVG (a XML-based vector image format which is basically a long string), it could allow to replace a lot of images on Commons or templates/tools. Here some examples:
* create simple forms,
* create graphs (line graph/bar graph for population or for production, elections diagrams like [[:File:1900Hawaii.svg]], etc.),
* create more complex visualisation like genealogical trees,
* create coat of arms (?),
* etc.
Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 10:47, 23 April 2025 (UTC)
:@[[User:VIGNERON|VIGNERON]]: Eventually that is something we might support, but there'll be nothing any time soon. It has a number of complex security and scalability concerns, sadly. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 13:21, 23 April 2025 (UTC)
::{{ping|Jdforrester (WMF)}} thanks. I talked about it for the last Corner but I wanted to leave a record here, if we have time, maybe I'll use that time to write some things to prepare (like listing templates and tools on the Wikimedia projects that generate SVG or visualisations). Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 15:28, 23 April 2025 (UTC)
:::Of course! I've explicitly added a section on this here: [[Wikifunctions:Embedded function calls#Non-text output]] — hope that helps assure you that we're thinking about it. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 21:40, 23 April 2025 (UTC)
== Object / type / function functions ==
*{{Z+|Z17893}}
*{{Z+|Z21180}}
*{{Z+|Z21182}}
*{{Z+|Z21193}}
== External function lists ==
* [[WF:importing]]
f6f3s6e1i9f9xmnajyhdc71yxzwawds
191284
191283
2025-06-06T12:53:43Z
Dv103
11127
/* Gregorian calendar date */
191284
wikitext
text/x-wiki
Do you have an idea for a new function? Suggest it here! It may help to refer to [[Wikifunctions:Glossary|our glossary]].
You can [https://www.wikifunctions.org/wiki/Special:CreateZObject?zid=Z8 create a function] right away if you have the user-rights.
If a function requires a new type, consider [[WF:TP|proposing it]].
Note that for now '''we only support a limited number of types as input and output types''' of functions. More types are coming in the next few months. For the full list, see [[WF:Type]].
Once created, consider adding new Functions to the [[Wikifunctions:Catalogue|catalogue]]. [[Category:Maintenance]]
== Proposed functions requiring only available types (string, Boolean, Natural number, list) ==
=== String ===
==== String character discard functions ====
* remove stereochemical specificity in [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string, like e/z isomers
** already fulfilled by someone else at: [[Z11815]]
* simplify [[:en:Simplified_molecular-input_line-entry_system|SMILES]] string according to some basic simplifications
** {{Partly done}}, see [[Z19380]]. There's testcases, and I (or someone else) can get around to the coding later. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 10:21, 26 October 2024 (UTC)
*** {{Done}} completely, still at [[Z19380]]. Another user helpfully wrote a python script that passed 1 of my test cases between October and now. I just re-wrote the script to pass all 3 test cases, and also created a JavaScript version. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:43, 10 January 2025 (UTC)
==== String character replacement functions ====
==== String search functions ====
==== String escaping and unescaping functions ====
==== String encoding and decoding functions ====
* Unicode normalising functions (there are several types of normalisation)
* [[wikidata:Q47467628|Backslash-U with delimiters ASCII encoding of Unicode encode]]
** Can someone elaborate on this? No example cases were given on the document, and backslash-U with delimiters is anyway not that prevalent as far as I have seen. [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 15:24, 26 December 2023 (UTC)
** {{Done}}, see [[Z21486]]. I've made 5 test cases (achieving 100% coverage) and implementations in both JavaScript and Python, which passes all test cases. Support for both the Basic Multilingual Plane (BMP) and supplementary characters (using surrogate pairs). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 02:49, 10 January 2025 (UTC)
* [[wikidata:Q47467628|XML and HTML ASCII encoding of Unicode encode]]
** {{Done}}, see [[Z21503]]. Again, I've also made 5 test cases which cover a wide variety of Unicode characters, and implementations in JS and Python (which pass all the tests). As before successful support for both the Basic Multilingual Plane (BMP) and supplementary characters (this time '''not using''' surrogate pairs, as is customary for HTML/XML encoding). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:30, 10 January 2025 (UTC)
* [https://html.spec.whatwg.org/#named-character-references HTML named character encode]
* [[wikidata:Q47466379|Punycode encode]] - [[Z10178]] (part only, not whole url); see also [[Z10185]]
* [[:en:Unified_English_Braille|Unified English Braille encode]] (discarding invalid characters?)
** {{Done}}, see [[Z21514]]. 6 test cases this time, and support for both letters and numbers, with implementations in JS and Python (both passing all the tests). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 06:00, 10 January 2025 (UTC)
==== String presentation functions ====
* add [[:en:Quotation_mark|locale-specific quotation marks]] to string
** Shouldn't the output depend on the locale? See [[mw:Extension:Scribunto/Lua_reference_manual#mw.language:formatNum|mw.language:formatNum]]. —[[User:Dexxor|Dexxor]] ([[User talk:Dexxor|talk]]) 17:15, 4 September 2023 (UTC)
==== String colour notation functions ====
* [[:en:Complementary_colors|complementary colour]] in RGB colour model ("#FF0000" ⇒ "#00FFFF")
** Any specification on invalid inputs? [[User:MilkyDefer|<span style="color:#09C">Milky</span>]][[User talk:MilkyDefer|'''<span style="color:#F09">Defer</span>''']] 11:22, 5 August 2023 (UTC)
*:Great question. I don't think there is a position documented on Wikifunctions for how to handle invalid input to a function. Can we throw exceptions? Return null? [[User:Dhx1|Dhx1]] ([[User talk:Dhx1|talk]]) 13:23, 6 August 2023 (UTC)
*::This shouldn't be a string function. This should be a type that represents a RGB color (with corresponding validation function (hopefully it can just be three unsigned 8bit integers)) and a function that returns the complementary color. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 12:38, 7 August 2023 (UTC)
** Work on the color type has been stalled for over a year. But this task is {{Done}}, I have made [[Z21554]], that uses string hex codes (with or without the initial # and supporting short hex format). This is probably the most optimal format, as I can imagine this function being used on-wiki for thing like the style parameter (CSS) of MediaWiki tags, or of templates etc. There's 5 testcases I've made, which are passed by both my JS and Python versions. :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:39, 11 January 2025 (UTC)
==== String notation validation checks ====
* check if string is an [[:en:International_Chemical_Identifier]]
** {{Partly done}} see [[Z21539]]. Supports the verification of the chemical formula and the stereochemical layer. There are 13 testcaes that I've written, all of which are passed by my JavaScript implementation. Note that a python implementation is not possible as the regex module is not available in Wikifunctions. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
** To do:
*** Needs to verify the hydrogen and connection sections of the main layer
*** Support the charge layer
*** Support the isotopic layer
**[[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 03:09, 11 January 2025 (UTC)
***{{ping|MolecularPilot}} A python impl. is infact possible. I created a basic direct translation at [[Z22823]]. Some tests are failing as the regex needs a bit of sorting out, out of scope for me, but you can give it a try! Keep in mind that you need to escape any \ with a \\ just before saving per [[Wikifunctions:Python_implementations#Known_limitations_as_of_October_2024]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:14, 26 February 2025 (UTC)
* check if string is a [[:en:SMILES_arbitrary_target_specification|SMILES arbitrary target specification (SMARTS) notation]]
* check if string is an [[:en:ABC_notation|ABC notation]]
* check if string is a [[:en:LilyPond|LilyPond notation]]
* {{Doing}} check if string is a [[:en:Portable_Game_Notation|portable game notation]] for a chess game ([[Z15867]], figuring out how to add newlines to the test input)
* [[Z14643]] check if string is [[:en:Forsyth–Edwards Notation|Forsyth–Edwards Notation]] for a chess position
* check if string is a [[:en:UIC_classification_of_locomotive_axle_arrangements|UIC classification of locomotive axle arrangements notation]]
* check if a string is a valid [[:en:ISBN|ISBN]]-13 (probably just a simple variant of [[Z10821]], dropping/validating the hyphens)
** {{Done}} at [[Z23561]]. Note than ISBN-13 starts with only 978/979, a differing factor from EAN. I have added that in the func and tests as well. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 12:53, 26 March 2025 (UTC)
* check if a string is a valid [[:en:Digital_object_identifier|DOI]]
** Something about implementation difficulties: https://stackoverflow.com/questions/27910/finding-a-doi-in-a-document-or-page [[User:Alexander-Mart-Earth|Alexander-Mart-Earth]] ([[User talk:Alexander-Mart-Earth|talk]]) 14:28, 21 December 2023 (UTC)
* check if a string is a valid [[:en:ISWN|ISWN]]
** {{Done}}, see [[Z21562]]. Contains 6 test cases that I made, all of which are passed by my Python and JavaScript implementations. It supports both just numbers, and a string containing the "separator" symbols (like ., - and /). [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 07:32, 11 January 2025 (UTC)
==== String validation checks ====
* {{doing}} check if string is in [[:en:Camel_case|lower camel case]]
* check if string is a valid ISO 3166 country code
* check if string is a valid ISO 8601 date/time (2023-08-03 ⇒ true; 2023-02-30 ⇒ false; 2023-08-03 15:00:00.000 ⇒ true; 2023-08-03 25:00:00.000 ⇒ false)
** {{Done|by=Philipnelson99}} at [[Z14206]]. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:23, 26 February 2025 (UTC)
* check if string is a valid [[:en:ISO_8601#EDTF|EDTF]] date/time
* {{doing}} check if string is a valid email address (watch out, see [https://github.com/kdeldycke/awesome-falsehood#emails this list of falsehoods] about email addresses to create unit tests - email addresses are more complicated than they seem) — [[Z10410]] creating test cases in progress. Currently it is stuck on figuring out what exactly is a valid emaill address. Nearly every errata for [[RFC:3696]] is about that.
* {{doing}} check if string is a valid [[d:Help:Items|Wikidata item]] — [[Z10696]] (possibly stuck on [[phab:T343593]]?)
====String analysis functions====
*Word frequency counting. Provide a list of words and their frequencies.
**{{Done}}, see [[Z21593]]. Providing a list of words and frequencies would require a new type, so instead it requires the sentence and the word you want to count, and returns the occurrences. Hyphenated words are not considered a match of their components, i.e. "fast-forward" is a match of "fast-forward" but nether "fast" nor "forward", I think this is the optimal behaviour but if someone disagrees we can change it. There is a JS implementation that I made which bases all of my 4 test cases. [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 05:41, 12 January 2025 (UTC)
*:@[[User:MolecularPilot|MolecularPilot]] And I have added a Python implementation at [[Z22473]]. I would appreciate if you could attach it! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 08:13, 15 February 2025 (UTC)
*::Cool, thank you so much for doing it! Someone's already beat me to it re attaching it, but great work! :) [[User:MolecularPilot|MolecularPilot]] ([[User talk:MolecularPilot|talk]]) 21:33, 16 February 2025 (UTC)
==== Monolingual text ====
==== String Wikitext operations ====
...
=== Natural number ===
* rectified linear unit (ReLU) - https://www.wikifunctions.org/view/en/Z13909
=== Integer===
* {{Done}} - multiply vectors ([[Z21903]], [[Z20659]])
=== Byte ===
See [[Wikifunctions:Catalogue/Boolean operations#Byte functions|existing Byte functions]] in catalogue.
* next byte without overflow: byte → byte
* previous byte without overflow: byte → byte
* next byte by Gray code: byte → byte
* previous byte by Gray code: byte → byte
* get nth bit as Boolean: byte, natural number → boolean
* highest bit set: byte → boolean
* lowest bit set: byte → boolean
* all bits set: byte → boolean
* no bits set: byte → boolean
* set nth bit: byte, natural number → byte
* clear nth bit: byte, natural number → byte
* switch nth bit: byte, natural number → byte
* add bytes without overflow: byte, byte → byte
* subtract bytes without overflow: byte, byte → byte
* multiply bytes without overflow: byte, byte → byte
* clamped add bytes: byte, byte → byte
* clamped subtract bytes: byte, byte → byte
* clamped multiply bytes: byte, byte → byte
* add bytes with overflow: byte, byte → byte
* subtract bytes with overflow: byte, byte → byte
* multiply bytes with overflow: byte, byte → byte
* modulo bytes: byte, byte → byte
* byte division: byte, byte → byte
* reverse: byte → byte
* right shift: byte → byte
* left shift: byte → byte
* right shift by n: byte, natural number → byte
* left shift by n: byte, natural number → byte
* right shift as ring: byte → byte
* left shift as ring: byte → byte
* right shift by n as ring: byte, natural number → byte
* left shift by n as ring: byte, natural number → byte
* how many bits set: byte → natural number
=== Unicode code point ===
See [[Wikifunctions:Catalogue/Character operations#Unicode code points|existing code point functions in catalogue]].
* Codepoint to list of bytes for UTF-8
* Codepoint to list of bytes for UTF-16
* Codepoint to list of bytes for UTF-32
===Object===
=== List ===
==== Basic list/iterable functions ====
* group
* [[w:Circular shift]]
==== Complex list functions ====
* zip lists together: for [ A .. Z ] and [ 1 .. 26 ] return [ [ A, 1 ], [ B, 2 ], .. ]
** Unsure what happens if input lists are of different lengths.
** If possible this function should be able to zip more than 2 lists together... 3, 4, n? Perhaps the input should be list(list, list, list, list, ..).
*{{Z+|Z19198}}
==== CSV list operations ====
* list of strings to csv
: number -> list of decimal digits<br>number -> list of binary digits<br>number -> list of digits in base provided [[User:Well very well|Well very well]] ([[User talk:Well very well|talk]]) 11:20, 18 May 2024 (UTC)
=== Functions with functions as arguments ===
* sort, by a given function
* test whether certain functions have specific properties of [[:w:Homogeneous_relation|homogeneous relations]] for particular lists/sets
* remove first element matching filter from list
=== Biology ===
==== Taxon functions ====
* Wikidata item representing taxon rank ({{Q|P31}} {{Q|Q427626}}) is at genus level or below
** Should(?) be possible with the current Wikidata functionality, from what I understand. See [[:Wikifunctions:Project chat#Taxon rank function(s)]] for a more detailed explanation. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 23:27, 16 May 2025 (UTC)
=== Gregorian calendar date ===
See [[Wikifunctions:Catalogue/Date operations#Gregorian calendar dates|catalogue of calendar date functions]] for existing functions.
* Create a reading function for Dagbani that handles all the possible formats (both the English-linke and the traditional ones, both the Gregorian and the Hijra calendars). [https://docs.google.com/document/d/1u7-ZeY7NHt75JICUPAYky3-7KgkvauD_W3fBjmvpFO0/edit?tab=t.0#heading=h.gf6hp9o3gi0j] [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 15:43, 31 May 2025 (UTC)
* year from date: date → year
* era from date: date → era
* before / sooner / earlier: date, date → boolean
* after / later: date, date → boolean
* same month: date, date → boolean
* same day of the month: date, date → boolean
* same day of the year: date, date → boolean
* same calendar year: date, date → boolean
* same day of the week: date, date → boolean
* within a year: date, date → boolean
* within a week: date, date → boolean
* within n days: date, date → boolean
* {{Z+|Z24918}}
* months between: date, date → natural number
* weeks between: date, date → natural number
* previous day: date → date
* n days later: date, natural number → date
* n days earlier: date, natural number → date
* n weeks later: date, natural number → date
* n weeks earlier: date, natural number → date
* n months later: date, natural number → date
* n months earlier: date, natural number → date
* n years later: date, natural number → date
* n months later: date, natural number → date
* Julian day number to date: integer → date
* how many leap days passed between two dates: date, date → natural number
* how many weekdays between two dates: date, date, day of the week → natural number
* is it easter: date → boolean
* days until next easter: date → natural number
* days since last easter: date → natural number
* day number of the year: date → natural number
* days until the end of the year: date → natural number
* is proleptic: date → boolean
* within Pythons date implementation: date → boolean
* within JavaScript's date implementation: date → boolean
* next time a day of the year is on a specific weekday: date, day of the week → date
* next time a day of the month is on a specific weekday: date, natural number, day of the week → date
* next Friday the 13th: date → date
* first weekday of the month: date, day of the week → date
* last weekday of the month: date, day of the week → date
* nth weekday of the month: date, day of the week, natural number → date
* nth working days after: date, list of wikidata item references (list of holidays), wikidata item reference (place) → date
== Morphological functions ==
morphology is the part of linguistics that studies how language parts are 'shaped' and change diachronically and when inflected. Hausa, Igbo, Malayalam, Bangla/Bengali and Dagbani are [[d:Wikidata:Lexicographical data/Focus languages|focus languages]] for Wikidata's lexicographic dataset, which is an important aspect of [[WF:glossary#Abstract Wikipedia|Abstract Wikipedia]].
=== mul - Multiple languages ===
* inputs: natural number (new numeric type) and language Z-number; output: 'singular', 'dual', 'paucal', 'plural', etc. as string
*: {{doing}}: {{Z|15977}}
=== ase - American Sign Language ===
* string: Stokoe to ase-[https://github.com/sutton-signwriting/core Sgnw] and vice-versa (consult {{ping|Slevinski}} as to best approach)
=== bn - Bangla ===
=== cy - Welsh ===
[[w:en:colloquial Welsh morphology]]
=== dag - Dagbani ===
=== de - German ===
* tense * person * number for each verb
** tenses: present, past, ...?
** person: first, second, third
** number: singular, plural
** {{doing}} third person singular present
** second person singular preterite
=== en - English ===
* [[Z11390]] Verb -> agent noun, e.g. "dance"->"dancer"
* Join English morphemes (extends [[Z13254]] to cases like re + en + able + er + s → re-enablers. [[Z13254]] will correctly join re-enable + ers or re- + enablers, but re + enablers → “renablers” (incorrect). [[Z13275]] tests the Reduce function to produce “detoxification” from a list of four morphemes (orchestrator limit exceeded with five). I doubt we’ll want to derive “toxify” from “toxic”, however.
* Derive lemmas from a form. This is envisaged as the converse of Join English morphemes. The focus would be identifying the base form (the lexeme’s lemma) rather than further segmenting the lemma. For example, “underlay” should return “underlie” (for which it is the past participle) and the noun “underlay” (for which it is the lemma) and (perhaps) the verb “underlay”, which might be the tendency of an unproductive hen or the activity of a carpet-fitter. As this is a purely functional converse, every string will have itself as a possible lemma.
* Generate [[:w:Numeral_prefix|Numerical prefixes]] of various kinds from a natural number input.
* {{Z+|Z19499}}
'''<big>eu - Basque</big>'''
* Basque language declension system in rather regular based on suffixes.
** Here a few examples for Basque declension:
*** {{Z+|Z18541}}
*** {{Z+|Z18670}}
**Before implementing all of them, we may propose an overall classification that eases both the implementation and the future usage of the functions. Here a first try based on bibliography from the [https://www.euskaltzaindia.eus/index.php?option=com_ebe&view=bilaketa&task=pdf&Itemid=1161&atala=deklinabide-taulak Basque Language Academy]:
***Personal pronouns: they can be treated as exceptions (e.g. "zuek -> zuei", etc.) together with proper noun declension, or as a separate case.
***Determiners: they can be treated as exceptions (e.g. "hau" -> "honek", etc) together with common noun declension, or as a separated case
***Grammatical cases:
****Absolutive ("Nor"): indefinite, singular and plural
****Ergative ("Nork"): indefinite, singular and plural
****Dative ("Nori"): indefinite, singular and plural
***Place and Time: we must distinguish animate (AN) and inanimate (IN)
****Inessive IN ("Non"): indefinite, singular and plural
****Inessive AN ("Norengan"): indefinite, singular and plural - It could be a composition of "Noren" + "-gan"
****Place and time ("Nongo"): indefinite, singular and plural
****Allative IN ("Nora"): indefinite, singular and plural
****Allative AN ("Norengana"): indefinite, singular and plural - It could be a composition of "Noren/Norengan" + "-gan/-a"
****Finished Allative AN ("Noraino"): indefinite, singular and plural - It could be a composition of "Nora" + "-ino"
****Finished Allative AN ("Norengainaino"): indefinite, singular and plural - It could be a composition of "Noregana" + "-ino"
****Right way Allative IN ("Noratz"): indefinite, singular and plural - It could be a composition of "Nora" + "-ntz"
****Right way Allative AN ("Norenganantz"): indefinite, singular and plural - It could be a composition of "Norengana" + "-ntz"
****Ablative IN ("Nondik"): indefinite, singular and plural
****Ablative AN ("Norengandik"): indefinite, singular and plural
***Rest of the cases:
****Partitive ("Zerik"): indefinite
****Possessive ("Noren"): indefinite, singular and plural
****Sociative ("Norekin"): indefinite, singular and plural
****Instrumental ("Zerez"): indefinite, singular and plural
****Motivative ("Zerengatik"): indefinite, singular and plural
****Destinative ("Norentzat"): indefinite, singular and plural - It could be a composition of "Noren" + "-tzat"
***Special case:
****Prolative ("Nortzat"): indefinite
***To take into consideration:
****Together with animate and inanimate classification, we should also consider if the noun is a proper noun ("izen berezia"). We can identify that automatically (e.g. check if written in Title case, but this may not be always possible like in the beginning of sentences), but a dedicated function may be preferred (or a boolean to the generic function saying it is a proper noun).
****The main distinction is between noun ending by vowel or consonant that can be easily computed
=== fr - French ===
* [[Z11590]] Masculine adjective -> feminine, e.g. "exact"->"exacte"
* Conjugated verb => Infinitive, e.g. "alla" => "aller", "mordit" => "mordre"
=== ha - Hausa ===
A notated demo sentence ("Aishà taa jeefar dà kàren Indoo" ― "Aisha threw away Indo's dog") is available at http://intent.xigt.org
=== ig - Igbo ===
=== ldn - Láadan ===
section moved to [[WF:human languages/Z1882]]
=== ml - Malayalam ===
===kcg - Tyap===
* Tyap has six determiners/definite articles which determine the pronoun, number (1-5), etc. forms used.
** ka & wu (basically for singular nouns and adjectives with a few exceptions)
** hu & ji (for singular and plural nouns and adjectives)
** ba & na (mainly for plural nouns.
*** Determiners come after nouns.
*** When an adjective comes before a noun, the determiner used is that of the adjective. E.g., a̱sham (ka) - (the) beautiful, kyang (hu) - (the) thing = a̱sham kyang (ka) - (the) beautiful thing.
* Tyap has a non-uniform noun class system used for noun pluralization and conversion from one part of speech to another. E.g., a̱bwom (song) and bwom (to sing), a̱fufwuo (ears) and fufwuo (ear).
* Affixation: Prefixes exist but suffixes hardly are found.
== Proposed functions requiring future types ==
'''Note these functions cannot be implemented properly until the needed types are requested and approved.'''
If one wishes to nevertheless attempt to define and implement them,
* the functions and implementations should indicate prominently in their labels that their input/output types must be adjusted once support for the appropriate replacement types become available; ''and''
* the functions should ''not'' be used in the implementations of any other functions, as the later adjustment of input/output types to appropriate replacements will break those implementations.
=== String manipulation functions ===
=== String analysis functions ===
* count distance between two letters in given alphabet (default to 26-charcater western alphabet. case insensitive. e.g. "a" & "A" ⇒ 0; "K" & "N" ⇒ 3)
=== String encoding and decoding functions ===
(would be better with types representing a stream of bytes)
* [[wikidata:Q113486941|BASE45 encode]]
* [[wikidata:Q113486941|BASE45 decode]]
* Hexadecimal UTF-8 encode ("ABC ₤" ⇒ "41 42 43 20 E2 82 A4")
* Hexadecimal UTF-8 decode ("41 42 43 20 E2 82 A4" ⇒ "ABC ₤")
* Decimal UTF-8 encode ("ABC ₤" ⇒ "65 66 67 32 226 130 164")
* Decimal UTF-8 decode ("65 66 67 32 226 130 164" ⇒ "ABC ₤")
* Octal UTF-8 encode ("ABC ₤" ⇒ "101 102 103 40 342 202 244")
* Octal UTF-8 decode ("101 102 103 40 342 202 244" ⇒ "ABC ₤")
* Binary UTF-8 encode ("ABC ₤" ⇒ "01000001 01000010 01000011 00100000 11100010 10000010 10100100")
* Binary UTF-8 decode ("01000001 01000010 01000011 00100000 11100010 10000010 10100100" ⇒ "ABC ₤")
* Unicode code point encode ("ABC ₤" ⇒ "41 42 43 20 20A4") - [[Z10785]]
* Unicode code point decode ("41 42 43 20 20A4" ⇒ "ABC ₤")
* Create regular expression object/string (i.e: "test" & "i" to /test/i)
=== Natural language functions ===
* Choose singular or plural based on number (e.g. singularOrPlural("person",6") -> "people")
** Note that there are also dual and other [[:w:grammatical number|grammatical number]]s in other languages. [[User:魔琴|魔琴]] ([[User talk:魔琴|talk]]) 18:54, 26 October 2023 (UTC)
** relevant interwiki link: [[d:WD:property proposal/plural forms]] [[User:Arlo Barnes|Arlo Barnes]] ([[User talk:Arlo Barnes|talk]]) 04:15, 9 February 2024 (UTC)
=== Cryptographic hash functions ===
(would be better with types representing a stream of bytes)
* {{todo}} [[wikidata:Q47477417|MD2]] - [[Z10135]]
* {{todo}} [[wikidata:Q47462255|MD4]] - [[Z10136]]
* {{todo}} [[wikidata:Q27036232|MD5]] - [[Z10137]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-128]] - [[Z10138]]
* {{todo}} [[wikidata:Q47208127|RIPEMD-160]] - [[Z10139]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-160]] - [[Z10140]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-256]] - [[Z10141]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-384]] - [[Z10142]]
* {{todo}} [[wikidata:Q47463469|BLAKE2b-512]] - [[Z10143]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-128]] - [[Z10144]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-160]] - [[Z10145]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-224]] - [[Z10146]]
* {{todo}} [[wikidata:Q47463469|BLAKE2s-256]] - [[Z10147]]
* {{todo}} [[wikidata:Q47465971|SHA-224]] - [[Z10149]]
* {{todo}} [[wikidata:Q47465971|HMAC-SHA-256]]
* {{todo}} [[wikidata:Q87486893|SHAKE-128]] - [[Z10150]]
* {{todo}} [[wikidata:Q87486893|SHAKE-256]] - [[Z10151]]
=== Colour functions ===
* return colour contrast ratio (per [https://webaim.org/articles/contrast/]) of two RGB colours (provided as strings e.g. "#FF0000")
=== Date, time, and calendric functions ===
Note: 'time' type not yet supported, use 'string' (or for strictly numeric values, 'natural number')
==== Bengali calendar ====
{{z+|12926}}
==== Chinese calendar ====
==== French Republican Calendar ====
decimalises and secularises the Gregorian
* day names: {{Z+|13006}}{{not done}} '''yet'''
==== Gregorian ====
widely used calendar derived from the Julian, basis for [[xkcd:1179|ISO 8601]]
* date to ISO week number {{q|2110154}}
* string to date
* date to ISO 8601 string
*: {{done}}, see {{z|21842}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 18:47, 21 January 2025 (UTC)
* date to year (yyyy)
* date to month of the year (1-12)
* date to month name (January-December)
* date to day of the month (1-31)
* date to hour of the day (0-23)
* date to minutes (0-59)
* date to seconds (0-59)
Named Day from Date or day of year ; Input type : Date ; Output Type : String. ; The initial use case was automated population of On The Day, based on various collections of Holidays, festival days and observances. ? [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
:So If you gave it 2025-05-01 It said "All Fools Day" etc.. Possibly an additional input of enumrated type to indicate which data set to pull holidays, fesitvals and observances from.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
Diary/calander Header function - Using the above and other date functions, generates a data set from a given date. Hence if you give it 2003-05-01 you get back a JOSN set contianing the {Day of week:String, Day in the Month, Observances} etc. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:35, 26 March 2025 (UTC)
==== Holocene calendar ====
* [[w:en:Holocene calendar#Conversion]]
*: {{done}}, see {{z|21913}}. --[[User:Sbb1413|Sbb1413]] ([[User talk:Sbb1413|talk]]) 13:30, 25 January 2025 (UTC)
==== Indian national calendar ====
==== Islamic ====
a Lunar calendar, also called Hijri
==== Julian ====
mostly used by astronomers, some historians, and some Orthodox Christian denominations
==== Mesoamerican calendars ====
including civil and clerical forms
==== Persian ====
also called Jalali
==== Thai calendar ====
==== Hebrew calendar ====
==== Darian calendar ====
Proposed time-keeping system for Mars, requires Julian Date/Time to calculate.
=== Basic numerical functions ===
* round up ("1.289" & "2" ⇒ "1.29"; "5678" & "2" ⇒ "5700")
*: So if the number is floating point, round to n decimal places, and if not, round to n significant figures. Is that right? [[User:BrightSunMan|BrightSunMan]] ([[User talk:BrightSunMan|talk]]) 19:36, 24 December 2023 (UTC)
* round down
* return integer value (5678.678 ⇒ 5678)
* {{Z+|Z13587}} (23 ⇒ "twenty-three")
* Convert money from US$ to anything else
** requires source of conversion rates, which is a hole in function-likeness
* Arabic numeral to Etruscan numeral
* Etruscan numeral to Arabic numeral
* floor and ceiling functions, based on defined standards.
=== Data serialization functions ===
* parse a string as [[:en:JSON|JSON]]
* extract string from JSON object based on [[:d:Q121208951|JSONPath]] (<code>{"name":"Alice"}</code>, "$.name" ⇒ "Alice")
*:Why not first convert a JSON string to an object, and then have a function that extracts fields based on JSONPath? Doing Stringly-typed things like this proposal as defined isn't a good idea. [[User:0xDeadbeef|0xDeadbeef]] ([[User talk:0xDeadbeef|talk]]) 16:16, 5 August 2023 (UTC)
*::This seems to be a good idea, thanks! I moved and splitted the proposal accordingly. --[[User:1-Byte|1-Byte]] ([[User talk:1-Byte|talk]]) 09:51, 6 August 2023 (UTC)
*:: is it okay to go ahead to create this 'extract string from JSON object based on JSONPath' as a function ? [[User:Dolphyb|Dolphyb]] ([[User talk:Dolphyb|talk]]) 16:14, 15 February 2024 (UTC)
=== Basic list/iterable functions requiring numeric types ===
* Sum the elements of a numeric list - [[Z14038]]
* Product of the elements of a numeric list
* {{Z+|Z12676}}
* Slice of list elements: for the supplied list, return a list of elements that are at indexes between a supplied range n:m
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Remove slice of elements from list: return the supplied list with elements between a supplied range of indexes removed
** Zero indexing is used (first element is index 0)?
** n and m are are included in the range?
** What happens if n and/or m are invalid indexes?
* Every nth element of list: returns every nth element of the supplied list
* Remove every nth element of list: removes every nth element of the supplied list -
* sample n objects from list (return up to n [[Wikifunctions:Determinism|random]] objects from the list)
* Jaccard similarity coefficient (see https://en.wikipedia.org/wiki/Jaccard_index)
=== Geodetics functions ===
[[w:en:planetary coordinate system]], [[w:en:well-known text representation of coordinate reference systems]]
==== Earth ====
* convert coordinates outside of the ranges (-180, 180) for longitude and (-90, 90) for latitude to a canonical form
==== Mars ====
* convert coordinates outside of the ranges [0, 360) for longitude and (-90, 90) for latitude to a canonical form
=== Unit conversion functions ===
* {{Z+|15560}}
=== Conversion function : 2D Cartesian to 2D Polar ===
Input : matrix [x,y]
Output: matrix [θ,r]
Short text : Polar conversion of x,y to a polar space centred at 0,0 in the Cartesian.
Constraints: x,y,r are reals (float64), θ lies in the range -π<0<π (Sign determined in relation to standards used in STEM applications.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
:The companion could also be provided. As I never did Geodetic functions, I am not sure how Lat, Long to map projection would work , but useful. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 14:30, 26 March 2025 (UTC)
=== Trignometric Functions ===
* sine, cosine,
*: Input : float64 Angle in radians.
*: Output : float64 desired trignometric value
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:40, 26 March 2025 (UTC)
==== Function Proposal : Decimalise angle of the form ('1:x' or '1 in x') to % (in 100) or ‰ (in 1000) ====
*Suggested name: gardient_decimal.
*Input type: Integer ( The 1 is implied.). Lower Bound +1: Upper Bound: 1000 (for most practical situations?)
*Output type: Real/float 64.
Proposer: [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:05, 28 March 2025 (UTC)
===Color Functions===
==== Colorspace Conversion ====
x,y,Y to sRGB (Illuminant D65).
Input : 3tuple of float64,
Output: 3 tuple of integer, where 0>=r<=255, 0>=g<=255 0>=b<=255.
Convert a color specfied as 3 float64 values, from x,y,Y colorspace to sRGB or raise an "Out of Gaumt" exception.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:09, 7 April 2025 (UTC)
==== Spectral Approximate from sRGB or XYZ values. ====
I'd like to see the techniques detailed here: http://scottburns.us/reflectance-curves-from-srgb/ implemented in Wikifunctions as the provided spreadhseet later in the paper doesn't appear to work with Libre Office. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 19:32, 2 June 2025 (UTC)
==== Subtractive color mix (Pigment style) ====
Implement the mixing function from Spectral.js (https://github.com/rvanwijnen/spectral.js/blob/3.0.0/spectral.js )(MIT license), to allow 2 or more sRGB triplets to be mixed like pigment colors. This is different from the subtract colors function implemented previously.
=== Music Functions ===
It would be nice to have '''12 equal temperament pitch class''' and '''12 equal temperament pitch''' types, as they would be useful for calculating harmonies and melodies. The pitch classes could be stored as natural numbers from 0 to 11, and represented with symbols C, C♯, D, ..., B. The pitches could be stored as integers with -1 being B3, 0 being C4, 1 being C♯4, etc. Over time, we could expand the pitch class and pitch types to other temperaments and just intonation. As I'm new to Wikifunctions and my coding skills are next to zero, this is just a suggestion to the community. (edited) [[User:CaffeineP|CaffeineP]] ([[User talk:CaffeineP|talk]]) 14:48, 9 April 2025 (UTC)
:Yes… There are some notational challenges because of enharmonics as well as naming conventions varying by language/culture, so English A♯ is equivalent to German B and English B♭, for example. Ideally, I would want the (English) pitch class that is five semitones higher than G♭ to be displayed as C♭ rather than B.
:Also, given some reference pitch like A4 = 440 Hz, we should be able to return the frequency in hertz of a given pitch and, conversely, the nearest pitch for a given frequency and its offset in cents (or whatever). The computation is a lot simpler than representing the result (or capturing how the result should be represented)! [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 20:08, 9 April 2025 (UTC)
* '''12-ET Pitch Class of a Pitch''': Return the 12 equal temperament pitch class of a given 12 equal temperament pitch. For example, C4 returns C.
* '''12-ET Pitch based on Pitch Class''': Return a 12 equal temperament pitch based on a given 12 equal temperament pitch class and a given integer. For example, C and 4 return C4.
* '''Interval between 12-ET Pitch Classes in Semitones''': Get the interval in semitones between two 12 equal temperament pitch classes, always assuming that the first is lower than (or the same as) the second, and the interval is less than an octave. For example, C and B return 11, while B and C return 1.
* '''Interval between 12-ET Pitches in Semitones''': Get the interval in semitones between two 12 equal temperament pitches. For example, C4 and B3 return -1, while C3 and B4 return 23.
* '''Raise 12-ET Pitch Class by Semitones''': Get a new 12 equal temperament pitch class through raising a given pitch class by the provided number of semitones. For example, raising B by 1 semitone returns C.
* '''Lower 12-ET Pitch Class by Semitones''': Same as above, but lower the pitch class instead of raising it.
* '''Raise 12-ET Pitch by Semitones''': Get a new 12 equal temperament pitch through raising a given pitch by the provided number of semitones. For example, raising B3 by 1 semitone returns C4.
* '''Lower 12-ET Pitch by Semitones''': Same as above, but lower the pitch instead of raising it.
* '''Frequency of a 12-ET Pitch''': Return a float64 frequency in Hz based on the provided 12 equal temperament pitch (and possibly a reference pitch with its frequency; if not provided, take default A4 = 440 Hz).
* '''Approximate 12-ET Pitch Class based on Frequency''': Return a 12 equal temperament pitch class approximately based on the provided frequency in Hz.
* '''Approximate 12-ET Pitch based on Frequency''': Return a 12 equal temperament pitch approximately based on the provided frequency in Hz.
=== SVG Functions ===
I would be nice to generate SVG (a XML-based vector image format which is basically a long string), it could allow to replace a lot of images on Commons or templates/tools. Here some examples:
* create simple forms,
* create graphs (line graph/bar graph for population or for production, elections diagrams like [[:File:1900Hawaii.svg]], etc.),
* create more complex visualisation like genealogical trees,
* create coat of arms (?),
* etc.
Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 10:47, 23 April 2025 (UTC)
:@[[User:VIGNERON|VIGNERON]]: Eventually that is something we might support, but there'll be nothing any time soon. It has a number of complex security and scalability concerns, sadly. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 13:21, 23 April 2025 (UTC)
::{{ping|Jdforrester (WMF)}} thanks. I talked about it for the last Corner but I wanted to leave a record here, if we have time, maybe I'll use that time to write some things to prepare (like listing templates and tools on the Wikimedia projects that generate SVG or visualisations). Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 15:28, 23 April 2025 (UTC)
:::Of course! I've explicitly added a section on this here: [[Wikifunctions:Embedded function calls#Non-text output]] — hope that helps assure you that we're thinking about it. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 21:40, 23 April 2025 (UTC)
== Object / type / function functions ==
*{{Z+|Z17893}}
*{{Z+|Z21180}}
*{{Z+|Z21182}}
*{{Z+|Z21193}}
== External function lists ==
* [[WF:importing]]
i43b39ap351a15fjji5kopatmzmwr4k
Wikifunctions:FAQ
4
1181
191345
146069
2025-06-07T04:43:37Z
Quiddity
83
fix space causing a </tvar> to show
191345
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<translate><!--T:1-->
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[<tvar name="1">Wikifunctions talk:FAQ</tvar>|talk page]], if your question is not listed here!
<!--T:55-->
Also, please consider our [[<tvar name="1">:m:Special:MyLanguage/Abstract Wikipedia/FAQ</tvar>|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.</translate>
__TOC__
<translate>
== Introduction == <!--T:2-->
=== What is this project about? === <!--T:3-->
<!--T:4-->
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
=== What is a function? === <!--T:5-->
<!--T:6-->
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
<!--T:7-->
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[<tvar name="1">:w:en:Template:Convert</tvar>|Template:Convert]] and [[<tvar name="2">:w:en:Template:Age</tvar>|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
=== What is an implementation? === <!--T:8-->
<!--T:9-->
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
=== What is a test? === <!--T:10-->
<!--T:11-->
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
<!--T:12-->
For example, testers for a “title case” function might include: “<tvar name="1"><span dir="ltr" lang="en">abc</span></tvar>” should become “<tvar name="2"><span dir="ltr" lang="en">Abc</span></tvar>”; “<tvar name="3"><span dir="ltr" lang="en">war and peace</span></tvar>” should become “<tvar name="4"><span dir="ltr" lang="en">War and Peace</span></tvar>”; “<tvar name="5"><span dir="ltr" lang="ru">война и мир</span></tvar>” should become “<tvar name="6"><span dir="ltr" lang="ru">Война и мир</span></tvar>”; and “<tvar name="7"><span dir="ltr" lang="en">123</span></tvar>” should remain “<tvar name="8"><span dir="ltr" lang="en">123</span></tvar>”.
=== Which features are available now, which will be soon available, and which are further away? === <!--T:13-->
</translate>
* <translate><!--T:14--> At launch:</translate>
** <translate><!--T:15--> We have the ability to have functions that work with Strings and Booleans.</translate>
** <translate><!--T:16--> Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</translate>
* <translate><!--T:17--> [[<tvar name="1">Wikifunctions:Status</tvar>|Ongoing development]]:</translate>
** <translate><!--T:18--> Generic types and generic functions are not fully supported.</translate>
** <translate><!--T:19--> Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</translate>
*** <translate><!--T:20--> One particularly interesting type will be binary data, and particularly files.</translate>
** <translate><!--T:21--> We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</translate>
** <translate><!--T:22--> Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</translate>
* <translate><!--T:23--> In the future:</translate>
** <translate><!--T:24--> It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</translate>
** <translate><!--T:25--> It will be possible to use data from Wikidata in functions.</translate>
** <translate><!--T:26--> It will be possible to call data sets from Commons Data namespace.</translate>
<translate>
=== How is Wikifunctions multilingual? === <!--T:56-->
<!--T:57-->
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:</translate>
* <translate><!--T:58--> '''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [<tvar name="1">https://www.wikifunctions.org/view/en/Z10000</tvar> English], [<tvar name="2">https://www.wikifunctions.org/view/pl/Z10000</tvar> Polish], and [<tvar name="3">https://www.wikifunctions.org/view/he/Z10000</tvar> Hebrew], and it is available in many more languages.</translate>
* <translate><!--T:59--> '''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [<tvar name="1">https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de</tvar> German], [<tvar name="2">https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en</tvar> English], or any other of about 300 languages.</translate>
* <translate><!--T:60--> '''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[<tvar name="1">Wikifunctions:Catalogue#Breton</tvar>|Breton]], [[<tvar name="2">Wikifunctions:Catalogue#Rohingya</tvar>|Rohingya]], [[<tvar name="3">Wikifunctions:Catalogue#English</tvar>|English]], and many other languages.</translate>
* <translate><!--T:61--> '''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[<tvar name="1">Z10000</tvar>|join function]] is implemented in both [[<tvar name="2">Z10005</tvar>|JavaScript]] and [[<tvar name="3">Z10004</tvar>|Python]].</translate>
<translate>
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? === <!--T:62-->
<!--T:63-->
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
=== How will Wikifunctions be integrated into other projects? === <!--T:27-->
<!--T:28-->
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
<!--T:29-->
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
<!--T:30-->
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
=== What Wikifunctions is not? === <!--T:31-->
<!--T:32-->
Please, see [[<tvar name="1">Special:MyLanguage/Wikifunctions:What Wikifunctions is not</tvar>|Wikifunctions:What Wikifunctions is not]] for more information on that.
=== What license will the functions and derived content be under? === <!--T:33-->
<!--T:34-->
Per the discussion happened [[<tvar name="1">:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion</tvar>|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</translate>
* <translate><!--T:35--> [[<tvar name="1">Special:MyLanguage/Wikifunctions:Glossary#Content</tvar>|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</translate>
* <translate><!--T:36--> [[<tvar name="1">Special:MyLanguage/Wikifunctions:Glossary#Function</tvar>|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</translate>
* <translate><!--T:37--> [[<tvar name="1">Special:MyLanguage/Wikifunctions:Glossary#Implementation</tvar>|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</translate>
* <translate><!--T:38--> [[<tvar name="1">Special:MyLanguage/Wikifunctions:Glossary#Content</tvar>|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</translate>
<translate>
<!--T:39-->
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
== Contributing == <!--T:40-->
=== I'm new here. What is there for me to do and how can I help? === <!--T:41-->
<!--T:42-->
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
=== How do I create a new function, implementation, or test? === <!--T:43-->
<!--T:44-->
To see how to create a new function, implementation, or test, see [[<tvar name="1">Special:MyLanguage/Wikifunctions:Introduction</tvar>|Wikifunctions:Introduction]].
<!--T:45-->
To see in more detail how to create an implementation, see [[<tvar name="1">Special:MyLanguage/Wikifunctions:How to create implementations</tvar>|Wikifunctions:How to create implementations]].
=== What should I edit first? === <!--T:46-->
<!--T:47-->
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page <tvar name="1">[[Special:ListMissingLabels]]</tvar>, and help to add them.
<!--T:48-->
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[<tvar name="1">Wikifunctions:Suggest a new function</tvar>|suggesting new functions]] and present your ideas.
<!--T:49-->
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
=== Where can I go for help? === <!--T:50-->
<!--T:51-->
Your first stop should be the [[<tvar name="1">Special:MyLanguage/Help:Contents</tvar>|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[<tvar name="2">Wikifunctions:Project chat</tvar>|Project chat]], and someone will answer your question.
=== How do we sort or categorize functions? === <!--T:52-->
</translate>
{{Tracked|T285424}}
<translate>
<!--T:54-->
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</translate>
[[Category:FAQ| {{#translation:}}]]
ng22w60jxnvjamn80ttkajuk1neung0
Wikifunctions:Project chat
4
1184
191342
191263
2025-06-07T03:08:09Z
SpBot
978
archive 1 section: 1 to [[Wikifunctions:Project chat/Archive/2025/05]] (after section [[Wikifunctions:Project chat/Archive/2025/05#Problems_with_evaluations:_fixes_are_coming|Problems_with_evaluations:_fixes_are_coming]]) - previous edit: [[:User:ShakespeareFan00|ShakespeareFan00]], 2025-06-06 11:22
191342
wikitext
text/x-wiki
{{shortcut|[[WF:CHAT]]}}
__NEWSECTIONLINK__
[[Category:Help]] <!-- please do not remove this line -->
Welcome to the Project chat, a place to discuss any and all aspects of Wikifunctions: the project itself, policy and proposals, individual data items, technical issues, etc.
Other places to find help:
* [[Wikifunctions:Administrators' noticeboard]]
* [[Wikifunctions:Report a technical problem]]
* [[Wikifunctions:FAQ]]
{{Autoarchive resolved section
|age = 1
|archive = ((FULLPAGENAME))/Archive/((year))/((month:##))
|timeout=30
}}
{{Archives|{{Special:PrefixIndex/WF:Project chat/Archive/|stripprefix=1}}}}
== proposed Reader and Display functions for Byte Type ==
I suggest we use the following functions as a reader and display function for the Byte Type:
* {{Z|Z22866}}
* {{Z|Z22887}}
Feel free to add an implementation to either with a language configuration if you would like to convert to a different numeral script. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 05:40, 27 February 2025 (UTC)
:How do you feel about displaying in three or more formats: hex, binary, decimal and (maybe) octal? Something like “F1 (hex), 11110001 (binary), 241 (decimal), 361 (octal)” or “F1 [16], 11110001 [2], 241 [10], 361 [8]”? [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 12:09, 2 March 2025 (UTC)
::They all seem too long IMO. Imagine how they would show up in rendered displays (e.g. on Tests). I agree that choosing a base has no right answer, but I think choosing any is still better than all. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 22:21, 2 March 2025 (UTC)
:::Ah, yes… you’re right, of course! [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 23:24, 2 March 2025 (UTC)
:Can we proceed with this one? In particular the reader will be useful to accept a wider range of inputs. [[User:99of9|99of9]] ([[User talk:99of9|talk]]) 00:31, 26 March 2025 (UTC)
::{{ping|DVrandecic (WMF)}} I know you've been busy, and am sorry to be pushy, but you asked for this [[Wikifunctions:Status_updates/2025-02-26|about 6 weeks ago]], and I tried to get it done the next day. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 06:32, 14 April 2025 (UTC)
:::@[[User:DVrandecic (WMF)|DVrandecic (WMF)]] @[[User:Denny|Denny]] ping again. The bot wants to archive this section. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 04:46, 16 May 2025 (UTC)
::::@[[User:99of9|99of9]] Thank you so much for your patience! The read and write function have been now set on [[Z80|Byte]] as per your proposal. Everyone, feel free to test it, I tried it a bit and it works like a charm! Thank you for all the work. --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 09:33, 16 May 2025 (UTC)
:::::Thanks for clearing some important backlog. It's great to have you back. If you have more capacity, I sent a reminder of a few trickier backlogs for you via @[[User:Sannita (WMF)|Sannita (WMF)]] at [https://t.me/Wikifunctions/25377]. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 23:56, 21 May 2025 (UTC)
::::::Hi @[[User:99of9|99of9]]! I checked with Sannita, and I am trying to find the other topics you listed. One is about [[Wikifunctions:Project chat/Archive/2024/06#Revisiting community %22maintainer%22 rights|connecting tests to built-ins]], and the other two seem about the converter for floating point numbers. I haven't caught up on the chat yet, is there a place I can read up on the floating point issues (besides going through the chat, which I will do some day)? --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 14:46, 26 May 2025 (UTC)
:::::::[https://t.me/Wikifunctions/24417 April 7th] “I've just been investigating Z21923 and am now confident that the float64 converters to code are not dealing with the special case of subnormal numbers. When the exponent is -1023 (just this specific value), the mantissa should not get the 1+ in line 47 of [[Z20875]]. Similar omission in the JS converter.
:::::::“Then in [[Z20885]] it looks like like 83 should not subtract the 0.5 for the specific case of the exp being -1023 (or actually -1022 at that stage, since it is decremented in the following line)” [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 16:30, 26 May 2025 (UTC)
::::::::Hi @[[User:DVrandecic (WMF)|DVrandecic (WMF)]], yes, thanks @[[User:GrounderUK|GrounderUK]] that's all I wrote about #3. If you need more info let me know, but I learned most of what I know from wiki. Most relevant here is [[:w:Double-precision_floating-point_format#Exponent_encoding]]. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 23:12, 26 May 2025 (UTC)
:::::::[https://t.me/Wikifunctions/22480 February 2nd] is #4: "I've realised that the question at the end of the [[Wikifunctions:Status_updates/2025-01-29|FOTW section]] I wrote is now more urgent. The question was "Should special values return with their other (usually disregarded) keys matching the values of the sign, mantissa and exponent in the IEEE 754 binary representations?". It's now urgent because the type reader is now hardcoding the representation of the special values in every test that involves them (e.g. [[Z22081]]). Perhaps obviously by posing the question, I favour returning values for all keys that match how they appear in the binary representations." This received some concurrence, and I haven't seen anyone against it. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 23:15, 26 May 2025 (UTC)
== Numeric type : Real number ? ==
In order to allow π to be supported in my previously suggested cartesian/polar conversion function, I note that a 'real' type needed to be supported.
A 'real' differs from a rational in that it it can take any supportable numerical value.
Obviously for Wikifunctions purposes a real has a floor and ceiling value for positive/negative infinity, and underflow infinity ( i.e too close to zero). Can someone assist me on converting this into a formal explanation?
I had this so for for real :
Constraint : <math> \pm \left| (\infty > x > 0) \right| </math>
Representation: "[0-9]*\.[0-9](\E((\+|\-)|)[0-9]*|)"
Pi would then be -
Function Name: Pi
Function type: Constant value - Real.
Constraint : 3.141... Unless in abstract there's a different way to define it.
Formal methods is not an area I thave that much experience with.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 08:37, 26 March 2025 (UTC)
:Defining a color for referenche elsehwere either as :
Representation:\#[0-9A-F]{6}. \* Hex String *\
Representaion: (\1\.\0|\0\.[1-9]+)\,{2}(\1\.\0|\0\.[1-9]+) \* 3 value float (0.0 < n 1.0 *\
:We don’t have a [[Wikifunctions:Type proposals|Type proposal]] for Real numbers yet. We can support arbitrarily precise approximations for an irrational number as a [[Z19677]] and we already have a float64 approximation for [[Z20862]], but someone should propose a Real number type (or, perhaps, an Irrational number type) if they have a clear idea of how it might work. I’m rather drawn to the idea of a separate Irrational number type, without thinking it through… [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 10:28, 26 March 2025 (UTC)
::One way it could work is to reprensent (comptable) real numbers by fonctions that take a precision and returns a rational number. <math>\pi<math> would be internally implementations of algorithms / formulas that computes it up to some arbutrary precision.
::The arithmetic basic opération like addition would be higher order fonctions that takes real numbers as arguments and returns themselves a real number, so a function that takes a precision and returns a rational number that approximates the sum up to that precision. (A number of bits, or a number of decimals) [[User:TomT0m|TomT0m]] ([[User talk:TomT0m|talk]]) 12:35, 21 April 2025 (UTC)
:::I've started a little way down this track. A good example is {{Z|Z23902}}, but with a rational return. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 23:47, 25 April 2025 (UTC)
:::@[[User:Dv103|Dv103]] made another very nice example of this at {{Z|Z24505}}, which I hope we can use as a general model. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 15:03, 5 May 2025 (UTC)
:::If I understand the proposal right, the proposal is not to create a type for real numbers, but rather functions that return a real number with an argument for the precision in one of the existing types. Is that right? That seems to take us pretty far.
:::To the best of my knowledge -- but I am not a mathematician -- the answer to the question of how to create a type for real numbers isn't obvious yet. See also [https://chadnauseam.com/coding/random/calculator-app this thread] and [https://dl.acm.org/doi/pdf/10.1145/3385412.3386037 this paper].
:::Having said that, and re-reading the thread and skimming the paper, it would involve two new types:
:::# a number with a precision. Since we need that for the Wikidata quantity type anyway, we should probably have one such type that will also work for the Wikidata quantity type.
:::# the type as described in the paper for even more goodness.
:::Just a thought. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 10:39, 16 May 2025 (UTC)
== Using functions on main page ==
Now that functions can be used on wikitext pages on wikifunctions.org, I think it would be a good idea to use at least a few of these functions on the main page. Additionally, while we are at it, it would be a good idea to update the welcome section with current goings-on. [[User:Feeglgeef|Feeglgeef]] ([[User talk:Feeglgeef|talk]]) 19:09, 16 April 2025 (UTC)
:Yes this is a good idea from my point of view. What functions do you want to publish there. I think for example a function to get difference between two dates would be interesting. Another thing is the information how many months Wikifunctions exists so far. [[User:Hogü-456|Hogü-456]] ([[User talk:Hogü-456|talk]]) 21:07, 16 April 2025 (UTC)
:Although we can’t actually count the number of functions, I think we could replace the plaintext count with a function that formats the value of some Natural number object. Picking up on @[[User:Hogü-456|Hogü-456]]’s suggestion, we could have a Wikifunctions data object (a list destined to become a map), and select the required datum from there. [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 08:51, 17 April 2025 (UTC)
::Is it possible to count the number of functions with a script. At [[Special:ListObjectsByType]] I have not found the total number of functions as the count is not related to the total number of objects of the selected type and instead to the objects displayed. [[User:Hogü-456|Hogü-456]] ([[User talk:Hogü-456|talk]]) 20:53, 18 April 2025 (UTC)
:::Yes. I meant we can’t have a Wikifunctions function that counts them, but we could have a function that displays the count according to language and rounded appropriately. [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 23:07, 18 April 2025 (UTC)
::@[[User:GrounderUK|GrounderUK]]: If you want us to provide a MediaWiki magic word that reports the number of Functions on the site, we can definitely build that — equivalent to <code><nowiki>{{NUMBEROFARTICLES}}</nowiki></code>. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 13:36, 24 April 2025 (UTC)
:::Yes, please! [[User:Feeglgeef|Feeglgeef]] ([[User talk:Feeglgeef|talk]]) 16:07, 24 April 2025 (UTC)
::::@[[User:GrounderUK|GrounderUK]], @[[User:Feeglgeef|Feeglgeef]]: Patch written; will hopefully get it reviewed over the weekend and shipped next week, or maybe that thereafter. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 16:19, 25 April 2025 (UTC)
:::::Ah, yes… and just those counts is also not a problem. No need to reply to my previous comment. Thank you for this (and everything you do). [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 16:45, 25 April 2025 (UTC)
::::::{{ping|99of9|Feeglgeef|GrounderUK|Hogü-456}} With apologies for the delay, this is now live – you can see entries in [[Special:Statistics]], and summon them in wikitext via:
::::::* <code><nowiki>{{NUMBEROFOBJECTS}}</nowiki></code>, the total number of Objects ({{NUMBEROFOBJECTS}}),
::::::* <code><nowiki>{{NUMBEROFFUNCTIONS}}</nowiki></code>, the number of Functions ({{NUMBEROFFUNCTIONS}}),
::::::* <code><nowiki>{{NUMBEROFIMPLEMENTATIONS}}</nowiki></code>, the number of Implementations ({{NUMBEROFIMPLEMENTATIONS}}),
::::::* <code><nowiki>{{NUMBEROFTESTCASES}}</nowiki></code>, the number of Test cases ({{NUMBEROFTESTCASES}}),
::::::* <code><nowiki>{{NUMBEROFTYPES}}</nowiki></code>, the number of Types ({{NUMBEROFTYPES}}), and
::::::* <code><nowiki>{{NUMBEROFLANGUAGES}}</nowiki></code>, the number of (natural) languages ({{NUMBEROFLANGUAGES}}).
::::::Do we want to add these to [[Template:Main page]]? (Should this particular part of the conversation move to [[Wikifunctions talk:Main Page]]?) [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 21:20, 13 May 2025 (UTC)
:::::::Number of Functions in the current manual spot please. [[User:Feeglgeef|Feeglgeef]] ([[User talk:Feeglgeef|talk]]) 11:03, 14 May 2025 (UTC)
:::::::I have replaced our manual counter for the number of functions with <nowiki>{{NUMBEROFFUNCTIONS}}</nowiki>. --[[User:Ameisenigel|Ameisenigel]] ([[User talk:Ameisenigel|talk]]) 13:46, 14 May 2025 (UTC)
::::::::Thank you! --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 10:46, 16 May 2025 (UTC)
:::Should that be number of functions or number of functions excluding built-ins? The “…that anyone can edit” tag suggests the latter, but we could just deduct the (relatively stable) number of built-ins. Thanks for the offer… I think this is [[phab:T345477]] (or related). [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 17:46, 24 April 2025 (UTC)
::::@[[User:GrounderUK|GrounderUK]]: Excluding pre-defined Objects is a real chore (and currently meaningless //e.g.// for Types or (natural) Languages, so for now I'm not offering it, but if really needed we can bear this in mind next time we re-build the DB table so it stores this information. Sorry to disappoint! [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 16:20, 25 April 2025 (UTC)
:::::Not a problem. We were talking specifically about functions, though. A separate count per type is also not a problem, but a count of all objects on its own does not satisfy the specific use case. Thanks! [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 16:29, 25 April 2025 (UTC)
:::Yes please. Please also consider which other magic words can he used to supply us with contemporaneous data. Real data makes running functions much more interesting. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 02:04, 25 April 2025 (UTC)
::::@[[User:99of9|99of9]]: Perhaps something like "this wiki has been running for {…} years, since opening on 2023-08-01", using [[Z20756|Z20756/age]]? [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 16:22, 25 April 2025 (UTC)
== proposed Display functions for Day of the week Type ==
I suggest we use the following functions as a display function for the Day of the week Type:
*{{Z+|Z24041}}
Types without display functions [[Help:Using_Wikifunctions#Output_type_not_supported|aren't supported]] when called from Wikipedias, so IMO it is a priority that we continue to connect display functions.
--[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:35, 19 April 2025 (UTC)
:'''Support''' That function works pretty well, thanks for your contributions 99of9! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 12:43, 19 April 2025 (UTC)
::You're welcome. Though most of the credit for the hard work done on this one goes to {{User|GrounderUK}}. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:53, 19 April 2025 (UTC)
:I have no problem with the function, but I do have reservations about setting an unfortunate precedent by relying on labels. I think the “officially correct” approach would be to go from the Wikifunctions object to the corresponding Wikidata item and from there to the item’s lexeme and the appropriate form/representation. Failures are possible, of course, and we have two fallback routes to consider, according to the language.
:First, for language varieties with a lot of overlap, like Australian English and (en) English, we should fall back to the more common variety. (Note that the function currently returns a blank for Australian English. I imagine that the general fallback for Australian English would be to British English before (en) English, with US-English as a last resort, but even this simple example leads us into treacherous waters.)
:Secondly, (also by language), whether we prefer labels to lexemes or a specific function, or (assuming defaults are excluded or handled when a specific function is the option) lexeme/label first then label/lexeme in specified language, or lexeme/label in any fallback language then label/lexeme in any fallback language… and then our default (fall-through) option.
:How might this work in practice? We could have a [[Z14294]] that would handle the second cases first. For example, English might be set to prefer labels whereas Italian might prefer lexemes (because « domenica » is feminine whereas other days are masculine, so we’d have « domenica prossima » (“next Sunday”) but « lunedì prossimo » (“next Monday”), per esempio). I guess we’d have separate functions for label then lexeme, lexeme only, lexeme then label, label only; the default function here might also be configured by language for a “native Wikifunctions” experience.
:However, configuration by language doesn’t allow the specified language to be switched (from “en-au” to “en”, for example). This suggests that language-switching should be handled separately in the configured functions. It might be a common function, but the sequence may differ according to whether you're looking for labels or lexemes. In any event, I suspect that "language" is better specified as a list, with an empty list defaulting to [[Z1360|"mul"]] (say) and falling through to the default specified in the configuration (or a "mul"-specific alternative). (And when I say “list”, I suppose it would have to be a string representation, for integration, so we might see something like “[Z60, "dag", "en", "mul"]”. I guess we can’t use a read or display function for a generic type, though, and perhaps that challenge is better considered under a separate heading.) [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 11:46, 20 April 2025 (UTC)
::Good thoughts. I think your proposed "officially correct" function would be worth writing (as would some of the variants you mention), and may indeed work even better for some languages. For language fallbacks, I think we can get separate functions to handle that without changing the input type of a display function. It will take some building, and will be more than a configuration by language, but I don't think it will be too much worse. Just as you were posting this, I was writing a crude language fallback map: {{Z|Z24097}} as a start! --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:10, 20 April 2025 (UTC)
:::Update: I've now adjusted the implementations to use the general language fallback if variants (like en-au) come up empty. And the test {{Z|Z24105}} now passes (with a long runtime). --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:42, 20 April 2025 (UTC)
:::Perhaps “crude” is a little harsh… but switching between “nn” and “no” then falling back to “sv” or “en” (according to personal preference) is the sort of scenario we might contemplate. One step at at time, though… so long as we don’t trip over one another’s feet! (You have a free run today, as far as I’m concerned! When I get started, I’m more interested in pursuing the lexeme route, but I want graceful fallback from [[Z6830]] outwards, and that means the option to switch languages if no lexeme is found, and (logically) a list of properties to work through too. Although such searches may have less of a performance overhead than item labels, I guess we’d only be able to manage a couple if we want to be able to default to labels afterwards.) [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 13:16, 20 April 2025 (UTC)
::::I'm not aiming for personal preference, because in my understanding display functions will generally apply to all users of a uselang. So I'm just aiming for the best (configurable) outcome for every language. For now I'll stick within the label space rather than the lexemes, but I agree it would be good to have a robust lexeme path available too. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 13:27, 20 April 2025 (UTC)
:::::You’re probably right, but I’m ''speculating'' that a personal preference and a project default could/should/would look the same at the function level. [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 14:25, 20 April 2025 (UTC)
::Althouh we obviously want as much progress on lexemes as possible, I've realised that I don't agree it is "officially correct" for display functions. These are rendered output of single day values in a language, not lexically correct parts of a sentence. I think the intent is almost exactly coincident with the intent of a Wikidata label. [[User:99of9|99of9]] ([[User talk:99of9|talk]]) 01:03, 21 April 2025 (UTC)
:::I take your point. Without [[phab:T366459]], the display function cannot display the Wikifunctions object label, and even assuming the counterfactual, I can see the sense in defaulting to the label for the corresponding Wikidata item. Presumably, this is how [[phab:T390558|“light-weight enumerations” (T390558)]] will operate, since there will be no persistent instances to which to attach labels. In any event, as I said before, “I have no problem with the function” and I am happy to withdraw my remark about the lexeme route being « “officially correct” ». (@[[User:DMartin (WMF)|DMartin (WMF)]] Any thoughts about displaying the string for a light-weight enumeration? Does the generic type get read and display functions?)
:::That having been said, the performance is a concern and I am getting a time-outs for Thursday in a language-fallback scenario like [[Z24106]]. I suggest we defer language-fallback until we can return multiple selected labels from a single visit to an item. I just used [[Z13436]] in [[Z24109]] to support [[Z24110]] but I think “label-list from item for language-list” will require a code implementation, in the absence of a [[phab: T390226|variadic filter function (T390226)]]. I’ll get started on that. [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 08:38, 21 April 2025 (UTC)
:::Update: I’ve created [[Z24118]], which seems to do the job. I’ve left it disconnected for now as I accidentally passed all the tests with my interim fallback. I think we can just plug in an additional function call for a single “general” language (like “en”) but we’d need to flatten the list if a function returns a list of languages (like my Scandinavian example). It all looks doable but it looks as though a simple variadic filter would not have done the job, downstream, because we need the results in language order (so that’s something else to think about). [[User:GrounderUK|GrounderUK]] ([[User talk:GrounderUK|talk]]) 12:15, 21 April 2025 (UTC)
::::Nice. I've made a harder test {{Z|Z24143}}, but also squeezed {{Z|Z24097}} into your list, so now your new composition passes and is fast enough. Scandinavian hierarchies still to come. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 01:29, 22 April 2025 (UTC)
:::::I've added {{Z|Z24329}}, which I'm confident does everything we need, because it ultimately relies on the complete flexibility of hardcoding fallback chains for every language in {{Z|Z24310}}. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 01:06, 30 April 2025 (UTC)
:@[[User:DVrandecic (WMF)]] I think this is ready to go. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 06:10, 8 May 2025 (UTC)
::@[[User:99of9|99of9]] thank you for your patience and your ping, I added {{Z|Z24041}} as a display function to {{Z|Z17402}}. Thanks to @[[User:GrounderUK|GrounderUK]] for the work! --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 07:37, 18 May 2025 (UTC)
== proposed Display function for Gregorian calendar month Type ==
I suggest we use {{Z|Z24086}} as a display function for the {{Z|Z16098}} Type. Similar to [[#proposed Display functions for Day of the week Type]], this display function calls for a Wikidata label of the object, and has elaborate and flexible handling of fallback languages if the editing language variant does not have a corresponding Wikidata label.
Types without display functions aren't supported when called from Wikipedias, so IMO it is a priority that we continue to connect display functions. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 01:13, 30 April 2025 (UTC)
:@[[User:99of9|99of9]]: Thank you! Done so! Again, thank you for your patience and for shepherding this change. --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 15:06, 18 May 2025 (UTC)
{{tracked|T394769}}
::For some reason now {{Z|Z24086}} doesn't work [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 16:45, 18 May 2025 (UTC)
:::Good pickup. I can't see anything wrong, and have tested the functions that the composition calls. Likely a bug? --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 02:09, 19 May 2025 (UTC)
::::Weird. It worked yesterday when I was testing it out. I'll let the team know. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 11:27, 19 May 2025 (UTC)
== Problems with a js implementation ==
{{tracked|T394663}}
The implementation [[Z24188]] doesn't work (it fails a testcase), and I have no idea why. Is it a Wikifunctions bug or am I doing something wrong? [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 10:44, 2 May 2025 (UTC)
:I didn't see anything immediately wrong, and my attempt at [[Z24414]] also fails. There are a lot of issues with lists and timeout/errors at the moment, but it appears that my changes have triggered it to go into infinite running mode https://phabricator.wikimedia.org/T392905. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 13:13, 2 May 2025 (UTC)
::@[[User:Dv103|Dv103]] reported as [[:phab:T394663]] for investigation. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:04, 19 May 2025 (UTC)
== Internal server error in running a composition ==
I'm getting internal server errors in all testcases for {{Z|Z24456}}. Any idea why?<br>
Also, is there some way to translate those oblique long Z-jsons you get as actual output into a way more human-readable form, like how normal objects are viewed on Wikifunctions? [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 15:00, 3 May 2025 (UTC)
:It's a problem that arises in {{Z|Z13397}} (see testcase {{Z|Z24458}}). I don't know why. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 15:50, 3 May 2025 (UTC)
::I filed a bug [[:phab:T394664]] for further investigation. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:10, 19 May 2025 (UTC)
== Smaller natural numbers ==
I want to use some number codes to represent an enum of 17 possible values. I find converting to and fro BigInt—the JS representation of the natural number type—bothersome, especially when 17 is the maximum number I need. Is there a representation of numbers that's analogous to an int8 or uint8?
Speaking of which, is there a list of types somewhere? [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 17:06, 3 May 2025 (UTC)
: Diving into things more: Is really every single number on Wikifunctions represented by a String? Parsing everything from and to ints seems quite inefficient and precluding some optimization. [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 20:32, 3 May 2025 (UTC)
::The simple answer is yes, since every type expands to values of other types, with only strings and references being the terminal types. The more complete answer in at [[Wikifunctions:Function model]]. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 21:34, 3 May 2025 (UTC)
::: That indeed explains how it is—that there are no canonical numbers. I've tried searching for why it is, though, and haven't found anything. [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 22:11, 3 May 2025 (UTC)
::::It was done for simplification. If there are no built-in numbers, there are no built-in mathematics, and it can reduce the number of built-ins considerably. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:11, 19 May 2025 (UTC)
::::: You don't need to introduce built-in mathematics when introducing numbers either. There's like 2 built-in implementations for String functions. [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 17:03, 19 May 2025 (UTC)
::::::Yes, good point. I really wanted to keep the number of built-in types low, that's the main reason. And even for numbers we had quite a few decisions to make, so I think it is good we did that in the open and together through a type proposal. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 12:57, 22 May 2025 (UTC)
:There is no int8 type. The complete list of types is at [https://www.wikifunctions.org/w/index.php?title=Special:ListObjectsByType/Z4]. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 21:37, 3 May 2025 (UTC)
:: Ooh, lovely! Is there a way to bump the "Wikifunctions pages" section to the top of [[Special:SpecialPages]]? I decided to look under "Lists of pages" and couldn't find that. [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 22:06, 3 May 2025 (UTC)
::There's {{Z|80}} for u8. [[User:YoshiRulz|YoshiRulz]] ([[User talk:YoshiRulz|talk]]) 23:19, 3 May 2025 (UTC)
::: Thanks. I've checked that before, though. It is exactly the same as natural number and using it here would be semantically confusing. [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 01:32, 4 May 2025 (UTC)
:Enums should be represented as enums (e.g. such as [[Z16098]]) and not as numbers, ideally. Let me know what's blocking that. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:28, 19 May 2025 (UTC)
::I don't have the permissions to create types, so that's gonna take a long time if the (absence of) responses to [[Wikifunctions:Type proposals/Grapheme]] are anything to go by. Do you think I have a shot at getting functioneer? [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 17:03, 19 May 2025 (UTC)
:::Enums usually go pretty fast (unless we are waiting for the light-weight enumerations, some of the current proposals are blocked on that). Even as a functioneer, one doesn't have type creation rights, these are currently limited to staff (type creation is currently not a user-friendly process, we want to improve that before opening that up). Yes, I would assume you have a good chance at becoming functioneer. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 12:59, 22 May 2025 (UTC)
:::: Ah, makes sense. Thanks! [[User:Aaron Liu|Aaron Liu]] ([[User talk:Aaron Liu|talk]]) 13:32, 22 May 2025 (UTC)
== Quick prototyping possible? ==
Generally, to see the output of a piece of code I'd like to write for Wikifunctions, I have to first create the function for it, then create an implementation, then connect that implementation if I want to see its output, even if it's not done. With compositions I can simply go to [[Special:RunFunction]] and test it there, but with code implementations there's not much I can do (to my knowledge, at least).
I've a relatively ambitious idea and I'd like to experiment with it before I try making a full-fledged function + implementation + tests for it. Is there any way I could do this in a way that doesn't require too much extraneous effort and ZObject creation? It's something that will require specific steps and I'd like to lay it out and test it before I fully commit to implementing it, but there doesn't seem to be an easy way for me to do that. — [[User:Theki|rae<sup>5e</sup>]] <[[User talk:Theki|talk]]> 16:59, 7 May 2025 (UTC)
:No, I think you have laid out most ways to do it for now. There is one small way that can improve it: the way I do it is that I usually create a small number of tests first, and then I can run and rerun the tests while coding the implementation before I publish the implementation. And then, only once the tests are good, I click on publish. Would that help a bit? --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:15, 19 May 2025 (UTC)
== Wikifunctions & Abstract Wikipedia Newsletter #201 is out: Abstract Wikipedia and the Wikimedia AI Strategy ==
There is [[:f:Special:MyLanguage/Wikifunctions:Status updates/2025-05-09|a new update]] for Abstract Wikipedia and Wikifunctions. Please, come and read it!
In this issue, we discuss how Abstract Wikipedia ties in with the newly announced WMF's strategy for AI, we talk about the Wikimedia Hackathon and our community meetings, and we take a look at the latest software developments.
Want to catch up with the previous updates? Check [[:f:Special:MyLanguage/Wikifunctions:Status updates|our archive]]!
Enjoy the reading! -- [[User:Sannita (WMF)|User:Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 10:27, 10 May 2025 (UTC)
<!-- Message sent by User:Sannita (WMF)@metawiki using the list at https://meta.wikimedia.org/w/index.php?title=Global_message_delivery/Targets/Wikifunctions_%26_Abstract_Wikipedia&oldid=28661550 -->
:This is an interesting update. I have thinked a bit about usage of AI for Abstract Wikipedia and I am not sure how well it will work for small language versions. As far as I unterstand it is necessary to have enough data to train a model. It is important to check a text if it makes sense and not just translate it or generating content in a language a person can not speak. Instead of having no article I also like boilerplate templates. So a text with gaps for variable content depending on the specific subject. For simple use cases it is possible to make suggestions without a huge LLM in the background and instead with simple decision trees. So I think it is necessary to improve the data in Wikidata and add more statements to items. Usually larger articles in Wikipedia have more contents at what is listed in statements in the related Wikidata item. For the definition and necessary for the translation of the boilerplate templates people who can speak the local language the an abstract text should be converted to are required. So far I miss interaction of people of small Wikipedia language versions in Wikifunctions and it seems to me like a theoretical discussion and I hope there is enough awareness about irregular cases. Languages are in parts not easy to generate automatically. [[User:Hogü-456|Hogü-456]] ([[User talk:Hogü-456|talk]]) 20:25, 11 May 2025 (UTC)
:Why shouldn't the language model also translate (render) from the middle pane (abstract content) to readable prose?
:I uploaded a screenshot of the middle pane and fed it into Gemma 3, Google's latest open model, with the prompt:
::''Render the abstract knowledge representation displayed in the image into fluent expository Hebrew prose, suitable for an encyclopedia.''
:The result was:
::''.מרי קורי היא האדם היחיד שזכה בפרס נובל בשתי קטגוריות מדעיות שונות''
:Or, in English:
::''Marie Curie is the only person to have won the Nobel Prize in two different scientific categories.''
:This is achievable using open models ''today''. It will only get better as LLMs are trained on richer corpora, expanding their reach to a wider variety of human languages. Where will these capabilities be in a year, and where will Wikifunction's natural language generation capabilities be? [[User:ATDT|ATDT]] ([[User talk:ATDT|talk]]) 01:39, 12 May 2025 (UTC)
::Hi @[[User:ATDT|ATDT]], thanks for the question! There area a number of reasons:
::* this doesn't work well for many of our small languages, such as Dagbani. For the large languages it often works OK, but they are the ones that need it least.
::* there is no guarantee of the results being correct. This system could work with a "let's generate and then have humans check the results" approach, but the goal of Abstract Wikipedia is to be able to edit the abstract content and then publish immediately in all supported languages ''without'' having to check the output again.
::* if a generation is wrong, it is unclear how to fix it (unless we do it manually, but in that case we are at the same point as with just using machine translation right now).
::I would think that if we use a model for generating output, we'd always need a human in the loop who understands both the input and the output languages. And that's basically the 1:1 machine translation approach, not the Abstract Wikipedia approach, where we create with high fidelity the output in all participating languages without requiring a human in the loop in the generation step. --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:37, 19 May 2025 (UTC)
== Fold and reduce swapped ==
Per my comments on [[Talk:Z876#Naming]] and [[WF:Catalogue/List operations#In-built functions with list outputs]],
I believe these functions' names are reversed from the conventional ones. Are there any FP greybeards who can confirm? [[User:YoshiRulz|YoshiRulz]] ([[User talk:YoshiRulz|talk]]) 05:22, 11 May 2025 (UTC)
:I was involved in the construction of some of these, following suggestions from others. I have no particular expertise in the nomenclature, so may well have transmitted naming errors. Feel free to rename if others confirm your suggestion. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:44, 11 May 2025 (UTC)
== Taxon rank function(s) ==
I understand that function suggestions usually go in [[:Wikifunctions:Suggest a function]], but I could use some feedback on this, especially since I'm unsure of what Wikifunctions is capable of currently...
I think it would be useful to have a function that, given a Wikidata item that is an instance of {{Q|Q427626}} (hereafter a taxon rank), e.g. {{Q|Q7432}}, {{Q|Q34740}}, {{Q|Q35409}}, etc., returns whether or not that taxon rank is situated at or below the rank of genus. That is, it would return true for genus, subgenus, species, subspecies, variety, and botany's series, subseries, section, and subsection, among a handful of other infraspecific ranks (or infrageneric ranks that I may be forgetting about). For efficiency, it may be worth it to hard-code a partial list of taxon ranks that are considered to be at the generic level or below, and as a fallback traverse the taxon rank hierarchy by looking at the values of {{Q|P361}}. Here's a pseudocode example.
function genericRankOrLower(taxonRank) {
const hardcodedGen = [
'Qxxxxx', //species
'Qxxxxx', //subgenus
'Qxxxxx' //genus
];
const hardcodedNonGen = [
'Qxxxxx', //family
'Qxxxxx', //order
'Qxxxxx', //class
'Qxxxxx', //phylum
'Qxxxxx' //kingdom
];
if (hardcodedGen.contains(taxonRank)) return true;
if (hardcodedNonGen.contains(taxonRank)) return false; // want to avoid expensive long traversals
let nextRank = WikidataLookup.GetFirst(item: taxonRank, property: P361);
if (nextRank != null) return genericRankOrLower(nextRank);
return false;
}
This would be useful because the names of taxa at the genus rank and lower should be italicized, but the names of taxa above the genus rank should not; e.g. the taxon name {{Q|Q13612717}} may be written as ''Eristalis stipator'' or ''Eristalis (Eoseristalis) stipator'' (the subgenus, in parentheses, is optional), while the family name {{Q|Q217905}} is written as Syrphidae. Wikispecies and the English Wikipedia have something that can help somewhat with this, [[:species:Template:Taxon italics]]/[[:en:Template:Taxon italics]], which will correctly italicize a taxon name (including cases where there are unitalicized portions, such as "var."). However, I don't believe they have a Wikidata-enabled template or module for determining if a taxon should be italicized.
In the actual use of this proposed function, there may need to be exceptions or special cases for e.g. viruses - I am unfamiliar with the italicization rules for virus names. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 20:02, 15 May 2025 (UTC)
:Sounds like a good function suggestion to me. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 04:34, 16 May 2025 (UTC)
::Thanks. I've added a suggestion at [[Wikifunctions:Suggest a function#Taxon functions]] - feel free to move it if necessary, as I'm not entirely sure where it fits best. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 23:30, 16 May 2025 (UTC)
== Wikifunctions & Abstract Wikipedia Newsletter #202 is out: Location of Abstract Content ==
There is [[:f:Special:MyLanguage/Wikifunctions:Status updates/2025-05-15|a new update]] for Abstract Wikipedia and Wikifunctions. Please, come and read it!
In this issue, we invite you to [[:m:Abstract Wikipedia/Location of Abstract Content|a consultation]] about where should the content of Abstract Wikipedia be stored, we invite you to our next online presentation, and we take a look at the latest software developments.
Want to catch up with the previous updates? Check [[:f:Special:MyLanguage/Wikifunctions:Status updates|our archive]]!
Enjoy the reading! -- [[User:Sannita (WMF)|User:Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 10:56, 16 May 2025 (UTC)
<!-- Message sent by User:Sannita (WMF)@metawiki using the list at https://meta.wikimedia.org/w/index.php?title=Global_message_delivery/Targets/Wikifunctions_%26_Abstract_Wikipedia&oldid=28661550 -->
== Just wonder, that fair use is allowed here or not? ==
Of course it doesn't seem allowed for files, as [[special:upload]] is disabled here, but how about functions or other text-like contents? Those may also be fair use-allowed on some certain projects (e.g. several Wikiquotes), [[m:Non-free_content#Other_projects]] only suggests "A new developing project, lack of discussions on this matter yet". Any inputs? --[[User:Liuxinyu970226|Liuxinyu970226]] ([[User talk:Liuxinyu970226|talk]]) 01:12, 18 May 2025 (UTC)
:Code contributions are licensed under Apache 2.0, and any contributions must be compatible with that license. [https://lib.asu.edu/news/research/fair-use-code Fair use and code] are a complicated combination, that can be crucial in some cases (for example for header declarations), but I don't think that would cover whole function implementations copied from sources that are not Apache 2.0 compatible. I am not a lawyer, and if we want a proper answer involving lawyers, we can work towards that. Why are you asking, what's the idea you're mulling over? --[[User:Denny|Denny]] ([[User talk:Denny|talk]]) 13:44, 19 May 2025 (UTC)
:@[[User:Liuxinyu970226|Liuxinyu970226]]: I see that [https://meta.wikimedia.org/w/index.php?diff=25452852&oldid=25438584&title=Non-free_content you are the one who added that claim] to the page on meta, nearly two years ago. I don't think it's correct; non-free content has never been allowed. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 16:18, 19 May 2025 (UTC)
::Somewhat modified, but looks still vague even for me... [[User:Liuxinyu970226|Liuxinyu970226]] ([[User talk:Liuxinyu970226|talk]]) 21:46, 19 May 2025 (UTC)
:::Thanks for [https://meta.wikimedia.org/w/index.php?diff=28754698&oldid=28747475&title=Non-free_content your edit]! [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 21:11, 21 May 2025 (UTC)
== Wikitext -> AST and vice versa ==
It may be useful to have functions for lexing/tokenizing and parsing Wikitext into an [[:en:Abstract syntax tree|AST]], and going from that AST back to Wikitext. It would vastly improve the power of functions in [[:Wikifunctions:Catalogue/String operations#Wikitext and Mediawiki string operations]]. I think this also meshes neatly with Abstract Wikipedia. If it's planned to have rich/styled output, dealing with an AST is much preferable to performing operations on Wikitext directly.
The downside of this is that it would be complicated and a lot of work to implement, and likely require the creation of a couple new types, at least. However, there already exist [[:mw:Alternative parsers|several Wikitext parsers]], so perhaps a parser (Parsoid?) could be provided as a built-in implementation? Though, this would still necessitate the creation of several types.
Would this be (a) feasible and (b) useful? --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 22:55, 19 May 2025 (UTC)
:Ah, I just read [[:Wikifunctions:Embedded function calls#Wikitext output]]. That would mean this wouldn't really be possible... though it may still be possible to implement an AST for HTML. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 23:23, 19 May 2025 (UTC)
== Wikifunctions & Abstract Wikipedia Newsletter #203 is out: Ongoing consultation about the Location for Abstract Content ==
There is [[:f:Special:MyLanguage/Wikifunctions:Status updates/2025-05-23|a new update]] for Abstract Wikipedia and Wikifunctions. Please, come and read it!
In this issue, we invite you again to [[:m:Abstract Wikipedia/Location of Abstract Content|a consultation]] about where should the content of Abstract Wikipedia be stored, we present some updates about existing and new types, we remind you of our next online presentation, and we take a look at the latest software developments.
Want to catch up with the previous updates? Check [[:f:Special:MyLanguage/Wikifunctions:Status updates|our archive]]!
Enjoy the reading! -- [[User:Sannita (WMF)|User:Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 13:54, 23 May 2025 (UTC)
<!-- Message sent by User:Sannita (WMF)@metawiki using the list at https://meta.wikimedia.org/w/index.php?title=Global_message_delivery/Targets/Wikifunctions_%26_Abstract_Wikipedia&oldid=28661550 -->
== Request for connecting implementations ==
Could a functioneer take a look at [[Z15362|Z15362/nth prime]] and [[Z24716|Z24716/bitwise NAND]] and consider revising the respective lists of connected implementations?
[[Z15362|Z15362/nth prime]]: I'd recommend connecting [[Z24783|Z24783/nth prime, caching primes]] and [[Z24784|Z24784/nth prime, caching primes, JS]], as these seem to be the fastest - they pass all the tests, whereas the others time out on at least one. It should also be noted that these two implementations use more memory than the other implementations, but it doesn't seem to have a particularly noticeable effect on the memory usage.
[[Z24716|Z24716/bitwise NAND]]: I'd like to see [[Z24780|Z24780/bitwise NAND, javascript]] connected. I understand that there's a potential performance benefit when multiple implementations used in a call share the same programming language (though this may not be the case at current), so it would be beneficial to have implementations in all supported programming languages, where possible.
Thanks. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 05:02, 24 May 2025 (UTC)
:All {{d}}. Thanks for the work! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:02, 24 May 2025 (UTC)
== proposed Read and Display functions for Unicode code point ==
I suggest we use the following functions as a read and display function for the Unicode code point Type:
* {{Z|Z23041}}
* {{Z|Z24823}}
The reader is intended to be as lenient as possible. If there are other possible input formats, feel free to extend it to include them.
The display uses U+FFFF notation. We have choice here. I picked this because it seems to be common and unambiguous. I'm happy to use another convention if others want it.
Feel free to add an implementation to either with a language configuration if you would like to convert to a different numeral script. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 03:01, 27 May 2025 (UTC)
:Thank you! Done as per [https://www.wikifunctions.org/wiki/Z86?uselang=en&diff=prev&oldid=189454 this edit]. Looks great!
:I was just hoping this week for having this type with a read and display function! This is awesome! --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 12:01, 27 May 2025 (UTC)
::Your work on {{Z|Z24809}} reminded me to finish this off. Last time I'd worked on it I had done almost everything but had been uncertain about which display format to use. Coming back to it the answer seemed clear. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 12:37, 27 May 2025 (UTC)
:::@[[User:99of9|99of9]] Ha! It was exactly writing the tests for that function which made me wish there was this display and read function! --[[User:DVrandecic (WMF)|DVrandecic (WMF)]] ([[User talk:DVrandecic (WMF)|talk]]) 10:03, 2 June 2025 (UTC)
== Wikifunctions & Abstract Wikipedia Newsletter #204 is out: Rolling out to five Wiktionaries; Calculating with today's date ==
There is [[:f:Special:MyLanguage/Wikifunctions:Status updates/2025-05-29|a new update]] for Abstract Wikipedia and Wikifunctions. Please, come and read it!
In this issue, we talk about our latest deployment on five Wiktionaries, we showcase a couple of functions about dates, we remind you of ongoing discussions and upcoming presentations, and we take a look at the latest software developments.
Want to catch up with the previous updates? Check [[:f:Special:MyLanguage/Wikifunctions:Status updates|our archive]]!
Also, we remind you that if you have questions or ideas to discuss, the next '''Volunteers' Corner''' will be held on '''[https://zonestamp.toolforge.org/1748885400 June 2, at 17:30 UTC]''' ([https://meet.google.com/xuy-njxh-rkw link to the meeting]).
Enjoy the reading! -- [[User:Sannita (WMF)|User:Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 14:38, 29 May 2025 (UTC)
<!-- Message sent by User:Sannita (WMF)@metawiki using the list at https://meta.wikimedia.org/w/index.php?title=Global_message_delivery/Targets/Wikifunctions_%26_Abstract_Wikipedia&oldid=28780680 -->
== Solvers (and color spectrum reconstruction.) ==
I am posting here as I wasn't sure how to define it formally for requesting directly.
A specific spreadsheet used for reconstructing approximate 'reflectance' data from RGB triplets, uses the Generalized Reduced Gradient(GRG) solver from Excel. This doesn't exist in Libre Office.
That spreadsheet is linked from ( http://scottburns.us/reflectance-curves-from-srgb-10/.(Burns,2025) The author also links - http://scottburns.us/matlab-octave-and-python-source-code-for-refl-recon-chrom-adapt/ (I don't see a license indication, but the authors are approachable, and have licensed some of their online contributions under Creative Commons, and I've already suggested they look into writing a contribution for Wikiversity under Open Access.)
My understanding of what the GRG does is that for a range of input values, a function is setup for the results set, with the sum of the intermediate steps having to meet some 'goal'(in the linked use case a 'minimized' value, these intermediate calculations being used to generate a set of finalised 'results'.
In the use case for (Burns,2025), the results set obtained through the GRG approach, is further constrained. Namely that an XYZ color, obtained from applying CIE observer functions to the generated 'reflectance' data must match a pre determined input XYZ color, although obtained by applying a suitable conversion from an sRGB triplet).
Would it be possible for some kind of 'solver' function/algorithim to be considered for Wikifunctions, to allow for the kinds of approaches taken in Burns, to be developed or expanded upon?
I appreciate the specific use case is a bit niche, and implentations are possibly beyond me, but having 'solvers' would be useful I think.
As an aside, having Wikifunctions able to make use reconstructed 'refelctance' data for typical RGB triplets might prove useful long term, especially if the approach can be extended to approximate for any 'color' ( such as xyz spaces recently added in CSS and recent browsers). A different author (Ronald Van Winjen, 2025), also uses approximated reflectance curves to implement a 'pigment' style subtractive color mixing 'function' as Spectral.js (https://github.com/rvanwijnen/spectral.js).
(That code is under MIT license, and uses a faster but possibly less specfic approximation technique.)
My apologies if I sound a bit more formalised in places, and if opthers are able to improve the referencing , feel free.
[[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 08:59, 5 June 2025 (UTC)
:Many solvers use something like [[:w:Newton's method]]. We have a few functions that attempt something like this ([[Z24539]], [[Z24553]]) which you could have a look at to incorporate into your colour analysis field. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 05:04, 6 June 2025 (UTC)
: Actual coding is beyond my expertise, but I figured I'd put the suggestion down for future reference. In Excel what it's doing is 'guessing' for an entire set of vlaues and tweaking those at goes I think. The estimation method you linked is for a single value, not a constrained set I think. [[User:ShakespeareFan00|ShakespeareFan00]] ([[User talk:ShakespeareFan00|talk]]) 11:22, 6 June 2025 (UTC)
9wcna4yr7qtmsjmvg7wngrb6ybqw51i
Wikifunctions:FAQ/en
4
1247
191350
146074
2025-06-07T04:43:58Z
FuzzyBot
207
Updating to match new version of source page
191350
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
__TOC__
== Introduction ==
=== What is this project about? ===
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
=== What is a function? ===
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
=== What is an implementation? ===
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
=== What is a test? ===
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
=== Which features are available now, which will be soon available, and which are further away? ===
* At launch:
** We have the ability to have functions that work with Strings and Booleans.
** Wikifunctions will be fully internationalized from the beginning. It can be used in any language.
* [[Wikifunctions:Status|Ongoing development]]:
** Generic types and generic functions are not fully supported.
** Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.
*** One particularly interesting type will be binary data, and particularly files.
** We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.
** Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.
* In the future:
** It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.
** It will be possible to use data from Wikidata in functions.
** It will be possible to call data sets from Commons Data namespace.
=== How is Wikifunctions multilingual? ===
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
* '''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.
* '''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.
* '''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.
* '''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
=== How will Wikifunctions be integrated into other projects? ===
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
=== What Wikifunctions is not? ===
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
=== What license will the functions and derived content be under? ===
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
== Contributing ==
=== I'm new here. What is there for me to do and how can I help? ===
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
=== How do I create a new function, implementation, or test? ===
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
=== What should I edit first? ===
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
=== Where can I go for help? ===
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
=== How do we sort or categorize functions? ===
{{Tracked|T285424}}
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
[[Category:FAQ| {{#translation:}}]]
93wa9sj281eob1tqlsvpnicr9nw84sl
Wikifunctions:Report vandalism
4
1723
191287
191149
2025-06-06T13:58:29Z
Dv103
11127
191287
wikitext
text/x-wiki
{{Wikifunctions:Report vandalism/header/{{#ifexist:Wikifunctions:Report vandalism/header/{{int:lang}}|{{int:lang}}|en}}}}
{{Autoarchive resolved section
|age = 1
|archive = ((FULLPAGENAME))/Archive/((year))/((month:##))
|level = 2
}}
__NEWSECTIONLINK__
{{Archives|{{Special:PrefixIndex/WF:Report vandalism/Archive/|stripprefix=1}}}}
<!-- Add new reports below this line -->
== Report concerning User:IcelandHertz0 ==
{{vandal|1=IcelandHertz0}} — '''Reasons:''' Promotional content [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:37, 5 June 2025 (UTC)
:@[[User:Bunnypranav|Bunnypranav]] Isn't it a promotional-only account? Even the accont name is promotional [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:52, 5 June 2025 (UTC)
::Now that you say it, I see the username relation, blocked. Thanks! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 07:08, 5 June 2025 (UTC)
:{{done|Deleted}}, and warned. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:53, 5 June 2025 (UTC)
:{{Section resolved|1=<span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:47, 5 June 2025 (UTC)}}
== Report concerning User:Phatarapum ==
{{vandal|1=Phatarapum}} — '''Reasons:''' Either a vandalism, a test or just added the labels in the wrong language section (but if Google Translate is to be believed, the latter is unlikely) [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 13:58, 6 June 2025 (UTC)
t5pj5sm7nsrtdcb36jg6j1c0gnpk86n
191288
191287
2025-06-06T14:35:27Z
Bunnypranav
9976
/* Report concerning User:Phatarapum */ Reply
191288
wikitext
text/x-wiki
{{Wikifunctions:Report vandalism/header/{{#ifexist:Wikifunctions:Report vandalism/header/{{int:lang}}|{{int:lang}}|en}}}}
{{Autoarchive resolved section
|age = 1
|archive = ((FULLPAGENAME))/Archive/((year))/((month:##))
|level = 2
}}
__NEWSECTIONLINK__
{{Archives|{{Special:PrefixIndex/WF:Report vandalism/Archive/|stripprefix=1}}}}
<!-- Add new reports below this line -->
== Report concerning User:IcelandHertz0 ==
{{vandal|1=IcelandHertz0}} — '''Reasons:''' Promotional content [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:37, 5 June 2025 (UTC)
:@[[User:Bunnypranav|Bunnypranav]] Isn't it a promotional-only account? Even the accont name is promotional [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:52, 5 June 2025 (UTC)
::Now that you say it, I see the username relation, blocked. Thanks! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 07:08, 5 June 2025 (UTC)
:{{done|Deleted}}, and warned. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:53, 5 June 2025 (UTC)
:{{Section resolved|1=<span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:47, 5 June 2025 (UTC)}}
== Report concerning User:Phatarapum ==
{{vandal|1=Phatarapum}} — '''Reasons:''' Either a vandalism, a test or just added the labels in the wrong language section (but if Google Translate is to be believed, the latter is unlikely) [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 13:58, 6 June 2025 (UTC)
:@[[User:Dv103|Dv103]], the edit is of course non-constructive, but it does not seem ill-intentioned. I'd say better just slap a AGF warning and see if they continue. Do ping me if they continue. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 14:35, 6 June 2025 (UTC)
4vvwj8we8euw1aha8omn5neki89n1tb
191344
191288
2025-06-07T03:08:14Z
SpBot
978
archive 1 section: 1 to [[Wikifunctions:Report vandalism/Archive/2025/06]] (after section [[Wikifunctions:Report vandalism/Archive/2025/06#Report_concerning_User:IcelandHertz0|Report_concerning_User:IcelandHertz0]]) - previous edit: [[:User:Bunnypranav|Bunnypranav]], 2025-06-06 14:35
191344
wikitext
text/x-wiki
{{Wikifunctions:Report vandalism/header/{{#ifexist:Wikifunctions:Report vandalism/header/{{int:lang}}|{{int:lang}}|en}}}}
{{Autoarchive resolved section
|age = 1
|archive = ((FULLPAGENAME))/Archive/((year))/((month:##))
|level = 2
}}
__NEWSECTIONLINK__
{{Archives|{{Special:PrefixIndex/WF:Report vandalism/Archive/|stripprefix=1}}}}
<!-- Add new reports below this line -->
== Report concerning User:Phatarapum ==
{{vandal|1=Phatarapum}} — '''Reasons:''' Either a vandalism, a test or just added the labels in the wrong language section (but if Google Translate is to be believed, the latter is unlikely) [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 13:58, 6 June 2025 (UTC)
:@[[User:Dv103|Dv103]], the edit is of course non-constructive, but it does not seem ill-intentioned. I'd say better just slap a AGF warning and see if they continue. Do ping me if they continue. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 14:35, 6 June 2025 (UTC)
o2tdrg9stgbve1jead4k1yiciv2g9sw
Wikifunctions:FAQ/zh
4
3292
191370
181977
2025-06-07T04:44:09Z
FuzzyBot
207
Updating to match new version of source page
191370
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
本页解答Wikifunctions相关的常见问题。若本页未能解答您的疑惑,欢迎前往[[Wikifunctions talk:FAQ|讨论页]]发问。
另外,有關於Wikifunctions和抽象維基百科之中更一般的問題,是否考慮一下我們的[[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|元維基上的FAQ]]。
__TOC__
<span id="Introduction"></span>
== 簡介 ==
<span id="What_is_this_project_about?"></span>
=== 这个-{A|zh:项目;zh-hans:项目;zh-hant:專案;}-是关于什么的? ===
Wikifunctions是一个新兴的维基媒体项目,它提供了一个任何人都可调用、编写、维护和使用的多样化-{A|zh:函数;zh-hans:函数;zh-hant:函式;}-目录。该项目还提供了一种底层技术,它最终将能够把抽象维基百科(Abstract Wikipedia)中与语言无关的内容翻译成任何一种维基百科语言版本。这将让每个人都能用自己偏好的语言来贡献和阅读文章。
<span id="What_is_a_function?"></span>
=== 什么是函数? ===
函数是一种知识形态,能够回答问题,比如两个日期之间过去了多少天,或者两个城市之间的距离。更复杂的函数可以解答更复杂的问题,例如三维形状的体积,特定日期火星和金星之间的距离,或者两个物种是否在同一时间存活。
我们已经在许多类型的知识查询中使用了函数,例如向搜索引擎提问。英文维基百科上的模板,例如[[:w:en:Template:Convert|Template:Convert]]和[[:w:en:Template:Age|Template:Age]],也是一些已经在许多维基百科中使用的功能示例,这些功能是用wikitext和Lua编写的,并且需要手动复制到希望使用它们的每一个维基上。
<span id="What_is_an_implementation?"></span>
=== 什么是-{A|zh:实现;zh-hans:实现;zh-hant:實作;}-? ===
实现是一种特定的执行函数方式。实现就像是一个食譜,它列出了运行函数所需的步骤。它可能是编程语言中的一段-{zh-cn:代码;zh-tw:程式碼}-或是对其它函数调用的组合。一个函数可能有多个实现,这些实现应当都是等效的。
<span id="What_is_a_test?"></span>
== 什么是测试? ==
测试是一种确定给定函数是否正常工作的方法。一个函数通常会有多个测试,每个测试都会指定一些输入到该函数以及给定输入的输出必须满足的条件。
例如,「標題大小寫」功能的測試器應包括:「<span dir="ltr" lang="en">abc</span>」應該要變成「<span dir="ltr" lang="en">Abc</span>」;「<span dir="ltr" lang="en">war and peace</span>」應該要變成「<span dir="ltr" lang="en">War and Peace</span>」;「<span dir="ltr" lang="ru">война и мир</span>」應該要變成「6」;而「<span dir="ltr" lang="en">123</span>」應該要保持「<span dir="ltr" lang="en">123</span>」。
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
===哪些功能現在已經可用,哪些很快就會可用,哪些還需要更長的時間?===
* 發佈時:
** 我們能讓函數處理Strings和Booleans。
** Wikifunctions從一開始就會完全國際化。它可以用於任何一個語言。
* [[Wikifunctions:Status|正在開發中]]:
** 不完全支援泛型的類型和泛型的函式。
** 新增類型在目前僅限於開發團隊。未來,社群將可以新增更多的類型。未來還有許多工作要做,讓類型的行為更順暢。
*** 其中一種特別有趣的類型是二進位的資料,尤其是檔案。
** 我們目前支援兩種程式語言的實作:JavaScript和Python。未來,我們希望支援更多的語言。
** 目前,從以任何程式語言撰寫的實作中呼叫其他函式是'''不'''可能的。目前只能透過組合來實現。
* 在將來:
** 可以從其他維基媒體專案中呼叫Wikifunctions函式,並將其結果整合到頁面的輸出中。
** 可以在函式中使用來自維基數據的資料。
** 可以從維基共享資源的命名空間呼叫資料集。
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Wikifunctions是什麼樣的多語言?===
Wikifunctions與抽象維基百科在多種語言上彼此互不影響:
* '''Wikifunctions的內容和使用者介面都是多語言的'''。使用者可以用任何的自然語言來讀出和呼叫Wikifunctions上的函式。以下是函式「join string」的[https://www.wikifunctions.org/view/en/Z10000 英語]、[https://www.wikifunctions.org/view/pl/Z10000 波蘭語]和[https://www.wikifunctions.org/view/he/Z10000 希伯來語]版函式,這個函式其他更多語言的版本。
* '''貢獻者可以用他們的語言編輯和改進Wikifunctions'''。甚至是這些實作也都可以用貢獻者本身的自然語言來編輯。例如,合成函式「and」可以用[https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de 德文]、[https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en 英文]、或其他約有300種語言中的任何一種來編輯。
* '''Wikifunctions的函式可以為任何一種自然語言產出結果'''。社群正在創造越來越多的函式,以支援許多自然語言的文字產生。我們有許多的函式可用在[[Wikifunctions:Catalogue#Breton|布列塔尼語]]、[[Wikifunctions:Catalogue#Rohingya|羅辛亞語]]、[[Wikifunctions:Catalogue#English|英語]]以及許多其他語言。
* '''Wikifunctions中的函式可以用各種不同的程式語言來實作。'''例如,[[Z10000|join函式]]就是用[[Z10005|JavaScript]]和[[Z10004|Python]]這二種語言來實作。
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Wikifunctions目前支援哪些程式語言?未來將支援哪些程式語言?===
目前,Wikifunctions支援以JavaScript和Python語言寫成的實作。我們計劃在未來增加對更多程式語言的支援。我們希望在2025年至少再增加一種程式語言(但尚未決定是哪一種)。
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
===Wikifunctions將會如何整合到其他專案中?===
Wikifunctions是建立抽象維基百科的第一步。我們近期的重點是支援社群,並根據回饋進行改進。與此同時,我們將開始將其與維基百科和維基數據整合的過程,這將實現更廣泛的現實生活應用,使我們更接近「抽象維基百科」的願景。
貢獻者將能夠在他們的wiki中呼叫儲存在Wikifunctions網站中的函式。函式呼叫的結果將顯示給維基的讀者。例如,這可以用來計算一個人的年齡,根據Wikidata的人口和面積數據計算人口密度,或者繪製圖表並將其整合到指定的條目中。
整合维基函数的另一种方法是在wiki中整合交互式函数调用界面。例如,在维基百科條目中,可以根据读者提供的参数动态计算物理方程式的结果、绘制数学函数并与之互动等。
<span id="What_Wikifunctions_is_not?"></span>
=== 维基函数不是什么? ===
具体请见[[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]]。
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== 这些函数将使用什么许可协议去授權? ===
根據2021年11月至12月間[[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|在Meta上進行的討論]],所有對Wikifunctions和更廣泛的抽象維基百科專案的貢獻都將以自由授權的方式發表。特別是:
* 维基函式的[[Special:MyLanguage/Wikifunctions:Glossary#Content|文本内容]]使用[[w:zh:知识共享许可协议|創用CC授權 4.0]]协议。
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|函数签名]]和其它结构化內容採用[[w:zh:知识共享许可协议#授權類型|CC 0]]许可协议发表。
* Wikifunctions中的[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|-{zh-cn:代码;zh-tw:程式碼}-的實作]]將以[[w:zh:Apache许可证|Apache-{zh:许可证;zh-hans:许可证;zh-hant:授權條款;}-]]的方式發佈。
* 抽象維基百科的[[Special:MyLanguage/Wikifunctions:Glossary#Content|抽象內容]] 將以創用CC授權 4.0發表。
未來仍有一些問題需要解決,例如從抽象內容所產生內容的授權。我們計劃與法律部門一起起草一份更全面的文件,說明人們如何在遵守授權的前提下,盡可能輕鬆地重複使用維基功能中的-{zh-cn:代码;zh-tw:程式碼}-。
<span id="Contributing"></span>
== 作出贡献 ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
===我是新來的。我可以做些什麼?如何做?===
歡迎您 我們很高興您能來到這裡!您有許多機會為Wikifunctions貢獻心力,從建立新功能到改善和翻譯文件。如果您正在尋找參與的方法,我們建議您,根據您的適應程度,就您感興趣的主題建議一個新功能、或甚至創造一個這樣的函式、提供一些測試、嘗試實作、協助翻譯、閱讀並改進我們的文件、協助組織社群。
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== 新的函式我要如何建立、實作、或測試?===
若要瞭解如何建立新函式、實作、或測試,請參閱[[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:介绍]].
要詳細瞭解如何建立實作,請參閱[[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:如何创建函式的-{zh:实现;zh-hans:实现;zh-hant:實作;}-]]。
<span id="What_should_I_edit_first?"></span>
===我應該先編輯什麼?===
如果您會寫多種程式語言,請在[[Special:ListMissingLabels]]頁面上找找,函式的標籤和說明上面還沒有你所會的程式語言,然後協助加入這些函式。
如果您對某個Wikifunctions可以提供函式的領域有興趣,但該在領域內但卻還沒有;或者如果您對某些函式有更多的想法,你可以到[[Wikifunctions:Suggest a new function|建議新功能]]頁面,並提出您的想法。
如果您是JavaScript或Python的程式設計師,或許您會想要看看尚未以JavaScript或Python實作出來的函式,然後嘗試寫出這些函式。
<span id="Where_can_I_go_for_help?"></span>
=== 我可以去哪裡尋求協助?===
您的第一站應該是[[Special:MyLanguage/Help:Contents|幫助-{zh:门户;zh-hant:入口}-]],在這裡您可以找到所有與使用和編輯維基功能相關的文件。如果你還是卡住了,請在[[Wikifunctions:Project chat|專案聊天]]上發消息,會有人回答你的問題。
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== 如何进行分类工作? ===
{{Tracked|T285424}}
在現在,對函式進行排序或分類的最佳方法是手動在維基函式命名空間中的頁面中進行。另一個方法是透過該函式的討論頁。我們會監督這些工作,並與社群討論,系統的哪些變更會對這項任務有幫助。
[[Category:FAQ| {{#translation:}}]]
cllo8hk9otuwez32tm5gu4ofkiyould
Wikifunctions:FAQ/de
4
3396
191351
146326
2025-06-07T04:43:58Z
FuzzyBot
207
Updating to match new version of source page
191351
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Dies ist eine spezielle Seite für häufig gestellte Fragen zu Wikifunctions. Bitte stelle deine eigene Frage auf der [[Wikifunctions talk:FAQ|Diskussionsseite]], wenn deine Frage hier nicht aufgeführt ist!
Bitte sieh dir unser [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ auf Meta]] für allgemeinere Fragen zu Wikifunctions und der Abstrakten Wikipedia an.
__TOC__
<span id="Introduction"></span>
== Einführung ==
<span id="What_is_this_project_about?"></span>
=== Worum geht es bei diesem Projekt? ===
Wikifunctions ist ein neues Wikimedia-Projekt, das einen Katalog aller Arten von Funktionen bereitstellt, die jeder aufrufen, schreiben, verwalten und nutzen kann. Es stellt auch die zugrunde liegende Technologie bereit, die schließlich die Übersetzung sprachunabhängiger Artikel aus der abstrakten Wikipedia in die Sprache jeder Wikipedia ermöglichen wird. Dies ermöglicht es jedem, Beiträge in seiner bevorzugten Sprache zu leisten und Artikel in dieser Sprache zu lesen.
<span id="What_is_a_function?"></span>
=== Was ist eine Funktion? ===
Funktionen sind eine Form von Wissen, die Fragen beantworten kann, beispielsweise wie viele Tage zwischen zwei Daten vergangen sind oder wie groß die Entfernung zwischen zwei Städten ist. Kompliziertere Funktionen können kompliziertere Fragen beantworten, etwa das Volumen einer dreidimensionalen Form, den Abstand zwischen Mars und Venus an einem bestimmten Datum oder ob zwei Arten gleichzeitig lebten.
Wir nutzen Funktionen bereits bei vielen Arten von Wissensabfragen, beispielsweise beim Stellen einer Frage an eine Suchmaschine. Die Vorlagen, wie etwa [[:w:en:Template:Convert|Vorlage:Einheitenumrechnung]] und [[:w:en:Template:Age|Vorlage:Alter]] in der englischen Wikipedia, sind auch Beispiele für Funktionalitäten, die bereits in vielen Wikipedias verwendet werden, geschrieben in Wikitext und Lua und manuell in jedes Wiki kopiert, wo es benötigt wird.
<span id="What_is_an_implementation?"></span>
=== Was ist eine Implementierung? ===
Eine Implementierung ist eine bestimmte Art und Weise, eine Funktion auszuführen. Eine Implementierung ist ein Rezept, das die Schritte auflistet, die zum Ausführen der Funktion erforderlich sind. Dabei kann es sich um einen Codeabschnitt in einer Programmiersprache oder um eine Kombination von Aufrufen anderer Funktionen handeln. Eine Funktion kann viele Implementierungen haben, die alle gleichwertig sein sollten.
<span id="What_is_a_test?"></span>
=== Was ist ein Test? ===
Ein Test ist eine Möglichkeit, festzustellen, ob eine bestimmte Funktion das Richtige tut. Eine Funktion verfügt normalerweise über mehrere Tester, von denen jeder eine Eingabe für die Funktion und die Bedingungen, die die Ausgabe für die gegebene Eingabe erfüllen muss, angibt.
Tester für eine „Groß-/Kleinschreibung“-Funktion könnten beispielsweise Folgendes umfassen: „<span dir="ltr" lang="en">abc</span>“ sollte zu „<span dir="ltr" lang="en">Abc</span>“ werden; „<span dir="ltr" lang="en">war and peace</span>“ sollte zu „<span dir="ltr" lang="en">War and Peace</span>“ werden; „<span dir="ltr" lang="ru">война и мир</span>“ sollte zu „<span dir="ltr" lang="ru">Война и мир</span>“ werden; und „<span dir="ltr" lang="en">123</span>“ sollte „<span dir="ltr" lang="en">123</span>“ bleiben.
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Welche Funktionen sind jetzt verfügbar, welche werden bald verfügbar sein und welche sind in weiter Ferne? ===
* Beim Start:
** Wir haben die Möglichkeit, Funktionen zu haben, die mit Zeichenketten und Booleschen Werten arbeiten.
** Wikifunctions wird von Anfang an vollständig internationalisiert sein. Es kann in jeder Sprache verwendet werden.
* [[Wikifunctions:Status|Laufende Entwicklung]]:
** Generische Typen und generische Funktionen werden nicht vollständig unterstützt.
** Das Hinzufügen von Typen ist vorerst auf das Entwicklungsteam beschränkt. Zukünftig kann die Gemeinschaft weitere Typen hinzufügen. Es wird in Zukunft noch viel zu tun geben, um das Verhalten der Typen deutlich reibungsloser zu gestalten.
*** Ein besonders interessanter Typ werden Binärdaten und insbesondere Dateien sein.
** Wir unterstützen derzeit zwei Programmiersprachen für Implementierungen: JavaScript und Python. In Zukunft wollen wir noch viele weitere unterstützen.
** Es ist derzeit ''nicht'' möglich, andere Funktionen aus Implementierungen aufzurufen, die in einer Programmiersprache geschrieben sind. Dies ist derzeit nur für Kompositionen verfügbar.
* In der Zukunft:
** Es wird möglich sein, Wikifunctions-Funktionen aus anderen Wikimedia-Projekten aufzurufen und deren Ergebnisse in die Ausgabe der Seite zu integrieren.
** Es wird möglich sein, Daten aus Wikidata in Funktionen zu verwenden.
** Es wird möglich sein, Datensätze aus dem Daten-Namensraum auf Commons aufzurufen.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Wie ist Wikifunctions mehrsprachig? ===
Wikifunctions und die Abstrakte Wikipedia sind auf eine Reihe unterschiedlicher Arten mehrsprachig, die sich nicht beeinflussen:
* '''Wikifunctions ist in Bezug auf seinen Inhalt und seine Benutzeroberfläche mehrsprachig.''' Benutzer können Funktionen auf Wikifunctions in jeder natürlichen Sprache lesen und aufrufen. Hier ist die Funktion “verbinde” auf [https://www.wikifunctions.org/view/en/Z10000 Englisch], [https://www.wikifunctions.org/view/pl/Z10000 Polnisch] und [https://www.wikifunctions.org/view/he/Z10000 Hebräisch]. Außerdem ist sie in vielen weiteren Sprachen verfügbar.
* '''Beitragende können Wikifunctions in ihrer eigenen Sprache bearbeiten und verbessern.''' Selbst Implementierungen können in der Sprache des Beitragenden bearbeitet werden. Beispielsweise kann die Komposition der Funktion “und” auf [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de Deutsch], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en Englisch] oder in über 300 Sprachen bearbeitet werden.
* '''Wikifunctions-Funktionen können genutzt werden, um Ergebnisse für jede natürliche Sprache zu erstellen.''' Die Community erstellt eine wachsende Anzahl von Funktionen zur Unterstützung der Generierung von Text in vielen natürlichen Sprachen. Wir haben Funktionen für [[Wikifunctions:Catalogue#Breton|Bretonisch]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|Englisch]] und viele andere Sprachen.
* '''Funktionen auf Wikifunctions können in unterschiedlichen Programmiersprachen implementiert werden.''' Beispielsweise ist die Funktion [[Z10000|verbinde]] sowohl in [[Z10005|JavaScript]] als auch in [[Z10004|Python]] implementiert.
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Welche Programmiersprachen unterstützt Wikifunctions derzeit? Welche Programmiersprachen werden in Zukunft unterstützt? ===
Derzeit unterstützt Wikifunctions Implementierungen in JavaScript und Python. Wir planen, in Zukunft die Unterstützung weiterer Programmiersprachen zu ergänzen. Wir hoffen, 2025 mindestens eine weitere Programmiersprache hinzuzufügen (haben aber noch nicht entschieden welche).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Wie wird Wikifunctions in andere Projekte integriert werden? ===
Wikifunctions ist der erste Schritt zum Aufbau der Abstrakten Wikipedia. Unser kurzfristiger Fokus wird darauf liegen, die Gemeinschaft zu unterstützen und auf der Grundlage von Rückmeldungen Verbesserungen vorzunehmen. Gleichzeitig werden wir mit der Integration in Wikipedia und Wikidata beginnen, was breitere reale Anwendungen ermöglichen und uns der Vision der Abstrakten Wikipedia näher bringen wird.
Beitragende werden Funktionen, die auf Wikifunctions gespeichert sind, aus ihren Wikis aufrufen können. Das Ergebnis des Funktionsaufrufs wird den Lesern des Wikis angezeigt. Dies kann beispielsweise genutzt werden, um das Alter einer Person oder die Bevölkerungsdichte anhand der Daten zur Einwohnerzahl und Größe des Gebiets aus Wikidata zu berechnen oder einen Graphen zu zeichnen und diesen in einen bestimmten Artikel einzubinden.
Eine weitere Option zur Integration von Wikifunctions wird es sein, eine interaktive Benutzeroberfläche für den Abruf von Funktionen in ihrem Wiki zu integrieren. Dies kann beispielsweise genutzt werden, um in einem Wikipedia-Artikel dynamisch das Ergebnis einer physikalischen Gleichung basierend auf Parametern des Lesers zu berechnen oder um mathematische Funktionen darzustellen und mit ihnen zu interagieren, etc.
<span id="What_Wikifunctions_is_not?"></span>
=== Was ist Wikifunctions nicht? ===
Siehe bitte [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:Was Wikifunctions nicht ist]] für weitere Informationen dazu.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Unter welcher Lizenz werden Funktionen und von ihnen abgeleitete Inhalte stehen? ===
Gemäß der Diskussion [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|auf Meta im November und Dezember 2021]] werden alle Beiträge zu Wikifunctions und den umfassenderen Projekten der Abstrakten Wikipedia unter freien Lizenzen veröffentlicht. Konkret:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Textinhalte]] auf Wikifunctions werden unter [[:de:Creative-Commons-Lizenz|CC BY-SA 4.0]] veröffentlicht.
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Funktionssignaturen]] und andere strukturierte Inhalte auf Wikifunctions werden unter [[:de:CC0|CC 0]] veröffentlicht.
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code-Implementierungen]] in Wikifunctions werden unter der [[:de:Apache-Lizenz|Lizenz Apache 2]] veröffentlicht.
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstrakter Inhalt]] für die Abstrakte Wikipedia wird unter CC BY-SA 4.0 veröffentlicht.
Es gibt noch einige Punkte, die in Zukunft geklärt werden müssen, beispielsweise die Lizenzierung der generierten Inhalte aus den abstrakten Inhalten. Wir planen, mit der Rechtsabteilung ein umfassenderes Dokument darüber zu verfassen, wie Menschen Code aus Wikifunctions unter Einhaltung der Lizenz so problemlos wie möglich wiederverwenden können.
<span id="Contributing"></span>
== Beitragen ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Ich bin neu hier. Was kann ich tun und wie kann ich helfen? ===
Willkommen! Wir freuen uns sehr, dass du da bist! Es gibt viele Möglichkeiten, zu Wikifunctions beizutragen, von der Erstellung neuer Funktionen bis hin zur Verbesserung und Übersetzung der Dokumentation. Wenn du nach Möglichkeiten suchst, dich zu engagieren, empfehlen wir dir, abhängig von deinem Komfortniveau, vielleicht eine neue Funktion zu einem Thema vorzuschlagen, das dich interessiert. Oder du erstellst sogar eine solche Funktion. Stelle einige Tests bereit. Versuche dich an einer Implementierung. Hilf bei Übersetzungen. Lies und verbessere unsere Dokumentation. Hilf bei der Organisation der Gemeinschaft.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Wie erstelle ich eine neue Funktion, Implementierung oder einen Test? ===
Um zu sehen, wie man eine neue Funktion, Implementierung oder einen Test erstellt, siehe [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Einführung]].
Für weitere Details zur Erstellung einer Implementierung siehe [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:Wie man Implementierungen erstellt]].
<span id="What_should_I_edit_first?"></span>
=== Was sollte ich als erstes bearbeiten? ===
Wenn du in mehreren Sprachen schreiben kannst, suche auf der Seite [[Special:ListMissingLabels]] nach Funktionen, für die es in deinen Sprachen noch keine Bezeichnungen und Beschreibungen gibt, und hilf dabei, sie hinzuzufügen.
Wenn du Interesse an einer Domain hast, die Funktionen in Wikifunctions bieten könnte, dies aber noch nicht tut, oder wenn du weitere Ideen für Funktionen hast, gehe zur Seite für [[Wikifunctions:Suggest a new function|Vorschläge für neue Funktionen]] und präsentiere deine Ideen.
Wenn du JavaScript oder Python programmierst, möchtest du vielleicht nach Funktionen suchen, die noch keine Implementierungen in JavaScript oder Python haben, und versuchen, diese zu schreiben.
<span id="Where_can_I_go_for_help?"></span>
=== Wo kann ich Hilfe erhalten? ===
Deine erste Anlaufstelle sollte das [[Special:MyLanguage/Help:Contents|Hilfeportal]] sein, wo du die gesamte Dokumentation zur Verwendung und Bearbeitung von Wikifunctions findest. Wenn du immer noch nicht weiterkommst, hinterlasse eine Nachricht in der [[Wikifunctions:Project chat|Projektdiskussion]] und jemand wird deine Frage beantworten.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Wie sortieren oder kategorisieren wir Funktionen? ===
{{Tracked|T285424}}
Der beste Weg, Funktionen zu sortieren oder zu kategorisieren, besteht derzeit darin, die Seiten im Wikifunctions-Namensraum manuell zu durchsuchen. Eine andere Möglichkeit wäre die Diskussionsseite der jeweiligen Funktion. Wir werden diese Bemühungen beobachten und mit der Gemeinschaft diskutieren, welche Änderungen am System für diese Aufgabe hilfreich wären.
[[Category:FAQ| {{#translation:}}]]
0ywesu00pwq38d9vqegbru16xv79pr5
Wikifunctions:FAQ/ja
4
3410
191358
146083
2025-06-07T04:44:03Z
FuzzyBot
207
Updating to match new version of source page
191358
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
ここはウィキファンクションズに関するよくある質問の専用ページです。ここに記載されていない質問があれば、[[Wikifunctions talk:FAQ|トークページ]]で質問してください!
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== はじめに ==
<span id="What_is_this_project_about?"></span>
=== ここはどんなプロジェクトですか? ===
ウィキファンクションズはウィキメディアの新しいプロジェクトで、誰もが呼び出し、作成、維持、利用できるあらゆる種類の関数のカタログを提供しています。また、言語に依存しない記事を抽象ウィキペディアから任意のウィキペディアの言語に翻訳することを最終的に可能にする基盤技術も提供しています。これによって、誰もが自分の好きな言語で記事を投稿したり読んだりすることができます。
<span id="What_is_a_function?"></span>
=== 関数とは何ですか? ===
関数とは、2つの日付の間に何日が経過したか、2つの都市の間の距離といった質問に答えることができる知識の一形態です。より複雑な関数は、3次元形状の体積、特定の日付における火星と金星の間の距離、2つの種が同時に生きていたかどうかなど、より複雑な質問に答えることができます。
私たちはすでに、検索エンジンに質問をするなど、多くの種類の知識照会で関数を使用しています。英語版ウィキペディアの[[:w:en:Template:Convert|Template:Convert]]や[[:w:en:Template:Age|Template:Age]]などのテンプレートも、多くのウィキペディアですでに使用されている関数の例であり、ウィキテキストとLuaで記述され、必要な各ウィキに手動でコピーされています。
<span id="What_is_an_implementation?"></span>
=== 実装とは何ですか? ===
<div class="mw-translate-fuzzy">
実装とは、関数を実行するための決まったやり方です。実装とは、関数の実行に必要な手順をリストしたレシピです。これは、プログラミング言語のコードの一部である場合もあれば、他の関数への呼び出しの組合せである場合もあります。関数には多数の実装があるかもしれませんが、すべて同等である必要があります。
</div>
<span id="What_is_a_test?"></span>
=== テストとは何ですか? ===
テストとは、特定の関数が正しいことを行っているかどうかを判断するやり方です。関数には通常、複数のテスターがあり、それぞれが関数への入力と、指定された入力に対する出力が満たさなければならない条件を指定します。
たとえば、「title case」関数のテスターには、「<span dir="ltr" lang="en">abc</span>」は「<span dir="ltr" lang="en">Abc</span>」になる、「<span dir="ltr" lang="en">war and peace</span>」は「<span dir="ltr" lang="en">War and Peace</span>」になる、「<span dir="ltr" lang="ru">война и мир</span>」は「<span dir="ltr" lang="ru">Война и мир</span>」になる、「<span dir="ltr" lang="en">123</span>」は「<span dir="ltr" lang="en">123</span>」のまま、といった内容が含まれるでしょう。
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== 機能のうち現在利用可能なもの、間もなく利用可能になるもの、および随分先になるものはどういったものですか? ===
* ローンチ時点:
** StringとBooleanを扱う関数を持つことができます。
** ウィキファンクションズは当初から完全に国際化されます。どんな言語でも使うことができます。
* [[Wikifunctions:Status|進行中の開発]]:
** <span class="mw-translate-fuzzy">ジェネリック型とジェネリック関数は完全にはサポートされていません。</span>
** <span class="mw-translate-fuzzy">型の追加は、今のところ開発チームに限定されています。将来的には、コミュニティ自身が型を追加できるようになります。型の動作をよりスムーズにするために、今後多くの作業が行われます。</span>
*** 特に興味深い型のひとつは、バイナリデータ、特にファイルです。
** <span class="mw-translate-fuzzy">現在は、JavaScriptとPythonの2つの実装用プログラミング言語をサポートしています。将来的には、さらに多くの言語をサポートしたいと考えています。</span>
** <span class="mw-translate-fuzzy">現在は、他のプログラミング言語で書かれた実装から他の関数を呼び出すことはでき''ません''。</span>
* 将来構想:
** <span class="mw-translate-fuzzy">他のWikimediaプロジェクトからウィキファンクションズ関数を呼び出し、その結果をページの出力に統合することが可能となるでしょう。</span>
** 関数内でウィキデータのデータを利用できるようになるでしょう。
** コモンズのデータ名前空間からデータセットを呼び出せるようになるでしょう。
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== ウィキファンクションズは他のプロジェクトにどのように統合されるでしょうか? ===
ウィキファンクションズは、抽象ウィキペディアの構築に向けた第一歩です。短期的には、コミュニティをサポートし、フィードバックに基づいて改善を行うことにフォーカスします。同時に、ウィキペディアとウィキデータを統合するプロセスを開始します。これにより、より広範な実生活アプリケーションが可能になり、抽象ウィキペディアのビジョンに近づくことができます。
<div class="mw-translate-fuzzy">
投稿者は、自分のWiki内からウィキファンクションズを通じて関数を呼び出すことができます。Wikiの読者には、関数呼び出しの結果が表示されます。これは、たとえば、ウィキデータの人口と面積のデータに基づいて年齢、人口密度を計算したり、グラフを描いて特定の記事に統合したりするために使用できます。
</div>
ウィキファンクションズを統合するもう1つの選択肢は、対話的な関数呼び出しインターフェースをWiki内に統合することです。これは、例えば、ウィキペディアの記事で、読者が与えたパラメータに基づいて物理方程式の結果を動的に計算したり、数学関数を描画して相互作用したりするのに使えます。
<span id="What_Wikifunctions_is_not?"></span>
<div class="mw-translate-fuzzy">
=== ウィキファンクションズは何でないか ===
</div>
詳細については、[[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]]を参照してください。
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== 関数と派生コンテンツにはどのようなライセンスが適用されますか? ===
<div class="mw-translate-fuzzy">
[[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]]で行われた議論によると、ウィキファンクションズとより広範な抽象ウィキペディアプロジェクトへのすべての貢献は、無料ライセンスの下で公開されます。特に:
</div>
* ウィキファンクションズの[[Special:MyLanguage/Wikifunctions:Glossary#Content|テキストコンテンツ]]は、[[w:クリエイティブ・コモンズ・ライセンス|CC BY-SA 4.0]]で公開されます。
* ウィキファンクションズにおける[[Special:MyLanguage/Wikifunctions:Glossary#Function|関数シグネチャ]]およびにそれ以外の構造化コンテンツは、[[w:ja:CC0|CC 0]]の下で公開されます。
* ウィキファンクションズの[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|コード実装]]は、[[w:ja:Apache License|Apache 2ライセンス]]の下で公開されます。
* 抽象ウィキペディアの[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]]は、CC BY-SA 4.0の下で公開されます。
抽象コンテンツから生成されたコンテンツのライセンスなど、今後対処する必要がある点がまだいくつかあります。ライセンスを遵守しながら、ウィキファンクションズのコードを可能な限り問題なく再利用する方法について、法務部門とより包括的な文書を作成する予定です。
<span id="Contributing"></span>
== 貢献 ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== ここに来るのは初めてです。何かお手伝いできることはありますか? ===
ようこそ!あなたがここにいてくれてとてもうれしいです!新しい関数の作成から文書の改善や翻訳に至るまで、ウィキファンクションズに貢献する機会はたくさんあります。参加する方法を探しているのであれば、好みのレベルに応じて、興味のあるトピックに新しい関数を提案することをお勧めします。あるいは、そのような関数を作成することもお勧めします。いくつかのテストを提供してください。実装を試してみてください。翻訳を手伝ってください。文書を読んで改善してください。コミュニティの組織化を手伝ってください。
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== 新しい関数、実装、テストを作成するにはどうすればよいですか? ===
新しい関数、実装、またはテストの作成方法については、[[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]]を参照してください。
実装の作成方法の詳細については、[[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]]を参照してください。
<span id="What_should_I_edit_first?"></span>
=== 最初は何を編集したら良いですか? ===
<div class="mw-translate-fuzzy">
もしあなたが複数の言語を話すのであれば、あなたの言語のラベルや説明をまだ持っていない関数を見つけて、それらを追加する手助けをしてください。
</div>
<div class="mw-translate-fuzzy">
もしあなたが、ウィキファンクションズで関数を提供する可能性のあるドメインに興味を持っているがまだ存在していないなかったり、関数についてもっとアイデアがある場合は、[[Wikifunctions:Suggest a new function|suggesting new functions]]のページにアクセスして、アイデアを発表してください。
</div>
もしあなたがJavaScriptやPythonをコーディングできるのであれば、JavaScriptやPythonでまだ実装されていない関数をチェックして、それらを作成したいと思うかもしれません。
<span id="Where_can_I_go_for_help?"></span>
=== 助けがほしいときは、どこに行けばいいですか? ===
<div class="mw-translate-fuzzy">
最初に立ち寄るべきは[[Special:MyLanguage/Help:Contents|Help portal]]で、ウィキデータの使い方や編集の仕方についての説明文書がすべてみつかると思います。それでもまだ行き詰まっているなら、[[Wikifunctions:Project chat|Project chat]]にメッセージを投稿してみてください。誰かがあなたの質問に答えてくれるでしょう。
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== 関数のソートやカテゴライズはどうしますか? ===
{{Tracked|T285424}}
今のところ、関数をソートしたり分類したりする最善の方法は、Wikifunctions名前空間のページを使って手動で行うことです。もう1つの選択肢は、指定された関数のトークページを使うことです。私たちはこれらの取り組みを監視し、システムのどの変更がこのタスクに役立つかをコミュニティと議論する予定です。
[[Category:FAQ| {{#translation:}}]]
3r62xx4jcnuc09hcn2g2i6i2s8mrbzy
Wikifunctions:FAQ/ru
4
3559
191365
146088
2025-06-07T04:44:06Z
FuzzyBot
207
Updating to match new version of source page
191365
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Эта страница содержит ответы на часто задаваемые вопросы о Викифункциях. Если вашего вопроса здесь еще нет, вы можете задать его на [[Wikifunctions talk:FAQ|странице обсуждения]].
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Введение ==
<span id="What_is_this_project_about?"></span>
=== О чем этот проект? ===
Викифункции – новый проект Викимедиа, содержащий каталог всех видов функций, которые любой может вызвать, написать, поддерживать и использовать. Проект также предоставляет базовую технологию, которая впоследствии позволит переводить не зависящие от языка статьи из абстрактной Википедии на язык любого раздела Википедии. Это позволит любому участнику редактировать и читать статьи на предпочитаемом языке.
<span id="What_is_a_function?"></span>
=== Что такое функция? ===
Функции — это форма знаний, которая может ответить на вопросы, такие как, сколько дней прошло между двумя датами или расстояние между двумя городами. Более сложные функции могут ответить на более сложные вопросы, такие как объем трехмерной формы, расстояние между Марсом и Венерой в определенную дату или жили ли два вида в одно время.
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<span id="What_is_an_implementation?"></span>
=== Что такое реализация? ===
<div class="mw-translate-fuzzy">
Реализация — это определенный способ выполнения функции. Реализация — это рецепт, в котором перечислены шаги, необходимые для выполнения функции. Это может быть кусок кода в языке программирования или комбинация вызовов к другим функциям. Функция может иметь много вариантов реализации, и все они должны быть эквивалентными.
</div>
<span id="What_is_a_test?"></span>
=== Что такое тест? ===
Тест — это способ определить, правильно ли выполняется функция. Функция, обычно, будет иметь несколько тестеров, каждый из которых указывает некоторые входные данные для функции и условия, которым должен удовлетворять результат выполнения функции для этих входных данных.
Например, тестеры для функции "регистр заголовка" могут включать: "<span dir="ltr" lang="en">abc</span>" должен стать "<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" должен стать " <span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" должен стать " <span dir="ltr" lang="ru">война и мир</span>"; и "<span dir="ltr" lang="en">123</span>" должен оставаться "<span dir="ltr" lang="en">123</span>".
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** В настоящее время ''не'' возможно вызывать другие функции с помощью реализаций, написанных на другом языке программирования.
* В будущем:
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== Чем не являются Викифункции? ===
Пожалуйста, см. [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Викифункции:Чем не являются Викифункции]] для получения дополнительной информации по этому вопросу.
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== Участие ==
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== Где я могу найти помощь? ===
<div class="mw-translate-fuzzy">
Первым делом изучите [[Special:MyLanguage/Help:Contents|портал помощи]], где вы найдете всю документацию, связанную с использованием и редактированием Викифункций. Если у Вас ещё остались вопросы, разместите сообщение на [[Wikifunctions:Project chat|форуме]], кто-то ответит на ваш вопрос.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Как мы сортируем или категоризируем функции? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
g5621sexq8t8o2f42incy2toshhcvib
Wikifunctions:FAQ/sv
4
3573
191367
146113
2025-06-07T04:44:07Z
FuzzyBot
207
Updating to match new version of source page
191367
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Detta är en sida för vanligaste frågorna om Wikifunctions. Känn dig fri att ställa dina egna frågor på [[Wikifunctions talk:FAQ|diskussionssidan]] om din fråga inte besvaras här!
Läs gärna också vår [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ på Meta]] som har mer allmänna frågor om Wikifunctions och abstrakta Wikipedia.
__TOC__
<span id="Introduction"></span>
== Introduktion ==
<span id="What_is_this_project_about?"></span>
=== Vad handlar projektet om? ===
Wikifunctions är ett nytt Wikimediaprojekt som erbjuder en katalog över alla möjliga sorters funktioner som vem som helst kan anropa, skriva, underhålla och använda. Det erbjuder också den underliggande teknologin som till slut kommer möjliggöra översättning av språkoberoende artiklar från Abstrakta Wikipedia till alla Wikipedias språk. Detta kommer möjliggöra för alla att bidra och läsa artiklar på sitt föredragna språk.
<span id="What_is_a_function?"></span>
=== Vad är en funktion? ===
Funktioner är ett sorts kunskap som kan besvara frågor, som till exempel hur många dagar som gått mellan två datum eller avståndet mellan två städer. Mer komplicerade funktioner kan svara på mer komplicerade frågor, såsom volymen av en tredimensionell form, avståndet mellan Mars och Venus vid ett angivet datum eller om två arter levde samtidigt.
Vi använder redan funktioner i flera formar av kunskapsfrågor, som när vi ställer frågor till en sökmotor. Mallar, såsom [[:w:en:Template:Convert|Template:Convert]] och [[:w:en:Template:Age|Template:Age]] på engelskspråkiga Wikipedia, är också exempel på funktionalitet som vi redan använder på flera Wikipediaversioner, skrivna i wikitext och Lua och manuellt kopierad till varje enskild wiki där det önskas.
<span id="What_is_an_implementation?"></span>
=== Vad är en implementering? ===
En implementation är visst sätt att köra en funktion. En implementation är ett recept som listar alla steg som behövs för att köra funktionen. Det kan vara en bit kod på ett programmeringsspråk eller en kombination av anrop av andra funktioner. En funktion kan ha flera implementationer vilka alla borde vara likvärdiga.
<span id="What_is_a_test?"></span>
=== Vad är ett test? ===
Ett test är ett sätt att bestämma om en viss funktion gör rätt sak. En funktion kommer oftast ha flera testare, där varje anger någon inmatning till funktionen och villkoren som den angivna inmatningen måste uppfylla.
Till exempel kan testare för en "titelkapitaliserings"-funktion kan innehålla: "<span dir="ltr" lang="en">abc</span>" borde bli "<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" borde bli "<span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" borde bli "<span dir="ltr" lang="ru">Война и мир</span>"; och "<span dir="ltr" lang="en">123</span>" borde bli förbli "<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Vilka funktioner är tillgängliga nu, vilka blir snart tillgängliga och vilka är längre bort? ===
* Vid starten:
** Vi kan ha funktioner som fungerar med strängar och booleaner.
** Wikifunctions kommer vara fullt internationaliserad från början och kan användas på alla språk.
* [[Wikifunctions:Status|Fortsatt utveckling]]:
** Allmänna typer och allmänna funktioner stöds inte helt.
** Att lägga till typer kommer för tillfället vara något som begränsas till utvecklingsteamet. I framtiden kommer gemenskapen kunna lägga till fler typer. Det finns mycket arbete att göra i framtiden för att få typer att bete sig smidigare.
*** En särskilt intressant typ kommer vara binär data och särskilda filer.
** Vi stödjer för tillfället två programmeringsspråk för implementationer: JavaScript och Python. I framtiden vill vi stödjer fler.
** Man kan för tillfället ''inte'' anropa andra funktioner från implementationer skrivna i något programmeringsspråk. Detta kan man för närvarande endast uppnå med komposition.
* I framtiden:
** Det går att anropa Wikifunctions-funktioner från andra Wikimediaprojekt och integrera deras resultat i sidans utmatning.
** Man kommer kunna använda data från Wikidata i funktioner.
** Man kan kommer kunna anropa datauppsättningar från Commons Data-namnrymd.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Hur är Wikifunctions flerspråkigt? ===
Wikifunctions och abstrakta Wikipedia är flerspråkiga på flera olika sätt som inte påverkar varandra:
* '''Wikifuntions är flerspråkigt vad gäller dess innehåll och användargränssnitt.''' Användare kan läsa och anropa funktioner på Wikifunctions på valfritt naturligt språk. Här är funktionen "slå ihop sträng" på [https://www.wikifunctions.org/view/en/Z10000 engelska], [https://www.wikifunctions.org/view/pl/Z10000 polska] och [https://www.wikifunctions.org/view/he/Z10000 hebreiska] och den är tillgänglig på fler språk.
* '''Bidragsgivare kan redigera och förbättra Wikifunctions på sitt eget språk.''' Även implementationer kan redigeras på bidragsgivarens eget språk. Till exempel kan kompositionen hos funktionen "and" redigeras på [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de tyska], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en engelska] eller något annat av runt 300 språk.
* '''Wikifunctions-funktioner kan användas för att skapa resultat för valfritt naturligt språk.''' Gemenskapen skapar ett växande antal funktioner för att stödja generering av text på många naturliga språk. Vi har funktioner för [[Wikifunctions:Catalogue#Breton|bretonska]], [[Wikifunctions:Catalogue#Rohingya|rohingya]], [[Wikifunctions:Catalogue#English|engelska]] och många fler språk.
* '''Funktioner på Wikifunctions kan implementeras på flera olika programmeringsspråk.''' Till exempel så implementeras [[Z10000|funktionen join]] i både [[Z10005|JavaScript]] och i [[Z10004|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Vilka programmeringsspråk stödjer Wikifunctions för tillfället? Vilka programmeringsspråk kommer stödjas i framtiden? ===
För nuvarande stödjer Wikifunctions implementationer skrivna i JavaScript och Python. Vi planerar att lägga till stöd för flera programmeringsspråk i framtiden. Vi hoppas kunna lägga till minst ett programmeringsspråk till under 2025 (men har ännu inte bestämt vilket).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Hur kommer Wikifunctions integreras med andra projekt? ===
Wikifunctions är det första steget mot att bygga upp abstrakta Wikipedia. Vi kommer i närtid att fokusera på att stödja gemenskapen och genomföra förbättringar baserat på återkoppling. Samtidigt kommer vi inleda processen med att integrera det med Wikipedia och Wikidata, som kommer möjliggöra bredare tillämpning i verkliga livet och röra oss närmare målsättning med abstrakta Wikipedia.
Bidragsgivare kommer kunna anropa funktioner som lagras på Wikifunctions inifrån sina wikier. Funktionens resultat kommer visas för wikins läsare kommer. Detta kan exempelvis användas för att beräkna en persons ålder, befolkningstätheten baserat på befolkning och områdesdata från Wikidata eller rita ett diagram och integrera det i en viss artikel.
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== Vad är inte Wikifunctions? ===
Se [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] för mer information om det.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Vilken licens kommer funktioner och härlett material publiceras under? ===
Efter en diskussion [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|på Meta mellan november och december 2021]] kommer alla bidrag till Wikifunctions och bredare abstrakta Wikipedia-projekten publiceras under fri licens. I synnerhet:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Textmaterial]] på Wikifunctions kommer publiceras under [[w:Creative Commons license|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Funktionssignaturer]] och annat strukturerat innehåll på Wikifunctions kommer publiceras under [[w:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Kodimplementationer]] på Wikifunctions kommer publiceras under [[w:Apache License|licensen Apache 2]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstrakt innehåll]] för abstrakta Wikipedia kommer publiceras under CC BY-SA 4.0.
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== Bidra ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Jag är ny här. Vad behöver göras och hur kan jag hjälpa till? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== Vart kan jag vända mig för att få hjälp? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do we sort or categorize functions? ===
</div>
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
g6pf7gmzic0t81z314z7buoo9w9qcsy
Wikifunctions:FAQ/it
4
8471
191357
174736
2025-06-07T04:44:01Z
FuzzyBot
207
Updating to match new version of source page
191357
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Questa è una pagina dedicata alle domande frequenti su Wikifunctions. Puoi inviare le tue domande nella [[Wikifunctions talk:FAQ|pagina di discussione]] se non trovi una risposta in questa pagina!
Inoltre, considera le nostre [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ su Meta]] per le domande più generali su Wikifunctions e Abstract Wikipedia
__TOC__
<span id="Introduction"></span>
== Introduzione ==
<span id="What_is_this_project_about?"></span>
=== Di cosa si occupa questo progetto? ===
Wikifunctions è un nuovo progetto Wikimedia che fornisce un catalogo di tutti i tipi di funzioni che chiunque può chiamare, scrivere, mantenere e utilizzare. Fornisce inoltre la tecnologia sottostante che permetterà la traduzione di articoli indipendenti da Abstract Wikipedia nella lingua di ogni Wikipedia. Ciò permetterà a tutti di contribuire e leggere gli articoli nella lingua che preferiscono.
<span id="What_is_a_function?"></span>
=== Cos'è una funzione? ===
Le funzioni sono una forma di conoscenza che può rispondere alle domande, come ad esempio il numero di giorni trascorsi tra due date o la distanza tra due città. Funzioni più complicate possono rispondere a domande più complicate, come il volume di una forma tridimensionale, la distanza tra Marte e Venere in una data determinata, o se due specie erano vive nello stesso periodo storico.
Usiamo già delle funzioni in molti tipi di ricerca delle informazioni, ad esempio facendo una domanda ad un motore di ricerca. I template, come ad esempio [[:w:en:Template:Convert|Template:Convert]] e [[:w:en:Template:Age|Template:Age]] nella Wikipedia Inglese, sono un esempio di funzionalità che sono già usate in molte versioni di Wikipedia, scritti in wikitesto e Lua e manualmente copiati in tutti i wiki in cui sono necessari.
<span id="What_is_an_implementation?"></span>
=== Cos'è una implementazione? ===
Un'implementazione è un modo particolare di eseguire una funzione. Un'implementazione è una ricetta che elenca i passaggi necessari per eseguire la funzione. Potrebbe essere un pezzo di codice in un linguaggio di programmazione, o una combinazione di chiamate ad altre funzioni. Una funzione può avere molte implementazioni, tutte strettamente equivalenti.
<span id="What_is_a_test?"></span>
=== Cos'è un test? ===
Un test è un modo per determinare se una determinata funzione sta facendo la cosa giusta. Una funzione avrà in genere più test, ognuno dei quali specifica alcuni ingressi alla funzione e le condizioni che l'uscita per il dato ingresso deve soddisfare.
Ad esempio, i test per una funzione "converti in Title Case" potrebbero includere: "<span dir="ltr" lang="en">abc</span>" diventa "<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" diventa "<span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" diventa "<span dir="ltr" lang="ru">Война и мир</span>"; "<span dir="ltr" lang="en">123</span>" rimane "<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Quali funzionalità sono già diponibili, quali lo saranno presto, e quali sono più distanti? ===
* Al lancio:
** Abbiamo la capacità di avere funzioni che funzionano con Stringhe e Booleani.
** Wikifunzions sarà completamente internazionalizzato fin dall'inizio. Può essere usato in qualsiasi lingua.
* [[Wikifunctions:Status|Sviluppi attuali]]:
** I tipi generici e le funzioni generiche non sono pienamente supportati.
** L'aggiunta di tipi, per ora, è limitato al team di sviluppo. Nel futuro, la comunità sara capace di aggiungere nuovi tipi. C'è molto lavoro che dovrà essere fatto per far funzionari i tipi in modo molto più fluido.
*** Un tipo particolarmente interessante saranno i dati binari, e in particolare i file.
** Attualmente supportiamo due linguaggi di programmazione per le implementazioni: JavaScript e Python. In futuro, abbiamo intenzione di supportarne molti altri.
** Attualmente, ''non'' è possibile chiamare altre funzioni dall'implementazione scritta in un qualsiasi linguaggio di programmazione. Questo è possibile solo tramite la composizione.
* In futuro:
** Sarà possibile chiamare le funzioni Wikifunctions da altri progetti Wikimedia e integrare i loro risultati nell'output della pagina.
** Sarà possibile utilizzare i dati di Wikidata nelle funzioni.
** Sarà possibile richiamare insieme di dati dal namespace di Commons Data.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== In che modo Wikifunctions è multilingue? ===
Wikifunctions e la Wikipedia astratta sono multilingua in diversi modi indipendenti:
* '''Wikifunctions è multilingua in termini di contenuti e di interfaccia utente'''. Gli utenti possono leggere e chiamare funzioni su Wikifunctions in qualsiasi lingua naturale. Ecco la funzione "concatena stringhe" in [https://www.wikifunctions.org/view/en/Z10000 inglese], [https://www.wikifunctions.org/view/pl/Z10000 polacco] ed [https://www.wikifunctions.org/view/he/Z10000 ebraico]; è disponibile in molte altre lingue.
* '''I contributori possono modificare e migliorare Wikifunctions usando la loro lingua.''' Ogni implementazione può essere modificata nella lingua madre di ogni utente. Per esempio, la composizione della funzione "e" può essere modificata in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de tedesco], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en inglese] o in ognuna delle circa 300 lingue.
* '''Le funzioni di Wikifunctions possono essere usate per restituire risultati in ogni lingua.''' La comunità sta creando un numero crescente di funzioni che supportano la generazione di testi in numerose lingue. Abbiamofunzioni per il [[Wikifunctions:Catalogue#Breton|Bretone]], il [[Wikifunctions:Catalogue#Rohingya|Rohingya]], l'[[Wikifunctions:Catalogue#English|Inglese]] e molte altre lingue.
* '''Le funzioni di Wikifunctions possono essere implementate con linguaggi di programmazione differenti.''' Ad esempio, la funzione [[Z10000]] è implementata sia in [[Z10005|JavaScript]] che in [[Z10004|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Quali linguaggi di programmazione vengono attualmente supportati? Quali saranno supportati nel futuro? ===
Attualmente, Wikifunctions supporta le implementazioni scritte in JavaScript e Python. In futuro, intendiamo aggiungere il supporto per altri linguaggi di programmazione. Speriamo di aggiungere almeno un altro linguaggio di programmazione entro il 2025 (ma non abbiamo ancora deciso quale).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Come sarà integrata Wikifunctions negli altri progetti? ===
Wikifunctions è il primo passo verso la costruzione di Abstract Wikipedia. Il nostro obiettivo a breve termine sarà sostenere la comunità e migliorare in base al feedback. Allo stesso tempo, inizieremo il processo di integrazione con Wikipedia e Wikidata, che consentirà applicazioni più ampie nella vita reale e ci avvicinerà alla visione di Abstract Wikipedia.
I contributori potranno chiamare le funzioni memorizzate sul sito Wikifunctions dal loro wiki. Il risultato della chiamata verrà visualizzato ai lettori della wiki. Questo può essere utilizzato, ad esempio, per calcolare l'età di una persona, la densità di popolazione basata su dati sulla popolazione e sull'area di Wikidata, o per disegnare un grafico e integrarlo in un articolo.
Un'altra opzione per integrare Wikifunctions sarà quella di integrare un'interfaccia per richiamare una funzione all'interno di una wiki. Questa interfaccia potrebbe essere usata, per esempio, in una voce di Wikipedia per calcolare il risultato di un'equazione fisica basandosi su parametri forniti dal lettore, disegnare ed interagire con funzioni matematiche, ecc.
<span id="What_Wikifunctions_is_not?"></span>
=== Cosa non è Wikifunctions? ===
Consulta [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:Cosa non è Wikifunctions]] per maggiori informazioni.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Sotto quale licenza saranno le funzioni e il contenuto collegato? ===
In accordo con la discussione che si è tenuta [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|su Meta tra novembre e dicembre 2021]], tutti i contributi su Wikifunctions e gli progetti di Abstract Wikipedia saranno pubblicati sotto licenza libera. In particolare:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Il contenuto testuale]] su Wikifunctions sarà pubblicato sotto [[w:Creative Commons license|CC BY-SA 4.0]].
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* Le [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|implementazioni]] di Wikifunctions saranno pubblicate sotto la [[w:Apache License|licenza Apache 2]].
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
Ci sono ancora alcuni punti che dovranno essere affrontati in futuro, come la licenza del contenuto generato dal contenuto astratto. Abbiamo in programma di redigere un documento più completo con il Dipartimento legale su come le persone possano riutilizzare il codice di Wikifunctions nel modo più indolore possibile, rispettando comunque la licenza.
<span id="Contributing"></span>
== Contribuire ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Sono appena entrato. Cosa c'è per me e come posso aiutare? ===
Benvenuti! Siamo molto felici di averti qui! Ci sono molte opportunità per contribuire a Wikifunctions, dalla creazione di nuove funzioni fino al miglioramento e alla traduzione della documentazione. Se cerchi di partecipare, ti consigliamo di suggerire, a seconda del tuo livello di comfort, una nuova funzione su un argomento che ti interessa. O addirittura creare tale funzione. Crea dei test. Prova a fare un'implementazione. Aiuta con le traduzioni. Leggi e migliora la nostra documentazione. Aiuta a organizzare la comunità.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Come posso creare una nuova funzione, implementazione o test? ===
Per vedere come creare una nuova funzione, implementazione o test, vedi [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduzione]].
Per vedere più nel dettaglio come creare un'implementazione, guarda [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:Come creare impletentazioni]].
<span id="What_should_I_edit_first?"></span>
=== Come dovrei iniziare? ===
Se conosci più lingue, trova funzioni che non hanno ancora etichette e descrizioni nelle tue lingue nella pagina [[Special:ListMissingLabels]] e aggiungile tu.
Se hai qualche interesse in un dominio che potrebbe essere coperto da funzioni su Wikifunctions, ma non lo è ancora, oppure se hai altre idee per funzioni, vai alla pagina per [[Wikifunctions:Suggest a new function|suggerire nuove funzioni]] e presenta le tue idee.
Se sei un programmatore in Javascript o Python, puoi cercare le funzioni che non hanno ancora un'implementazione in Javascript o Python, e aggiungerle tu.
<span id="Where_can_I_go_for_help?"></span>
=== Dove posso cercare aiuto? ===
Inizialmente dovresti andare nel [[Special:MyLanguage/Help:Contents|portale d'aiuto]], dove puoi cercare tutta la documentazione sull'uso e sulla modifica di Wikifunctions. Se sei ancora bloccato, lascia un messaggio sulla [[Wikifunctions:Project chat|Chat di progetto]], e qualcuno risponderà alla tua domanda.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Come ordiniamo o categorizziamo le funzioni? ===
{{Tracked|T285424}}
Per ora, il modo migliore per ordinare o classificare le funzioni è farlo a mano attraverso le pagine nel namespace di Wikifunctions. Un'altra opzione sarebbe quella di consultare la pagina di discussione della funzione data. Monitoreremo questi sforzi e discuteremo con la comunità quali modifiche al sistema potrebbero essere utili per questo compito.
[[Category:FAQ| {{#translation:}}]]
0nbot9ypuqu0jecz46uuynh7yxeg10g
Wikifunctions:FAQ/bn
4
9168
191348
146098
2025-06-07T04:43:57Z
FuzzyBot
207
Updating to match new version of source page
191348
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
এটি উইকিফাংশন সম্পর্কে প্রায়শই জিজ্ঞাসিত প্রশ্ন সম্পর্কিত একটি পাতা। আপনার নিজের কোনো প্রশ্ন থাকলে এবং তা যদি এই তালিকায় না থাকে তবে অনুগ্রহ করে [[Wikifunctions talk:FAQ|আলাপ পাতায়]] তা বলুন।
এছাড়াও, উইকিফাংশন এবং বিমূর্ত উইকিপিডিয়া সম্পর্কে আরও সাধারণ প্রশ্নগুলির বিষয়ে আমাদের [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|মেটাতে প্রাজিপ্র]] বিবেচনা করুন।
__TOC__
<span id="Introduction"></span>
== ভূমিকা ==
<span id="What_is_this_project_about?"></span>
=== এই প্রকল্পটি কী সম্পর্কে? ===
উইকিফাংশন হলো একটি নতুন উইকিমিডিয়া প্রকল্প যা যে কেউ কল করতে, লিখতে, রক্ষণাবেক্ষণ এবং ব্যবহার করতে পারে এমন সব ধরনের ফাংশনের ক্যাটালগ প্রদান করে। এটি এমন অন্তর্নিহিত প্রযুক্তিও প্রদান করে যা শেষ পর্যন্ত বিমূর্ত উইকিপিডিয়া থেকে ভাষা-স্বাধীন নিবন্ধগুলোকে যেকোনো উইকিপিডিয়ার ভাষায় অনুবাদ করতে সক্ষম করবে। এটি প্রত্যেককে অবদান রাখতে এবং তাদের পছন্দের ভাষায় নিবন্ধ পড়ার সুযোগ দেবে।
<span id="What_is_a_function?"></span>
=== একটি ফাংশন কী? ===
ফাংশন হল জ্ঞানের একটি রূপ যা দুটি তারিখের মধ্যে কত দিন কেটে গেছে বা দুটি শহরের মধ্যে দূরত্বের মতো প্রশ্নের উত্তর দিতে পারে। আরও জটিল ফাংশনগুলি আরও জটিল প্রশ্নের উত্তর দিতে পারে, যেমন ত্রিমাত্রিক আকৃতির আয়তন, একটি নির্দিষ্ট তারিখে মঙ্গল ও শুক্রের মধ্যে দূরত্ব, অথবা একই সময়ে দুটি প্রজাতি জীবিত ছিল কিনা।
আমরা ইতিমধ্যেই অনেক ধরণের জ্ঞান অনুসন্ধানে ফাংশন ব্যবহার করি, যেমন একটি সার্চ ইঞ্জিনকে প্রশ্ন জিজ্ঞাসা করা। এছাড়াও ইংরেজি উইকিপিডিয়াতে টেমপ্লেটগুলি, যেমন [[:w:en:Template:Convert|টেমপ্লেট:convert]] এবং [[:w:en:Template:Age|টেমপ্লেট:age]], ফাংশন সমূহের উদাহরণ যা ইতিমধ্যে অনেক উইকিপিডিয়াতে ব্যবহৃত হয়েছে। টেমপ্লেট গুলো উইকিপাঠ্য এবং লুয়াতে লেখা এবং প্রতিটি উইকি যেখানে এটি চায় সেখানে ম্যানুয়ালি কপি করা হয়েছে।
<span id="What_is_an_implementation?"></span>
=== বাস্তবায়ন কী? ===
বাস্তবায়ন হল একটি ফাংশন কার্যকর করার একটি নির্দিষ্ট উপায়। বাস্তবায়ন হল এমন একটি প্রণালী যা ফাংশনটি চালানোর জন্য প্রয়োজনীয় পদক্ষেপগুলি তালিকাভুক্ত করে। এটি একটি প্রোগ্রামিং ভাষার কোডের অংশ হতে পারে, অথবা অন্যান্য ফাংশনে কলের সংমিশ্রণ হতে পারে। একটি ফাংশনের অনেক বাস্তবায়ন থাকতে পারে, যা সবগুলিই সমতুল্য হওয়া উচিত।
<span id="What_is_a_test?"></span>
=== একটি পরীক্ষা কী? ===
একটি পরীক্ষা হল একটি প্রদত্ত ফাংশন সঠিক কাজ করছে কিনা তা নির্ধারণ করার একটি উপায়। একটি ফাংশনে সাধারণত একাধিক পরীক্ষক থাকবে, প্রতিটি পরীক্ষক ফাংশনে কিছু ইনপুট নির্দিষ্ট করে এবং প্রদত্ত ইনপুটের জন্য আউটপুটকে অবশ্যই শর্ত পূরণ করতে হবে।
উদাহরণস্বরূপ, একটি "টাইটেল কেস" ফাংশনের জন্য পরীক্ষক গুলো অন্তর্ভুক্ত করতে পারে: "<span dir="ltr" lang="en">abc</span>" হওয়া উচিত "<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" হওয়া উচিত "<span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" হওয়া উচিত "<span dir="ltr" lang="ru">Война и мир</span>"; এবং "<span dir="ltr" lang="en">123</span>" থাকা উচিত "<span dir="ltr" lang="en">123</span>" হিসেবেই।
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== কোন বৈশিষ্ট্যগুলি এখন উপলব্ধ, কোনটি শীঘ্রই উপলব্ধ হবে এবং কোনটি আরও দূরে? ===
* লঞ্চের সময়:
** আমাদের অক্ষরসারি বা স্ট্রিং এবং বুলিয়ানের সাথে কাজ করে এমন ফাংশন রাখার ক্ষমতা রয়েছে।
** উইকিফাংশন শুরু থেকেই সম্পূর্ণ আন্তর্জাতিকীকৃত হবে। এটি যেকোনো ভাষায় ব্যবহার করা যেতে পারে।
* [[Wikifunctions:Status|চলমান উন্নয়ন]]:
** সাধারণ ধরণ এবং সাধারণ ফাংশন সম্পূর্ণরূপে সমর্থিত নয়।
** আপাতত একটি ধরণ যুক্ত করা কেবল উন্নয়নকারী দলের জন্যই সীমাবদ্ধ। ভবিষ্যতে, সম্প্রদায় আরও ধরণ যোগ করতে সক্ষম হবে। ধরনগুলিকে আরও মসৃণ আচরণ করানোর জন্য ভবিষ্যতে অনেক কাজ করতে হবে।
*** একটি বিশেষ আকর্ষণীয় প্রকার হবে বাইনারি উপাত্ত এবং বিশেষ করে ফাইল।
** আমরা বর্তমানে বাস্তবায়নের জন্য দুটি প্রোগ্রামিং ভাষা সমর্থন করি: জাভাস্ক্রিপ্ট এবং পাইথন। ভবিষ্যতে আমরা আরও অনেকগুলো সমর্থন করতে চাই।
** প্রোগ্রামিং ভাষায় লিখিত বাস্তবায়ন থেকে অন্যান্য ফাংশনকে কল করা বর্তমানে ''সম্ভব নয়''। এটি বর্তমানে শুধুমাত্র প্রণয়নের মাধ্যমেই সম্ভব।
* ভবিষ্যতে:
** অন্যান্য উইকিমিডিয়া প্রকল্প থেকে উইকিফাংশনের ফাংশন কল করা সম্ভব হবে, এবং পাতার আউটপুটের মধ্যে তাদের ফলাফল একত্রিত করা সম্ভব হবে।
** ফাংশনে উইকিউপাত্ত থেকে উপাত্ত ব্যবহার করা সম্ভব হবে।
** কমন্সের উপাত্ত নামস্থান থেকে উপাত্ত সেট কল করা সম্ভব হবে।
<span id="How_is_Wikifunctions_multilingual?"></span>
=== কিভাবে উইকিফাংশন বহুভাষিক? ===
উইকিফাংশন এবং বিমূর্ত উইকিপিডিয়া বিভিন্ন উপায়ে বহুভাষিক যা একে অপরকে প্রভাবিত করে না:
* '''উইকিফাংশন এর বিষয়বস্তু এবং ইউজার ইন্টারফেসের দিক থেকে বহুভাষিক।''' ব্যবহারকারীরা যেকোনো প্রাকৃতিক ভাষায় উইকিফাংশনে ফাংশন পড়তে এবং কল করতে পারেন। এখানে [https://www.wikifunctions.org/view/en/Z10000 ইংরেজি], [https://www.wikifunctions.org/view/pl/Z10000 পোলিশ] এবং [https://www.wikifunctions.org/view/he/Z10000 হিব্রু] ভাষায় "অক্ষরসারি সংযোগ" ফাংশন রয়েছে এবং এটি আরও অনেক ভাষায় উপলব্ধ।
* '''অবদানকারীরা তাদের ভাষা ব্যবহার করে উইকিফাংশন সম্পাদনা ও উন্নতি করতে পারে।''' এমনকি বাস্তবায়নও অবদানকারীর স্বাভাবিক ভাষায় সম্পাদনা করা যেতে পারে। উদাহরণস্বরূপ, "এবং" ফাংশনের বাস্তবায়নটি [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de জার্মান], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en ইংরেজি], বা প্রায় ৩০০টি ভাষার অন্য যে কোনোটিতে সম্পাদনা করা যেতে পারে।
* '''উইকিফাংশনের ফাংশন গুলো ব্যবহার করা যেতে পারে কোনো প্রাকৃতিক ভাষার জন্য ফলাফল তৈরি করতে।''' সম্প্রদায় অনেকগুলি প্রাকৃতিক ভাষায় পাঠ্য তৈরি করতে সহায়তা করার জন্য ক্রমবর্ধমান সংখ্যক ফাংশন তৈরি করছে। আমাদের [[Wikifunctions:Catalogue#Breton|ব্রেটন]], [[Wikifunctions:Catalogue#Rohingya|রোহিঙ্গা]], [[Wikifunctions:Catalogue#English|ইংরেজি]] এবং অন্যান্য অনেক ভাষার জন্য ফাংশন আছে।
* '''উইকিফাংশনের ফাংশনগুলি বিভিন্ন প্রোগ্রামিং ভাষায় প্রয়োগ করা যেতে পারে।''' উদাহরণস্বরূপ, [[Z10000|ফাংশন সংযোগ]]-কে [[Z10005|জাভাস্ক্রিপ্ট]] এবং [[Z10004|পাইথন]] উভয় ক্ষেত্রেই প্রয়োগ করা হয়েছে।
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== উইকিফাংশন বর্তমানে কোন প্রোগ্রামিং ভাষাগুলো সমর্থন করে? কোন প্রোগ্রামিং ভাষা ভবিষ্যতে সমর্থিত হবে? ===
বর্তমানে, উইকিফাংশন জাভাস্ক্রিপ্ট এবং পাইথনে লিখিত বাস্তবায়নকে সমর্থন করে। আমরা ভবিষ্যতে আরও প্রোগ্রামিং ভাষার জন্য সমর্থন যোগ করার পরিকল্পনা করছি। আমরা ২০২৫ সালে কমপক্ষে আরও একটি প্রোগ্রামিং ভাষা যুক্ত করার আশা করছি (তবে এখনও কোনটি সিদ্ধান্ত নেওয়া হয়নি)।
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== কীভাবে উইকিফাংশন অন্যান্য প্রকল্পের সাথে ইন্টিগ্রেট হবে? ===
উইকিফাংশন হল বিমূর্ত উইকিপিডিয়া তৈরির প্রথম পদক্ষেপ। আমাদের নিকট মেয়াদী লক্ষ হবে সম্প্রদায়কে সমর্থন করা এবং প্রতিক্রিয়ার উপর ভিত্তি করে উন্নতি করা। একই সঙ্গে আমরা এটিকে উইকিপিডিয়া এবং উইকিউপাত্তের সঙ্গে একীভূত করার প্রক্রিয়া শুরু করব, যা বৃহত্তর বাস্তব জীবনের প্রয়োগগুলিকে সক্ষম করবে এবং আমাদের বিমূর্ত উইকিপিডিয়ার দৃষ্টিভঙ্গির কাছাকাছি নিয়ে যাবে।
অবদানকারীরা তাদের উইকির মধ্যে থেকে উইকিফাংশন সাইটে সংরক্ষিত ফাংশন কল করতে সক্ষম হবে। ফাংশন কলের ফলাফল উইকির পাঠকদের কাছে প্রদর্শিত হবে। উদাহরণস্বরূপ, একজন ব্যক্তির বয়স গণনা করতে, উইকিউপাত্ত থেকে জনসংখ্যা এবং এলাকার তথ্যের উপর ভিত্তি করে জনসংখ্যার ঘনত্ব নির্ণয়ে, অথবা একটি গ্রাফ আঁকা এবং একটি প্রদত্ত নিবন্ধে এটি একীভূত করা।
উইকিফাংশনকে একীভূত করার আরেকটি বিকল্প হবে তাদের উইকির মধ্যে একটি ইন্টারেক্টিভ ফাংশন কল ইন্টারফেসকে সংহত করা। উদাহরণস্বরূপ, একটি উইকিপিডিয়া নিবন্ধে পাঠক প্রদত্ত পরামিতিগুলির উপর ভিত্তি করে একটি ভৌত সমীকরণের ফলাফল গতিশীলভাবে গণনা করতে, গাণিতিক ক্রিয়াকলাপের সাথে আঁকতে এবং যোগাযোগ করতে এটি ব্যবহার করা যেতে পারে।
<span id="What_Wikifunctions_is_not?"></span>
=== উইকিফাংশন কী নয়? ===
এর জন্য আরও তথ্যের জন্য অনুগ্রহ করে [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|উইকিফাংশন কী নয়]] পাতাটি দেখুন।
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== ফাংশন এবং প্রাপ্ত বিষয়বস্তু কোন লাইসেন্সের অধীনে থাকবে? ===
[[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|মেটায় নভেম্বর এবং ডিসেম্বর ২০২১ এ]] হওয়া আলোচনা অনুসারে, উইকিফাংশন এবং বৃহত্তর বিমূর্ত উইকিপিডিয়া প্রকল্পগুলোতে সমস্ত অবদান বিনামূল্যে লাইসেন্সের অধীনে প্রকাশিত হবে। নির্দিষ্টভাবে:
* উইকিফাংশনে [[Special:MyLanguage/Wikifunctions:Glossary#Content|পাঠ্য বিষয়বস্তু]] [[w:Creative Commons license|সিসি বাই-এসএ ৪.০]] এর অধীনে প্রকাশিত হবে।
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|ফাংশনের সিগনেচার]] এবং উইকিফাংশনের অন্যান্য কাঠামোগত বিষয়বস্তু [[w:CC0|সিসি ০]] এর অধীনে প্রকাশিত হবে।
* উইকিফাংশনে [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|কোড বাস্তবায়ন]] [[w:Apache License|অ্যাপাচি ২ লাইসেন্সের]] অধীনে প্রকাশিত হবে।
* বিমূর্ত উইকিপিডিয়ার [[Special:MyLanguage/Wikifunctions:Glossary#Content|বিমূর্ত বিষয়বস্তু]] সিসি বাই-এসএ ৪.০ এর অধীনে প্রকাশিত হবে।
এখনও কিছু বিষয় রয়েছে যা ভবিষ্যতে সমাধান করা প্রয়োজন, যেমন বিমূর্ত বিষয়বস্তু থেকে উত্পন্ন বিষয়বস্তুর লাইসেন্স। লাইসেন্স মেনে চলার সময় লোকজন কীভাবে উইকিফাংশন থেকে যতটা সম্ভব কম ব্যথাহীনভাবে কোডটি পুনরায় ব্যবহার করতে পারে সে সম্পর্কে আমরা আইনি বিভাগের সাথে আরও বিস্তৃত নথির খসড়া তৈরি করার পরিকল্পনা করছি।
<span id="Contributing"></span>
== অবদান ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== আমি এখানে নতুন। আমার কী করার আছে এবং আমি কিভাবে সাহায্য করতে পারি? ===
স্বাগত! আমরা আপনাকে এখানে পেয়ে খুব খুশি! নতুন ফাংশন তৈরি করা থেকে শুরু করে ডকুমেন্টেশনের উন্নতি এবং অনুবাদ করার জন্য উইকিফাংশনে অবদান রাখার অনেক সুযোগ রয়েছে। আপনি যদি এতে জড়িত হওয়ার উপায় খুঁজে থাকেন, তাহলে আমরা সুপারিশ করছি যে, আপনার স্বাচ্ছন্দ্যের উপর ভিত্তি করে, আপনি আপনার আগ্রহের বিষয়ে একটি নতুন ফাংশনের পরামর্শ দিন। অথবা এমন একটি ফাংশন তৈরি করুন। কিছু টেস্ট প্রদান করুন। এটি বাস্তবায়নে চেষ্টা করুন। অনুবাদে সাহায্য করুন। আমাদের ডকুমেন্টেশন/নথিপত্র উন্নয়নে সাহায্য করুন এবং তা পড়ুন। সম্প্রদায় সংগঠিত করতে সাহায্য করুন।
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== আমি কিভাবে একটি নতুন ফাংশন, বাস্তবায়ন, বা পরীক্ষা তৈরি করব? ===
কিভাবে একটি নতুন ফাংশন, বাস্তবায়ন, বা পরীক্ষা তৈরি করা যায় তা জানতে [[Special:MyLanguage/Wikifunctions:Introduction|উইকিফাংশন:ভূমিকা]] দেখুন।
কিভাবে একটি বাস্তবায়ন তৈরি করতে হয় তা বিস্তারিতভাবে জানতে দেখুন [[Special:MyLanguage/Wikifunctions:How to create implementations|উইকিফাংশন:কিভাবে বাস্তবায়ন তৈরি করতে হয়]]।
<span id="What_should_I_edit_first?"></span>
=== আমার প্রথমে কী সম্পাদনা করা উচিত? ===
<div class="mw-translate-fuzzy">
আপনি যদি বেশ কয়েকটি ভাষা লিখতে পারেন, তাহলে এমন ফাংশনগুলো খুঁজে বের করুন যেগুলোর লেবেল এবং বর্ণনা এখনও আপনার ভাষায় নেই এবং এগুলি যোগ করতে সহায়তা করুন৷
</div>
আপনার যদি এমন একটি বিষয়ের প্রতি আগ্রহ থাকে যা উইকিফাংশনের ফাংশনগুলিকে বৈশিষ্ট্যযুক্ত করতে পারে, কিন্তু এখনও সেগুলো তৈরী হয়নি বা আপনার যদি ফাংশনগুলির জন্য আরও ধারণা থাকে, তাহলে [[Wikifunctions:Suggest a new function|নতুন ফাংশনগুলির পরামর্শ দেওয়া]] পৃষ্ঠায় যান এবং আপনার ধারণাগুলি বর্ণনা করুন৷
আপনি যদি জাভাস্ক্রিপ্ট বা পাইথনের কোডার হন, তাহলে হয়তো আপনি এমন ফাংশনগুলি পরীক্ষা করতে চাইবেন যেগুলির এখনও জাভাস্ক্রোপ্ট বা পাইথনে বাস্তবায়ন নেই, এবং সেগুলি লেখার চেষ্টা করুন।
<span id="Where_can_I_go_for_help?"></span>
=== সাহায্যের জন্য কোথায় যাবো? ===
আপনার প্রথম ঠিকানা হওয়া উচিত [[Special:MyLanguage/Help:Contents|সাহায্য প্রবেশদ্বার]] যেখানে আপনি উইকিফাংশনের ব্যবহার এবং সম্পাদনা সংক্রান্ত সমস্ত নথি পাবেন। আপনি যদি এখনও আটকে থাকেন তবে [[Wikifunctions:Project chat|প্রকল্প আড্ডায়]] একটি বার্তা লিখুন, এবং কেই আপনার প্রশ্নের উত্তর দেবে।
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== আমরা কিভাবে ফাংশন বাছাই বা শ্রেণীবদ্ধ করব? ===
{{Tracked|T285424}}
আপাতত, ফাংশনগুলিকে সাজানোর বা শ্রেণীবদ্ধ করার সর্বোত্তম উপায় হল উইকিফাংশন নামস্থানে পৃষ্ঠাগুলির মাধ্যমে হাত দ্বারাই এটি করা। আরেকটি বিকল্প হবে প্রদত্ত ফাংশনের আলাপ পাতার মাধ্যমে। আমরা এই প্রচেষ্টাগুলি পর্যবেক্ষণ করব এবং সম্প্রদায়ের সঙ্গে আলোচনা করব যে সিস্টেম এ কোন পরিবর্তনগুলি এই কাজের জন্য সহায়ক হবে।
[[Category:FAQ| {{#translation:}}]]
rzxeh15sy39bge391fv4yxjd8606869
Wikifunctions:FAQ/id
4
9216
191356
170873
2025-06-07T04:44:01Z
FuzzyBot
207
Updating to match new version of source page
191356
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Ini adalah halaman khusus untuk Soal Sering Ditanya (SSD) tentang Wikifunctions. Silakan ajukan pertanyaan Anda sendiri di [[Wikifunctions talk:FAQ|halaman pembicaraan]] jika pertanyaan Anda tidak tercantum di sini!
Selain itu, pertimbangkan untuk melihat daftar [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|SSD di Meta]] mengenai pertanyaan yang lebih umum mengenai Wikifunctions dan Wikipedia Abstrak.
__TOC__
<span id="Introduction"></span>
== Pendahuluan ==
<span id="What_is_this_project_about?"></span>
=== Proyek apakah ini? ===
Wikifunctions adalah proyek Wikimedia baru yang menyediakan katalog dari berbagai jenis fungsi yang dapat dipanggil, ditulis, dipelihara, dan digunakan oleh siapa saja. Ia juga menyediakan teknologi dasar yang pada akhirnya akan memungkinkan terjemahan artikel bebas-bahasa dari Wikipedia Abstrak ke Wikipedia bahasa apa pun. Dengan demikian, semua orang dapat berkontribusi dan membaca artikel dalam bahasa yang mereka sukai.
<span id="What_is_a_function?"></span>
=== Apa itu "fungsi"? ===
Fungsi adalah bentuk pengetahuan yang dapat menjawab pertanyaan, seperti berapa hari telah berlalu antara dua tanggal atau jarak antara dua kota. Fungsi yang lebih rumit dapat menjawab pertanyaan yang lebih rumit, seperti volume dari bangun ruang tiga dimensi, jarak antara Mars dan Venus pada tanggal tertentu, atau apakah dua spesies hidup pada saat yang sama.
Kita sudah menggunakan fungsi dalam berbagai jenis pencarian pengetahuan, seperti bertanya ke mesin pencari. Templat, seperti [[:w:en:Template:Convert|Template:Convert]] dan [[:w:en:Template:Age|Template:Age]] di Wikipedia bahasa Inggris, juga merupakan contoh fungsi yang sudah digunakan banyak Wikipedia, ditulis dalam teks wiki dan Lua serta disalin secara manual ke setiap wiki yang menginginkannya.
<span id="What_is_an_implementation?"></span>
=== Apa itu implementasi? ===
Implementasi adalah cara tertentu untuk mengeksekusi fungsi. Implementasi adalah resep yang mencantumkan langkah-langkah yang diperlukan untuk menjalankan fungsi. Ia bisa jadi merupakan sepotong kode dalam suatu bahasa pemrograman, atau kombinasi panggilan untuk fungsi-fungsi lain. Sebuah fungsi dapat memiliki banyak implementasi, yang semuanya harus setara.
<span id="What_is_a_test?"></span>
=== Apa itu tes? ===
Tes adalah cara untuk menentukan apakah suatu fungsi melakukan hal yang benar. Sebuah fungsi biasanya memiliki beberapa penguji, masing-masing menentukan beberapa masukan untuk fungsi dan kondisi yang harus dipenuhi keluaran untuk input yang diberikan.
Misalnya, tes untuk fungsi "kapitalisasi judul" bisa berupa: "<span dir="ltr" lang="en">abc</span>" harus menjadi "<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" harus menjadi "<span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" harus menjadi "<span dir="ltr" lang="en">abc</span>"; dan "<span dir="ltr" lang="en">123</span>" harus tetap "<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Fitur apa saja yang tersedia sekarang, yang akan segera tersedia, dan yang masih lama tersedia? ===
* Saat peluncuran:
** Kita bisa memiliki fungsi yang bekerja dengan nilai-nilai Untaian dan Boolean.
** Wikifunctions akan sepenuhnya diinternasionalkan dari awal. Ia bisa digunakan dalam bahasa apa pun.
* [[Wikifunctions:Status|Sedang dikembangkan]]:
** Tipe generik dan fungsi generik tidak sepenuhnya didukung.
** Menambahkan tipe, untuk saat ini, akan menjadi sesuatu yang hanya dilakukan oleh tim pengembangan. Di masa yang akan datang, komunitas akan dapat menambahkan lebih banyak tipe. Ada banyak pekerjaan di masa depan untuk membuat tipe berperilaku lebih lancar.
*** Salah satu tipe yang sangat menarik akan data biner, dan terutama berkas.
** Saat ini kami mendukung dua bahasa pemrograman untuk implementasi: JavaScript dan Python. Di masa depan, kami ingin mendukung lebih banyak lagi.
** Saat ini, ''tidak'' mungkin fungsi lain dipanggil dari implementasi yang ditulis dalam bahasa pemrograman lain.
* Di masa yang akan datang:
** Akan mungkin untuk memanggil fungsi Wikifunctions dari proyek Wikimedia lainnya, dan mengintegrasikan hasilnya ke keluaran halaman.
** Akan mungkin untuk menggunakan data dari Wikidata dalam fungsi.
** Akan mungkin untuk memanggil himpunan data dari ruang nama Data Commons.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Bagaimana Wikifunctions bisa disebut multibahasa? ===
Wikifunctions dan Wikipedia Abstrak bersifat multibahasa dalam sejumlah cara yang berbeda dan tidak saling memengaruhi:
* '''Wikifunctions bersifat multibahasa dalam cakupan konten dan antarmuka penggunanya.''' Pengguna bisa membaca dan memanggil fungsi di Wikifunctions dalam bahasa alami mana pun. Berikut adalah fungsi “menggabungkan untaian” dalam bahasa [https://www.wikifunctions.org/view/en/Z10000 Inggris], [https://www.wikifunctions.org/view/pl/Z10000 Polandia], dan [https://www.wikifunctions.org/view/he/Z10000 Ibrani], dan fungsi tersebut juga tersedia dalam banyak bahasa lain.
* '''Kontributor dapat menyunting dan memperbaiki Wikifunctions menggunakan bahasa mereka masing-masing.''' Implementasipun bisa disunting dalam bahasa alaminya kontributor. Sebagai contoh, komposisi fungsi “dan” bisa disunting dalam bahasa [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de Jerman], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en Inggris], ataupun 300 bahasa lainnya.
* '''Fungsi Wikifunctions bisa digunakan untuk mengeluarkan hasil dalam bahasa alami mana pun.''' Komunitas sedang membuat fungsi-fungsi untuk mendukung pembuatan teks dalam banyak bahasa alami. Kami punya fungsi untuk bahasa [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|Inggris]], dan lain-lain.
* '''Fungsi di Wikifunctions bisa diimplementasikan dalam berbagai bahasa pemrograman berbeda.''' Sebagai contoh, [[Z10000|fungsi penggabung]] diimplementasikan dalam bahasa [[Z10005|JavaScript]] dan [[Z10004|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Bahasa pemrograman apa saja yang saat ini didukung oleh Wikifunctions? Bahasa pemrograman apa saja yang akan didukung di masa mendatang? ===
Saat ini, Wikifunctions mendukung implementasi yang ditulis dalam JavaScript dan Python. Kami berencana untuk menambahkan dukungan untuk lebih banyak bahasa pemrograman di masa depan. Kami berharap untuk menambahkan setidaknya satu bahasa pemrograman lagi pada tahun 2025 (tetapi belum memutuskan bahasa yang mana).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Bagaimana Wikifunctions akan diintegrasikan ke dalam proyek-proyek lain? ===
Wikifunctions adalah langkah pertama menuju membangun Wikipedia Abstrak. Fokus jangka pendek kami akan mendukung komunitas dan membuat perbaikan berdasarkan umpan balik. Pada saat yang sama, kami akan memulai proses mengintegrasikannya dengan Wikipedia dan Wikidata, yang akan memungkinkan aplikasi nyata yang lebih luas dan membawa kita lebih dekat dengan visi Wikipedia Abstrak.
Kontributor akan dapat memanggil fungsi dari Wikifunctions dari dalam wiki mereka. Hasil panggilan fungsi akan ditampilkan untuk pembaca. Hal ini dapat digunakan, misalnya, untuk menghitung usia seseorang, kepadatan populasi berdasarkan data populasi dan area dari Wikidata, atau untuk menggambar grafik dan mengintegrasikannya ke dalam artikel tertentu.
Pilihan lainnya untuk mengintegrasikan Wikifunctions adalah dengan mengintegrasikan antarmuka panggilan fungsi interaktif dalam wiki mereka. Hal ini dapat digunakan, misalnya, dalam artikel Wikipedia untuk menghitung hasil persamaan fisik secara dinamis berdasarkan parameter yang disediakan pembaca, menggambar dan berinteraksi dengan fungsi matematika, dll.
<span id="What_Wikifunctions_is_not?"></span>
=== Apa yang tidak dicakup oleh Wikifunctions? ===
Tolong lihat [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:Wikifunctions bukanlah]] untuk informasi mengenai hal tersebut.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Lisensi apa yang akan digunakan untuk fungsi dan konten turunannya? ===
Sesuai diskusi yang terjadi [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|di Meta antara bulan November dan Desember 2021]], semua kontribusi di Wikifunctions dan proyek-proyek Wikipedia Abstrak akan diterbitkan di bawah lisensi bebas. Secara khusus:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Konten teks]] di Wikifunctions akan diterbitkan di bawah [[w:id:Lisensi Creative Commons|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Pengenal fungsi]] dan konten terstruktur lainnya di Wikifunctions akan diterbitkan di bawah [[w:id:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Implementasi kode]] di Wikifunctions akan diterbitkan di bawah [[w:id:Lisensi Apache|lisensi Apache 2]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Konten Abstrak]] untuk Wikipedia Abstrak akan diterbitkan di bawah CC BY-SA 4.0.
Masih ada beberapa poin yang perlu ditangani di masa depan, seperti lisensi konten yang dihasilkan dari konten abstrak. Kami berencana untuk menyusun dokumen yang lebih komprehensif dengan Departemen Hukum tentang bagaimana orang-orang dapat menggunakan kembali kode dari Wikifunctions dengan semudah mungkin selama masih sejalan dengan lisensi.
<span id="Contributing"></span>
== Berkontribusi ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Saya baru bergabung di sini. Apa yang harus saya lakukan dan bagaimana saya dapat ikut membantu? ===
Selamat datang! Kami sangat senang menerima Anda di sini! Ada banyak kesempatan untuk berkontribusi di Wikifunctions, mulai dari menciptakan fungsi baru sampai memperbaiki dan menerjemahkan dokumentasi. Jika Anda mencari cara untuk terlibat, kami menyarankan, tergantung pada tingkat kenyamanan Anda, agar Anda mungkin bisa mengusulkan fungsi baru pada topik yang Anda minati. Atau bahkan menciptakan fungsi seperti itu. Berikan beberapa tes. Cobalah mengerjakan implementasi. Bantu penerjemahan. Baca dan perbaiki dokumentasi kami. Bantu mengorganisir komunitas.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Bagaimana cara membuat fungsi, implementasi, atau tes baru? ===
Untuk melihat cara membuat fungsi, implementasi, atau tes baru, lihat [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Perkenalan]].
Untuk melihat cara membuat implementasi secara lebih rinci, lihat [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:Cara membuat implementasi]].
<span id="What_should_I_edit_first?"></span>
=== Apa yang harus saya sunting mula-mula? ===
Jika Anda bisa menuturkan beberapa bahasa, cari fungsi yang belum memiliki label dan deskripsi dalam bahasa Anda pada halaman [[Special:ListMissingLabels]], dan bantu menambahkannya.
Jika Anda punya minat dalam bidang yang bisa memiliki fungsi di Wikifunctions, tetapi bidang tersebut belum memilikinya, atau jika Anda punya ide untuk fungsi baru, pergi ke halaman [[Wikifunctions:Suggest a new function|pengusulan fungsi baru]], dan sampaikan ide Anda.
Jika Anda bisa membuat kode dalam bahasa JavaScript atau Python, mungkin Anda ingin memeriksa fungsi yang belum memiliki implementasi dalam bahasa JavaScript atau Python, dan mencoba menulisnya.
<span id="Where_can_I_go_for_help?"></span>
=== Bagaimana saya bisa mendapatkan bantuan? ===
Tempat pertama yang sebaiknya Anda kunjungi adalah [[Special:MyLanguage/Help:Contents|portal Bantuan]], tempat Anda akan menemukan semua dokumentasi mengenai cara menggunakan dan menyunting Wikifunctions. Jika Anda masih kesulitan, kirim pesan di [[Wikifunctions:Project chat|Warung Kopi]], dan seseorang akan menjawab pertanyaan Anda.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Bagaimana cara mengurutkan atau mengkategorikan fungsi? ===
{{Tracked|T285424}}
Untuk saat ini, cara terbaik untuk mengurutkan atau mengategorikan fungsi adalah melakukannya secara manual melalui halaman di ruang nama Wikifunctions. Pilihan lainnya adalah melalui halaman diskusi dari suatu fungsi. Kami akan memantau upaya ini, dan membahas dengan komunitas mengenai perubahan sistem yang akan membantu untuk tugas ini.
[[Category:FAQ| {{#translation:}}]]
su4ey9cjrt9udaqh8pfzc720kgwiccs
Wikifunctions:FAQ/vi
4
10751
191368
146093
2025-06-07T04:44:08Z
FuzzyBot
207
Updating to match new version of source page
191368
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Đây là một trang dành riêng cho những câu hỏi thường gặp về Wikifunctions. Hãy tự do hỏi những câu hỏi của mình trong [[Wikifunctions talk:FAQ|trang thảo luận]], nếu câu hỏi của bạn không được hiện ở đây!
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Giới thiệu ==
<span id="What_is_this_project_about?"></span>
=== Dự án này về cái gì? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a function? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">In the future:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What Wikifunctions is not? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
== Contributing ==
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where can I go for help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do we sort or categorize functions? ===
</div>
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
im5zyc7zye7cmkkmc6o3cj3x1f98fsc
Wikifunctions:FAQ/he
4
11371
191354
150250
2025-06-07T04:44:00Z
FuzzyBot
207
Updating to match new version of source page
191354
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
הדף הזה מוקדש לשאלות נפוצות על ויקיפונקציות. תרגישו חופשיים לשאול את השאלה שלך ב[[Wikifunctions talk:FAQ|דף השיחה]] אם היא עדיין לא רשומה פה!
בנוסף, ישנו דף [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|שאלות ותשובות במטא]], העוסק בשאלות יותר כלליות על ויקיפונקציות או ויקיפדיה המופשטת.
__TOC__
<span id="Introduction"></span>
== מבוא ==
<span id="What_is_this_project_about?"></span>
=== במה המיזם עוסק? ===
ויקיפונקציות היא מיזם ויקימדיה חדש שמספק קטלוג של כל מיני פונקציות שכל אחד יכול לקרוא להן, לכתוב ולתחזק אותן, ולהשתמש בהן. מיזם ויקיפונקציות מספק את הטכנולוגיה היסודים שתאפשר בסופו של דבר תרגום של ערכים בלתי־תלויים בשפה מוויקיפדיה מופשטת (Abstract Wikipedia) לשפה של כל ויקיפדיה אחרת. זה יאפשר לכולם לתרום ולקרוא ערכים בשפה המועדפת עליהם.
<span id="What_is_a_function?"></span>
== מהי פונקציה? ==
פונקציות הן סוג של ידע שיכול לענות על שאלות, כגון כמה ימים עברו בין שני תאריכים, או מהו המרחק בין שתי ערים. פונקציות מורכבות יותר יכולות לענות על שאלות מורכבות יותר, כמו מה הנפח של צורה תלת־ממדית, המרחק ממאדים לנוגה בתאריך מסוים, או האם שני מינים חיו באותו הזמן.
אנו כבר משתמשים בפונקציות בסוגים רבים של פניות לקבלת ידע, כגון הפניית שאלה למנוע חיפוש. התבניות, כגון [[:w:en:Template:Convert|Template:Convert]] ו־[[:w:en:Template:Age|Template:Age]] בוויקיפדיה האנגלית, הן גם דוגמאות לפונקציות שכבר משמשות בוויקיפדיות רבות, כתובות בקוד ויקי ובלואה ([[:w:he:WP:Lua|Lua]]) ומועתקות ידנית לכל ויקי לפי הצורך.
<span id="What_is_an_implementation?"></span>
=== מהו מימוש? ===
מימוש הוא דרך מסוימת לבצע פונקציה. מימוש הוא מתכון שמפרט את הצעדים הדרושים להרצת הפונקציה. הוא יכול להיות פיסת קוד בשפת תכנות או שילוב של קריאות לפונקציות אחרות. לפונקציה יכולים להיות מימושים רבים, שכולם חייבים להיות שקולים זה לזה.
<span id="What_is_a_test?"></span>
=== מהי בדיקה? ===
בדיקה היא דרך לקבוע האם פונקציה נתונה עושה את הדבר הנכון. לרוב, לפונקציה יהיו כמה בדיקות, שכל אחת מהן מציינת קלט כלשהו לפונקציה והתנאים שהפלט התואם נדרש לקיים.
לדוגמה, בודקים לפונקציה "רישיות כותרת" (title case) עשויים לכלול: "<span dir="ltr" lang="en">abc</span>" צריך להפוך ל־"<span dir="ltr" lang="en">Abc</span>"; "<span dir="ltr" lang="en">war and peace</span>" צריך להפוך ל־"<span dir="ltr" lang="en">War and Peace</span>"; "<span dir="ltr" lang="ru">война и мир</span>" צריך להפוך ל־"<span dir="ltr" lang="ru">Война и мир</span>"; ו־"<span dir="ltr" lang="en">123</span>" צריך להפוך ל־"<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== אילו יכולות זמינות עכשיו, אילו יהיו זמינים בקרוב ואילו בהמשך? ===
* בהשקה:
** תהיה לנו יכולת לארח פונקציות שעובדות עם מחרוזות ובוליאנים.
** יהיה אפשר לתרגם ויקיפונקצמות ישר מההתחלה. יהיה אפשר להשתמש בהן בכל שפה.
* [[Wikifunctions:Status|בפיתוח מתמשך]]:
** סוגים כלליים פונקציות כלליות (generic) אינם נתמכים לגמרי.
** הוספת סוגים תהיה, לעת־עתה, משהו שרק צוות הפיתוח יכול לעשות. בעתיד, הקהילה תוכל להוסיף עוד סוגים. יש הרבה עבודה שעלינו לעשות בעתיד כדי לגרום לסוגים להתנהג בצורה הרבה יותר חלקה.
*** סוג מעניין במיוחד יהיה נתונים בינריים ובמיוחד קבצים.
** אנחנו תומכים עכשיו בשתי שפות למימושים: JavaScript ופייתון. אנחנו רוצים לתמוך בהרבה יותר שפות בעתיד.
** כרגע, ''לא'' ניתן לקרוא לפונקציות מתוך מימושים בשום שפת תכנות. כרגע זה אפשרי רק באמצעות הרכבה.
* בעתיד:
** יהיה אפשר לקרוא לפונקצית של ויקיפונקציות למיזמי ויקימדיה אחרים ולשלב את התוצאות שלהן בפלט של דף.
** יהיה אפשר להשתמש בנתונים מוויקינתונים בפונקציות.
** יהיה אפשר לקרוא לערכות נתונים ממרחב השם Data בוויקישיתוף.
<span id="How_is_Wikifunctions_multilingual?"></span>
== איך מיזם ויקיפונקציות יהיה רב־לשוני? ==
מיזמי ויקיפונקציות וויקיפדיה מופשטת יהיה רב־לשוניים בכמה אופנים שאינם משפיעים זה על זה:
* '''מיזם ויקיפונקציות יהיה רב־לשוני מבחינת התוכן וממשק המשתמש שלו.''' משתמשים יכולים לקרוא את התוכן ולקרוא לפונקציות בוויקיפונקציות בכל שפה טבעית. הנה פונקציית "שרשור מחרוזות" [https://www.wikifunctions.org/view/en/Z10000 באנגלית], [https://www.wikifunctions.org/view/pl/Z10000 בפולנית] [https://www.wikifunctions.org/view/he/Z10000 בעברית], והיא זמינה בשפות רבות נוספות.
* '''תורמים יכולים לערוך ולשפר את ויקיפונקציות בשפה שלהם.''' ניתן לערוך אפילו מימושים בשפה הטבעית של התורם. למשל, ניתן לערוך את ההרכבה של הפונקציה "וגם" [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de בגרמנית], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en באנגלית] או בכל אחת מכ־300 שפות.
* '''אפשר להשתמש בפונקציות של ויקיפונקציות כדי ליצור תוצאות לכל שפה טבעית.''' הקהילה יוצרת מספר הולך וגדל של פונקציות כדי לתמוך ביצירת טקסט בשפות טבעיות רבות. יש לנו פונקציות עבור [[Wikifunctions:Catalogue#Breton|ברטונית]], [[Wikifunctions:Catalogue#Rohingya|רוהינגיה]], [[Wikifunctions:Catalogue#English|אנגלית]] ושפות רבות אחרות.
* '''ניתן לממש פונקציות בוויקיפונקציות בשפות תכנות שונות.''' למשל, [[Z10000|פונקציית השרשור]] ממומשת גם ב־[[Z10005|JavaScript]] וגם ב[[Z10004|פייתון]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== באילו שפות תכנות מיזם ויקיפונקציות תומך כעת? אילו שפות תכנות ייתמכו בעתיד? ===
כעת, ויקיפונקציות תומכות במימושים שכתובים ב־JavaScript ובפייתון. אנחנו מתכננים להוסיף תמיכה ביותר שפות תכנות בעתיד. אנו מקווים להוסיף לפחות שפת תכנות אחת בשנת 2025 (אבל עדיין לא החלטנו איזו).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== איך ישולבו ויקיפונקציות במיזמים אחרים? ===
מיזם ויקיפונקציות הוא הצעד הראשון לקראת בניית ויקיפדיה מופשטת (Abstract Wikipedia). ההתמקדות בטווח הקרוב שלנו תהיה בתמיכה בקהילה ובביצוע שיפורים על סמך משוב. במקביל נתחיל בתהליך השילוב שלו עם ויקיפדיה וויקינתונים, מה שיאפשר יישומים רחבים יותר בחיים האמיתיים ויקרב אותנו לחזון של ויקיפדיה מופשטת.
תורמים יוכלו לקרוא לפונקציות שמאוחסנות באתר ויקיפונקציות מתוך הוויקי שלהם. התוצאה של קריאת הפונקציה תוצג לקוראי הוויקי. זה יכול לשמש, למשל, לחישוב גילו של אדם, צפיפות האוכלוסין בהתבסס על נתוני אוכלוסייה ושטח מוויקינתונים, או לציור תרשים ולשילובו בערך נתון.
אפשרות נוספת לשילוב של ויקיפונקציות היא הכנסת ממשק אינטראקטיבי לקריאה לפונקציות לתוך הוויקי שלהם. זה יכול לשמש, למשל, בערך בוויקיפדיה לחישוב דינמי של תוצאה של משוואה בפיזיקה על סמך פרמטרים שניתנים על־ידי הקורא, לצייר פונקציות מתמטיות ולתקשר איתן, וכו'.
<span id="What_Wikifunctions_is_not?"></span>
=== מה מיזם ויקיפונקציות איננו? ===
ר' את הדף [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|מה מיזם ויקיפונקציות איננו]] למידע נוסף.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== מה יהיה הרישיון של הפונקציות והתוכן הנגזר מהם? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== תרומה ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== הגעתי עכשיו. מה יש לי לעשות ואיך אפשר לעזור? ===
ברוך בואך! אנחנו שמחים מאוד שבאת! יש הזדמנויות רבות לתרום לוויקיפונקציות, מיצירת פונקציות חדשות ועד לשיפור ותרגום תיעוד. אם חיפשת דרכים להיכנס לעניינים, אנו ממליצים לך, בהתאם לרמת הנוחות שלך, להציע פונקציה חדשה בנושא שמעניין אותך. או אפילו ליצור פונקציה כזאת בעצמך. לכתוב כמה בדיקות. לנסות את עצמך בכתיבת מימוש. לעזור בתרגומים. לקרוא ולשפר את התיעוד שלנו. לעזור בארגון הקהילה.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== איך אפשר ליצור פונקציה חדשה, מימוש חדש או בדיקה חדשה? ===
כדי לראות איך ליצור פונקציה חדשה, מימוש חדש או בדיקה חדשה, ר' [[Special:MyLanguage/Wikifunctions:Introduction|מבוא לוויקיפונקציות]].
ליותר פרטים על יצירת מימוש, ר' [[Special:MyLanguage/Wikifunctions:How to create implementations|איך ליצור מימושים]].
<span id="What_should_I_edit_first?"></span>
=== מה כדאי לי לערוך תחילה? ===
אם יש לך יכולת לכתוב בכמה שפות, אפשר למצוא פונקציות שעדיין אין להן תוויות ותיאורים בשפות שלך בדף [[Special:ListMissingLabels]], ולעזור להוסיף אותם.
אם מעניין אותך נושא מסוים שיכולות להיות עליו פונקציות בוויקיפונקציות, אך הן עדיין לא קיימות, או אם יש לך רעיונות נוספים לפונקציות, ר' את הדף [[Wikifunctions:Suggest a new function|להצעת פונקציות חדשות]]. שם אפשר להציג את הרעיונות שלך.
אם יש לך יכולות כתיבת קוד ב-JavaScript או בפייתון, אולי אפשר לחפש פונקציות שעדיין אין להן מימושים ב-JavaScript או בפייתון ולנסות לכתוב אותן.
<span id="Where_can_I_go_for_help?"></span>
=== לאן אוכל לפנות לעזרה? ===
התחנה הראשונה שלך אמורה להיות [[Special:MyLanguage/Help:Contents|פורטל העזרה]] שאפשר למצוא בו את כל התיעוד הקשור לשימוש בוויקיפונקציות ועריכה באתר. אם נתקעת, נא לשלוח הודעה ב-[[Wikifunctions:Project chat|מזנון]], ומישהו ויענה על השאלה שלך.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== איך אנו ממיינים את הפונקציות? ===
{{Tracked|T285424}}
לעת־עתה, הדרך הטובה ביותר למיין או לסווג פונקציות היא לעשות זאת ידנית דרך דפים במרחב השמות Wikifunctions. אפשרות נוספת תהיה דרך דף השיחה של הפונקציה הנתונה. אנו נעקוב אחר המאמצים האלה, ונדון עם הקהילה אילו שינויים במערכת יועילו למשימה הזאת.
[[Category:FAQ| {{#translation:}}]]
p5acv8qvm34jsfk1jat7e9a9bcxremh
Wikifunctions:FAQ/en-gb
4
11821
191349
146076
2025-06-07T04:43:58Z
FuzzyBot
207
Updating to match new version of source page
191349
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
== Introduction ==
=== What is this project about? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
=== What is a function? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
=== What is an implementation? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
=== What is a test? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
=== Which features are available now, which will be soon available, and which are further away? ===
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">In the future:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
=== How will Wikifunctions be integrated into other projects? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<div class="mw-translate-fuzzy">
=== What Wikifunctions is not? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
=== What license will the functions and derived content be under? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
== Contributing ==
=== I'm new here. What is there for me to do and how can I help? ===
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organising the community.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== How do I create a new function or implementation or test? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
=== What should I edit first? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
=== Where can I go for help? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== How do we sort or categorise functions? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
8vbdsf4fwvqj9j4p9u5p7qc3udjhh4e
Wikifunctions:FAQ/fr
4
13207
191352
173662
2025-06-07T04:44:00Z
FuzzyBot
207
Updating to match new version of source page
191352
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Ceci est une page dédiée à la Foire Aux Questions sur les Wikifunctions. N'hésitez pas à poser votre propre question sur la [[Wikifunctions talk:FAQ|page de discussion]], si votre question n'est pas listée ici !
Veuillez également consulter notre [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ sur Meta]] pour des questions plus générales sur Wikifunctions et/ou sur la Wikipédia abstraite.
__TOC__
== Introduction ==
<span id="What_is_this_project_about?"></span>
=== Sur quoi porte ce projet ? ===
Wikifunctions est un nouveau projet de Wikimedia qui fournit un catalogue de toutes sortes de fonctions que n'importe qui peut appeler, écrire, maintenir, et utiliser. Elle fournit aussi la technologie de base qui permettrait éventuellement la traduction des articles indépendants de la langue d' [[meta:Abstract Wikipedia/fr|Abstract Wikipedia]] vers la langue de n'importe quel projet de Wikipédia. Ceci permettra à tout le monde de contribuer et lire des articles dans leur langue préférée.
<span id="What_is_a_function?"></span>
=== Qu’est-ce qu’une fonction ? ===
Les fonctions sont une forme de connaissance qui peut répondre à des questions, telles que le nombre de jours qui se sont écoulés entre deux dates ou la distance entre deux villes. Des fonctions plus complexes peuvent répondre à des questions plus complexes, comme le volume d'une forme tridimensionnelle, la distance entre Mars et Vénus à une certaine date, ou si deux espèces étaient vivantes en même temps.
Nous utilisons déjà des fonctions dans de nombreux types de requêtes sur la connaissance, comme poser une question à un moteur de recherche. Les modèles, tels que [[:w:en:Template:Convert|Template:Convert]] et [[:w:en:Template:Age|Template:Age]] sur la Wikipédia anglaise, sont également des exemples de fonctionnalités déjà utilisées dans de nombreuses Wikipédias, écrites en wikitext et en Lua et copiées manuellement sur chaque wiki où elles sont nécessaires.
<span id="What_is_an_implementation?"></span>
=== Qu'est-ce qu'une implémentation ? ===
Une implémentation est une façon particulière d'exécuter une fonction. Une implémentation est une recette qui énumère les étapes nécessaires pour exécuter la fonction. Il peut s'agir d'un morceau de code dans un langage de programmation ou d'une combinaison d'appels à d'autres fonctions. Une fonction peut avoir de nombreuses implémentations, qui devraient toutes être équivalentes.
<span id="What_is_a_test?"></span>
=== Qu'est-ce qu'un test ? ===
Un test est un moyen de déterminer si une fonction donnée fait ce qu'il faut. Une fonction aura généralement plusieurs testeurs, chacun spécifiant une certaine entrée de la fonction et les conditions que la sortie pour l'entrée donnée doit remplir.
Par exemple, les testeurs pour une fonction "title case" peuvent inclure : "<span dir="ltr" lang="en">abc</span>" devrait devenir "<span dir="ltr" lang="en">Abc</span>" ; "<span dir="ltr" lang="en">war and peace</span>" devrait devenir "<span dir="ltr" lang="en">War and Peace</span>" ; "<span dir="ltr" lang="ru">война и мир</span>" devrait devenir "<span dir="ltr" lang="ru">Война и мир</span>" ; et "<span dir="ltr" lang="en">123</span>" devrait rester "<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Quelles sont les fonctionnalités disponibles aujourd'hui, celles qui le seront bientôt et celles qui le seront plus tard ? ===
* Lors du lancement :
** Chaînes et booléens.
** Wikifunctions sera entièrement internationalisé dès le départ. Il peut être utilisé dans n'importe quelle langue.
* [[Wikifunctions:Status|Développement en cours]] :
** Les types génériques et les fonctions génériques ne sont pas entièrement pris en charge.
** L'ajout de types sera, pour l'instant, limité à l'équipe de développement. À l'avenir, la communauté pourra ajouter elle-même de nouveaux types. Il y a beaucoup de travail à faire dans l'avenir pour que les types se comportent de manière beaucoup plus fluide.
*** Un type particulièrement intéressant sera les données binaires, et en particulier les fichiers.
** Nous prenons actuellement en charge deux langages de programmation pour les implémentations : JavaScript et Python. À l'avenir, nous voulons en supporter beaucoup d'autres.
** Il n'est actuellement ''pas'' possible d'appeler d'autres fonctions à partir d'implémentations écrites dans un autre langage de programmation. En ce moment, ceci est seulement possible avec composition.
* A l'avenir :
** Il sera possible d'appeler les fonctions de Wikifunctions à partir d'autres projets Wikimedia et d'intégrer leurs résultats dans la sortie de la page.
** Il sera possible d'utiliser les données de Wikidata dans les fonctions.
** Il sera possible d'appeler des ensembles de données à partir de l'espace de noms Data de Commons.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Comment Wikifunctions est multilingue ? ===
Wikifonctions et la Wikipédia abstraite sont multilingues de différentes manières qui n’ont pas d’impact l’une sur l’autre :
* '''Wikifonctions est multilingue en termes de contenu et d’interface utilisateur'''. Les utilisateurs peuvent lire et appeler des fonctions sur Wikifonctions dans n’importe quelle langue naturelle. Voici la fonction « combinaison de chaînes » en [https://www.wikifunctions.org/view/en/Z10000 anglais], [https://www.wikifunctions.org/view/pl/Z10000 polonais], et [https://www.wikifunctions.org/view/he/Z10000 hébreu] ; elle est disponible dans de nombreuses autres langues.
* '''Les contributeurs peuvent éditer et améliorer les Wikifonctions dans leur langue.''' Même les implémentations peuvent être éditées dans la langue naturelle du contributeur. Par exemple, la composition de la fonction « et » peut être éditée en [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de allemand], en [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en anglais], ou dans n’importe quelle autre langue parmi les 300 proposées.
* '''Les fonctions de Wikifunctions peuvent être utilisées pour créer des résultats dans n’importe quelle langue naturelle'''. La communauté crée un nombre grandissant de fonctions permettant de générer des textes dans de nombreuses langues naturelles. Nous avons des fonctions pour le [[1$|breton]], [[2$|rohingya]], [[3$|anglais]], et bien d’autres langues.
* ''''Les fonctions de Wikifunctions peuvent être implémentées dans différents langages de programmation.''' Par exemple, la fonction [[Z10000| combinaison de chaînes]] est implémentée à la fois en [[Z10000|JavaScript]] et en [[Z10005|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Quels langages de programmation sont actuellement dans Wikifunctions ? Quels langages de programmation seront pris en charge à l'avenir ? ===
Actuellement, Wikifunctions accepte les implémentations écrites en JavaScript et en Python. Nous prévoyons d’ajouter d’autres langages de programmation à l’avenir. Nous espérons ajouter au moins un autre langage de programmation en 2025 (mais nous n’avons pas encore décidé lequel).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Comment Wikifunctions sera-t-il intégré dans d'autres projets ? ===
Wikifunctions est la première étape de la construction d'Abstract Wikipedia. À court terme, nous nous attacherons à soutenir la communauté et à apporter des améliorations sur la base des commentaires reçus. Parallèlement, nous entamerons le processus d'intégration avec Wikipédia et Wikidata, ce qui permettra d'élargir les applications réelles et de nous rapprocher de la vision d'Abstract Wikipedia.
Les contributeurs pourront appeler des fonctions hébergées sur le site Wikifunctions à partir de leurs wikis. Le résultat de l'appel de la fonction sera affiché aux lecteurs du wiki. Cela peut être utilisé, par exemple, pour calculer l'âge d'une personne, la densité de population basée sur les données de population et de superficie de Wikidata, ou pour dessiner un graphique et l'intégrer dans un article donné.
Une autre option pour intégrer Wikifunctions consistera à intégrer une interface interactive d'appel de fonctions dans leur wiki. Cette interface pourrait être utilisée, par exemple, dans un article de Wikipédia pour calculer dynamiquement le résultat d'une équation physique en fonction des paramètres fournis par le lecteur, dessiner et interagir avec des fonctions mathématiques, etc.
<span id="What_Wikifunctions_is_not?"></span>
=== Ce que Wikifonctions n’est pas ===
Veuillez consulter [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:Ce que WikiFunctions n'est pas]] pour plus d'informations à ce sujet.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Sous quelle licence seront les fonctions et le contenu dérivé ? ===
Conformément à la discussion qui s'est déroulée [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|sur Meta entre novembre et décembre 2021]], toutes les contributions à Wikifunctions et aux projets plus larges de la Wikipédia abstraite seront publiées sous licence libre. En particulier :
* Le [[Special:MyLanguage/Wikifunctions:Glossary#Content|contenu textuel]] de Wikifunctions sera publié sous [[w:Creative Commons license|CC BY-SA 4.0]].
* Les [[Special:MyLanguage/Wikifunctions:Glossary#Function|signatures de fonctions]] et autres contenus structurés sur Wikifunctions seront publiés sous la licence [[w:CC0|CC 0]].
* Les [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|implémentations de code]] dans Wikifunctions seront publiées sous la [[w:Apache License|Licence Apache 2]].
* Le [[Special:MyLanguage/Wikifunctions:Glossary#Content|contenu abstrait]] pour Abstract Wikipedia sera publié sous CC BY-SA 4.0.
Certains points devront encore être abordés à l'avenir, comme la licence du contenu généré à partir du contenu abstrait. Nous prévoyons de rédiger un document plus complet avec le département juridique sur la façon dont les gens peuvent réutiliser le code des Wikifunctions aussi facilement que possible, tout en adhérant à la licence.
<span id="Contributing"></span>
== Contribuer ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Je suis nouveau ici. Que dois-je faire et comment puis-je aider ? ===
Bienvenue ! Nous sommes très heureux de vous accueillir ici ! Il existe de nombreuses possibilités de contribuer à Wikifunctions, qu'il s'agisse de créer de nouvelles fonctions ou d'améliorer et de traduire la documentation. Si vous cherchez des moyens de vous impliquer, nous vous recommandons, selon votre niveau d'aisance, de suggérer une nouvelle fonction sur un sujet qui vous intéresse. Ou même de créer une telle fonction. Proposez des tests. Essayez-vous à une implémentation. Aidez à la traduction. Lisez et améliorez notre documentation. Aidez à organiser la communauté.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Comment créer une nouvelle fonction, une nouvelle implémentation ou un nouveau test ? ===
Pour voir comment créer une nouvelle fonction, une implémentation ou un test, voir [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
Pour voir plus en détail comment créer une implémentation, voir [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:Comment créer des implémentations]].
<span id="What_should_I_edit_first?"></span>
=== Que devrais-je éditer en premier ? ===
Si vous pouvez écrire plusieurs langages, recherchez les fonctions qui n'ont pas encore d'étiquettes et de descriptions dans vos langages sur la page [[Special:ListMissingLabels]], et aidez à les ajouter.
Si vous êtes intéressé par un domaine qui pourrait proposer des fonctions dans Wikifunctions, mais que ce n'est pas encore le cas, ou si vous avez d'autres idées de fonctions, rendez-vous sur la page [[Wikifunctions:Suggest a new function|suggérant de nouvelles fonctions]] et présentez vos idées.
Si vous êtes un développeur en JavaScript ou en Python, vous voudrez peut-être rechercher des fonctions qui n'ont pas encore d'implémentation en JavaScript ou en Python, et essayer de les écrire.
<span id="Where_can_I_go_for_help?"></span>
=== Où puis-je trouver de l'aide ? ===
Votre premier arrêt devrait être le [[Special:MyLanguage/Help:Contents|Portail d'aide]] où vous trouverez toute la documentation relative à l'utilisation et à l'édition des Wikifunctions. Si vous êtes toujours bloqué, postez un message sur le [[Wikifunctions:Project chat|Chat du projet]] et quelqu'un répondra à votre question.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Comment trier ou catégoriser les fonctions ? ===
{{Tracked|T285424}}
Pour l'instant, la meilleure façon de trier ou de catégoriser les fonctions est de le faire à la main à travers les pages de l'espace de noms Wikifunctions. Une autre option serait de passer par la page de discussion de la fonction en question. Nous surveillerons ces efforts et discuterons avec la communauté des changements à apporter au système pour faciliter cette tâche.
[[Category:FAQ| {{#translation:}}]]
by2l6ee2u7dx71etly9410c4tr9vqqz
Wikifunctions:FAQ/gu
4
14592
191353
146077
2025-06-07T04:44:00Z
FuzzyBot
207
Updating to match new version of source page
191353
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== પરિચય ==
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is this project about? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
=== વિધેય (ફંક્શન) શું છે? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* ભવિષ્યમાં:
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<span id="How_is_Wikifunctions_multilingual?"></span>
=== વિકિવિધેય બહુભાષી કઇ રીતે છે? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
<div class="mw-translate-fuzzy">
=== વિકિવિધેય શું નથી? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== યોગદાન ==
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== હું મદદ માટે ક્યાં જઈ શકું? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== અમે વિધેયોની ગોઠવણી કે વર્ગીકરણ કેવી રીતે કરીએ છીએ? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
cnfb42unosmfr4chrydcqhu6exkcw42
Wikifunctions:FAQ/uk
4
14697
191369
146092
2025-06-07T04:44:08Z
FuzzyBot
207
Updating to match new version of source page
191369
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Це спеціальна сторінка для частих запитань про Вікіфункції. Будь ласка, не соромтеся задати своє питання на [[Wikifunctions talk:FAQ|сторінці обговорення]], якщо ваше питання не вказано тут!
Крім того, будь ласка, розгляньте наші [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|ЧаПи на Meta]] щодо більш загальних питань про Вікіфункції та Абстрактну Вікіпедію.
__TOC__
<span id="Introduction"></span>
== Вступ ==
<span id="What_is_this_project_about?"></span>
=== Про що цей проєкт? ===
Вікіфункції — це новий проєкт Вікімедіа, що надає каталог всіх видів функцій, які може будь-хто викликати, писати, обслуговувати та використовувати. Він також надає базову технологію, що в майбутньому дозволить переклад мовно-незалежних статей із Абстрактної Вікіпедії на мову будь-якої Вікіпедії. Це дозволить кожному робити свої внески та читати статті мовами, яким вони надають перевагу.
<span id="What_is_a_function?"></span>
=== Що таке функція? ===
Функції — це форма знань, яка може відповісти на запитання, наприклад, скільки днів минуло між двома датами або яка відстань між двома містами. Складніші функції можуть відповісти на складніші запитання, наприклад, який об'єм тривимірної форми, яка відстань між Марсом і Венерою на певну дату або чи жили два види одночасно.
Ми вже використовуємо функції в багатьох типах запитів на знання, наприклад, ставлячи запитання пошуковій системі. Шаблони, такі як [[:w:en:Template:Convert|Template:Convert]] і [[:w:en:Template:Age|Template:Age]] в англійській Вікіпедії, також є прикладами функцій, які вже використовуються в багатьох Вікіпедіях, написані у вікітексті та Lua та вручну скопійовані до кожної вікі, де вони потрібні.
<span id="What_is_an_implementation?"></span>
=== Що таке реалізація? ===
Реалізація — це конкретний спосіб виконання функції. Реалізація — це рецепт, який перераховує кроки, необхідні для запуску функції. Це може бути шматок коду на мові програмування, або комбінація викликів інших функцій. Функція може мати багато реалізацій, які всі повинні бути еквівалентними.
<span id="What_is_a_test?"></span>
=== Що таке тест? ===
Тест — це спосіб визначити, чи правильно виконується ця функція. Функція, як правило, має кілька тестерів, кожен із яких визначає певний вхід функції та умови, яким повинен відповідати вихід для цього входу.
Наприклад, тестувальники для функції «регістр назви» можуть включати: «<span dir="ltr" lang="en">abc</span>» повинно стати «<span dir="ltr" lang="en">Abc</span>»; «<span dir="ltr" lang="en">war and peace</span>» повинно стати «<span dir="ltr" lang="en">War and Peace</span>»; «<span dir="ltr" lang="ru">война и мир</span>» повинно стати «<span dir="ltr" lang="ru">Война и мир</span>» та «<span dir="ltr" lang="en">123</span>» повинно залишитися «<span dir="ltr" lang="en">123</span>».
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Які функції доступні зараз, які будуть доступні незабаром, і які пізніше? ===
* На старті:
** Ми маємо можливість мати функції, що працюють з рядками (Strings) та булевими змінними (Booleans).
** Вікіфункції будуть повністю інтернаціоналізовані із самого початку. Вони можуть бути використанні в будь-якій мові.
* [[Wikifunctions:Status|Поточна розробка]]:
** Загальні типи і загальні функції не повністю підтримуються.
** Зараз додавання типів є чимось, що обмежено командою розробників. У майбутньому спільнота матиме змогу додавати більше типів. Є багато роботи, яку потрібно зробити в майбутньому, щоб зробити поведінку типів набагато плавнішою.
*** Одним особливо зацікавленим типом буде бінарний тип, а особливо, файли.
** Зараз ми підтримуємо дві мови програмування для реалізацій: JavaScript і Python. У майбутньому, ми хочемо підтримувати багато інших мов.
** Тепер ''не'' можливо викликати інші функції з реалізацій, написаних будь-якою мовою програмування. Наразі це можливо лише через композицію.
* У майбутньому:
** Буде можливість викликати функції Вікіфункції з інших проєктів Вікімедіа та інтегрувати їхні результати у вивід сторінки.
** Буде можливість використовувати дані із Вікіданих у функціях.
** Буде можливість викликати набори даних із простору Commons Data.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Як Вікіфункції є багатомовними? ===
Вікіфункції й абстрактна Вікіпедія є багатомовними різними способами, які не впливають один на одного:
* '''Вікіфункції є багатомовними з точки зору їх вмісту та інтерфейсу користувача'''. Користувачі можуть читати і викликати функції на Вікіфункціях будь-якою природною мовою. Ось функція «об'єднати рядки» [https://www.wikifunctions.org/view/en/Z10000 англійською], [https://www.wikifunctions.org/view/pl/Z10000 польською] мовами та [https://www.wikifunctions.org/view/he/Z10000 івритом], і вона доступна багатьма іншими мовами.
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Які мови програмування зараз підтримуються Вікіфункціями? Які мови програмування підтримуватимуться в майбутньому? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Як Вікіфункції будуть інтегровані в інші проєкти? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== Чим не є Вікіфункції? ===
Будь ласка, ознайомтесь із [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Вікіфункції:Чим не є Вікіфункції]] для детальнішої інформації про це.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Під якою ліцензією перебуватимуть функції та похідний контент? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== Участь ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Я тут новачок. Що мені робити і чим я можу допомогти? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Як створити нову функцію, реалізацію або тест? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<span id="What_should_I_edit_first?"></span>
=== Що мені редагувати спочатку? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== Куди я можу звернутися за допомогою? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Як ми сортуємо або класифікуємо функції? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
7s4rk2o7stnza3thgx6kf5akw9tnetw
Wikifunctions:FAQ/hi
4
15190
191355
146080
2025-06-07T04:44:01Z
FuzzyBot
207
Updating to match new version of source page
191355
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== परिचय ==
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is this project about? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a function? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">In the future:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What Wikifunctions is not? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
== Contributing ==
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where can I go for help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do we sort or categorize functions? ===
</div>
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
50srn4zpv0dkoaiidf74d13aggzhct9
Z12427
0
19325
191290
189269
2025-06-06T17:00:38Z
WrenFalcon
12896
Added Z24797 and Z24820 to the approved list of implementations
191290
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z12427"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z13518",
"Z17K2": "Z12427K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "φυσικός αριθμός"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "ọnụọgụgụ: Nọmba eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "সংখ্যা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "nombre à tester"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "טבעי"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "numero naturale"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "bilangan"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "natürliche Zahl"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "număr natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1672",
"Z11K2": "自然數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "自然数"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "likas"
}
]
}
}
],
"Z8K2": "Z40",
"Z8K3": [
"Z20",
"Z12433",
"Z12434",
"Z13685",
"Z14091",
"Z14092",
"Z14093",
"Z14094",
"Z14095",
"Z14097",
"Z14098",
"Z14099",
"Z14100",
"Z14682",
"Z14693",
"Z14696",
"Z14701",
"Z14702",
"Z24793",
"Z21083"
],
"Z8K4": [
"Z14",
"Z14096",
"Z14090",
"Z12428",
"Z24797",
"Z24820"
],
"Z8K5": "Z12427"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "is prime"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1005",
"Z11K2": "является простым числом"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "είναι πρώτος αριθμός"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "ist Primzahl"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1592",
"Z11K2": "är primtal"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "bụ isi"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "এটি কি মৌলিক সংখ্যা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "est-ce un nombre premier ?"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "האם ראשוני"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "è un numero primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "adalah prima"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "é primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1003",
"Z11K2": "Es primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "este un număr prim?"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1672",
"Z11K2": "為質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "是质数"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1902",
"Z11K2": "係質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "lantay ba"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1011",
"Z31K2": [
"Z6",
"কী মৌলিক",
"মৌলিক সংখ্যা যাচাই"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1186",
"Z31K2": [
"Z6",
"ראשוני?"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1664",
"Z31K2": [
"Z6",
"prim?",
"număr prim?",
"este prim?"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1844",
"Z31K2": [
"Z6",
"balho ba",
"prime ba"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Checks if the provided natural number is prime or not. "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1005",
"Z11K2": "Проверяет, является ли предоставленное целое число простым или нет."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "επιστρέφει αληθής εάν ο αριθμός είναι πρώτος "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "prüft, ob die Zahl eine Primzahl ist"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1592",
"Z11K2": "testar om ett positivt heltal är ett primtal"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Na-enyocha ma integer enyere ọ bụ isi ma ọ bụ na ọ bụghị."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "যাচাই করবে যে প্রদত্ত সংখ্যাটি মৌলিক কি না।"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "renvoie \"vrai\" si le nombre donné est un nombre premier, sinon \"faux\""
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "בדיקה האם מספר טבעי הוא ראשוני, או לא."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "cek apakah bilangan yang dimasukkan adalah prima atau tidak"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "Verifica se o inteiro fornecido é primo ou não."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1003",
"Z11K2": "Comprobación verdero/falso si el número introducido es primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "Verifică dacă numărul natural dat este prim sau nu."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "检查提供的整数是否为质数。"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1902",
"Z11K2": "試下一個數係咪質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "Tinitignan kung yung ibinigay na bilang na likas ay lantay ba o hindi."
}
]
}
}
jz615db8tio7dg2o7ymcsmp96gmbaoz
191291
191290
2025-06-06T17:01:22Z
WrenFalcon
12896
Removed Z12428 from the approved list of implementations
191291
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z12427"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z13518",
"Z17K2": "Z12427K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "φυσικός αριθμός"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "ọnụọgụgụ: Nọmba eke"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "সংখ্যা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "nombre à tester"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "טבעי"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "numero naturale"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "bilangan"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "natürliche Zahl"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "număr natural"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1672",
"Z11K2": "自然數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "自然数"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "likas"
}
]
}
}
],
"Z8K2": "Z40",
"Z8K3": [
"Z20",
"Z12433",
"Z12434",
"Z13685",
"Z14091",
"Z14092",
"Z14093",
"Z14094",
"Z14095",
"Z14097",
"Z14098",
"Z14099",
"Z14100",
"Z14682",
"Z14693",
"Z14696",
"Z14701",
"Z14702",
"Z24793",
"Z21083"
],
"Z8K4": [
"Z14",
"Z14096",
"Z14090",
"Z24797",
"Z24820"
],
"Z8K5": "Z12427"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "is prime"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1005",
"Z11K2": "является простым числом"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "είναι πρώτος αριθμός"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "ist Primzahl"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1592",
"Z11K2": "är primtal"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "bụ isi"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "এটি কি মৌলিক সংখ্যা"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "est-ce un nombre premier ?"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "האם ראשוני"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "è un numero primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "adalah prima"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "é primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1003",
"Z11K2": "Es primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "este un număr prim?"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1672",
"Z11K2": "為質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "是质数"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1902",
"Z11K2": "係質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "lantay ba"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1011",
"Z31K2": [
"Z6",
"কী মৌলিক",
"মৌলিক সংখ্যা যাচাই"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1186",
"Z31K2": [
"Z6",
"ראשוני?"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1664",
"Z31K2": [
"Z6",
"prim?",
"număr prim?",
"este prim?"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1844",
"Z31K2": [
"Z6",
"balho ba",
"prime ba"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Checks if the provided natural number is prime or not. "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1005",
"Z11K2": "Проверяет, является ли предоставленное целое число простым или нет."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1827",
"Z11K2": "επιστρέφει αληθής εάν ο αριθμός είναι πρώτος "
},
{
"Z1K1": "Z11",
"Z11K1": "Z1430",
"Z11K2": "prüft, ob die Zahl eine Primzahl ist"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1592",
"Z11K2": "testar om ett positivt heltal är ett primtal"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1014",
"Z11K2": "Na-enyocha ma integer enyere ọ bụ isi ma ọ bụ na ọ bụghị."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1011",
"Z11K2": "যাচাই করবে যে প্রদত্ত সংখ্যাটি মৌলিক কি না।"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1004",
"Z11K2": "renvoie \"vrai\" si le nombre donné est un nombre premier, sinon \"faux\""
},
{
"Z1K1": "Z11",
"Z11K1": "Z1186",
"Z11K2": "בדיקה האם מספר טבעי הוא ראשוני, או לא."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1078",
"Z11K2": "cek apakah bilangan yang dimasukkan adalah prima atau tidak"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1381",
"Z11K2": "Verifica se o inteiro fornecido é primo ou não."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1003",
"Z11K2": "Comprobación verdero/falso si el número introducido es primo"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1664",
"Z11K2": "Verifică dacă numărul natural dat este prim sau nu."
},
{
"Z1K1": "Z11",
"Z11K1": "Z1645",
"Z11K2": "检查提供的整数是否为质数。"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1902",
"Z11K2": "試下一個數係咪質數"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1844",
"Z11K2": "Tinitignan kung yung ibinigay na bilang na likas ay lantay ba o hindi."
}
]
}
}
kyumdrk0s5zg2vztjry69idpq9cv3rc
Wikifunctions:FAQ/nl
4
19760
191361
146108
2025-06-07T04:44:04Z
FuzzyBot
207
Updating to match new version of source page
191361
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Dit is een pagina toegewijd aan de veelgestelde vragen over Wikifuncties. Alstublieft, voel je vrij om je eigen vragen in de [[Wikifunctions talk:FAQ|overlegpagina]] te stellen, indien je vragen hier niet zijn vermeld!
<div class="mw-translate-fuzzy">
Bekijk ook onze [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ op Meta]] met betrekking tot meer algemene vragen over Wikifuncties en/of Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Introductie ==
<span id="What_is_this_project_about?"></span>
=== Waar gaat dit project over? ===
Wikifuncties is een nieuw Wikimedia-project dat een catalogus biedt van allerlei functies die iedereen kan oproepen, schrijven, onderhouden en gebruiken. Het biedt ook de onderliggende technologie die uiteindelijk de vertaling van taalonafhankelijke artikelen van Abstract Wikipedia in de taal van elke Wikipedia mogelijk maakt. Zo kan iedereen artikelen in hun voorkeurstaal bijdragen en lezen.
<span id="What_is_a_function?"></span>
== Wat is een functie? ==
Functies zijn een vorm van kennis die vragen kan beantwoorden, zoals hoeveel dagen er zijn verstreken tussen twee data of de afstand tussen twee steden. Gecompliceerde functies kunnen meer ingewikkelde vragen beantwoorden, zoals het volume van een driedimensionale vorm, de afstand tussen Mars en Venus op een bepaalde datum, of de vraag of twee soorten tegelijkertijd leefden.
We gebruiken functies in veel soorten kennisverzoeken, zoals het stellen van een vraag aan een zoekmachine. De sjablonen, zoals [[:w:en:Template:Convert|Template:Convert]] en [[:w:en:Template:Age|Template:Age]] op de Engelstalige Wikipedia, zijn ook voorbeelden van functionaliteiten die al in veel Wikipedia's worden gebruikt, in wikitekst en Lua zijn geschreven en handmatig naar elke wiki gekopieerd zijn waar die nodig is.
<span id="What_is_an_implementation?"></span>
== Wat is een implementatie? ==
<div class="mw-translate-fuzzy">
Een implementatie is een bepaalde manier om een functie uit te voeren. Een implementatie is een recept dat de stappen vermeldt die nodig zijn om de functie uit te voeren. Het kan een stukje code zijn in een programmeertaal of een combinatie van andere functies. Een functie kan veel implementaties hebben, die allemaal gelijkwaardig moeten zijn.
</div>
<span id="What_is_a_test?"></span>
=== Wat is een test? ===
Een test is een manier om te bepalen of een bepaalde functie het juiste doet. Een functie zal meestal meerdere testers hebben, die elk een bepaalde invoer aan de functie en de uitvoersvoorwaarden specificeren.
Bijvoorbeeld, testen voor een functie "title case" kunnen omvatten: “<span dir="ltr" lang="en">abc</span>” moet “<span dir="ltr" lang="en">Abc</span>” worden; “<span dir="ltr" lang="en">war and peace</span>” moet “<span dir="ltr" lang="en">War and Peace</span>” worden; “<span dir="ltr" lang="ru">война и мир</span>” moet “<span dir="ltr" lang="ru">Война и мир</span>” worden; en “<span dir="ltr" lang="en">123</span>” moet “<span dir="ltr" lang="en">123</span>” blijven.
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Welke mogelijkheden zijn nu beschikbaar, welke zijn straks beschikbaar, en welke komen later? ===
* Bij de lancering:
** We hebben de mogelijkheid om functies te hebben die werken met tekenreeksen en booleans.
** Wikifuncties zullen vanaf het begin volledig internationaal worden. Het kan in elke taal worden gebruikt.
* [[Wikifunctions:Status|Huidige ontwikkeling]]:
** <span class="mw-translate-fuzzy">generieke typen en generieke functies worden niet volledig ondersteund.</span>
** <span class="mw-translate-fuzzy">Het toevoegen van typen zal vooralsnog iets zijn dat beperkt is tot het ontwikkelaarsteam. In de toekomst zal de gemeenschap zelf meer soorten kunnen toevoegen. Er is veel werk in de toekomst om de typen veel soepeler te laten gedragen.</span>
*** Een bijzonder interessant type is binaire gegevens en met name bestanden.
** <span class="mw-translate-fuzzy">We ondersteunen momenteel twee programmeertalen voor implementaties, JavaScript en Python. In de toekomst willen we nog veel meer ondersteunen.</span>
** <span class="mw-translate-fuzzy">Het is nu ''niet'' mogelijk om andere functies op te roepen van implementaties die in een programmeertaal zijn geschreven. Dit is nu alleen mogelijk door middel van compositie.</span>
* In de toekomst:
** <span class="mw-translate-fuzzy">Het zal mogelijk zijn om Wikifuncties-functies uit andere Wikimedia-projecten te roepen en hun resultaten te integreren in de uitvoer van de pagina.</span>
** Het zal mogelijk zijn om gegevens uit Wikidata te gebruiken bij functies.
** Het zal mogelijk zijn om gegevenssets te roepen uit de Data-naamruimte op Commons.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Hoe is Wikifuncties meertalig? ===
Wikifuncties en Abstract Wikipedia zijn meertalig op verschillende manieren die elkaar niet beïnvloeden:
* '''Wikifuncties is meertalig op basis van zijn inhoud en gebruikersinterface.''' Gebruikers kunnen functies op Wikifuncties in iedere natuurlijke taal lezen en roepen. Hier staat de “tekenreeks samenvoegen” functie in [https://www.wikifunctions.org/view/en/Z10000 Engels], [https://www.wikifunctions.org/view/pl/Z10000 Pools], en [https://www.wikifunctions.org/view/he/Z10000 Hebreeuws], en het is beschikbaar in veel meer talen.
* '''Bijdragers kunnen Wikifuncties met hun eigen talen bewerken en verbeteren.''' Ook kunnen implementaties in de natuurlijke taal van de bijdrager worden bewerkt. Bijvoorbeeld de samenvoeging van de “en” functie kan bewerkt zijn in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de Duits], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en Engels] of een andere uit ongeveer 300 talen.
* '''Wikifuncties functies kunnen worden gebruikt om resultaten voor iedere natuurlijke taal te maken.''' De gemeenschap is bezig met het creëren van een aantal functies om de tekstgeneratie in veel natuurlijke talen te ondersteunen. We hebben functies voor [[Wikifunctions:Catalogue#Breton|het Bretons]], [[Wikifunctions:Catalogue#Rohingya|het Rohingya]], [[Wikifunctions:Catalogue#English|het Engels]] en veel andere talen.
* '''Functies in Wikifuncties kunnen in verschillende programmeertalen worden geïmplementeerd.''' Bijvoorbeeld de [[Z10000|samenvoegen-functie]] is geïmplementeerd in zowel [[Z10005|JavaScript]] als [[Z10004|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Welke programmeertalen zijn momenteel door Wikifuncties ondersteund? Welke programmeertalen worden in de toekomst ondersteund? ===
Momenteel ondersteunt Wikifuncties implementaties die zijn geschreven in JavaScript en Python. We willen in de toekomst meer programmeertalen ondersteunen. We hopen in 2025 nog minstens één andere programmeertaal toe te voegen (maar dat hebben we nog niet besloten).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Hoe wordt Wikifuncties geïntegreerd in andere projecten? ===
Wikifuncties is de eerste stap naar het bouwen van Abstract Wikipedia. Onze focus op de korte termijn zal het ondersteunen van de gemeenschap zijn en het verbeteren op basis van feedback. Tegelijkertijd zullen we beginnen met het proces om het te integreren met Wikipedia en Wikidata, wat bredere toepassingen in het echte leven mogelijk maakt en ons dichter bij de visie van Abstract Wikipedia brengt.
<div class="mw-translate-fuzzy">
Bijdragers zullen functies van Wikifuncties vanuit hun wiki's kunnen oproepen. Voor lezers van de wiki wordt het resultaat van de functie-oproep weergegeven. Dit kan bijvoorbeeld worden gebruikt om de leeftijd van een persoon, de bevolkingsdichtheid op basis van bevolking- en oppervlaktegegevens van Wikidata berekenen, of om een grafiek te tekenen en te integreren in een bepaald artikel.
</div>
Een andere optie om Wikifuncties te integreren is om een interactieve functieoproep-interface binnen hun wiki te integreren. Dit kan bijvoorbeeld worden gebruikt in een Wikipedia-artikel om het resultaat van een natuurkundige vergelijking dynamisch te berekenen op basis van door de lezer verstrekte parameters en te interageren met wiskundige functies, enz.
<span id="What_Wikifunctions_is_not?"></span>
=== Wat is Wikifuncties niet? ===
Alstublieft zie [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifuncties:Wat Wikifuncties niet is]] voor meer informatie daarvoor.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Onder welke licentie zullen de functies en afgeleide inhoud beschikbaar zijn? ===
Op basis van de discussie die [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|op Meta tussen november en december 2021]] plaatsvond, zullen alle bijdragen aan Wikifuncties en de bredere Abstract Wikipedia-projecten onder vrije licenties worden gepubliceerd. In het bijzonder:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Tekstuele inhoud]] op Wikifuncties zal worden gepubliceerd onder [[w:nl:Creative Commons-licentie|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Functiehandtekeningen]] en andere gestructureerde inhoud op Wikifuncties zullen worden gepubliceerd onder [[w:nl:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code-implementaties]] in Wikifuncties zullen worden gepubliceerd onder de [[w:nl:Apache-licentie|Apache 2-licentie]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstracte inhoud]] voor Abstract Wikipedia wordt gepubliceerd onder CC BY-SA 4.0.
Er zijn nog punten die in de toekomst moeten worden aangepakt, zoals de licentie van de gegenereerde inhoud van de abstracte inhoud. We zijn van plan om samen met de juridische afdeling een uitgebreider document op te stellen over hoe mensen de code van Wikifuncties zo pijnloos mogelijk kunnen hergebruiken, terwijl ze zich aan de licentie houden.
<span id="Contributing"></span>
== Bijdragen ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Ik ben nieuw hier. Wat is er voor mij te doen en hoe kan ik helpen? ===
Welkom! We zijn erg blij dat je hier bent! Er zijn veel mogelijkheden om bij te dragen aan Wikifuncties, van het creëren van nieuwe functies tot het verbeteren en vertalen van de documentatie. Als je op zoek bent naar manieren om betrokken te raken, raden wij je aan, afhankelijk van je niveau van comfort, om een nieuwe functie voor te stellen over een onderwerp waarin je interesse hebt. Of zelfs die functie kunt aanmaken. Je kunt helpen met vertalingen. Je kunt onze documentatie lezen en verbeteren. Je kunt helpen met het organiseren van de gemeenschap.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Hoe creëer ik een nieuwe functie, implementatie of test? ===
Om te zien hoe je een nieuwe functie, implementatie, of test kunt aanmaken, ga naar [[Special:MyLanguage/Wikifunctions:Introduction|Wikifuncties:Introductie]].
Om meer gedetailleerd te zien hoe je een implementatie maakt, zie [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifuncties:Implementaties maken]].
<span id="What_should_I_edit_first?"></span>
=== Wat moet ik eerst bewerken? ===
<div class="mw-translate-fuzzy">
Als je meerdere talen spreekt dan kun je functies zoeken die nog geen labels en beschrijvingen in je talen hebben en deze helpen toe te voegen.
</div>
Als je interesse hebt in een onderwerp dat functies in Wikifuncties zou kunnen bevatten, maar dat nog niet kunt, of als je meer ideeën voor functies hebt, kun je naar de pagina gaan om [[Wikifunctions:Suggest a new function|nieuwe functies voor te stellen]] en je ideeën presenteren.
Als je programmeur bent van JavaScript of Python wil je misschien functies controleren die nog geen implementaties hebben in JavaScript of Python en hen proberen te schrijven.
<span id="Where_can_I_go_for_help?"></span>
=== Waar kan ik hulp krijgen? ===
<div class="mw-translate-fuzzy">
Je eerste stop zou het [[Special:MyLanguage/Help:Contents|Hulpportaal]] moeten zijn, waar je alle documentatie kunt vinden met betrekking tot het gebruik en bewerken van Wikifuncties. Als je nog steeds niet verder kunt, dan kun je een bericht op [[Wikifunctions:Project chat|Project chat]] plaatsen, iemand zal je vraag dan beantwoorden.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Hoe sorteren of categoriseren wij functies? ===
{{Tracked|T285424}}
Voorlopig is het het beste om handmatig door pagina's in de Wikifuncties-naamruimte functies te bladeren. Een andere optie zou zijn via de overlegpagina van de gegeven functie. Wij zullen deze inspanningen volgen en met de gemeenschap bespreken welke wijzigingen in het systeem voor deze taak nuttig zouden zijn.
[[Category:FAQ| {{#translation:}}]]
4y1y556xfvwex5dhvztlt8nscf5zj1j
Wikifunctions:FAQ/pl
4
19835
191363
146110
2025-06-07T04:44:05Z
FuzzyBot
207
Updating to match new version of source page
191363
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
To jest strona poświęcona często zadawanym pytaniom na temat Wikifunkcji. Możesz zadać własne pytanie na [[Wikifunctions talk:FAQ|stronie dyskusji]], jeśli twojego pytania nie ma na liście!
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Wprowadzenie ==
<span id="What_is_this_project_about?"></span>
=== O co chodzi w tym projekcie? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
=== Co to jest funkcja? ===
Funkcje to forma wiedzy, która może odpowiedzieć na pytania, takie jak ile dni minęło między dwiema datami lub odległość między dwiema miastami. Bardziej złożone funkcje mogą odpowiedzieć na bardziej skomplikowane pytania, takie jak objętość trójwymiarowego kształtu, odległość między Marsem a Wenus w określonym dniu lub czy dwa gatunki żyły w tym samym czasie.
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<span id="What_is_an_implementation?"></span>
=== Co to jest implementacja? ===
Implementacja to szczególny sposób wykonania funkcji. Implementacja to przepis zawierający listę kroków niezbędnych do uruchomienia funkcji. Może to być fragment kodu w języku programowania lub kombinacja wywołań innych funkcji. Funkcja może mieć wiele implementacji i wszystkie powinny być równoważne.
<span id="What_is_a_test?"></span>
=== Czym jest test? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Jaka funkcjonalność jest już dostępna, jaka będzie wkrótce, a jaka później? ===
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** Wikifunkcje będą od początku w pełni umiędzynarodowione. Można ich używać w dowolnym języku.
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span class="mw-translate-fuzzy">Dodawanie typów będzie na razie czymś ograniczonym dla zespołu programistów. W przyszłości społeczność będzie mogła samodzielnie dodawać więcej typów. Czeka nas dużo pracy, aby typy zachowywały się bardziej gładko.</span>
*** Szczególnie interesującym typem będą dane binarne, a zwłaszcza pliki.
** Obecnie obsługujemy dwa języki programowania dla implementacji: JavaScript i Python. W przyszłości chcemy obsługiwać ich znacznie więcej.
** <span class="mw-translate-fuzzy">Obecnie ''nie'' jest możliwe wywoływanie innych funkcji z implementacji napisanych w innym języku programowania.</span>
* W przyszłości:
** <span class="mw-translate-fuzzy">Będzie możliwe wywoływanie funkcji Wikifunkcji z innych projektów Wikimedia i integrowanie ich wyników z wynikami strony.</span>
** W funkcjach będzie można używać danych z Wikidanych.
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<span id="How_is_Wikifunctions_multilingual?"></span>
=== W jaki sposób Wikifunkcje są wielojęzyczne? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* '''Funkcje w Wikifunkcjach mogą być implementowane w różnych językach programowania.''' Na przykład [[Z10000|funkcja łączenia tekstu]] jest zaimplementowana zarówno w [[Z10005|JavaScripcie]], jak i [[Z10004|Pythonie]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Jakie języki programowania obsługują obecnie Wikifunkcje? Jakie języki programowania będą obsługiwane w przyszłości? ===
Obecnie Wikifunkcje obsługują implementacje napisane w języku JavaScript i Python. W przyszłości planujemy dodać wsparcie dla większej liczby języków programowania. Mamy nadzieję, że w 2025 roku dołączy się przynajmniej jeden język programowania (ale jeszcze nie zdecydowaliśmy który).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== W jaki sposób Wikifunkcje zostaną zintegrowane z innymi projektami? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
Inną opcją na integrację WikiFunkcji będzie umożliwienie bezpośrednio w wiki interaktywnego wywoływania funkcji. Dzięki temu będzie można na przykład w artykule w Wikipedii dynamicznie obliczać wyniki równań fizycznych na podstawie parametrów wprowadzonych przez czytelnika; rysować i wchodzić w interakcję z funkcjami matematycznymi; itp.
<span id="What_Wikifunctions_is_not?"></span>
=== Czym Wikifunkcje nie są? ===
Więcej informacji na ten temat znajdziesz w artykule [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunkcje:Czym Wikifunkcje nie są]].
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Jakiej licencji będą podlegać funkcje i treści pochodne? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Implementacje kodu]] w Wikifuncjach będą publikowane na [[w:Apache License|Licencji Apache 2]].
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== Wkład ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Jestem tu nowy. Co mogę zrobić i jak mogę pomóc? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Jak utworzyć nową funkcję, implementację lub test? ===
Aby zobaczyć, jak utworzyć nową funkcję, implementację lub test, zobacz [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunkcje:Wprowadzenie]].
Aby zobaczyć bardziej szczegółowo, jak utworzyć implementację, zobacz [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunkcje:Jak tworzyć implementacje]].
<span id="What_should_I_edit_first?"></span>
=== Co powinienem edytować na początku? ===
<div class="mw-translate-fuzzy">
Jeśli znasz kilka języków, znajdź funkcje, które nie mają jeszcze etykiet i opisów w tych językach i pomóż je dodać.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
Jeśli jesteś programistą w JavaScripcie lub Pythonie, być może chcesz sprawdzić funkcje, które nie mają jeszcze implementacji w JavaScript lub Pythonie i spróbować je napisać.
<span id="Where_can_I_go_for_help?"></span>
=== Gdzie mogę zwrócić się po pomoc? ===
<div class="mw-translate-fuzzy">
Twoje pierwsze kroki powinny prowadzić do [[Special:MyLanguage/Help:Contents|Portalu pomocy]], gdzie znajdziesz całą dokumentację związaną z korzystaniem i edycją WikiFunkcji. Jeśli nadal będziesz mieć problemy, umieść wiadomość na [[Wikifunctions:Project chat|Czacie projektu]], gdzie ktoś odpowie na twoje pytanie.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Jak sortujemy i kategoryzujemy funkcje? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
k5yd858k4srcozke6jporr9lz66gicq
Wikifunctions:Status updates
4
22740
191292
190594
2025-06-06T18:31:53Z
DVrandecic (WMF)
7
191292
wikitext
text/x-wiki
<languages/>
{{shortcut|WF:SU}}{{notice|1=<translate><!--T:1--> '''[[<tvar name="sub">:m:Global message delivery/Targets/Wikifunctions & Abstract Wikipedia</tvar>|Subscribe]]''' to receive short on-wiki MassMessage notifications about each new issue</translate>}}
{{Wikifunctions updates
| prevlabel = <translate><!--T:2--> Previous update</translate>
| prev = 2024-02-01
| nextlabel = <translate><!--T:3--> Last update</translate>
| next = 2025-06-06
}}
<translate><!--T:4-->
A lot is happening around Wikifunctions and Abstract Wikipedia. This is the page where our updates are posted, including the [[<tvar name="1">Special:MyLanguage/WF:function of the Week</tvar>|function of the Week]].
<!--T:5-->
You can also subscribe to the [[<tvar name="sub">:m:Global message delivery/Targets/Wikifunctions & Abstract Wikipedia</tvar>|on-wiki newsletter]] to have them delivered to your talk page or to your project's village pump.
== Newsletters == <!--T:28-->
</translate>
<!--<nowiki> Newsletter entry template:
* <translate><tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-??-??|2025-??-??]]</bdi></tvar>: Title</translate>
NOTE: Remember to also update the "next =" date at the top of this page.
</nowiki>-->
=== 2025 ===
* <translate><tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-06-06|2025-06-06]]</bdi></tvar>: Where will Abstract Content go?</translate>
* <translate><!--T:74--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-05-29|2025-05-29]]</bdi></tvar>: Rolling out to five Wiktionaries; Calculating with today's date</translate>
* <translate><!--T:73--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-05-23|2025-05-23]]</bdi></tvar>: Ongoing consultation about the Location for Abstract Content</translate>
* <translate><!--T:72--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-05-15|2025-05-15]]</bdi></tvar>: Location of Abstract Content</translate>
* <translate><!--T:71--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-05-09|2025-05-09]]</bdi></tvar>: Abstract Wikipedia and the Wikimedia AI Strategy</translate>
* <translate><!--T:70--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-04-30|2025-04-30]]</bdi></tvar>: Abstract Wikipedia is a MacArthur 100&Change finalist</translate>
* <translate><!--T:69--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-04-25|2025-04-25]]</bdi></tvar>: Welcome, Gregory!</translate>
* <translate><!--T:68--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-04-16|2025-04-16]]</bdi></tvar>: Wikifunctions integrated in Dagbani - and Wikifunctions; and the date of Easter</translate>
* <translate><!--T:67--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-04-11|2025-04-11]]</bdi></tvar>: Quarter in review</translate>
* <translate><!--T:65--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-04-05|2025-04-05]]</bdi></tvar>: Quarterly Planning for April–June 2025; We are looking for a Senior Product Manager</translate>
* <translate><!--T:66--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-03-28|2025-03-28]]</bdi></tvar>: It's about time</translate>
* <translate><!--T:64--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-03-20|2025-03-20]]</bdi></tvar>: Wikidata-based simple enumerations</translate>
* <translate><!--T:63--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-03-15|2025-03-15]]</bdi></tvar>: Upcoming NLG meeting, Recent Changes in the software</translate>
* <translate><!--T:62--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-03-07|2025-03-07]]</bdi></tvar>: Recent Changes in the software, Recording of Volunteer’s Corner, and talks in London</translate>
* <translate><!--T:61--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-02-26|2025-02-26]]</bdi></tvar>: From things to words</translate>
* <translate><!--T:60--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-02-19|2025-02-19]]</bdi></tvar>: A proposal for types per language and part of speech</translate>
* <translate><!--T:59--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-02-13|2025-02-13]]</bdi></tvar>: Restricting the World, redux</translate>
* <translate><!--T:58--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-02-06|2025-02-06]]</bdi></tvar>: Invitation to the Natural Language Generation Special Interest Group</translate>
* <translate><!--T:57--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-01-29|2025-01-29]]</bdi></tvar>: With 2000 Functions into the new year: time for stats</translate>
* <translate><!--T:56--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-01-22|2025-01-22]]</bdi></tvar>: Welcome, David! Naming conventions recommendations</translate>
* <translate><!--T:55--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2025-01-15|2025-01-15]]</bdi></tvar>: Happy Wikipedia day! Quarterly planning</translate>
=== 2024 ===
* <translate><!--T:54--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-12-19|2024-12-19]]</bdi></tvar>: Function of the Week: age; Intros for year articles; New Type: Floating-point number</translate>
* <translate><!--T:53--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-12-12|2024-12-12]]</bdi></tvar>: Sketching a path to Abstract Wikipedia; Team offsite in Lisbon; and much more</translate>
* <translate><!--T:52--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-11-27|2024-11-27]]</bdi></tvar>: WordGraph release; New Special page: list functions by tests; new type for day of the year, and much more</translate>
* <translate><!--T:51--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-11-21|2024-11-21]]</bdi></tvar>: New special page for missing labels, new type for Gregorian years, and much more</translate>
* <translate><!--T:50--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-11-13|2024-11-13]]</bdi></tvar>: New Type: Rational number; Documentation on Wikidata-based types; and more</translate>
* <translate><!--T:48--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-11-07|2024-11-07]]</bdi></tvar>: The Dream of a Universal Language</translate>
* <translate><!--T:49--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-11-01|2024-11-01]]</bdi></tvar>: Rewriting the backend</translate>
* <translate><!--T:47--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-10-25|2024-10-25]]</bdi></tvar>: Our goal for this Quarter: Agreement</translate>
* <translate><!--T:45--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-10-17|2024-10-17]]</bdi></tvar>: What could abstract content look like?</translate>
* <translate><!--T:46--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-10-11|2024-10-11]]</bdi></tvar>: Wikidata Lexemes in Wikifunctions are coming soon</translate>
* <translate><!--T:44--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-10-02|2024-10-02]]</bdi></tvar>: Focus topic: Food</translate>
* <translate><!--T:43--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-09-26|2024-09-26]]</bdi></tvar>: Quarterly planning for October–December 2024; Presentation at Celtic Knot tomorrow</translate>
* <translate><!--T:42--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-09-20|2024-09-20]]</bdi></tvar>: Introducing focus topic areas</translate>
* <translate><!--T:41--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-09-13|2024-09-13]]</bdi></tvar>: Dagbani Wikipedia will be our first wiki for Wikifunctions integration</translate>
* <translate><!--T:40--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-09-06|2024-09-06]]</bdi></tvar>: Volunteer's corner and other updates</translate>
* <translate><!--T:39--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-08-29|2024-08-29]]</bdi></tvar>: Limits on Name and Description Lengths </translate>
* <translate><!--T:38--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-08-23|2024-08-23]]</bdi></tvar>: WasmEdge, Now 300ms Less Edgy</translate>
* <translate><!--T:37--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-08-16|2024-08-16]]</bdi></tvar>: Wikimania 2024 edition</translate>
* <translate><!--T:36--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-08-02|2024-08-02]]</bdi></tvar>: Revamping our 'About' widget</translate>
* <translate><!--T:35--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-07-26|2024-07-26]]</bdi></tvar>: Wikimania 2024 coming soon!</translate>
* <translate><!--T:34--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-07-18|2024-07-18]]</bdi></tvar>: Research report on integrating Wikifunctions from Wikipedia</translate>
* <translate><!--T:33--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-07-10|2024-07-10]]</bdi></tvar>: Type proposals for accessing Lexemes</translate>
* <translate><!--T:32--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-07-03|2024-07-03]]</bdi></tvar>: Quarterly planning</translate>
* <translate><!--T:31--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-06-26|2024-06-26]]</bdi></tvar>: Welcome, Daphne!</translate>
* <translate><!--T:30--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-06-20|2024-06-20]]</bdi></tvar>: New Type: Integers</translate>
* <translate><!--T:29--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-06-13|2024-06-13]]</bdi></tvar>: New Type: Igbo calendar months</translate>
* <translate><!--T:27--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-06-06|2024-06-06]]</bdi></tvar>: New Type: Sign</translate>
* <translate><!--T:26--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-05-30|2024-05-30]]</bdi></tvar>: A single singular or a plurality of plurals?</translate>
* <translate><!--T:25--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-05-22|2024-05-22]]</bdi></tvar>: New Type: Gregorian calendar months</translate>
* <translate><!--T:24--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-05-15|2024-05-15]]</bdi></tvar>: Call for Functions: Spell out the number!</translate>
* <translate><!--T:23--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-05-10|2024-05-10]]</bdi></tvar>: Flagship type for enumerations: Months of the Gregorian calendar</translate>
* <translate><!--T:22--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-05-03|2024-05-03]]</bdi></tvar>: Team meeting and Quarterly plan</translate>
* <translate><!--T:21--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-04-19|2024-04-19]]</bdi></tvar>: Welcome, Sharvani!</translate>
* <translate><!--T:20--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-04-11|2024-04-11]]</bdi></tvar>: New API for calling Wikifunctions and celebrating 1000 functions</translate>
* <translate><!--T:19--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-04-03|2024-04-03]]</bdi></tvar>: Product Update on Diff and Upcoming API Improvements</translate>
* <translate><!--T:18--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-03-28|2024-03-28]]</bdi></tvar>: Creating tests is now much easier!</translate>
* <translate><!--T:17--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-03-21|2024-03-21]]</bdi></tvar>: On the way to internationalizing numbers</translate>
* <translate><!--T:16--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-03-13|2024-03-13]]</bdi></tvar>: On identity</translate>
* <translate><!--T:15--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-03-07|2024-03-07]]</bdi></tvar>: Introducing our second new type: Natural numbers</translate>
* <translate><!--T:14--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-02-28|2024-02-28]]</bdi></tvar>: Type proposal for natural numbers</translate>
* <translate><!--T:13--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-02-22|2024-02-22]]</bdi></tvar>: Updating the function model</translate>
* <translate><!--T:12--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-02-14|2024-02-14]]</bdi></tvar>: Fix-it week</translate>
* <translate><!--T:11--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-02-07|2024-02-07]]</bdi></tvar>: Quarterly planning. Thank you, Nick! Function of the Week: is permutation</translate>
* <translate><!--T:9--> <tvar name="1"><bdi dir="ltr">[[Special:MyLanguage/Wikifunctions:Status updates/2024-02-01|2024-02-01]]</bdi></tvar>: The Igbo Imperative!</translate>
<translate>
=== Before February 2024 === <!--T:7-->
<!--T:10-->
All updates from this period are [[<tvar name="meta">:m:Special:MyLanguage/Abstract Wikipedia/Updates</tvar>|available on Meta-Wiki]].
</translate>
[[Category:Status updates{{#translation:}}| ]]
njp7966k5116mjg2pppb856s28ny63i
Wikifunctions:FAQ/pt-br
4
23593
191364
146115
2025-06-07T04:44:06Z
FuzzyBot
207
Updating to match new version of source page
191364
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Esta é uma página dedicada às perguntas frequentes sobre a Wikifunções. Por favor, sinta-se à vontade para fazer sua própria pergunta na [[Wikifunctions talk:FAQ|página de discussão]], se ela não estiver listada aqui!
Além disso, considere nosso [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ no Meta]] sobre questões mais gerais sobre a Wikifunções e a Wikipédia Abstrata.
__TOC__
<span id="Introduction"></span>
== Introdução ==
<span id="What_is_this_project_about?"></span>
=== Do que se trata esse projeto? ===
A Wikifunções é um novo projeto da Wikimedia que fornece um catálogo de todos os tipos de funções que qualquer um pode chamar, escrever, manter e usar. Ele também fornece a tecnologia subjacente que eventualmente permitirá a tradução de artigos independentes de idioma da Wikipédia Abstrata para o idioma de qualquer Wikipédia. Isso permitirá que todos contribuam e leiam artigos em seus idiomas preferidos.
<span id="What_is_a_function?"></span>
=== O que é uma função? ===
As funções são uma forma de conhecimento que pode responder perguntas, como quantos dias se passaram entre duas datas ou a distância entre duas cidades. Funções mais complicadas podem responder perguntas mais complicadas, como o volume de uma forma tridimensional, a distância entre Marte e Vênus em uma determinada data, ou se duas espécies estavam vivas ao mesmo tempo.
Já usamos funções em muitos tipos de consultas de conhecimento, como fazer uma pergunta a um mecanismo de busca. As predefinições, como [[:w:en:Template:Convert|Template:Convert]] e [[:w:en:Template:Age|Template:Age]] na Wikipédia em inglês, também são exemplos de funcionalidades que já são usadas em muitas Wikipédias, escritas em wikitexto e Lua e copiadas manualmente para cada wiki onde são desejadas.
<span id="What_is_an_implementation?"></span>
=== O que é uma implementação? ===
Uma implementação é uma maneira particular de executar uma função. Uma implementação é uma receita que lista as etapas necessárias para executar a função. Pode ser um pedaço de código em uma linguagem de programação ou uma combinação de chamadas para outras funções. Uma função pode ter muitas implementações, que devem ser todas equivalentes.
<span id="What_is_a_test?"></span>
=== O que é um teste? ===
Um teste é uma maneira de determinar se uma dada função está fazendo a coisa certa. Uma função normalmente terá vários testadores, cada um especificando alguma entrada para a função e as condições que a saída para a entrada dada deve cumprir.
Por exemplo, os testadores para uma função “capitalização de título” podem incluir: “<span dir="ltr" lang="en">abc</span>” deve se tornar “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” deve se tornar “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” deve se tornar “<span dir="ltr" lang="ru">Война и мир</span>”; e “<span dir="ltr" lang="en">123</span>” deve permanecer “<span dir="ltr" lang="en">123</span>”.
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== Quais recursos estão disponíveis agora, quais estarão disponíveis em breve e quais estão mais distantes? ===
* No lançamento:
** Temos a capacidade de ter funções que funcionam com Cadeias e Booleanos.
** A Wikifunções será totalmente internacionalizada desde o início. Ela pode ser usada em qualquer idioma.
* [[Wikifunctions:Status|Desenvolvimento em andamento]]:
** Tipos genéricos e funções genéricas não são totalmente suportados.
** Adicionar tipos será, por enquanto, algo limitado à equipe de desenvolvimento. No futuro, a comunidade poderá adicionar mais tipos. Há muito trabalho a ser feito no futuro para fazer com que os tipos se comportem de forma muito mais suave.
*** Um tipo particularmente interessante serão os dados binários, particularmente os arquivos.
** Atualmente, oferecemos suporte a duas linguagens de programação para implementações: JavaScript e Python. No futuro, queremos oferecer suporte a muitas outras.
** Atualmente, ''não'' é possível chamar outras funções de implementações escritas em qualquer linguagem de programação. Atualmente, isso só é possível por meio de composição.
* No futuro:
** Será possível chamar funções da Wikifunções de outros projetos da Wikimedia e integrar seus resultados na saída da página.
** Será possível usar dados do Wikidata em funções.
** Será possível chamar conjuntos de dados do namespace Commons Data.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== Como a Wikifunções é multilíngue? ===
A Wikifunções e a Wikipédia Abstrata são multilíngues de diversas maneiras diferentes que não afetam uma à outra:
* '''A Wikifunções é multilíngue em termos de conteúdo e interface de usuário.''' Os usuários podem ler e chamar funções na Wikifunções em qualquer idioma natural. Aqui está a função “juntar cadeias” em [https://www.wikifunctions.org/view/en/Z10000 inglês], [https://www.wikifunctions.org/view/pl/Z10000 polonês] e [https://www.wikifunctions.org/view/he/Z10000 hebraico], e está disponível em muitos outros idiomas.
* '''Colaboradores podem editar e melhorar a Wikifunções usando sua linguagem.''' Até mesmo implementações podem ser editadas na linguagem natural do colaborador. Por exemplo, a composição da função “e” pode ser editada em [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de alemão], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en inglês], ou qualquer outro dos cerca de 300 idiomas.
* '''As funções da Wikifunções podem ser usadas para criar resultados para qualquer idioma natural.''' A comunidade está criando um número crescente de funções para dar suporte à geração de texto em muitos idiomas naturais. Temos funções para [[Wikifunctions:Catalogue#Breton|bretão]], [[Wikifunctions:Catalogue#Rohingya|ruainga]], [[Wikifunctions:Catalogue#English|inglês]], e muitos outros idiomas.
* '''As funções na Wikifunções podem ser implementadas em várias linguagens de programação diferentes.''' Por exemplo, a [[Z10000|função juntar]] é implementada em [[Z10005|JavaScript]] e em [[Z10004|Python]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== Quais linguagens de programação a Wikifunções suporta atualmente? Quais linguagens de programação serão suportadas no futuro? ===
Atualmente, a Wikifunções suporta implementações escritas em JavaScript e Python. Planejamos adicionar suporte para mais linguagens de programação no futuro. Esperamos adicionar pelo menos mais uma linguagem de programação em 2025 (mas ainda não decidimos qual).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== Como a Wikifunções será integrada a outros projetos? ===
A Wikifunções é o primeiro passo para construir a Wikipédia Abstrata. Nosso foco a curto prazo será dar suporte à comunidade e fazer melhorias com base no feedback. Ao mesmo tempo, começaremos o processo de integração com a Wikipédia e o Wikidata, o que permitirá aplicações mais amplas na vida real e nos deixará mais próximos da visão da Wikipédia Abstrata.
Os contribuidores poderão chamar funções armazenadas no site da Wikifunções de dentro de suas wikis. O resultado da chamada de função será exibido aos leitores da wiki. Isso pode ser usado, por exemplo, para calcular a idade de uma pessoa, a densidade populacional com base em dados de população e área do Wikidata, ou para desenhar um gráfico e integrá-lo a um determinado artigo.
Outra opção para integrar a Wikifunções será integrar uma interface de chamada de função interativa dentro de sua wiki. Isso poderia ser usado, por exemplo, em um artigo da Wikipédia para calcular dinamicamente o resultado de uma equação física com base em parâmetros fornecidos pelo leitor, desenhar e interagir com funções matemáticas, etc.
<span id="What_Wikifunctions_is_not?"></span>
=== O que a Wikifunções não é? ===
Por favor, veja [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunções:O que a Wikifunções não é]] para mais informações sobre isso.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== Sob qual licença as funções e o conteúdo derivado estarão? ===
Conforme a discussão aconteceu [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|no Meta entre novembro e dezembro de 2021]], todas as contribuições para a Wikifunções e os projetos mais amplos da Wikipédia Abstrata serão publicadas sob licenças livres. Em particular:
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Conteúdo textual]] na Wikifunções será publicado sob [[w:pt:Licença Creative Commons|CC BY-SA 4.0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|Assinaturas de função]] e outros conteúdos estruturados na Wikifunções serão publicados sob [[w:CC0|CC 0]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Implementações de código]] na Wikifunções serão publicadas sob a [[w:pt:Licença Apache|Licença Apache 2]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|Conteúdo Abstrato]] para a Wikipédia Abstrata será publicado sob CC BY-SA 4.0.
Ainda há alguns pontos que precisarão ser abordados no futuro, como a licença do conteúdo gerado a partir do conteúdo abstrato. Planejamos redigir um documento mais abrangente com o departamento Jurídico sobre como as pessoas podem reutilizar o código da Wikifunções da forma mais indolor possível, ao mesmo tempo em que respeitam a licença.
<span id="Contributing"></span>
== Contribuindo ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Sou novo aqui. O que posso fazer e como posso ajudar? ===
Bem-vindo(a)! Estamos muito felizes em ter você aqui! Há muitas oportunidades para contribuir com a Wikifunções, desde criar novas funções até melhorar e traduzir a documentação. Se você está procurando maneiras de se envolver, recomendamos que, dependendo do seu nível de conforto, você sugira uma nova função sobre um tópico do seu interesse. Ou até mesmo crie uma função desse tipo. Forneça alguns testes. Tente sua mão em uma implementação. Ajude com as traduções. Leia e melhore nossa documentação. Ajude a organizar a comunidade.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== Como faço para criar uma nova função, implementação ou teste? ===
Para ver como criar uma nova função, implementação ou teste, consulte [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunções:Introdução]].
Para ver mais detalhes sobre como criar uma implementação, consulte [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunções:Como criar implementações]].
<span id="What_should_I_edit_first?"></span>
=== O que devo editar primeiro? ===
<div class="mw-translate-fuzzy">
Se você consegue escrever em várias linguagens, encontre funções que ainda não tenham rótulos e descrições em suas linguagens e ajude a adicioná-las.
</div>
Se você tiver algum interesse em um domínio que poderia apresentar funções na Wikifunções, mas ainda não o faz, ou se tiver mais ideias para funções, vá para a página de [[Wikifunctions:Suggest a new function|sugestão de novas funções]] e apresente suas ideias.
Se você é um programador em JavaScript ou Python, talvez queira verificar funções que ainda não tenham implementações em JavaScript ou Python e tentar escrevê-las.
<span id="Where_can_I_go_for_help?"></span>
=== Onde posso obter ajuda? ===
Sua primeira parada deve ser o [[Special:MyLanguage/Help:Contents|portal de ajuda]] onde você encontrará toda a documentação relacionada ao uso e edição da Wikifunções. Se você ainda estiver travado, poste uma mensagem no [[Wikifunctions:Project chat|chat do projeto]], e alguém responderá sua pergunta.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Como classificamos ou categorizamos funções? ===
{{Tracked|T285424}}
Por enquanto, a melhor maneira de classificar ou categorizar funções é fazê-lo manualmente por meio de páginas no namespace Wikifunctions. Outra opção seria por meio da página de discussão da função dada. Monitoraremos esses esforços e discutiremos com a comunidade quais mudanças no sistema seriam úteis para essa tarefa.
[[Category:FAQ| {{#translation:}}]]
o5wsf49b1es3zjy5amiw0b8djdkuss6
Wikifunctions:FAQ/da
4
24620
191346
172911
2025-06-07T04:43:57Z
FuzzyBot
207
Updating to match new version of source page
191346
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Introduktion ==
<span id="What_is_this_project_about?"></span>
=== Hvad omhandler dette projekt? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
=== Hvad er en funktion? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* [[Wikifunctions:Status|Igangnværende udvikling]]:
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* I fremtiden:
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What Wikifunctions is not? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
== Contributing ==
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where can I go for help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do we sort or categorize functions? ===
</div>
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
fv4cp3vvz8lobfrj2cf1jdz8lobyd8n
Wikifunctions:FAQ/su
4
27383
191366
146090
2025-06-07T04:44:06Z
FuzzyBot
207
Updating to match new version of source page
191366
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
Ieu mangrupikeun halaman khusus pikeun patarosan umum ngeunaan Wikifunctions. Punten taroskeun patarosan anjeun nyalira dina [[Wikifunctions talk:FAQ|kaca obrolan]] upami patarosan anjeun henteu didaptarkeun di dieu!
<div class="mw-translate-fuzzy">
Salaku tambahan, pertimbangkeun pariksa daptar [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|Patarosan anu sering ditaroskeun dina Meta]] ngeunaan patarosan anu langkung umum ngeunaan Wikifungsi sareng/atanapi Abstrak Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
==Panganteur==
<span id="What_is_this_project_about?"></span>
=== proyék naon ieu? ===
Wikifunctions mangrupa proyék Wikimedia anyar nu nyadiakeun katalog sagala rupa fungsi nu saha bisa nelepon, nulis, ngajaga, jeung make. Éta ogé nyayogikeun téknologi anu mendasar anu pamustunganana bakal ngamungkinkeun tarjamahan tulisan anu mandiri tina basa tina Wikipedia Abstract kana basa Wikipedia naon waé. Ku kituna, dulur-dulur bisa nyumbang jeung maca artikel dina basa nu dipikaresepna.
<span id="What_is_a_function?"></span>
=== Naon sih "fungsi"? ===
Fungsi mangrupa wangun pangaweruh nu bisa ngajawab patarosan, kayaning sabaraha poé geus kaliwat antara dua tanggal atawa jarak antara dua kota. Fungsi nu leuwih rumit bisa ngajawab patarosan nu leuwih rumit, saperti volume bentuk tilu dimensi, jarak antara Mars jeung Venus dina tanggal nu tangtu, atawa naha dua spésiés hirup dina waktu nu sarua.
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is a test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">In the future:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What Wikifunctions is not? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
== Contributing ==
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== I'm new here. What is there for me to do and how can I help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where can I go for help? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do we sort or categorize functions? ===
</div>
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
ipre0p8azz9jdmtxwqxe94fktk6bud1
Wikifunctions:FAQ/lb
4
30751
191360
146084
2025-06-07T04:44:03Z
FuzzyBot
207
Updating to match new version of source page
191360
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== Aféierung ==
<span id="What_is_this_project_about?"></span>
=== Wourëms geet et an dësem Projet? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
=== Wat ass eng Funktioun? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<span id="What_is_an_implementation?"></span>
=== Wat ass eng Implementéiereung? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<span id="What_is_a_test?"></span>
=== Wat ass een Test? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* An Zukunft…
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How is Wikifunctions multilingual? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How will Wikifunctions be integrated into other projects? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== Wat ass Wikifunctions net? ===
Kuckt wgl. [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:Wat Wikifunctions net ass]] fir méi Informatiounen dozou.
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== Bäidroen ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== Ech sinn nei hei. Wat kann ech maachen a wéi kann ech hëllefen? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What should I edit first? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== Wou fannen ech Hëllef? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== Wéi sortéieren oder kategoriséiere mir Funkctiounen? ====
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
be5tw76plj2lavleo6enkhpfvwl3ar8
Wikifunctions:Catalogue/Date operations
4
41958
191265
190998
2025-06-06T12:06:51Z
Denny
81
/* Gregorian calendar dates */
191265
wikitext
text/x-wiki
== Date operations ==
=== Gregorian calendar dates ===
See [[Wikifunctions:Suggest a function#Gregorian calendar date|suggested functions]] for more function ideas.
==== Operations on a date ====
* {{Z+|Z20440}}
* {{Z+|Z20750}}
* {{Z+|Z20816}}
==== Information about a date ====
* {{Z+|Z20421}}
* {{Z+|Z24122}}
* {{Z+|Z20740}}
* {{Z+|Z20822}}
* {{Z+|Z20741}}
==== Information between two dates ====
* {{Z+|Z20430}}
* {{Z+|Z20756}}
* {{Z+|Z24918}}
* {{Z+|Z24901}}
* {{Z+|Z20744}}
* {{Z+|Z20856}}
===== Conversions =====
* {{Z+|Z22844}}
* {{Z+|Z23801}}
* {{Z+|Z23808}}
* {{Z+|Z23246}}
* {{Z+|Z24884}}
==== Dates to strings ====
* {{Z+|Z20780}}
* {{Z+|Z20788}}
* {{Z+|Z22214}}
* {{Z+|Z20770}}
* {{Z+|Z24880}}
* {{Z+|Z20776}}
* {{Z+|Z20773}}
* {{Z+|Z20782}}
* {{Z+|Z20794}}
* {{Z+|Z20785}}
* {{Z+|Z20791}}
* {{Z+|Z23197}}
* {{Z+|Z20801}}
==== Strings to dates ====
* {{Z+|Z20808}}
* {{Z+|Z23976}}
* {{Z+|Z24007}}
* {{Z+|Z23984}}
* {{Z+|Z23990}}
* {{Z+|Z23961}}
=== Day of Roman year ===
* {{Z+|Z20388}}
* {{Z+|Z20343}}
* {{Z+|Z20355}}
* {{Z+|Z20399}}
* {{Z+|Z20357}}
* {{Z+|Z20362}}
* {{Z+|Z20367}}
* {{Z+|Z20406}}
* {{Z+|Z20591}}
* {{Z+|Z22933}}
* {{Z+|Z23427}}
=== Using non-date types ===
* {{Z+|Z10996}}
* {{Z+|Z11015}}
* {{Z+|Z11011}}
* {{Z+|Z12176}}
* {{Z+|Z13163}}
* {{Z+|Z16914}}
* {{Z+|Z13306}}
* {{Z+|Z16908}}
* {{Z+|Z13300}}
* {{Z+|Z13335}}
* {{Z+|Z18957}}
* {{Z+|Z18961}}
=== Bengali date operations ===
* {{Z+|Z12926}}
* {{Z+|Z18131}}
* {{Z+|Z18435}}
* {{Z+|Z18462}}
* {{Z+|Z18169}}
* {{Z+|Z18573}}
* {{Z+|Z18582}}
* {{Z+|Z18387}}
* {{Z+|Z18397}}
* {{Z+|Z18662}}
== Year operations ==
===Gregorian year===
* {{Z+|Z20166}}
* {{Z+|Z20172}}
* {{Z+|Z20314}}
* {{Z+|Z20185}}
* {{Z+|Z20160}}
* {{Z+|Z20192}}
* {{Z+|Z20588}}
* {{Z+|Z20198}}
* {{Z+|Z20219}}
* {{Z+|Z20181}}
* {{Z+|Z20257}}
* {{Z+|Z20290}}
* {{Z+|Z20302}}
==Day of the week==
*{{Z+|Z17414}}
*{{Z+|Z20421}}
*{{Z+|Z17420}}
*{{Z+|Z17435}}
*{{Z+|Z17517}}
*{{Z+|Z17478}}
*{{Z+|Z17485}}
*{{Z+|Z17452}}
*{{Z+|Z17536}}
*{{Z+|Z17506}}
*{{Z+|Z17511}}
*{{Z+|Z20290}}
*{{Z+|Z20302}}
*{{Z+|Z17540}}
*{{Z+|Z17516}}
*{{Z+|Z17549}}
*{{Z+|Z17556}}
*{{Z+|Z17578}}
*{{Z+|Z23415}}
*{{Z+|Z23419}}
==Month operations==
=== Gregorian months ===
*{{Z+|Z16137}}
*{{Z+|Z16136}}
*{{Z+|Z16299}}
*{{Z+|Z16255}}
*{{Z+|Z16230}}
*{{Z+|Z16330}}
*{{Z+|Z16518}}
*{{Z+|Z16580}}
*{{Z+|Z16272}}
*{{Z+|Z16289}}
*{{Z+|Z16584}}
*{{Z+|Z16648}}
*{{Z+|Z16542}}
*{{Z+|Z16316}}
*{{Z+|Z16332}}
*{{Z+|Z16348}}
*{{Z+|Z16307}}
*{{Z+|Z16293}}
*{{Z+|Z13596}}
*{{Z+|Z22240}}
*{{Z+|Z23403}}
=== Igbo months ===
*{{Z+|Z16000}}
*{{Z+|Z16945}}
*{{Z+|Z16955}}
*{{Z+|Z16972}}
*{{Z+|Z16973}}
*{{Z+|Z16990}}
*{{Z+|Z17685}}
== Era operations ==
=== Gregorian era ===
* {{Z+|Z17817}}
* {{Z+|Z17977}}
* {{Z+|Z18072}}
* {{Z+|Z18080}}
* {{Z+|Z18084}}
== Language specific ==
=== Basque ===
* {{Z+|Z18826}}
=== Arabic ===
* {{Z+|20013}}
[[Category:Lists of functions]]
abmjot4cysk63s4n3etcn6qz6nv05uf
191267
191265
2025-06-06T12:11:08Z
Denny
81
/* Information about a date */
191267
wikitext
text/x-wiki
== Date operations ==
=== Gregorian calendar dates ===
See [[Wikifunctions:Suggest a function#Gregorian calendar date|suggested functions]] for more function ideas.
==== Operations on a date ====
* {{Z+|Z20440}}
* {{Z+|Z20750}}
* {{Z+|Z20816}}
==== Information about a date ====
* {{Z+|Z20421}}
* {{Z+|Z24936}}
* {{Z+|Z24122}}
* {{Z+|Z20740}}
* {{Z+|Z20822}}
* {{Z+|Z20741}}
==== Information between two dates ====
* {{Z+|Z20430}}
* {{Z+|Z20756}}
* {{Z+|Z24918}}
* {{Z+|Z24901}}
* {{Z+|Z20744}}
* {{Z+|Z20856}}
===== Conversions =====
* {{Z+|Z22844}}
* {{Z+|Z23801}}
* {{Z+|Z23808}}
* {{Z+|Z23246}}
* {{Z+|Z24884}}
==== Dates to strings ====
* {{Z+|Z20780}}
* {{Z+|Z20788}}
* {{Z+|Z22214}}
* {{Z+|Z20770}}
* {{Z+|Z24880}}
* {{Z+|Z20776}}
* {{Z+|Z20773}}
* {{Z+|Z20782}}
* {{Z+|Z20794}}
* {{Z+|Z20785}}
* {{Z+|Z20791}}
* {{Z+|Z23197}}
* {{Z+|Z20801}}
==== Strings to dates ====
* {{Z+|Z20808}}
* {{Z+|Z23976}}
* {{Z+|Z24007}}
* {{Z+|Z23984}}
* {{Z+|Z23990}}
* {{Z+|Z23961}}
=== Day of Roman year ===
* {{Z+|Z20388}}
* {{Z+|Z20343}}
* {{Z+|Z20355}}
* {{Z+|Z20399}}
* {{Z+|Z20357}}
* {{Z+|Z20362}}
* {{Z+|Z20367}}
* {{Z+|Z20406}}
* {{Z+|Z20591}}
* {{Z+|Z22933}}
* {{Z+|Z23427}}
=== Using non-date types ===
* {{Z+|Z10996}}
* {{Z+|Z11015}}
* {{Z+|Z11011}}
* {{Z+|Z12176}}
* {{Z+|Z13163}}
* {{Z+|Z16914}}
* {{Z+|Z13306}}
* {{Z+|Z16908}}
* {{Z+|Z13300}}
* {{Z+|Z13335}}
* {{Z+|Z18957}}
* {{Z+|Z18961}}
=== Bengali date operations ===
* {{Z+|Z12926}}
* {{Z+|Z18131}}
* {{Z+|Z18435}}
* {{Z+|Z18462}}
* {{Z+|Z18169}}
* {{Z+|Z18573}}
* {{Z+|Z18582}}
* {{Z+|Z18387}}
* {{Z+|Z18397}}
* {{Z+|Z18662}}
== Year operations ==
===Gregorian year===
* {{Z+|Z20166}}
* {{Z+|Z20172}}
* {{Z+|Z20314}}
* {{Z+|Z20185}}
* {{Z+|Z20160}}
* {{Z+|Z20192}}
* {{Z+|Z20588}}
* {{Z+|Z20198}}
* {{Z+|Z20219}}
* {{Z+|Z20181}}
* {{Z+|Z20257}}
* {{Z+|Z20290}}
* {{Z+|Z20302}}
==Day of the week==
*{{Z+|Z17414}}
*{{Z+|Z20421}}
*{{Z+|Z17420}}
*{{Z+|Z17435}}
*{{Z+|Z17517}}
*{{Z+|Z17478}}
*{{Z+|Z17485}}
*{{Z+|Z17452}}
*{{Z+|Z17536}}
*{{Z+|Z17506}}
*{{Z+|Z17511}}
*{{Z+|Z20290}}
*{{Z+|Z20302}}
*{{Z+|Z17540}}
*{{Z+|Z17516}}
*{{Z+|Z17549}}
*{{Z+|Z17556}}
*{{Z+|Z17578}}
*{{Z+|Z23415}}
*{{Z+|Z23419}}
==Month operations==
=== Gregorian months ===
*{{Z+|Z16137}}
*{{Z+|Z16136}}
*{{Z+|Z16299}}
*{{Z+|Z16255}}
*{{Z+|Z16230}}
*{{Z+|Z16330}}
*{{Z+|Z16518}}
*{{Z+|Z16580}}
*{{Z+|Z16272}}
*{{Z+|Z16289}}
*{{Z+|Z16584}}
*{{Z+|Z16648}}
*{{Z+|Z16542}}
*{{Z+|Z16316}}
*{{Z+|Z16332}}
*{{Z+|Z16348}}
*{{Z+|Z16307}}
*{{Z+|Z16293}}
*{{Z+|Z13596}}
*{{Z+|Z22240}}
*{{Z+|Z23403}}
=== Igbo months ===
*{{Z+|Z16000}}
*{{Z+|Z16945}}
*{{Z+|Z16955}}
*{{Z+|Z16972}}
*{{Z+|Z16973}}
*{{Z+|Z16990}}
*{{Z+|Z17685}}
== Era operations ==
=== Gregorian era ===
* {{Z+|Z17817}}
* {{Z+|Z17977}}
* {{Z+|Z18072}}
* {{Z+|Z18080}}
* {{Z+|Z18084}}
== Language specific ==
=== Basque ===
* {{Z+|Z18826}}
=== Arabic ===
* {{Z+|20013}}
[[Category:Lists of functions]]
14vpx7xq2rnb5nv00nez3vzlhofjgsl
191281
191267
2025-06-06T12:35:08Z
Denny
81
/* Day of Roman year */
191281
wikitext
text/x-wiki
== Date operations ==
=== Gregorian calendar dates ===
See [[Wikifunctions:Suggest a function#Gregorian calendar date|suggested functions]] for more function ideas.
==== Operations on a date ====
* {{Z+|Z20440}}
* {{Z+|Z20750}}
* {{Z+|Z20816}}
==== Information about a date ====
* {{Z+|Z20421}}
* {{Z+|Z24936}}
* {{Z+|Z24122}}
* {{Z+|Z20740}}
* {{Z+|Z20822}}
* {{Z+|Z20741}}
==== Information between two dates ====
* {{Z+|Z20430}}
* {{Z+|Z20756}}
* {{Z+|Z24918}}
* {{Z+|Z24901}}
* {{Z+|Z20744}}
* {{Z+|Z20856}}
===== Conversions =====
* {{Z+|Z22844}}
* {{Z+|Z23801}}
* {{Z+|Z23808}}
* {{Z+|Z23246}}
* {{Z+|Z24884}}
==== Dates to strings ====
* {{Z+|Z20780}}
* {{Z+|Z20788}}
* {{Z+|Z22214}}
* {{Z+|Z20770}}
* {{Z+|Z24880}}
* {{Z+|Z20776}}
* {{Z+|Z20773}}
* {{Z+|Z20782}}
* {{Z+|Z20794}}
* {{Z+|Z20785}}
* {{Z+|Z20791}}
* {{Z+|Z23197}}
* {{Z+|Z20801}}
==== Strings to dates ====
* {{Z+|Z20808}}
* {{Z+|Z23976}}
* {{Z+|Z24007}}
* {{Z+|Z23984}}
* {{Z+|Z23990}}
* {{Z+|Z23961}}
=== Day of Roman year ===
* {{Z+|Z20388}}
* {{Z+|Z20343}}
* {{Z+|Z24936}}
* {{Z+|Z20355}}
* {{Z+|Z20399}}
* {{Z+|Z20357}}
* {{Z+|Z20362}}
* {{Z+|Z20367}}
* {{Z+|Z20406}}
* {{Z+|Z20591}}
* {{Z+|Z22933}}
* {{Z+|Z23427}}
=== Using non-date types ===
* {{Z+|Z10996}}
* {{Z+|Z11015}}
* {{Z+|Z11011}}
* {{Z+|Z12176}}
* {{Z+|Z13163}}
* {{Z+|Z16914}}
* {{Z+|Z13306}}
* {{Z+|Z16908}}
* {{Z+|Z13300}}
* {{Z+|Z13335}}
* {{Z+|Z18957}}
* {{Z+|Z18961}}
=== Bengali date operations ===
* {{Z+|Z12926}}
* {{Z+|Z18131}}
* {{Z+|Z18435}}
* {{Z+|Z18462}}
* {{Z+|Z18169}}
* {{Z+|Z18573}}
* {{Z+|Z18582}}
* {{Z+|Z18387}}
* {{Z+|Z18397}}
* {{Z+|Z18662}}
== Year operations ==
===Gregorian year===
* {{Z+|Z20166}}
* {{Z+|Z20172}}
* {{Z+|Z20314}}
* {{Z+|Z20185}}
* {{Z+|Z20160}}
* {{Z+|Z20192}}
* {{Z+|Z20588}}
* {{Z+|Z20198}}
* {{Z+|Z20219}}
* {{Z+|Z20181}}
* {{Z+|Z20257}}
* {{Z+|Z20290}}
* {{Z+|Z20302}}
==Day of the week==
*{{Z+|Z17414}}
*{{Z+|Z20421}}
*{{Z+|Z17420}}
*{{Z+|Z17435}}
*{{Z+|Z17517}}
*{{Z+|Z17478}}
*{{Z+|Z17485}}
*{{Z+|Z17452}}
*{{Z+|Z17536}}
*{{Z+|Z17506}}
*{{Z+|Z17511}}
*{{Z+|Z20290}}
*{{Z+|Z20302}}
*{{Z+|Z17540}}
*{{Z+|Z17516}}
*{{Z+|Z17549}}
*{{Z+|Z17556}}
*{{Z+|Z17578}}
*{{Z+|Z23415}}
*{{Z+|Z23419}}
==Month operations==
=== Gregorian months ===
*{{Z+|Z16137}}
*{{Z+|Z16136}}
*{{Z+|Z16299}}
*{{Z+|Z16255}}
*{{Z+|Z16230}}
*{{Z+|Z16330}}
*{{Z+|Z16518}}
*{{Z+|Z16580}}
*{{Z+|Z16272}}
*{{Z+|Z16289}}
*{{Z+|Z16584}}
*{{Z+|Z16648}}
*{{Z+|Z16542}}
*{{Z+|Z16316}}
*{{Z+|Z16332}}
*{{Z+|Z16348}}
*{{Z+|Z16307}}
*{{Z+|Z16293}}
*{{Z+|Z13596}}
*{{Z+|Z22240}}
*{{Z+|Z23403}}
=== Igbo months ===
*{{Z+|Z16000}}
*{{Z+|Z16945}}
*{{Z+|Z16955}}
*{{Z+|Z16972}}
*{{Z+|Z16973}}
*{{Z+|Z16990}}
*{{Z+|Z17685}}
== Era operations ==
=== Gregorian era ===
* {{Z+|Z17817}}
* {{Z+|Z17977}}
* {{Z+|Z18072}}
* {{Z+|Z18080}}
* {{Z+|Z18084}}
== Language specific ==
=== Basque ===
* {{Z+|Z18826}}
=== Arabic ===
* {{Z+|20013}}
[[Category:Lists of functions]]
siynso2x4duawwz5irmxn4g1wtbzxs3
Wikifunctions:FAQ/ar
4
43136
191347
146100
2025-06-07T04:43:57Z
FuzzyBot
207
Updating to match new version of source page
191347
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
هذه صفحة مخصصة للأسئلة الشائعة حول وظائف ويكي. من فضلك، لا تتردد في طرح سؤالك الخاص في [[Wikifunctions talk:FAQ|صفحة النقاش]]، إذا لم يكن سؤالك مدرجًا هنا!
يرجى أيضًا الاطلاع على [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|الأسئلة الشائعة على ميتا]] بخصوص المزيد من الأسئلة العامة حول ويكي دوال وويكيبيديا المجردة.
__TOC__
<span id="Introduction"></span>
== المقدمة ==
<span id="What_is_this_project_about?"></span>
=== ما هو هذا المشروع؟ ===
ويكي دوال هو مشروع ويكيميديا جديد يوفر قائمة بجميع أنواع الدوال التي يمكن لأي شخص الاتصال بها وكتابتها وصيانتها واستخدامها. كما أنها توفر التكنولوجيا الأساسية التي ستمكن في النهاية من ترجمة المقالات المستقلة لغويا من ويكيبيديا المجردة إلى ويكيبيديا بأي لغة. سيسمح هذا للجميع بالمساهمة وقراءة المقالات بلغاتهم المفضلة.
<span id="What_is_a_function?"></span>
== ما هي الدالة؟ ==
الدوال هي شكل من أشكال المعرفة التي يمكنها الإجابة على الأسئلة، مثل عدد الأيام التي مرت بين تاريخين أو المسافة بين مدينتين. يمكن للدوال الأكثر تعقيدًا أن تجيب على أسئلة أكثر تعقيدًا، مثل قيمة حجم شكل ثلاثي الأبعاد، أو المسافة بين المريخ والزهرة في تاريخ معين، أو ما إذا كان هناك نوعان على قيد الحياة في نفس الوقت.
نحن نستخدم بالفعل الدوال في العديد من أنواع الاستعلامات المعرفية، مثل طرح سؤال على محرك البحث. القوالب، مثل [[:w:en:Template:Convert|قالب:تحويل]] و [[:w:en:Template:Age|قالب:العمر]] في ويكيبيديا الإنجليزية، هي أيضًا أمثلة على الدوال المستخدمة بالفعل في العديد من الويكيبيديات، المكتوبة في نصوص الويكي و وحدات ''لوا'' ونسخها يدويًا إلى كل ويكي حيثما تم احتياجها.
<span id="What_is_an_implementation?"></span>
=== ما هو التنفيذ (التطبيق)؟ ===
التنفيذ هو طريقة معينة لتنفيذ دالة. التنفيذ عبارة عن وصفة تسرد الخطوات المطلوبة لتشغيل الدالة. قد يكون جزءًا من التعليمات البرمجية في لغة برمجة أو مجموعة من الاستدعاءات لوظائف أخرى. قد يكون للوظيفة العديد من التطبيقات، والتي يجب أن تكون جميعها متكافئة.
<span id="What_is_a_test?"></span>
=== ما هو الاختبار؟ ===
الاختبار هو وسيلة لتحديد ما إذا كانت دالة معينة تفعل الشيء الصحيح. عادةً ما تحتوي الدالة على عدة اختبارات، يحدد كل منها بعض المدخلات للدالة والشروط التي يجب أن يستوفيها مخرج الإدخال المحدد.
على سبيل المثال، قد يتضمن مختبرو دالة "حالة العنوان" ما يلي: "<span dir="ltr" lang="en">abc</span>" يجب أن يصبح "<span dir="ltr" lang="en">Abc</span>"؛ "<span dir="ltr" lang="en">war and peace</span>" يجب أن يصبح "<span dir="ltr" lang="en">War and Peace</span>"؛ "<span dir="ltr" lang="ru">война и мир</span>" يجب أن يصبح "<span dir="ltr" lang="ru">Война и мир</span>"؛ و"<span dir="ltr" lang="en">123</span>" يجب أن يظل "<span dir="ltr" lang="en">123</span>".
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== ما هي الميزات المتوفرة الآن، والتي ستكون متاحة قريبًا، وما هي الميزات البعيدة؟ ===
* عند الإطلاق:
** لدينا إمكانية الحصول على دوال تعمل مع السلاسل النصية والبوليانية.
** سيتم تدويل ويكي دوال بالكامل من البداية. ويمكن استخدامها بأي لغة.
* [[Wikifunctions:Status|تطوير مستمر]]:
** الأنواع العامة والدوال العامة غير مدعومة بشكل كامل.
** ستكون إضافة الأنواع، في الوقت الحالي، أمرًا يقتصر على فريق التطوير. وفي المستقبل، سيتمكن المجتمع من إضافة المزيد من الأنواع. هناك الكثير من العمل الذي يتعين القيام به في المستقبل لجعل الأنواع تتصرف بشكل أكثر سلاسة.
*** أحد الأنواع المثيرة للاهتمام بشكل خاص هو البيانات الثنائية، وخاصة الملفات.
** نحن ندعم حاليًا لغتي برمجة لعمليات التنفيذ: جافاسكريبت وبايثون. وفي المستقبل، نريد دعم المزيد.
** حاليًا، ''غير'' ممكن استدعاء دوال أخرى من التنفيذات المكتوبة بأي لغة برمجة. وهذا ممكن حاليًا فقط من خلال التكوين.
* في المستقبل:
** سيكون من الممكن استدعاء دوال ويكي دوال من مشاريع ويكيميديا أخرى ودمج النتائج المحصل عليها في إصدار الصفحة.
** سيكون من الممكن استخدام البيانات من ويكي بيانات في الدوال.
** سيكون من الممكن استدعاء مجموعات البيانات من نطاقات البيانات المعروفة.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== كيف تكون ويكي دوال متعددة اللغات؟ ===
ويكي دوال وويكيبديا المجردة متعددة اللغات بعدة طرق مختلفة والتي لا تؤثر بعضها ببعض:
* "'ويكي دوال متعدد اللغات من حيث المحتوى وواجهة المستخدم."' يمكن للمستخدمين قراءة و استدعاء وظائف على ويكي دوال بأي لغة طبيعية. هنا مثلا دالة "الإضافة إلى السلسلة" [https://www.wikifunctions.org/view/en/Z10000 بالإنجليزية], [https://www.wikifunctions.org/view/pl/Z10000 بالبولوندية]، و[https://www.wikifunctions.org/view/he/Z10000 بالعبرية], و هذه الدالة متاحة بالعديد من اللغات.
* "'المساهمين يمكنهم تحرير وتحسين ويكي دوال باستخدام لغتهم."' حتى التنفيذات يمكن تحريرها باللغة الطبيعية للمساهمين. على سبيل المثال تركيب دالة "و" يمكن تحريرها باللغات [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de الألمانية], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en الإنجليزية]، أو أي لغة أخرى يعني حوالي 300 لغة.
* "'دوال ويكي دوال يمكن استخدامها لخلق نتائج لأي لغة طبيعية."' المجتمع ينشأ عدد متزايد من الدوال لدعم توليد النصوص في العديد من اللغات الطبيعية. لدينا دوال [[Wikifunctions:Catalogue#Breton|بريتون]], [[Wikifunctions:Catalogue#Rohingya|الروهنجيا]], [[Wikifunctions:Catalogue#English|الإنجليزية]] و العديد من اللغات الأخرى.
* "الدوال في ويكيدوال يمكن تطبيقها بمختلف لغات البرمجة."' على سبيل المثال، [[Z10000|دالة الضم]] يتم تنفيذها بكل من [[Z10005|جافا سكريبت]] و [[Z10004|بايثون]].
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== ما هي لغات البرمجة التي تدعمها ويكيدوال حاليا؟ وما هي لغات البرمجة التي سيتم دعمها في المستقبل؟ ===
حاليًا، ويكي دوال تدعم تطبيقات مكتوبة بجافا سكريبت وبايثون. ونحن نخطط لإضافة دعم لغات برمجة أكثر في المستقبل. ونأمل بإضافة لغة برمجة واحدة أخرى في الأقل في 2025 (ولكن لم تقرر بعد أي واحد).
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== كيف يمكن لويكي دوال تتكامل مع المشاريع الأخرى؟ ===
ويكي_دوال هي الخطوة الأولى نحو بناء ويكيبيديا المجردة. سينصب تركيزنا في المدى القريب على دعم المجتمع وإجراء تحسينات بناءً على الملاحظات. بالتزامن مع ذلك، سنبدأ عملية دمجه مع ويكيبيديا وويكي بيانات، مما سيمكن من تطبيقات واقعية أوسع ويقربنا من رؤية ويكيبيديا المجردة.
سيتمكن المساهمون من استدعاء الدوال المخزنة على موقع ويكي_دوال من داخل مواقع الويكي الخاصة بهم. ستُعرض نتيجة استدعاء الدالة لقراء الويكي. يمكن استخدام ذلك، على سبيل المثال، لحساب عمر شخص ما، أو الكثافة السكانية بناءً على بيانات السكان والمساحة من ويكي بيانات، أو لرسم بياني ودمجه في مقالة معينة.
هناك خيار آخر لدمج ويكي_دوال، وهو تضمين واجهة تفاعلية لاستدعاء الدوال داخل الويكي. يمكن استخدام ذلك، على سبيل المثال، في مقالة ويكيبيديا لحساب نتيجة معادلة فيزيائية بشكل ديناميكي بناءً على متغيرات يقدمها القارئ، أو لرسم الدوال الرياضية والتفاعل معها، وغير ذلك.
<span id="What_Wikifunctions_is_not?"></span>
=== ما الذي لا تمثله ويكي_دوال؟ ===
من فضلك، راجع [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|ويكي_دوال:ويكي دوال ليست]] لمزيد من المعلومات حول ذلك.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== تحت أي ترخيص ستكون الدوال والمحتوى المشتق؟ ===
بناءً على النقاش الذي جرى [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|في ميتا خلال شهري نوفمبر وديسمبر 2021]]، ستكون جميع المساهمات في ويكي_دوال وفي مشاريع ويكيبيديا المجردة عمومًا متاحةً تحت تراخيص حرة. وتحديدًا:
* سيتم نشر [[Special:MyLanguage/Wikifunctions:Glossary#Content|المحتوى النصي]] على ويكي_دوال بموجب ترخيص [[w:Creative Commons license|المشاع الإبداعي المشاركة بالمثل النسخة 4.0]].
* سيتم نشر [[Special:MyLanguage/Wikifunctions:Glossary#Function|توقيعات الدوال]] وغيرها من المحتوى المُهيكل على ويكي دوال بموجب ترخيص [[w:CC0|CC0]].
* سيتم نشر [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|التنفيذات البرمجية]] في ويكي دوال بموجب [[w:Apache License|ترخيص أباتشي 2]].
* [[Special:MyLanguage/Wikifunctions:Glossary#Content|المحتوى المجرد]] لويكبيديا المجردة سيتم نشره تحت رخصة المشاع الإبداعي، المشاركة بالمثل النسخة 4.0
هناك بعض الأمور التي سيتم تناولها مستقبلًا، مثل مسألة ترخيص المحتوى المُوَلَّد من المحتوى المُجَرَّد. ننوي إعداد وثيقة أشمل مع القسم القانوني حول كيفية إعادة استخدام الرموز البرمجية من ويكي دوال بسهولة، مع مراعاة شروط الترخيص.
<span id="Contributing"></span>
== المساهمة ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== أنا جديد هنا. ما الذي يجب علي فعله وكيف يمكنني المساعدة؟ ===
أهلًا وسهلًا بك! يسعدنا جدًا انضمامك إلينا! هناك العديد من الفرص للمساهمة في ويكي دوال، من إنشاء دوال جديدة إلى تحسين وترجمة التوثيق. إذا كنت تبحث عن طرق للمشاركة، نقترح عليك حسب قدرتك اقتراح دالة جديدة حول موضوع يهمك، أو حتى إنشاء هذه الدالة، أو توفير بعض الاختبارات، أو تجربة كتابة تنفيذ، أو المساعدة في الترجمة، أو قراءة التوثيق وتحسينه، أو المساعدة في تنظيم المجتمع.
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== كيف يمكنني إنشاء دالة أو تنفيذ أو اختبار جديد؟ ===
لمعرفة كيفية إنشاء دالة جديدة أو تنفيذ أو اختبار، راجع [[Special:MyLanguage/Wikifunctions:Introduction|ويكي دوال:تقديم]].
لمعرفة المزيد من التفاصيل حول كيفية إنشاء تنفيذات، راجع [[Special:MyLanguage/Wikifunctions:How to create implementations|ويكي دوال: كيفية إنشاء تنفيذات]].
<span id="What_should_I_edit_first?"></span>
=== ما الذي يجب أن أقوم بتحريره أولاً؟ ===
<div class="mw-translate-fuzzy">
إذا كنت تستطيع الكتابة بعدة لغات، ابحث عن الدوال التي لا تملك تسمياتٍ وأوصافًا بلغتك بعد، وساعد في إضافتها.
</div>
إذا كان لديك اهتمام بمجال يمكن أن يضم دوال في ويكي دوال، ولكنه لا يضمها بعد، أو إذا كانت لديك المزيد من الأفكار للدوال، فانتقل إلى صفحة [[Wikifunctions:Suggest a new function|اقتراح دوال جديدة]]، واعرض أفكارك.
إذا كنتَ مُبرمجًا بلغة جافا سكريبت أو بايثون، فربما ترغب في التحقق من الدوال التي لا تملك تنفيذات بلغة جافا سكريبت أو بايثون حتى الآن، ومُحاولة كتابتها.
<span id="Where_can_I_go_for_help?"></span>
=== أين يمكنني الذهاب للحصول على المساعدة؟ ===
يجب أن تكون محطتك الأولى هي [[ Special:MyLanguage/Help:Contents | بوابة المساعدة ]] حيث ستجد جميع الوثائق المتعلقة باستخدام وتحرير ويكي دوال. إذا كنت لا تزال تواجه مشكلة، فانشر رسالة على [[ Wikifunctions:Project chat | دردشة المشروع ]]، وسيقوم شخص ما بالإجابة على سؤالك.
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== كيف نقوم بفرز أو تصنيف الدوال؟ ===
{{Tracked|T285424}}
في الوقت الحالي، أفضل طريقة لفرز أو تصنيف الدوال هي القيام بذلك يدويًا من خلال الصفحات في نطاق ويكي دوال. خيار آخر سيكون من خلال صفحة نقاش الدالة المعنية. سنراقب هذه الجهود، وسنناقش مع المجتمع التغييرات التي ستكون مفيدة لهذه المهمة في النظام.
[[Category:FAQ| {{#translation:}}]]
26moypvfhbt96r3yg2pag92dstfm35r
Wikifunctions:FAQ/pa
4
53018
191362
175455
2025-06-07T04:44:04Z
FuzzyBot
207
Updating to match new version of source page
191362
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
<div lang="en" dir="ltr" class="mw-content-ltr">
This is a dedicated page for the Frequently Asked Questions about Wikifunctions. Please, feel free to ask your own question on the [[Wikifunctions talk:FAQ|talk page]], if your question is not listed here!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Also, please consider our [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|FAQ on Meta]] regarding more general questions about Wikifunctions and Abstract Wikipedia.
</div>
__TOC__
<span id="Introduction"></span>
== ਜਾਣ-ਪਛਾਣ ==
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is this project about? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
== ਵਿਕੀਕਾਰਜ਼ ਕੀ ਏ? ==
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What is an implementation? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<span id="What_is_a_test?"></span>
== ਪ੍ਰੀਖਿਆ ਕੀ ਏ? ==
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which features are available now, which will be soon available, and which are further away? ===
</div>
* ਸ਼ੁਰੂ ਹੋਣ ਸਮੇਂ:
** <span lang="en" dir="ltr" class="mw-content-ltr">We have the ability to have functions that work with Strings and Booleans.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Wikifunctions will be fully internationalized from the beginning. It can be used in any language.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Wikifunctions:Status|Ongoing development]]:</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Generic types and generic functions are not fully supported.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* ਭਵਿੱਖ ਵਿੱਚ:
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call Wikifunctions functions from other Wikimedia projects and integrate their results into the output of the page.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to use data from Wikidata in functions.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">It will be possible to call data sets from Commons Data namespace.</span>
<span id="How_is_Wikifunctions_multilingual?"></span>
=== ਵਿਕੀਕਾਰਜ਼ ਬਹੁਭਾਸ਼ਾਈ ਕਿਵੇਂ ਏ? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions and Abstract Wikipedia are multilingual in a number of ways that do not impact each other:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions is multilingual in terms of its content and user interface.''' Users can read and call functions on Wikifunctions in any natural language. Here is the “join string” function in [https://www.wikifunctions.org/view/en/Z10000 English], [https://www.wikifunctions.org/view/pl/Z10000 Polish], and [https://www.wikifunctions.org/view/he/Z10000 Hebrew], and it is available in many more languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Which programming languages does Wikifunctions currently support? Which programming languages will be supported in the future? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== ਵਿਕੀਕਾਰਜ਼ ਨੂੰ ਹੋਰ ਪ੍ਰੋਜੈਕਟਾਂ ਵਿੱਚ ਕਿਵੇਂ ਜੋੜਿਆ ਜਾਵੇਗਾ? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== ਵਿਕੀਕਾਰਜ਼ ਕੀ ਨਹੀਂ ਏ? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Please, see [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|Wikifunctions:What Wikifunctions is not]] for more information on that.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== What license will the functions and derived content be under? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Textual content]] on Wikifunctions will be published under [[w:Creative Commons license|CC BY-SA 4.0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Function|Function signatures]] and other structured content on Wikifunctions will be published under [[w:CC0|CC 0]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Implementation|Code implementations]] in Wikifunctions will be published under the [[w:Apache License|Apache 2 license]].</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">[[Special:MyLanguage/Wikifunctions:Glossary#Content|Abstract Content]] for Abstract Wikipedia will be published under CC BY-SA 4.0.</span>
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== ਯੋਗਦਾਨ ਪਾਉਣਾ ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== ਮੈਂ ਇੱਥੇ ਨਵਾਂ/ਨਵੀਂ ਹਾਂ। ਮੇਰੇ ਲਈ ਇੱਥੇ ਕਰਨ ਲਈ ਕੀ ਹੈ ਅਤੇ ਮੈਂ ਕਿਵੇਂ ਮਦਦ ਕਰ ਸਕਦਾ/ਸਕਦੀ ਹਾਂ? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== How do I create a new function, implementation, or test? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see how to create a new function, implementation, or test, see [[Special:MyLanguage/Wikifunctions:Introduction|Wikifunctions:Introduction]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
To see in more detail how to create an implementation, see [[Special:MyLanguage/Wikifunctions:How to create implementations|Wikifunctions:How to create implementations]].
</div>
<span id="What_should_I_edit_first?"></span>
=== ਮੈਨੂੰ ਪਹਿਲਾਂ ਕੀ ਸੋਧਣਾ ਚਾਹੀਦਾ ਏ?
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== ਮਦਦ ਲਈ ਮੈਂ ਕਿੱਥੇ ਜਾ ਸਕਦਾ/ਸਕਦੀ ਹਾਂ? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== ਅਸੀਂ ਕਾਰਜ਼ਾਂ ਨੂੰ ਕਿਵੇਂ ਛਾਂਟਦੇ ਜਾਂ ਸ਼੍ਰੇਣੀਬੱਧ ਕਰਦੇ ਹਾਂ? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
qj1b2f2svno9fux88umycgmucn511te
Z23976
0
54431
191407
190547
2025-06-07T10:30:11Z
Dv103
11127
Added Z24946 to the approved list of implementations
191407
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z23976"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z6",
"Z17K2": "Z23976K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "data"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20420",
"Z8K3": [
"Z20",
"Z23977",
"Z23978",
"Z23979",
"Z24016",
"Z24015"
],
"Z8K4": [
"Z14",
"Z23980",
"Z24946"
],
"Z8K5": "Z23976"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "leggi Data Gregoriana, multilingue"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "read Gregorian date, multiple languages"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"parse Gregorian date, multiple languages"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
b2q3pg1zqb7dckgr6afumcrnc8rqjvd
Z23990
0
54445
191400
190902
2025-06-07T10:17:13Z
Dv103
11127
Added Z24945 to the approved list of implementations
191400
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z23990"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z6",
"Z17K2": "Z23990K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "data"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20420",
"Z8K3": [
"Z20",
"Z23991",
"Z23993",
"Z23994",
"Z23995",
"Z24037",
"Z24038",
"Z24836",
"Z24890",
"Z24891",
"Z24892"
],
"Z8K4": [
"Z14",
"Z23992",
"Z24945"
],
"Z8K5": "Z23990"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "leggi Data gregoriana, en, dag (mga)"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "read Gregorian Date, en, dag (mdy)"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"parse Gregorian Date, en, dag (mdy)"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Leniently reads a Gregorian Date, preferring the mdy format. It also supports the Dagbani Gregorian calendar format"
}
]
}
}
byu9ioiyvid5s39pl62sx4mrq08gm74
Z24030
0
54539
191408
180015
2025-06-07T10:31:04Z
Dv103
11127
191408
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24030"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tvar monthNames={\n\t};\n\tvar eraNames={\n\t\tad:+1,\n\t\tbc:-1,\n\t\tbce:-1,\n\t\tce:+1,\n\t};\n\tvar separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tvar prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\t\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\t\n\tfunction extractNumber(s){\n\t\tlet res=/-?\\+?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn Number(res[0]);\n\t\t}\n\t\treturn null;\n\t}\n\t\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\t\n\tfunction extractMonthLiteral(s){\n\t\tfor (let m in monthNames){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn monthNames[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractEpoch(s){\n\t\tfor (let m in eraNames){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn eraNames[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\t\n\tZ23976K1=Z23976K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\t\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23976K1)){\n\t\tZ23976K1=Z23976K1.split(\"T\")[0];\n\t\tvar list=Z23976K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\t\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23976K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23976K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23976K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\t\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato=elements[i].split(\"-\");\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\t\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\t\n\t// Wikifunctions.Debug(\"elements:\");\n\t// Wikifunctions.Debug(elements);\n\t\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\tfor(let i=0; i\u003Celements.length; ++i){\n\t\tlet p=[];\n\t\tlet n=extractNumber(elements[i]);\n\t\tlet m=extractMonthLiteral(elements[i]);\n\t\tlet e=extractEpoch(elements[i]);\n\t\t\n\t\t//day\n\t\tp.push((n!=null \u0026\u0026 n\u003E0 \u0026\u0026 n\u003C=31) ? n : null);\n\t\t//month\n\t\tp.push((n!=null \u0026\u0026 n\u003E0 \u0026\u0026 n\u003C=12) ? n-1 : (m!=null ? m : null));\n\t\t//year\n\t\tp.push(n!=null ? n : null);\n\t\t//epoch\n\t\tp.push(e);\n\t\t\n\t\tif (forceToYear(elements[i])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\t\tpossibilities.push(p);\n\t}\n\t\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\t\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1 ? -Math.abs(y)+1 : Math.abs(y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\t\t\t\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\t\t\t\n\t\t\treturn{\n\t\t\t\tK3: (d),\n\t\t\t\tK2: (m),\n\t\t\t\tK1: BigInt(year)\n\t\t\t};\n\t\t}\n\t}\n}"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "(!) leggi data gregoriana, constr, mul, js"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "(!) read Gregorian Date, year constr, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Aggiunge contraint sugli anni"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Adds constraint on years"
}
]
}
}
6iscjccx4tvntia911sqm2zvubmkjxt
Wikifunctions:Type proposals/Wikidata time
4
56521
191340
190913
2025-06-06T20:46:25Z
DMartin (WMF)
24
/* Open questions */
191340
wikitext
text/x-wiki
== Summary ==
This type is modeled after Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype, and will support the import of all values of that type from Wikidata into Wikifunctions. The content here also builds on [[Wikifunctions:Time_in_Wikidata|Time in Wikidata]], which provides additional background information for this proposal. We also acknowledge and draw upon an earlier type proposal, [[Wikifunctions:Type_proposals/Wikidata_value#Point_in_time|Point in time]], with similar objectives.
In addition to ''Wikidata time'' , we also propose here 4 other simple types used for keys inside ''Wikidata time'': ''Wikidata time precision, Datetime, Time of day,'' and ''Calendar model.''
== Uses ==
* ''Why should this exist?''
Wikidata contains many statements with values of the [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype. A wide variety of Wikifunctions will be able to make use of these values, and this type will enable Wikifunctions to import these values from Wikidata.
* ''What kinds of functions would be created using this?''
Many kinds, including in particular functions that are called from Wikipedias and other MediaWiki projects to provide [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] values (or content computed from them), and Abstract Wikipedia functions that generate statements, paragraphs, and articles containing these values.
* ''What standard concepts, if any, does this align with?''
Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype.
== Structure ==
'''''Wikidata time''''' has these 6 keys, shown with proposed English labels:
* <code>K1/datetime</code>, of a new type ''Datetime'' to be defined as shown below. This represents the point in time which serves as the base value for ''Wikidata time''.
* <code>K2/precision</code>, of an enum type ''Wikidata time precision,'' to be defined as shown below.
* <code>K3/after</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) after the given time could it be?
* <code>K4/before</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) before the given time could it be?
* <code>K5/timezone</code>, of type [[Z16683|Integer]], for the ''timezone'' offset from UTC in minutes (by which to display the value).
* <code>K6/calendar model</code>, of an enum type ''Calendar model (''see below), telling which calendar to use for displaying the value.
'''''Datetime''''' has these 2 keys:
* <code>K1/date</code>, of type [[Z20420|Gregorian calendar date]].
* <code>K2/time</code>, of type ''Time of day'' described below.
'''''Time of day''''' has these 3 keys:
* <code>K1/hour</code>, of type [[Z13518|Natural number]].
* <code>K2/minute</code>, of type [[Z13518|Natural number]].
* <code>K3/second</code>, of type [[Z13518|Natural number]].
'''''Wikidata time precision''','' an enum type, has these 15 allowed elements (as specified for the [[mediawikiwiki:Wikibase/DataModel#Dates_and_times|time]] datatype), one of which appears as the value of <code>K1</code> in an instance of the type. Each of these concepts has a Wikidata item; we hope to implement this as a Wikidata item reference-based "lightweight enum type" (If that capability is available in time):
* billion years
* hundred million years
* ten million years
* million years
* hundred thousand years
* ten thousand years
* millennium
* century
* decade
* year
* month
* day
* hour
* minute
* second
'''Calendar model,''' a lightweight enum type of Wikidata item reference, will include (at least) these possible values:
* { Z1K1: 'Z6091', Z6091K1: 'Q1985727' } / Gregorian calendar
* { Z1K1: 'Z6091', Z6091K1: 'Q11184' } / Julian calendar
=== Example values ===
''TBD''
{|class="wikitable" style="margin:.6em 1.6em"
|-
| <syntaxhighlight lang="json" line="line">{
"type": "…",
"value": "…"
}</syntaxhighlight>
| <syntaxhighlight lang="json">{
"Z1K1": "Zxyz",
"ZxyzK1": "…"
}</syntaxhighlight>
|}
== Validator ==
The validator for '''Wikidata time''' checks that:
* The value of each key is a valid instance of the key's defined type.
* The value of <code>K5/offset</code> is between -719 and +720, inclusive.
The validator for '''Datetime''' checks that:
* The value of each key is a valid instance of the key's defined type.
The '''Time of day''' validator checks that:
* The value of <code>K1/hour</code> is a valid ''Natural number'' between 0 and 23, inclusive.
* The value of <code>K2/minute</code> is a valid ''Natural number'' between 0 and 59, inclusive.
* The value of <code>K3/second</code> is a valid ''Natural number'' between 0 and 60, inclusive. (60 is allowed to accommodate leap-seconds.)
The validators for '''Wikidata time precision''' and '''Calendar model''' check that:
* The value of their <code>K1</code> key is one of the allowed elements for the type.
== Identity ==
For each of the above types''':'''
* Two instances are the same if they have equal values for each of their keys. Equality of those values, in turn, is specified by the definitions & documentation of their respective types.
== Converting to code ==
=== Python ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
=== JavaScript ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
== Display function ==
''How would a value of this type be displayed on Wikifunctions''
…TBD
== Read function ==
''When entering a value for this type as a string, what format should that string have?''
…TBD
== Open questions ==
* In Wikidata practice for ''Wikidata time'', is the time part of <code>K1/datetime</code> always in UTC, or is it in the offset time?
* In Wikidata practice for ''Wikidata time'', is the date part of <code>K1/datetime</code> always in the ''Gregorian calendar date'', even if the displayed calendar model is Julian?
** According to both of these documentation pages, this is '''not''' the case:
*** [https://www.wikidata.org/wiki/Special:ListDatatypes Special:ListDatatypes]
*** [https://doc.wikimedia.org/Wikibase/master/php/docs_topics_json.html Wikibase JSON]
** So we have an '''unresolved issue''': do we convert a Julian calendar timestamp to Gregorian and save it that way, or do we allow for Wikidata datetime to contain an instance of ''Julian calendar date'' (which would have to be created first)?
* Revisit: is the use of lightweight enum type of Wikidata item reference our best option for ''Calendar model''?
** For one thing, how many different calendar models are currently used, and how many should we anticipate might be used in future?
** Also, when we have ZObject-based lightweight enum types, are we going to want to switch to those?
*** Probably not, because Wikidata may have more calendar models, at any given time, than what is present on Wikifunctions.
== Alternatives ==
''In order to capture the idea presented in the summary, what alternative structures, display functions, read functions, etc. could have made sense too?''
* In ''Datetime,'' [[Wikifunctions:Type_proposals/Moment_in_time|Moment in time]] could have been used as the type of <code>K2</code>.
* For <code>K6</code>, instead of creating an enum type for ''Calendar model,'' its allowed values could have been references to [[Z20420|Gregorian calendar date]] or ''Julian calendar date'' (which doesn't exist yet).
== Comments ==
''For general comments, please reply to the proposer, or use the ''Discussion'' section below.''
* {{s}} as proposer. --[[User:DMartin (WMF)|DMartin (WMF)]] ([[User talk:DMartin (WMF)|talk]]) 06:10, 23 May 2025 (UTC)
* {{s}} strong support obviously (functions can be connected to Wikidata so we should support Wikidata types) with two comments: Wikidata support hour, minute, second in theory but not in practice ; and I'm wondering about the display/read functionality. Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 16:07, 1 June 2025 (UTC)
*
…
== Discussion ==
m0krip0ca8gwnrv8xd83g591mqdrid8
191394
191340
2025-06-07T07:57:05Z
Dv103
11127
/* Open questions */
191394
wikitext
text/x-wiki
== Summary ==
This type is modeled after Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype, and will support the import of all values of that type from Wikidata into Wikifunctions. The content here also builds on [[Wikifunctions:Time_in_Wikidata|Time in Wikidata]], which provides additional background information for this proposal. We also acknowledge and draw upon an earlier type proposal, [[Wikifunctions:Type_proposals/Wikidata_value#Point_in_time|Point in time]], with similar objectives.
In addition to ''Wikidata time'' , we also propose here 4 other simple types used for keys inside ''Wikidata time'': ''Wikidata time precision, Datetime, Time of day,'' and ''Calendar model.''
== Uses ==
* ''Why should this exist?''
Wikidata contains many statements with values of the [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype. A wide variety of Wikifunctions will be able to make use of these values, and this type will enable Wikifunctions to import these values from Wikidata.
* ''What kinds of functions would be created using this?''
Many kinds, including in particular functions that are called from Wikipedias and other MediaWiki projects to provide [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] values (or content computed from them), and Abstract Wikipedia functions that generate statements, paragraphs, and articles containing these values.
* ''What standard concepts, if any, does this align with?''
Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype.
== Structure ==
'''''Wikidata time''''' has these 6 keys, shown with proposed English labels:
* <code>K1/datetime</code>, of a new type ''Datetime'' to be defined as shown below. This represents the point in time which serves as the base value for ''Wikidata time''.
* <code>K2/precision</code>, of an enum type ''Wikidata time precision,'' to be defined as shown below.
* <code>K3/after</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) after the given time could it be?
* <code>K4/before</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) before the given time could it be?
* <code>K5/timezone</code>, of type [[Z16683|Integer]], for the ''timezone'' offset from UTC in minutes (by which to display the value).
* <code>K6/calendar model</code>, of an enum type ''Calendar model (''see below), telling which calendar to use for displaying the value.
'''''Datetime''''' has these 2 keys:
* <code>K1/date</code>, of type [[Z20420|Gregorian calendar date]].
* <code>K2/time</code>, of type ''Time of day'' described below.
'''''Time of day''''' has these 3 keys:
* <code>K1/hour</code>, of type [[Z13518|Natural number]].
* <code>K2/minute</code>, of type [[Z13518|Natural number]].
* <code>K3/second</code>, of type [[Z13518|Natural number]].
'''''Wikidata time precision''','' an enum type, has these 15 allowed elements (as specified for the [[mediawikiwiki:Wikibase/DataModel#Dates_and_times|time]] datatype), one of which appears as the value of <code>K1</code> in an instance of the type. Each of these concepts has a Wikidata item; we hope to implement this as a Wikidata item reference-based "lightweight enum type" (If that capability is available in time):
* billion years
* hundred million years
* ten million years
* million years
* hundred thousand years
* ten thousand years
* millennium
* century
* decade
* year
* month
* day
* hour
* minute
* second
'''Calendar model,''' a lightweight enum type of Wikidata item reference, will include (at least) these possible values:
* { Z1K1: 'Z6091', Z6091K1: 'Q1985727' } / Gregorian calendar
* { Z1K1: 'Z6091', Z6091K1: 'Q11184' } / Julian calendar
=== Example values ===
''TBD''
{|class="wikitable" style="margin:.6em 1.6em"
|-
| <syntaxhighlight lang="json" line="line">{
"type": "…",
"value": "…"
}</syntaxhighlight>
| <syntaxhighlight lang="json">{
"Z1K1": "Zxyz",
"ZxyzK1": "…"
}</syntaxhighlight>
|}
== Validator ==
The validator for '''Wikidata time''' checks that:
* The value of each key is a valid instance of the key's defined type.
* The value of <code>K5/offset</code> is between -719 and +720, inclusive.
The validator for '''Datetime''' checks that:
* The value of each key is a valid instance of the key's defined type.
The '''Time of day''' validator checks that:
* The value of <code>K1/hour</code> is a valid ''Natural number'' between 0 and 23, inclusive.
* The value of <code>K2/minute</code> is a valid ''Natural number'' between 0 and 59, inclusive.
* The value of <code>K3/second</code> is a valid ''Natural number'' between 0 and 60, inclusive. (60 is allowed to accommodate leap-seconds.)
The validators for '''Wikidata time precision''' and '''Calendar model''' check that:
* The value of their <code>K1</code> key is one of the allowed elements for the type.
== Identity ==
For each of the above types''':'''
* Two instances are the same if they have equal values for each of their keys. Equality of those values, in turn, is specified by the definitions & documentation of their respective types.
== Converting to code ==
=== Python ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
=== JavaScript ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
== Display function ==
''How would a value of this type be displayed on Wikifunctions''
…TBD
== Read function ==
''When entering a value for this type as a string, what format should that string have?''
…TBD
== Open questions ==
* In Wikidata practice for ''Wikidata time'', is the time part of <code>K1/datetime</code> always in UTC, or is it in the offset time?
* In Wikidata practice for ''Wikidata time'', is the date part of <code>K1/datetime</code> always in the ''Gregorian calendar date'', even if the displayed calendar model is Julian?
** According to both of these documentation pages, this is '''not''' the case:
*** [https://www.wikidata.org/wiki/Special:ListDatatypes Special:ListDatatypes]
*** [https://doc.wikimedia.org/Wikibase/master/php/docs_topics_json.html Wikibase JSON]
** So we have an '''unresolved issue''': do we convert a Julian calendar timestamp to Gregorian and save it that way, or do we allow for Wikidata datetime to contain an instance of ''Julian calendar date'' (which would have to be created first)?
*** If we decide for the latter, we still need to figure out if it is the ''Datetime'' type whose first element can be both of ''Gregorian calendar date'' or ''Julian calendar date'', or if we should separate the ''Datetime with Gregorian calendar'' and the ''Datetime with Julian calendar''. Personally I would prefer this second option, since the Datetime type would be very useful in Wikifunctions even outside of Wikidata dealing functions, so it would be better to make the standard ''Datetime'' type as easy to use as possible. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 07:56, 7 June 2025 (UTC)
* Revisit: is the use of lightweight enum type of Wikidata item reference our best option for ''Calendar model''?
** For one thing, how many different calendar models are currently used, and how many should we anticipate might be used in future?
** Also, when we have ZObject-based lightweight enum types, are we going to want to switch to those?
*** Probably not, because Wikidata may have more calendar models, at any given time, than what is present on Wikifunctions.
== Alternatives ==
''In order to capture the idea presented in the summary, what alternative structures, display functions, read functions, etc. could have made sense too?''
* In ''Datetime,'' [[Wikifunctions:Type_proposals/Moment_in_time|Moment in time]] could have been used as the type of <code>K2</code>.
* For <code>K6</code>, instead of creating an enum type for ''Calendar model,'' its allowed values could have been references to [[Z20420|Gregorian calendar date]] or ''Julian calendar date'' (which doesn't exist yet).
== Comments ==
''For general comments, please reply to the proposer, or use the ''Discussion'' section below.''
* {{s}} as proposer. --[[User:DMartin (WMF)|DMartin (WMF)]] ([[User talk:DMartin (WMF)|talk]]) 06:10, 23 May 2025 (UTC)
* {{s}} strong support obviously (functions can be connected to Wikidata so we should support Wikidata types) with two comments: Wikidata support hour, minute, second in theory but not in practice ; and I'm wondering about the display/read functionality. Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 16:07, 1 June 2025 (UTC)
*
…
== Discussion ==
0k56gimtcr3gau0ld6671adt6ftyds4
191395
191394
2025-06-07T08:12:15Z
Dv103
11127
/* Display function */ First draft for display functions
191395
wikitext
text/x-wiki
== Summary ==
This type is modeled after Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype, and will support the import of all values of that type from Wikidata into Wikifunctions. The content here also builds on [[Wikifunctions:Time_in_Wikidata|Time in Wikidata]], which provides additional background information for this proposal. We also acknowledge and draw upon an earlier type proposal, [[Wikifunctions:Type_proposals/Wikidata_value#Point_in_time|Point in time]], with similar objectives.
In addition to ''Wikidata time'' , we also propose here 4 other simple types used for keys inside ''Wikidata time'': ''Wikidata time precision, Datetime, Time of day,'' and ''Calendar model.''
== Uses ==
* ''Why should this exist?''
Wikidata contains many statements with values of the [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype. A wide variety of Wikifunctions will be able to make use of these values, and this type will enable Wikifunctions to import these values from Wikidata.
* ''What kinds of functions would be created using this?''
Many kinds, including in particular functions that are called from Wikipedias and other MediaWiki projects to provide [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] values (or content computed from them), and Abstract Wikipedia functions that generate statements, paragraphs, and articles containing these values.
* ''What standard concepts, if any, does this align with?''
Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype.
== Structure ==
'''''Wikidata time''''' has these 6 keys, shown with proposed English labels:
* <code>K1/datetime</code>, of a new type ''Datetime'' to be defined as shown below. This represents the point in time which serves as the base value for ''Wikidata time''.
* <code>K2/precision</code>, of an enum type ''Wikidata time precision,'' to be defined as shown below.
* <code>K3/after</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) after the given time could it be?
* <code>K4/before</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) before the given time could it be?
* <code>K5/timezone</code>, of type [[Z16683|Integer]], for the ''timezone'' offset from UTC in minutes (by which to display the value).
* <code>K6/calendar model</code>, of an enum type ''Calendar model (''see below), telling which calendar to use for displaying the value.
'''''Datetime''''' has these 2 keys:
* <code>K1/date</code>, of type [[Z20420|Gregorian calendar date]].
* <code>K2/time</code>, of type ''Time of day'' described below.
'''''Time of day''''' has these 3 keys:
* <code>K1/hour</code>, of type [[Z13518|Natural number]].
* <code>K2/minute</code>, of type [[Z13518|Natural number]].
* <code>K3/second</code>, of type [[Z13518|Natural number]].
'''''Wikidata time precision''','' an enum type, has these 15 allowed elements (as specified for the [[mediawikiwiki:Wikibase/DataModel#Dates_and_times|time]] datatype), one of which appears as the value of <code>K1</code> in an instance of the type. Each of these concepts has a Wikidata item; we hope to implement this as a Wikidata item reference-based "lightweight enum type" (If that capability is available in time):
* billion years
* hundred million years
* ten million years
* million years
* hundred thousand years
* ten thousand years
* millennium
* century
* decade
* year
* month
* day
* hour
* minute
* second
'''Calendar model,''' a lightweight enum type of Wikidata item reference, will include (at least) these possible values:
* { Z1K1: 'Z6091', Z6091K1: 'Q1985727' } / Gregorian calendar
* { Z1K1: 'Z6091', Z6091K1: 'Q11184' } / Julian calendar
=== Example values ===
''TBD''
{|class="wikitable" style="margin:.6em 1.6em"
|-
| <syntaxhighlight lang="json" line="line">{
"type": "…",
"value": "…"
}</syntaxhighlight>
| <syntaxhighlight lang="json">{
"Z1K1": "Zxyz",
"ZxyzK1": "…"
}</syntaxhighlight>
|}
== Validator ==
The validator for '''Wikidata time''' checks that:
* The value of each key is a valid instance of the key's defined type.
* The value of <code>K5/offset</code> is between -719 and +720, inclusive.
The validator for '''Datetime''' checks that:
* The value of each key is a valid instance of the key's defined type.
The '''Time of day''' validator checks that:
* The value of <code>K1/hour</code> is a valid ''Natural number'' between 0 and 23, inclusive.
* The value of <code>K2/minute</code> is a valid ''Natural number'' between 0 and 59, inclusive.
* The value of <code>K3/second</code> is a valid ''Natural number'' between 0 and 60, inclusive. (60 is allowed to accommodate leap-seconds.)
The validators for '''Wikidata time precision''' and '''Calendar model''' check that:
* The value of their <code>K1</code> key is one of the allowed elements for the type.
== Identity ==
For each of the above types''':'''
* Two instances are the same if they have equal values for each of their keys. Equality of those values, in turn, is specified by the definitions & documentation of their respective types.
== Converting to code ==
=== Python ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
=== JavaScript ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
== Display function ==
'''''Wikidata time''''' ...TBD
'''''Datetime''''' should display as a string that joins the output of the {{Z|Z20420}} display function and the ''Time of day'' display function with a suitable, language-dependent separator. For example, in English a possible output could be "7 June 2025, 10:05:42". The default, language-independent display function should instead use ISO 8601 format (e.g.: "2025-06-07T10:05:42").
'''''Time of day''''' should display as the time as the language-default time representation (e.g.: "22:10:56" or "10:10:56 p.m."). The language-independent display function should use the 24h hh:mm:ss format, as per ISO 8601.
== Read function ==
''When entering a value for this type as a string, what format should that string have?''
…TBD
== Open questions ==
* In Wikidata practice for ''Wikidata time'', is the time part of <code>K1/datetime</code> always in UTC, or is it in the offset time?
* In Wikidata practice for ''Wikidata time'', is the date part of <code>K1/datetime</code> always in the ''Gregorian calendar date'', even if the displayed calendar model is Julian?
** According to both of these documentation pages, this is '''not''' the case:
*** [https://www.wikidata.org/wiki/Special:ListDatatypes Special:ListDatatypes]
*** [https://doc.wikimedia.org/Wikibase/master/php/docs_topics_json.html Wikibase JSON]
** So we have an '''unresolved issue''': do we convert a Julian calendar timestamp to Gregorian and save it that way, or do we allow for Wikidata datetime to contain an instance of ''Julian calendar date'' (which would have to be created first)?
*** If we decide for the latter, we still need to figure out if it is the ''Datetime'' type whose first element can be both of ''Gregorian calendar date'' or ''Julian calendar date'', or if we should separate the ''Datetime with Gregorian calendar'' and the ''Datetime with Julian calendar''. Personally I would prefer this second option, since the Datetime type would be very useful in Wikifunctions even outside of Wikidata dealing functions, so it would be better to make the standard ''Datetime'' type as easy to use as possible. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 07:56, 7 June 2025 (UTC)
* Revisit: is the use of lightweight enum type of Wikidata item reference our best option for ''Calendar model''?
** For one thing, how many different calendar models are currently used, and how many should we anticipate might be used in future?
** Also, when we have ZObject-based lightweight enum types, are we going to want to switch to those?
*** Probably not, because Wikidata may have more calendar models, at any given time, than what is present on Wikifunctions.
== Alternatives ==
''In order to capture the idea presented in the summary, what alternative structures, display functions, read functions, etc. could have made sense too?''
* In ''Datetime,'' [[Wikifunctions:Type_proposals/Moment_in_time|Moment in time]] could have been used as the type of <code>K2</code>.
* For <code>K6</code>, instead of creating an enum type for ''Calendar model,'' its allowed values could have been references to [[Z20420|Gregorian calendar date]] or ''Julian calendar date'' (which doesn't exist yet).
== Comments ==
''For general comments, please reply to the proposer, or use the ''Discussion'' section below.''
* {{s}} as proposer. --[[User:DMartin (WMF)|DMartin (WMF)]] ([[User talk:DMartin (WMF)|talk]]) 06:10, 23 May 2025 (UTC)
* {{s}} strong support obviously (functions can be connected to Wikidata so we should support Wikidata types) with two comments: Wikidata support hour, minute, second in theory but not in practice ; and I'm wondering about the display/read functionality. Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 16:07, 1 June 2025 (UTC)
*
…
== Discussion ==
ozie8vru9aucjcm0l3192note139mo6
191396
191395
2025-06-07T08:25:04Z
Dv103
11127
/* Read function */ First draft for reading functions
191396
wikitext
text/x-wiki
== Summary ==
This type is modeled after Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype, and will support the import of all values of that type from Wikidata into Wikifunctions. The content here also builds on [[Wikifunctions:Time_in_Wikidata|Time in Wikidata]], which provides additional background information for this proposal. We also acknowledge and draw upon an earlier type proposal, [[Wikifunctions:Type_proposals/Wikidata_value#Point_in_time|Point in time]], with similar objectives.
In addition to ''Wikidata time'' , we also propose here 4 other simple types used for keys inside ''Wikidata time'': ''Wikidata time precision, Datetime, Time of day,'' and ''Calendar model.''
== Uses ==
* ''Why should this exist?''
Wikidata contains many statements with values of the [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype. A wide variety of Wikifunctions will be able to make use of these values, and this type will enable Wikifunctions to import these values from Wikidata.
* ''What kinds of functions would be created using this?''
Many kinds, including in particular functions that are called from Wikipedias and other MediaWiki projects to provide [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] values (or content computed from them), and Abstract Wikipedia functions that generate statements, paragraphs, and articles containing these values.
* ''What standard concepts, if any, does this align with?''
Wikidata's [https://www.mediawiki.org/wiki/Wikibase/DataModel#Dates_and_times time] datatype.
== Structure ==
'''''Wikidata time''''' has these 6 keys, shown with proposed English labels:
* <code>K1/datetime</code>, of a new type ''Datetime'' to be defined as shown below. This represents the point in time which serves as the base value for ''Wikidata time''.
* <code>K2/precision</code>, of an enum type ''Wikidata time precision,'' to be defined as shown below.
* <code>K3/after</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) after the given time could it be?
* <code>K4/before</code>, of type [[Z13518|Natural number]]. If the date is uncertain, how many units (given by the precision) before the given time could it be?
* <code>K5/timezone</code>, of type [[Z16683|Integer]], for the ''timezone'' offset from UTC in minutes (by which to display the value).
* <code>K6/calendar model</code>, of an enum type ''Calendar model (''see below), telling which calendar to use for displaying the value.
'''''Datetime''''' has these 2 keys:
* <code>K1/date</code>, of type [[Z20420|Gregorian calendar date]].
* <code>K2/time</code>, of type ''Time of day'' described below.
'''''Time of day''''' has these 3 keys:
* <code>K1/hour</code>, of type [[Z13518|Natural number]].
* <code>K2/minute</code>, of type [[Z13518|Natural number]].
* <code>K3/second</code>, of type [[Z13518|Natural number]].
'''''Wikidata time precision''','' an enum type, has these 15 allowed elements (as specified for the [[mediawikiwiki:Wikibase/DataModel#Dates_and_times|time]] datatype), one of which appears as the value of <code>K1</code> in an instance of the type. Each of these concepts has a Wikidata item; we hope to implement this as a Wikidata item reference-based "lightweight enum type" (If that capability is available in time):
* billion years
* hundred million years
* ten million years
* million years
* hundred thousand years
* ten thousand years
* millennium
* century
* decade
* year
* month
* day
* hour
* minute
* second
'''Calendar model,''' a lightweight enum type of Wikidata item reference, will include (at least) these possible values:
* { Z1K1: 'Z6091', Z6091K1: 'Q1985727' } / Gregorian calendar
* { Z1K1: 'Z6091', Z6091K1: 'Q11184' } / Julian calendar
=== Example values ===
''TBD''
{|class="wikitable" style="margin:.6em 1.6em"
|-
| <syntaxhighlight lang="json" line="line">{
"type": "…",
"value": "…"
}</syntaxhighlight>
| <syntaxhighlight lang="json">{
"Z1K1": "Zxyz",
"ZxyzK1": "…"
}</syntaxhighlight>
|}
== Validator ==
The validator for '''Wikidata time''' checks that:
* The value of each key is a valid instance of the key's defined type.
* The value of <code>K5/offset</code> is between -719 and +720, inclusive.
The validator for '''Datetime''' checks that:
* The value of each key is a valid instance of the key's defined type.
The '''Time of day''' validator checks that:
* The value of <code>K1/hour</code> is a valid ''Natural number'' between 0 and 23, inclusive.
* The value of <code>K2/minute</code> is a valid ''Natural number'' between 0 and 59, inclusive.
* The value of <code>K3/second</code> is a valid ''Natural number'' between 0 and 60, inclusive. (60 is allowed to accommodate leap-seconds.)
The validators for '''Wikidata time precision''' and '''Calendar model''' check that:
* The value of their <code>K1</code> key is one of the allowed elements for the type.
== Identity ==
For each of the above types''':'''
* Two instances are the same if they have equal values for each of their keys. Equality of those values, in turn, is specified by the definitions & documentation of their respective types.
== Converting to code ==
=== Python ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
=== JavaScript ===
We expect to get started by relying on the existing default conversion strategy; something more sophisticated could come later if needed.
== Display function ==
'''''Wikidata time''''' ...TBD
'''''Datetime''''' should display as a string that joins the output of the {{Z|Z20420}} display function and the ''Time of day'' display function with a suitable, language-dependent separator. For example, in English a possible output could be "7 June 2025, 10:05:42". The default, language-independent display function should instead use ISO 8601 format (e.g.: "2025-06-07T10:05:42").
'''''Time of day''''' should display as the time as the language-default time representation (e.g.: "22:10:56" or "10:10:56 p.m."). The language-independent display function should use the 24h hh:mm:ss format, as per ISO 8601.
== Read function ==
'''''Wikidata time''''' …TBD
'''''Datetime''''' should be read from any string that contains a {{Z|Z20420}} and a ''Time of day'' input separated by a reasonable separator (in both orders). Every language should support the ISO 8601 formats.
'''''Time of day''''' reader should be mostly language-independent, supporting both 24h and 12h formats (and supporting other representations of the arab digits). If the input doesn't contain the seconds' value, it should be assumed to have value 00. The hour "24" should be interpreted as equivalent to "00". Language-specific readers should be implemented for languages that have other commonly used formats to represent the time of day. Every language should support the ISO 8601 formats.
== Open questions ==
* In Wikidata practice for ''Wikidata time'', is the time part of <code>K1/datetime</code> always in UTC, or is it in the offset time?
* In Wikidata practice for ''Wikidata time'', is the date part of <code>K1/datetime</code> always in the ''Gregorian calendar date'', even if the displayed calendar model is Julian?
** According to both of these documentation pages, this is '''not''' the case:
*** [https://www.wikidata.org/wiki/Special:ListDatatypes Special:ListDatatypes]
*** [https://doc.wikimedia.org/Wikibase/master/php/docs_topics_json.html Wikibase JSON]
** So we have an '''unresolved issue''': do we convert a Julian calendar timestamp to Gregorian and save it that way, or do we allow for Wikidata datetime to contain an instance of ''Julian calendar date'' (which would have to be created first)?
*** If we decide for the latter, we still need to figure out if it is the ''Datetime'' type whose first element can be both of ''Gregorian calendar date'' or ''Julian calendar date'', or if we should separate the ''Datetime with Gregorian calendar'' and the ''Datetime with Julian calendar''. Personally I would prefer this second option, since the Datetime type would be very useful in Wikifunctions even outside of Wikidata dealing functions, so it would be better to make the standard ''Datetime'' type as easy to use as possible. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 07:56, 7 June 2025 (UTC)
* Revisit: is the use of lightweight enum type of Wikidata item reference our best option for ''Calendar model''?
** For one thing, how many different calendar models are currently used, and how many should we anticipate might be used in future?
** Also, when we have ZObject-based lightweight enum types, are we going to want to switch to those?
*** Probably not, because Wikidata may have more calendar models, at any given time, than what is present on Wikifunctions.
== Alternatives ==
''In order to capture the idea presented in the summary, what alternative structures, display functions, read functions, etc. could have made sense too?''
* In ''Datetime,'' [[Wikifunctions:Type_proposals/Moment_in_time|Moment in time]] could have been used as the type of <code>K2</code>.
* For <code>K6</code>, instead of creating an enum type for ''Calendar model,'' its allowed values could have been references to [[Z20420|Gregorian calendar date]] or ''Julian calendar date'' (which doesn't exist yet).
== Comments ==
''For general comments, please reply to the proposer, or use the ''Discussion'' section below.''
* {{s}} as proposer. --[[User:DMartin (WMF)|DMartin (WMF)]] ([[User talk:DMartin (WMF)|talk]]) 06:10, 23 May 2025 (UTC)
* {{s}} strong support obviously (functions can be connected to Wikidata so we should support Wikidata types) with two comments: Wikidata support hour, minute, second in theory but not in practice ; and I'm wondering about the display/read functionality. Cheers, [[User:VIGNERON|VIGNERON]] ([[User talk:VIGNERON|talk]]) 16:07, 1 June 2025 (UTC)
*
…
== Discussion ==
lcm0406b1hd3fbuvsumw8gcbf9c0uf6
Wikifunctions:Project chat/Archive/2025/05
4
56771
191341
190908
2025-06-07T03:08:09Z
SpBot
978
archiving 1 section from [[Wikifunctions:Project chat]] (after section [[Wikifunctions:Project chat/Archive/2025/05#Problems_with_evaluations:_fixes_are_coming|Problems_with_evaluations:_fixes_are_coming]])
191341
wikitext
text/x-wiki
{{Talkarchive}}
== Update language tag of "Simple English" (Z1124) ==
Please update the language tag of [[Z1124]] to "<code>en-simple</code>" as the variant subtag "<code>simple</code>" is already registered in the Language Subtag Registry: https://www.iana.org/assignments/language-subtag-registry/language-subtag-registry . -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 07:03, 13 May 2025 (UTC)
: @[[User:Winston Sung|Winston Sung]]: This can't be done until MediaWiki drops use of the tag, sorry. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 18:42, 14 May 2025 (UTC)
: @[[User:Jdforrester (WMF)|Jdforrester (WMF)]]:
: MediaWiki [https://codesearch.wmcloud.org/search/?q=en-x-simple no longer use <code>en-x-simple</code>] but [https://codesearch.wmcloud.org/search/?q=en-simple already use <code>en-simple</code> instead]. -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 01:16, 15 May 2025 (UTC)
:: @[[User:Winston Sung|Winston Sung]]: Ah, interesting, whoever did those changes didn't file a task with us. Will file one. [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 11:36, 15 May 2025 (UTC)
: Just note it here: the Phabricator task filed by @[[User:Jdforrester (WMF)|Jdforrester (WMF)]] is [[phab:T394401]]. -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 11:44, 15 May 2025 (UTC)
: :<small>This section was archived on a request by: -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 11:55, 16 May 2025 (UTC)</small>
== Edit request - broken implementation ==
Please see [[:Talk:Z19164#Edit request: implementation broken]]. I found a bug and wish to make a change, but I do not have permissions to do so. Thanks. --[[User:WrenFalcon|WrenFalcon]] ([[User talk:WrenFalcon|talk]]) 06:23, 15 May 2025 (UTC)
:Thanks. It looks like this is now resolved. --[[User:99of9|99of9]] ([[User talk:99of9|talk]]) 04:32, 16 May 2025 (UTC)
::<small>This section was archived on a request by: [[User:99of9|99of9]] ([[User talk:99of9|talk]]) 04:32, 16 May 2025 (UTC)</small>
== Wikifunctions & Abstract Wikipedia Newsletter #200 is out: Abstract Wikipedia is a MacArthur 100&Change finalist ==
There is [[:f:Special:MyLanguage/Wikifunctions:Status updates/2025-04-30|a new update]] for Abstract Wikipedia and Wikifunctions. Please, come and read it!
In this issue, we announce that we reached the final stage of a grant competition, we introduce our next big conversation about where the content of Abstract Wikipedia will be located, and we take a look at the latest software developments.
Want to catch up with the previous updates? Check [[:f:Special:MyLanguage/Wikifunctions:Status updates|our archive]]!
Also, we remind you that if you have questions or ideas to discuss, the next '''Volunteers' Corner''' will be held on '''[https://zonestamp.toolforge.org/1746466200 May 5, at 17:30 UTC]''' ([https://meet.google.com/xuy-njxh-rkw link to the meeting]).
Enjoy the reading! -- [[User:Sannita (WMF)|User:Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 10:57, 1 May 2025 (UTC)
<!-- Message sent by User:Sannita (WMF)@metawiki using the list at https://meta.wikimedia.org/w/index.php?title=Global_message_delivery/Targets/Wikifunctions_%26_Abstract_Wikipedia&oldid=28628447 -->
:<small>This section was archived on a request by: [[User:Sannita (WMF)|Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 13:57, 23 May 2025 (UTC)</small>
== Change to translatewiki.net-like/Miraheze-Meta-like page translation target languages ==
Currently, the page translation target language configuration on Wikifunctions were [[gerrit:plugins/gitiles/operations/mediawiki-config/+/a4d0b2f22e0270ddd12d5a07ae78efde47a3566e/wmf-config/InitialiseSettings.php#7422|inherited from the "language converter page translation model"]].
However, this actually created several problems including the broken main page with malfunctioned language converter tags ( [https://www.wikifunctions.org/wiki/Wikifunctions:Main_Page?uselang=zh-hans zh-Hans] , [https://www.wikifunctions.org/wiki/Wikifunctions:Main_Page?uselang=zh-hant zh-Hant] , [https://www.wikifunctions.org/wiki/Wikifunctions:Main_Page?uselang=zh-hk zh-Hant-HK] ). More breakages could be found on [[phab:T328838]].
As Wikifunctions haven't build up the large "tech debt", I would like to propose to use the [[gerrit:plugins/gitiles/translatewiki/+/e61ec8f4d0d342d793cbb415ca50536901ed2393/mw-config/TranslateSettings.php#172|"translatewiki page translation model"]]/[https://github.com/miraheze/mw-config/blob/2f622587bbb5b78933ef3e940d3141edb4928df5/LocalSettings.php#L5911 "Miraheze Meta page translation model"] instead [[gerrit:1143697|on Wikifunctions]].
This would also make the page translation target languages align with the ZObjects translation target languages.
-- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 06:58, 13 May 2025 (UTC)
: @[[User:Winston Sung|Winston Sung]]: This sounds reasonable as an approach, thank you for flagging. Are there any community members here doing wikitext translation into multi-script languages who might have a view? [[User:Jdforrester (WMF)|Jdforrester (WMF)]] ([[User talk:Jdforrester (WMF)|talk]]) 18:46, 14 May 2025 (UTC)
: Pinging @[[User:0xDeadbeef|0xDeadbeef]], @[[User:LowensteinYang|LowensteinYang]], @[[User:MilkyDefer|MilkyDefer]], @[[User:S8321414|S8321414]], @[[User:Stevenliuyi|Stevenliuyi]], @[[User:Supaplex|Supaplex]], @[[User:星海子|星海子]], @[[User:魔琴|魔琴]]. -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 02:58, 15 May 2025 (UTC)
: Cannot understand the technical configs and details. Just to say fixing it would be nice. [[User:魔琴|魔琴]] ([[User talk:魔琴|talk]]) 03:08, 15 May 2025 (UTC)
: Please explain in detail about these translation models and their differences. I only see some configurations in your links and cannot grasp their differences. [[User:MilkyDefer|<span style="color:#09C">Milky</span>]][[User talk:MilkyDefer|'''<span style="color:#F09">Defer</span>''']] 03:39, 15 May 2025 (UTC)
: @[[User:MilkyDefer|MilkyDefer]]:
: Below are examples of the proposed translation model.
:* https://translatewiki.net/wiki/Special:Translate?group=page-Project%3AAbout&action=page&language=zh-hans&filter=
:* https://translatewiki.net/wiki/Special:Translate?group=page-Project%3AAbout&action=page&language=zh-hant&filter=
:* https://meta.miraheze.org/wiki/Special:Translate?group=page-Miraheze+Meta&action=page&language=zh-hans&filter=
:* https://meta.miraheze.org/wiki/Special:Translate?group=page-Miraheze+Meta&action=page&language=zh-hant&filter=
: Note: "translatewiki page translation model"/"Miraheze Meta page translation model" refer to the same translation model.
: -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 03:44, 15 May 2025 (UTC)
::Correct me if I am misunderstanding sth. The old configuration only has a blanket zh. The new configuration has zh-hans (for cn, my, sg), zh-hant (for tw) and zh-hk (for mo, hk). Is that right? [[User:MilkyDefer|<span style="color:#09C">Milky</span>]][[User talk:MilkyDefer|'''<span style="color:#F09">Defer</span>''']] 11:49, 16 May 2025 (UTC)
::That's correct for the zh/zh-* part. -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 11:54, 16 May 2025 (UTC)
:If this issue can be fixed by changing translation model, I will {{Support}}--[[User:S8321414|S8321414]] ([[User talk:S8321414|talk]]) 03:53, 15 May 2025 (UTC)
: {{Done}} in [https://schedule-deployment.toolforge.org/window/1748502000 Thursday, May 29, 2025 UTC morning backport window].
: :<small>This section was archived on a request by: -- [[User:Winston Sung|Winston Sung]] ([[User talk:Winston Sung|talk]]) 08:16, 29 May 2025 (UTC)</small>
== Error in "is Jalali leap year" ==
Hi!
The correct implementation for this function should consider 4 as a leap year not 5. Otherwise the algorithm is correct. So it should be:
<syntaxhighlight lang="python">
def Z11011(Z11011K1):
year = int(Z11011K1)
if(year <= 5):
mod = year % 4;
return (mod == 0);
is_leap_year = (year % 33) in [1, 5, 9, 13, 17, 22, 26, 30]
return is_leap_year
</syntaxhighlight>I didn't have permission to edit. How can I edit functions? Do I also need permission for function creation? [[User:Niyumard|Niyumard]] ([[User talk:Niyumard|talk]]) 12:02, 3 May 2025 (UTC)
:I've just disconnected the Python implementation, so that you van edit it. An advice: create a testcase that the current implementation fails, so it's evident that there is a bug that should be corrected. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 12:05, 3 May 2025 (UTC)
::I fixed the python code and added the test case that fails the JavaScript code. Can I disconnect the javascript code myself, or connect my own test cases or not, is there any guide for newbies? [[User:Niyumard|Niyumard]] ([[User talk:Niyumard|talk]]) 12:20, 3 May 2025 (UTC)
:::I've disconnected the js implementation.
:::Only Functioneers can connect and disconnect implementations and testcases, but everyone can create functions, testcases and implementations. This is described in the page [[Wikifunctions:Functioneers]]. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 12:26, 3 May 2025 (UTC)
::::I find it odd given the open nature of other wikis.
::::Done! And thanks a lot for your prompt reaction. Is this the correct place for asking Functioneers to connect and disconnect, or should I take my requests to some other place next time? [[User:Niyumard|Niyumard]] ([[User talk:Niyumard|talk]]) 12:32, 3 May 2025 (UTC)
:::::It's mainly for security concerns (it's not wise to freely execute code uploaded by anyone). For now there is not a place specifically for requesting connections or disconnections (at least not that I am aware of), the closest page is [[Wikifunctions:Community portal]]. [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 12:41, 3 May 2025 (UTC)
::::::Makes sense. Thanks! [[User:Niyumard|Niyumard]] ([[User talk:Niyumard|talk]]) 12:49, 3 May 2025 (UTC)
== Problems with evaluations: fixes are coming ==
Hi all, a quick update on the situation about evaluations not properly working in all cases, raised in the Telegram group. We identified the problem, and have been working in the last couple of weeks to solve it.
More specifically, you can find more info at [[phab:T393130]] (some fixes already merged that should come up today, others will come in the next weeks), at [[phab:T392905]] (fix already merged, should be up today), and at [[phab:T393152]] (fix already merged, should be already up). We're also following [[phab:T391435]] and [[phab:T392905]].
If you have more malfunctions to report, please let me know here. Also, you can freely comment the Phab tickets to discuss directly with the engineers. Thanks for your attention! [[User:Sannita (WMF)|Sannita (WMF)]] ([[User talk:Sannita (WMF)|talk]]) 14:18, 7 May 2025 (UTC)
fu44vqw4i2vp6eorzy0dlcgs467qyou
Wikifunctions:Status updates/2025-05-29
4
57559
191299
190646
2025-06-06T19:18:39Z
Jdforrester (WMF)
4
Link to new edition.
191299
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate><!--T:1--> Previous update</translate>
| prev = 2025-05-23
| nextlabel = <translate><!--T:2--> Next update</translate>
| next = 2025-06-06
}}
<translate>
=== Rolling out embedded function calls to five Wiktionaries === <!--T:3-->
<!--T:26-->
We have rolled out embedded function calls to a first set of Wiktionary projects: [[<tvar name="1">:ha:wikt:</tvar>|Hausa]], [[<tvar name="2">:ig:wikt:</tvar>|Igbo]], [[<tvar name="3">:ml:wikt:</tvar>|Malayalam]], [[<tvar name="4">:bn:wikt:</tvar>|Bengali]], and [[<tvar name="5">:dv:wikt:</tvar>|Divehi Wiktionary]]. These represent [[<tvar name="6">:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2021-04-15</tvar>|the focus languages]] that have a Wiktionary (that is, all but Dagbani), and in addition one right-to-left language, Divehi. This also represents a rough doubling of pageviews to wikis with embedded function calls, following our plan for a careful roll-out to the projects.
<!--T:4-->
As before, we ask folks to show restraint and only contribute to these projects if you are or want to become a member of the given community. '''Do not use any of those wikis as test beds.''' You can use the [[<tvar name="1">Wikifunctions:Embedded function calls/sandbox</tvar>|Wikifunctions call sandbox]] for that. You can find [[<tvar name="2">Special:MyLanguage/Wikifunctions:Embedded function calls</tvar>|documentation about embedding function calls]] on Wikifunctions.
<!--T:5-->
We have switched our roll-out to focus on Wiktionaries for now, instead of Wikipedias. This change was in order to follow the [[<tvar name="1">:mw:Special:MyLanguage/Parsoid/Deployments</tvar>|Parsoid roll-out]], on which embedded function calls depend. We will come back to the Wikipedias probably later this year.
<!--T:6-->
In the next few months we are planning to deploy to many more Wiktionaries. This will allow the Wiktionary communities to work on functions that are useful across the different Wiktionary projects. This might include the already existing [[<tvar name="1">:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2023-09-08</tvar>|morphological functions]] (''e.g.'' the [[<tvar name="2">Z11089</tvar>|regular plural]] of <tvar name="3">''house''</tvar> is <tvar name="4">''{{#function:Z11089|house}}''</tvar>), or functions such as this one listing the [[<tvar name="5">Z24676</tvar>|three main tense forms of an English verb]], ''e.g.'' <tvar name="6">''{{#function:Z24687|L3366}}''</tvar>. We are currently limited to simple string outputs in what can be embedded in pages, but for later this year we plan to allow some formatting, with the goal to create whole conjugation tables, which could be reused across many different language editions of Wiktionary projects. Until then, we are curious what kind of functions you will be building now!
=== Calculating with today’s date === <!--T:7-->
<!--T:27-->
Hello on this lovely <tvar name="1">{{#function:Z20421|}}</tvar>. It is <tvar name="2">{{#function:Z20744||6 August 2025}}</tvar> days until [[<tvar name="3">:wikimania:Special:MyLanguage/2025:Wikimania</tvar>|Wikimania 2025]]!
<!--T:8-->
If you’re reading this text on the wiki page on which it was published, the day of the week and the number of days in the previous sentence will update automatically as we get closer to Wikimania (if you’re reading this in an e-mail, this won’t work – there is no integration of Wikifunctions function calls in e-mails yet, or planned).
<!--T:9-->
A new feature when embedding function calls in wikipages allows you to leave the value for a [[<tvar name="1">Z20420</tvar>|Gregorian calendar date]] empty. If you do so, the value will be automatically set to the current day when the page is accessed (according to the wiki’s timezone). This allows for all kinds of dynamic outputs: you can return the [[<tvar name="2">Z20756</tvar>|age]] of a person or institution, the current [[<tvar name="3">Z20421</tvar>|day of the week]], today’s [[<tvar name="4">Z20741</tvar>|distance to the Moon]], and much more.
<!--T:10-->
You use this feature by simply leaving the value empty. Feel free to try it out on the [[<tvar name="1">Wikifunctions:Embedded function calls/sandbox</tvar>|embedded calls Sandbox]]. You can find [[<tvar name="2">Special:MyLanguage/Wikifunctions:Embedded function calls</tvar>|further documentation on how to use embedded function calls]] in wikis that have that enabled.
<!--T:11-->
We are planning to work on two other types to get default values: a [[<tvar name="1">Z6091</tvar>|Wikidata item reference]] to set the item connected to a given page (if any), and the [[<tvar name="2">Z60</tvar>|language]] of a given page. Both can then be used in function calls to adapt the function call to a given page. These are expected to be developed and deployed later this year.
<!--T:12-->
Please let us know if you find any issues with the new feature.
=== Presentation at Wikidata and Sister Projects event === <!--T:13-->
<!--T:28-->
29 May–1 June 2025 will be the [[<tvar name="1">:d:Special:MyLanguage/Event:Wikidata and Sister Projects</tvar>|Wikidata and Sister Projects]] event. [[<tvar name="2">User:DMartin (WMF)</tvar>|David Martin]] and [[<tvar name="3">User:Sannita (WMF)</tvar>|Luca Martinelli]] are going to present about how Wikidata powers language functions on Wikifunctions and more, on [<tvar name="4">https://zonestamp.toolforge.org/1748539800</tvar> 29 May at 17:30 UTC] (that is, today).
<!--T:14-->
You can learn more about the event on the [[<tvar name="1">:d:Special:MyLanguage/Event:Wikidata and Sister Projects</tvar>|Wikidata and Sister Projects event page]].
=== Recent Changes in the software === <!--T:15-->
<!--T:29-->
Last week, as discussed above, we finished one of our planned Quarterly pieces of work, and also a number of pieces of others.
<!--T:16-->
For the 'light-weight enums' work (<tvar name="1">[[:phab:T390558|T390558]]</tvar>), we have added an interface (<tvar name="2">[[:phab:T391918|T391918]]</tvar>) and special rights for creating and editing them (<tvar name="3">[[:phab:T391913|T391913]]</tvar> and <tvar name="4">[[:phab:T391914|T391914]]</tvar>); for now, like with Types, we're holding them back only for staff, but we will expand their access later. To make the creation and editing tools possible, we also re-designed our tests for what kinds of edits and creations are allowed to be more flexible. There's still more to do here before we call this complete, but we should be able to demonstrate it on-wiki shortly.
<!--T:17-->
Within our performance strand of work this Quarter, we're working to add better caching to the orchestrator. We have added the functionality to the MediaWiki side of the code to trigger this new behaviour (<tvar name="1">[[:phab:T391971|T391971]]</tvar>). Soon, we will wire it together, and measure and report on the impact.
<!--T:18-->
Following-up on a wide-ranging set of issues that [[<tvar name="1">User:99of9</tvar>|User:99of9]] found when running Test cases, we added some regression tests related to different valid 'shapes' of Language objects (<tvar name="2">[[:phab:T391329|T391329]]</tvar>).
<!--T:19-->
As part of Wikimedia-wide support, we have added a new Language, [[<tvar name="1">Z1970</tvar>|Z1970/qxp]] (<tvar name="2">[[:phab:T394068|T394068]]</tvar>).
=== Ongoing consultation about Location of Abstract Content === <!--T:20-->
<!--T:30-->
Thanks to everyone who participated in the consultation about the [[<tvar name="1">:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content</tvar>|Location for Abstract Content]] so far! The consultation will continue for another two weeks. We try to keep answering questions by and participating in the consultation with the community.
<!--T:21-->
Personally, I found the arguments thought-provoking, and I find myself changing my own position as I read about new ideas and considerations I haven’t had before. I am planning to add a current state of my thinking next week. So keep the ideas and arguments going!
=== News in Types === <!--T:22-->
<!--T:31-->
The [[<tvar name="1">Z86</tvar>|Unicode code point]] type has been set up with a [[<tvar name="2">Z23041</tvar>|read]] and [[<tvar name="3">Z24823</tvar>|display]] function, thus improving the UX on Wikifunctions and also allowing Functions using this Type to be used in embedded calls. Thanks to [[<tvar name="4">User:99of9</tvar>|User:99of9]] for shepherding this improvement and for working on the read and display functions.
<!--T:23-->
For our current work to support import of more Wikidata content (<tvar name="1">[[:phab:T390559|T390559]]</tvar>), discussions on three new types proposals are ongoing: [[<tvar name="2">Wikifunctions:Type proposals/Wikidata time</tvar>|Wikidata time]], [[<tvar name="3">Wikifunctions:Type proposals/Wikidata quantity</tvar>|Wikidata quantity]], and [[<tvar name="4">Wikifunctions:Type proposals/Wikidata geocoordinates</tvar>|Wikidata geocoordinates]]. Comments are welcome!
=== Fresh Functions weekly: 17 new Functions === <!--T:24-->
<!--T:32-->
This week we had 17 new functions. Here are some of the functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</translate>
* {{Z|Z24736}}
* {{Z|Z24749}}
* {{Z|Z24757}}
* {{Z|Z24809}}
* {{Z|Z24823}}
<translate>
<!--T:25-->
A [<tvar name="1">https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest</tvar> complete list of all functions sorted by when they were created] is available.
</translate>
[[Category:Status updates{{#translation:}}|2025-05-29]]
nsffhhlfemrsgymtoa15i16lsruqc28
Wikifunctions:Status updates/2025-05-29/en
4
57587
191300
190649
2025-06-06T19:18:50Z
FuzzyBot
207
Updating to match new version of source page
191300
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Previous update
| prev = 2025-05-23
| nextlabel = Next update
| next = 2025-06-06
}}
=== Rolling out embedded function calls to five Wiktionaries ===
We have rolled out embedded function calls to a first set of Wiktionary projects: [[:ha:wikt:|Hausa]], [[:ig:wikt:|Igbo]], [[:ml:wikt:|Malayalam]], [[:bn:wikt:|Bengali]], and [[:dv:wikt:|Divehi Wiktionary]]. These represent [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2021-04-15|the focus languages]] that have a Wiktionary (that is, all but Dagbani), and in addition one right-to-left language, Divehi. This also represents a rough doubling of pageviews to wikis with embedded function calls, following our plan for a careful roll-out to the projects.
As before, we ask folks to show restraint and only contribute to these projects if you are or want to become a member of the given community. '''Do not use any of those wikis as test beds.''' You can use the [[Wikifunctions:Embedded function calls/sandbox|Wikifunctions call sandbox]] for that. You can find [[Special:MyLanguage/Wikifunctions:Embedded function calls|documentation about embedding function calls]] on Wikifunctions.
We have switched our roll-out to focus on Wiktionaries for now, instead of Wikipedias. This change was in order to follow the [[:mw:Special:MyLanguage/Parsoid/Deployments|Parsoid roll-out]], on which embedded function calls depend. We will come back to the Wikipedias probably later this year.
In the next few months we are planning to deploy to many more Wiktionaries. This will allow the Wiktionary communities to work on functions that are useful across the different Wiktionary projects. This might include the already existing [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2023-09-08|morphological functions]] (''e.g.'' the [[Z11089|regular plural]] of ''house'' is ''{{#function:Z11089|house}}''), or functions such as this one listing the [[Z24676|three main tense forms of an English verb]], ''e.g.'' ''{{#function:Z24687|L3366}}''. We are currently limited to simple string outputs in what can be embedded in pages, but for later this year we plan to allow some formatting, with the goal to create whole conjugation tables, which could be reused across many different language editions of Wiktionary projects. Until then, we are curious what kind of functions you will be building now!
=== Calculating with today’s date ===
Hello on this lovely {{#function:Z20421|}}. It is {{#function:Z20744||6 August 2025}} days until [[:wikimania:Special:MyLanguage/2025:Wikimania|Wikimania 2025]]!
If you’re reading this text on the wiki page on which it was published, the day of the week and the number of days in the previous sentence will update automatically as we get closer to Wikimania (if you’re reading this in an e-mail, this won’t work – there is no integration of Wikifunctions function calls in e-mails yet, or planned).
A new feature when embedding function calls in wikipages allows you to leave the value for a [[Z20420|Gregorian calendar date]] empty. If you do so, the value will be automatically set to the current day when the page is accessed (according to the wiki’s timezone). This allows for all kinds of dynamic outputs: you can return the [[Z20756|age]] of a person or institution, the current [[Z20421|day of the week]], today’s [[Z20741|distance to the Moon]], and much more.
You use this feature by simply leaving the value empty. Feel free to try it out on the [[Wikifunctions:Embedded function calls/sandbox|embedded calls Sandbox]]. You can find [[Special:MyLanguage/Wikifunctions:Embedded function calls|further documentation on how to use embedded function calls]] in wikis that have that enabled.
We are planning to work on two other types to get default values: a [[Z6091|Wikidata item reference]] to set the item connected to a given page (if any), and the [[Z60|language]] of a given page. Both can then be used in function calls to adapt the function call to a given page. These are expected to be developed and deployed later this year.
Please let us know if you find any issues with the new feature.
=== Presentation at Wikidata and Sister Projects event ===
29 May–1 June 2025 will be the [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata and Sister Projects]] event. [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] are going to present about how Wikidata powers language functions on Wikifunctions and more, on [https://zonestamp.toolforge.org/1748539800 29 May at 17:30 UTC] (that is, today).
You can learn more about the event on the [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata and Sister Projects event page]].
=== Recent Changes in the software ===
Last week, as discussed above, we finished one of our planned Quarterly pieces of work, and also a number of pieces of others.
For the 'light-weight enums' work ([[:phab:T390558|T390558]]), we have added an interface ([[:phab:T391918|T391918]]) and special rights for creating and editing them ([[:phab:T391913|T391913]] and [[:phab:T391914|T391914]]); for now, like with Types, we're holding them back only for staff, but we will expand their access later. To make the creation and editing tools possible, we also re-designed our tests for what kinds of edits and creations are allowed to be more flexible. There's still more to do here before we call this complete, but we should be able to demonstrate it on-wiki shortly.
Within our performance strand of work this Quarter, we're working to add better caching to the orchestrator. We have added the functionality to the MediaWiki side of the code to trigger this new behaviour ([[:phab:T391971|T391971]]). Soon, we will wire it together, and measure and report on the impact.
Following-up on a wide-ranging set of issues that [[User:99of9|User:99of9]] found when running Test cases, we added some regression tests related to different valid 'shapes' of Language objects ([[:phab:T391329|T391329]]).
As part of Wikimedia-wide support, we have added a new Language, [[Z1970|Z1970/qxp]] ([[:phab:T394068|T394068]]).
=== Ongoing consultation about Location of Abstract Content ===
Thanks to everyone who participated in the consultation about the [[:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content|Location for Abstract Content]] so far! The consultation will continue for another two weeks. We try to keep answering questions by and participating in the consultation with the community.
Personally, I found the arguments thought-provoking, and I find myself changing my own position as I read about new ideas and considerations I haven’t had before. I am planning to add a current state of my thinking next week. So keep the ideas and arguments going!
=== News in Types ===
The [[Z86|Unicode code point]] type has been set up with a [[Z23041|read]] and [[Z24823|display]] function, thus improving the UX on Wikifunctions and also allowing Functions using this Type to be used in embedded calls. Thanks to [[User:99of9|User:99of9]] for shepherding this improvement and for working on the read and display functions.
For our current work to support import of more Wikidata content ([[:phab:T390559|T390559]]), discussions on three new types proposals are ongoing: [[Wikifunctions:Type proposals/Wikidata time|Wikidata time]], [[Wikifunctions:Type proposals/Wikidata quantity|Wikidata quantity]], and [[Wikifunctions:Type proposals/Wikidata geocoordinates|Wikidata geocoordinates]]. Comments are welcome!
=== Fresh Functions weekly: 17 new Functions ===
This week we had 17 new functions. Here are some of the functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24736}}
* {{Z|Z24749}}
* {{Z|Z24757}}
* {{Z|Z24809}}
* {{Z|Z24823}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
[[Category:Status updates{{#translation:}}|2025-05-29]]
9xc6fumprlgxvyxuz4lv3virzs8kpvk
Wikifunctions:Status updates/2025-05-29/pt-br
4
57614
191303
191142
2025-06-06T19:18:52Z
FuzzyBot
207
Updating to match new version of source page
191303
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-23
| nextlabel = Próxima atualização
| next = 2025-06-06
}}
<span id="Rolling_out_embedded_function_calls_to_five_Wiktionaries"></span>
=== Implementando chamadas de função incorporadas em cinco Wikcionários ===
Implementamos chamadas de funções incorporadas em um primeiro conjunto de projetos do Wikcionário: [[:ha:wikt:|hausa]], [[:ig:wikt:|igbo]], [[:ml:wikt:|malaiala]], [[:bn:wikt:|bengali]] e [[:dv:wikt:|divehi]]. Eles representam os idiomas de foco que têm um Wikcionário (ou seja, todos menos o dagbani) e, além disso, um idioma da direita para a esquerda, o divehi. Isso também representa uma duplicação aproximada de visualizações de página para wikis com chamadas de função incorporadas, seguindo nosso plano para uma implementação cuidadosa dos projetos.
Como antes, pedimos que as pessoas se contenham e contribuam para esses projetos somente se forem ou quiserem se tornar membros da comunidade em questão. '''Não use nenhuma dessas wikis como bancos de testes.''' Você pode usar a [[Wikifunctions:Embedded function calls/sandbox|caixa de areia de chamadas da Wikifunctions]] para isso. Leia a [[Special:MyLanguage/Wikifunctions:Embedded function calls|documentação sobre a incorporação de chamadas de função]] na Wikifunctions.
Mudamos nossa implementação para nos concentrarmos nos Wikcionários por enquanto, em vez das Wikipédias. Essa mudança foi feita para seguir a [[:mw:Special:MyLanguage/Parsoid/Deployments|implementação do Parsoid]], da qual dependem as chamadas de função incorporadas. Voltaremos às Wikipédias provavelmente ainda este ano.
Nos próximos meses, estamos planejando a implementação em muitos outros Wikcionários. Isso permitirá que as comunidades do Wikcionário trabalhem em funções que sejam úteis nos diferentes projetos do Wikcionário. Isso pode incluir as já existentes [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2023-09-08|funções morfológicas]] (''p. ex.'', o [[Z11089|plural regular]] de ''house'' sendo ''{{#function:Z11089|house}}''), ou funções como esta que lista as [[Z24676|três formas verbais principais de um verbo em inglês]], ''p. ex.'' ''{{#function:Z24687|L3366}}''. No momento, estamos limitados a saídas (''outputs'') de cadeias de caracteres simples no que pode ser incorporado em páginas, mas planejamos permitir alguma formatação ainda este ano, com o objetivo de criar tabelas de conjugação completas, que poderiam ser reutilizadas em muitas edições de idiomas diferentes de projetos do Wikcionário. Até lá, estamos curiosos para saber que tipo de funções vocês estarão criando a partir de agora!
<span id="Calculating_with_today’s_date"></span>
=== Calculando com a data de hoje ===
Olá neste(a) lindo(a) {{#function:Z20421|}}. Faltam {{#function:Z20744||6 August 2025}} dias para a [[:wikimania:Special:MyLanguage/2025:Wikimania|Wikimania 2025]]!
Se você estiver lendo este texto na página wiki em que foi publicado, o dia da semana e o número de dias na frase anterior serão atualizados automaticamente à medida que nos aproximarmos da Wikimania (se você estiver lendo este texto em um e-mail, isso não funcionará — ainda não há integração das chamadas de função da Wikifunctions em e-mails, e nem está planejada).
Um novo recurso ao incorporar chamadas de função em páginas wiki permite que você deixe o valor de uma [[Z20420|data do calendário gregoriano]] vazio. Se fizer isso, o valor será automaticamente definido para o dia atual quando a página for acessada (de acordo com o fuso horário da wiki). Isso permite todos os tipos de resultados dinâmicos: você pode retornar a [[Z20756|idade]] de uma pessoa ou instituição, o [[Z20421|dia da semana]] atual, a [[Z20741|distância da Lua]] de hoje e muito mais.
Para usar esse recurso, basta deixar o valor vazio. Sinta-se à vontade para experimentá-lo na [[Wikifunctions:Embedded function calls/sandbox|caixa de areia de chamadas incorporadas]]. Leia [[Special:MyLanguage/Wikifunctions:Embedded function calls|mais documentação sobre como usar chamadas de função incorporadas]] em wikis que tenham essa opção ativada.
Estamos planejando trabalhar em dois outros tipos para obter valores padrão: uma [[Z6091|referência de itens do Wikidata]] para definir o item conectado a uma determinada página (se houver) e o [[Z60|idioma]] de uma determinada página. Ambos podem ser usados em chamadas de função para adaptar a chamada de função a uma determinada página. Espera-se que esses recursos sejam desenvolvidos e implantados ainda este ano.
Informe-nos se encontrar algum problema com o novo recurso.
<span id="Presentation_at_Wikidata_and_Sister_Projects_event"></span>
=== Apresentação no evento “Wikidata e projetos irmãos” ===
De 29 de maio a 1 de junho de 2025, haverá o evento [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata e projetos irmãos]]. [[User:DMartin (WMF)|David Martin]] e [[User:Sannita (WMF)|Luca Martinelli]] farão uma apresentação sobre como o Wikidata potencializa as funções de linguagem na Wikifunctions e muito mais, no dia [https://zonestamp.toolforge.org/1748539800 29 de maio às 17:30 UTC] (ou seja, hoje).
Saiba mais sobre o evento na página do evento [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata e projetos irmãos]].
<span id="Recent_Changes_in_the_software"></span>
=== Mudanças recentes no ''software'' ===
Na semana passada, conforme discutido acima, concluímos um de nossos trabalhos planejados para o trimestre e também vários outros.
Para o trabalho de “enums leves” ([[:phab:T390558|T390558]]), adicionamos uma interface ([[:phab:T391918|T391918]]) e direitos especiais para criá-los e editá-los ([[:phab:T391913|T391913]] e [[:phab:T391914|T391914]]); por enquanto, assim como no caso dos Tipos, estamos reservando-os apenas para funcionários, mas expandiremos o acesso posteriormente. Para possibilitar as ferramentas de criação e edição, também reformulamos nossos testes para que os tipos de edições e criações permitidos sejam mais flexíveis. Ainda há mais a ser feito antes de considerarmos isso completo, mas devemos poder demonstrá-lo na wiki em breve.
Em nossa linha de trabalho de desempenho neste trimestre, estamos trabalhando para adicionar um melhor armazenamento em ''cache'' ao orquestrador. Adicionamos a funcionalidade ao lado do código do MediaWiki para acionar esse novo comportamento ([[:phab:T391971|T391971]]). Em breve, vamos conectar tudo isso, medir e relatar o impacto.
Seguindo um amplo conjunto de problemas que o [[User:99of9|User:99of9]] encontrou ao executar casos de teste, adicionamos alguns testes de regressão relacionados a diferentes “formas” válidas de objetos Language ([[:phab:T391329|T391329]]).
Como parte da compatibilidade com toda a Wikimedia, adicionamos um novo idioma, [[Z1970|Z1970/qxp]] ([[:phab:T394068|T394068]]).
<span id="Ongoing_consultation_about_Location_of_Abstract_Content"></span>
=== Consulta contínua sobre a localização de conteúdo abstrato ===
Agradecemos a todos que participaram da consulta sobre a [[:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content|localização de conteúdo abstrato]] até o momento! A consulta continuará por mais duas semanas. Tentamos continuar respondendo às perguntas e participando da consulta com a comunidade.
Pessoalmente, achei os argumentos instigantes e me vejo mudando minha própria posição ao ler sobre novas ideias e considerações que não tinha antes. Estou planejando adicionar um estado atual do meu pensamento na próxima semana. Portanto, continuem com as ideias e os argumentos!
<span id="News_in_Types"></span>
=== Novidades nos Tipos ===
O tipo de [[Z86|ponto de código Unicode]] foi configurado com uma função de [[Z23041|leitura]] e [[Z24823|exibição]], melhorando assim a experiência do usuário na Wikifunctions e também permitindo que as Funções que utilizam esse Tipo sejam usadas em chamadas incorporadas. Agradecemos a [[User:99of9|User:99of9]] por ter conduzido essa melhoria e por ter trabalhado nas funções de leitura e exibição.
Para nosso trabalho atual de suporte à importação de mais conteúdo do Wikidata ([[:phab:T390559|T390559]]), estão em andamento discussões sobre três novos tipos de propostas: os tipos ''[[Wikifunctions:Type proposals/Wikidata time|time]]'', ''[[Wikifunctions:Type proposals/Wikidata quantity|quantity]]'' e ''[[Wikifunctions:Type proposals/Wikidata geocoordinates|geocoordinates]]'' do Wikidata. Comentários são bem-vindos!
<span id="Fresh_Functions_weekly:_17_new_Functions"></span>
=== Novas funções toda semana: 17 novas funções ===
Nesta semana, tivemos 17 novas funções. Aqui estão algumas das funções com implementações e testes de aprovação para você ter uma ideia de quais funções foram criadas. Agradecemos a todos os que contribuíram!
* {{Z|Z24736}}
* {{Z|Z24749}}
* {{Z|Z24757}}
* {{Z|Z24809}}
* {{Z|Z24823}}
Está disponível uma [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest lista completa de todas as funções ordenadas por quando foram criadas].
[[Category:Status updates{{#translation:}}|2025-05-29]]
phq2byi4r59zqsx9e26mycj136ms3gd
Wikifunctions:Status updates/2025-05-29/fr
4
57629
191301
190917
2025-06-06T19:18:50Z
FuzzyBot
207
Updating to match new version of source page
191301
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Mise à jour précédente
| prev = 2025-05-23
| nextlabel = Mise à jour suivante
| next = 2025-06-06
}}
<span id="Rolling_out_embedded_function_calls_to_five_Wiktionaries"></span>
=== Déploiement d'appels de fonctions intégrés dans cinq wiktionnaires ===
Nous avons déployé les appels de fonction intégrés dans une première série de projets Wiktionnaire : [[:ha:wikt:|hausa]], [[:ig:wikt:|igbo]], [[:ml:wikt:|malayalam]], [[:bn:wikt:|bengali]] et [[:dv:wikt:|divehi]]. Cela représente [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2021-04-15|les langues cibles]] qui ont un Wiktionnaire (c'est-à-dire toutes sauf le dagbani), et en plus une langue de droite à gauche, le divehi. Cela représente également un doublement approximatif du nombre de pages vues sur les wikis avec des appels de fonction intégrés, conformément à notre plan de déploiement prudent des projets.
Comme précédemment, nous demandons aux gens de faire preuve de retenue et de ne contribuer à ces projets que si vous êtes ou souhaitez devenir membre de la communauté concernée. '''N'utilisez aucun de ces wikis comme zone de test.''' Vous pouvez utiliser le [[Wikifunctions:Embedded function calls/sandbox|bac à sable d'appel Wikifonctions]] pour cela. Vous pouvez trouver de la [[Special:MyLanguage/Wikifunctions:Embedded function calls|documentation sur l'intégration des appels de fonction]] sur Wikifonctions.
Nous avons modifié notre déploiement pour nous concentrer sur les Wiktionnaires pour l’instant, au lieu des Wikipédias. Ce changement a été effectué afin de suivre le déploiement de [[:mw:Special:MyLanguage/Parsoid/Deployments|Parsoid]], dont dépendent les appels de fonction intégrés. Nous reviendrons sur les Wikipédias probablement plus tard dans l’année.
Au cours des prochains mois, nous prévoyons de déployer le système dans de nombreux autres Wiktionnaires. Cela permettra aux communautés Wiktionary de travailler sur des fonctions utiles aux différents projets Wiktionary. Il peut s’agir des [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2023-09-08|fonctions morphologiques]] déjà existantes (''par exemple'' le [[Z11089|pluriel régulier]] de ''house'' est ''{{#function:Z11089|house}}''), ou de fonctions telles que celle-ci listant les [[Z24676|trois formes principales d’un verbe anglais]], ''par exemple'' : ''{{#function:Z24687|L3366}}''. Nous sommes actuellement limités à de simples chaines de caractères pour ce qui peut être intégré dans les pages, mais dans le courant de l’année, nous prévoyons de permettre un certain formatage, dans le but de créer des tableaux de conjugaison entiers, qui pourraient être réutilisés dans de nombreuses éditions linguistiques différentes des projets Wiktionary. D’ici là, nous sommes curieux de savoir quel type de fonctions vous allez créer maintenant !
<span id="Calculating_with_today’s_date"></span>
=== Calcul avec la date du jour ===
Bonjour en ce beau {{#function:Z20421|}}. Il reste {{#function:Z20744||6 August 2025}} jours avant [[:wikimania:Special:MyLanguage/2025:Wikimania|Wikimania 2025]] !
Si vous lisez ce texte sur la page wiki sur laquelle il a été publié, le jour de la semaine et le nombre de jours dans la phrase précédente seront mis à jour automatiquement au fur et à mesure que nous nous rapprochons de la Wikimania (si vous lisez ce texte dans un e-mail, cela ne fonctionnera pas - il n'y a pas encore d'intégration des appels de fonctions Wikifunctions dans les e-mails, et ce n'est pas prévu).
<div lang="en" dir="ltr" class="mw-content-ltr">
A new feature when embedding function calls in wikipages allows you to leave the value for a [[Z20420|Gregorian calendar date]] empty. If you do so, the value will be automatically set to the current day when the page is accessed (according to the wiki’s timezone). This allows for all kinds of dynamic outputs: you can return the [[Z20756|age]] of a person or institution, the current [[Z20421|day of the week]], today’s [[Z20741|distance to the Moon]], and much more.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
You use this feature by simply leaving the value empty. Feel free to try it out on the [[Wikifunctions:Embedded function calls/sandbox|embedded calls Sandbox]]. You can find [[Special:MyLanguage/Wikifunctions:Embedded function calls|further documentation on how to use embedded function calls]] in wikis that have that enabled.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We are planning to work on two other types to get default values: a [[Z6091|Wikidata item reference]] to set the item connected to a given page (if any), and the [[Z60|language]] of a given page. Both can then be used in function calls to adapt the function call to a given page. These are expected to be developed and deployed later this year.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Please let us know if you find any issues with the new feature.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Presentation at Wikidata and Sister Projects event ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
29 May–1 June 2025 will be the [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata and Sister Projects]] event. [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] are going to present about how Wikidata powers language functions on Wikifunctions and more, on [https://zonestamp.toolforge.org/1748539800 29 May at 17:30 UTC] (that is, today).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
You can learn more about the event on the [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata and Sister Projects event page]].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week, as discussed above, we finished one of our planned Quarterly pieces of work, and also a number of pieces of others.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For the 'light-weight enums' work ([[:phab:T390558|T390558]]), we have added an interface ([[:phab:T391918|T391918]]) and special rights for creating and editing them ([[:phab:T391913|T391913]] and [[:phab:T391914|T391914]]); for now, like with Types, we're holding them back only for staff, but we will expand their access later. To make the creation and editing tools possible, we also re-designed our tests for what kinds of edits and creations are allowed to be more flexible. There's still more to do here before we call this complete, but we should be able to demonstrate it on-wiki shortly.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Within our performance strand of work this Quarter, we're working to add better caching to the orchestrator. We have added the functionality to the MediaWiki side of the code to trigger this new behaviour ([[:phab:T391971|T391971]]). Soon, we will wire it together, and measure and report on the impact.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Following-up on a wide-ranging set of issues that [[User:99of9|User:99of9]] found when running Test cases, we added some regression tests related to different valid 'shapes' of Language objects ([[:phab:T391329|T391329]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As part of Wikimedia-wide support, we have added a new Language, [[Z1970|Z1970/qxp]] ([[:phab:T394068|T394068]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Ongoing consultation about Location of Abstract Content ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Thanks to everyone who participated in the consultation about the [[:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content|Location for Abstract Content]] so far! The consultation will continue for another two weeks. We try to keep answering questions by and participating in the consultation with the community.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I found the arguments thought-provoking, and I find myself changing my own position as I read about new ideas and considerations I haven’t had before. I am planning to add a current state of my thinking next week. So keep the ideas and arguments going!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== News in Types ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[Z86|Unicode code point]] type has been set up with a [[Z23041|read]] and [[Z24823|display]] function, thus improving the UX on Wikifunctions and also allowing Functions using this Type to be used in embedded calls. Thanks to [[User:99of9|User:99of9]] for shepherding this improvement and for working on the read and display functions.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For our current work to support import of more Wikidata content ([[:phab:T390559|T390559]]), discussions on three new types proposals are ongoing: [[Wikifunctions:Type proposals/Wikidata time|Wikidata time]], [[Wikifunctions:Type proposals/Wikidata quantity|Wikidata quantity]], and [[Wikifunctions:Type proposals/Wikidata geocoordinates|Wikidata geocoordinates]]. Comments are welcome!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 17 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 17 new functions. Here are some of the functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
* {{Z|Z24736}}
* {{Z|Z24749}}
* {{Z|Z24757}}
* {{Z|Z24809}}
* {{Z|Z24823}}
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
[[Category:Status updates{{#translation:}}|2025-05-29]]
p87aq3te9e5kzs8fe2gd1igbrnienn4
Wikifunctions:Status updates/2025-05-29/de
4
57904
191302
191077
2025-06-06T19:18:50Z
FuzzyBot
207
Updating to match new version of source page
191302
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Vorheriges Update
| prev = 2025-05-23
| nextlabel = Nächstes Update
| next = 2025-06-06
}}
<span id="Rolling_out_embedded_function_calls_to_five_Wiktionaries"></span>
=== Einführung eingebetteter Funktionsaufrufe in fünf Wiktionarys ===
Wir haben eingebettete Funktionsaufrufe in einer ersten Reihe von Wiktionary-Projekten eingeführt: [[:ha:wikt:|Hausa]], [[:ig:wikt:|Igbo]], [[:ml:wikt:|Malayalam]], [[:bn:wikt:|Bengalisch]] und [[:dv:wikt:|Divehi]]. Diese repräsentieren [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2021-04-15|die Fokussprachen]], die über ein Wiktionary verfügen (also alle außer Dagbani) und zusätzlich eine von rechts nach links geschriebene Sprache, Divehi. Dies entspricht ungefähr einer Verdoppelung der Seitenaufrufe für Wikis mit eingebetteten Funktionsaufrufen, gemäß unserem Plan einer behutsamen Einführung in den Projekten.
Wir bitten nach wie vor um Zurückhaltung und darum, nur dann zu diesen Projekten beizutragen, wenn du Mitglied der jeweiligen Community bist oder werden möchtest. '''Verwende keines dieser Wikis als Testumgebung.''' Du kannst hierfür die [[Wikifunctions:Embedded function calls/sandbox|Spielwiese für Wikifunctions-Aufrufe]] verwenden. Eine [[Special:MyLanguage/Wikifunctions:Embedded function calls|Dokumentation zum Einbetten von Funktionsaufrufen]] findet sich auf Wikifunctions.
Wir haben unsere Einführung vorerst auf Wiktionarys statt Wikipedias umgestellt. Diese Änderung erfolgte im Zuge der [[:mw:Special:MyLanguage/Parsoid/Deployments|Parsoid-Einführung]], von der eingebettete Funktionsaufrufe abhängen. Wir werden voraussichtlich später in diesem Jahr auf die Wikipedias zurückkommen.
In den nächsten Monaten planen wir die Einführung in vielen weiteren Wiktionarys. Dies ermöglicht den Wiktionary-Communitys, an Funktionen zu arbeiten, die in den verschiedenen Wiktionary-Projekten nützlich sind. Dazu gehören beispielsweise die bereits vorhandenen [[:meta:Special:MyLanguage/Abstract Wikipedia/Updates/2023-09-08|morphologischen Funktionen]] (''z. B.'' der [[Z11089|reguläre Plural]] von ''house'' ist ''{{#function:Z11089|house}}'') oder Funktionen wie diese, die die [[Z24676|drei Hauptformen eines englischen Verbs]] auflistet, ''z. B.'' ''{{#function:Z24687|L3366}}''. Derzeit sind wir bei der Einbettung in Seiten auf einfache Zeichenketten-Ausgaben beschränkt, planen aber für später in diesem Jahr, einige Formatierungen zuzulassen, mit dem Ziel, ganze Konjugationstabellen zu erstellen, die in vielen verschiedenen Sprachversionen von Wiktionary-Projekten wiederverwendet werden können. Bis dahin sind wir gespannt, welche Funktionen ihr jetzt entwickeln werdet!
<span id="Calculating_with_today’s_date"></span>
=== Berechnung mit dem heutigen Datum ===
Hallo an diesem schönen {{#function:Z20421|}}. Es sind noch {{#function:Z20744||6 August 2025}} Tage bis zur [[:wikimania:Special:MyLanguage/2025:Wikimania|Wikimania 2025]]!
Wenn du diesen Text auf der Wiki-Seite liest, auf der er veröffentlicht wurde, werden der Wochentag und die Anzahl der Tage im vorherigen Satz automatisch aktualisiert, je näher wir der Wikimania kommen (wenn du dies in einer E-Mail liest, funktioniert dies nicht – eine Integration von Wikifunctions-Funktionsaufrufen in E-Mails ist noch nicht vorhanden und auch nicht geplant).
Eine neue Funktion beim Einbetten von Funktionsaufrufen auf Wikiseiten ermöglicht es, den Wert für ein [[Z20420|Datum des Gregorianischen Kalenders]] leer zu lassen. In diesem Fall wird der Wert beim Seitenaufruf automatisch auf den aktuellen Tag gesetzt (entsprechend der Zeitzone des Wikis). Dies ermöglicht vielfältige dynamische Ausgaben: Du kannst das [[Z20756|Alter]] einer Person oder Institution, den aktuellen [[Z20421|Wochentag]], die heutige [[Z20741|Entfernung zum Mond]] und vieles mehr zurückgeben.
Du nutzt diese Funktion, indem du den Wert einfach leer lässt. Probiere es gerne auf der [[Wikifunctions:Embedded function calls/sandbox|Spielwiese für eingebettete Funktionsaufrufe]] aus. Du findest [[Special:MyLanguage/Wikifunctions:Embedded function calls|weitere Dokumentation zur Verwendung eingebetteter Funktionsaufrufe]] in Wikis, die diese Funktion aktiviert haben.
Wir planen, daran zu arbeiten, Standardwerte für zwei andere Typen zu erhalten: eine [[Z6091|Wikidata-Datenobjekt-Referenz]], um das mit einer bestimmten Seite verbundene Objekt (falls vorhanden) festzulegen, und die [[Z60|Sprache]] einer bestimmten Seite. Beide können dann in Funktionsaufrufen verwendet werden, um den Funktionsaufruf an eine bestimmte Seite anzupassen. Diese werden voraussichtlich noch in diesem Jahr entwickelt und bereitgestellt.
Bitte informiere uns, wenn du Probleme mit der neuen Funktion bemerkst.
<span id="Presentation_at_Wikidata_and_Sister_Projects_event"></span>
=== Präsentation bei der Veranstaltung Wikidata und Schwesterprojekte ===
Vom 29. Mai bis 1. Juni 2025 findet die Veranstaltung [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Wikidata und Schwesterprojekte]] statt. [[User:DMartin (WMF)|David Martin]] und [[User:Sannita (WMF)|Luca Martinelli]] werden am [https://zonestamp.toolforge.org/1748539800 29. Mai um 19:30 MESZ] (also heute) vorstellen, wie Wikidata Sprachfunktionen auf Wikifunctions unterstützt und vieles mehr.
Weitere Informationen zu der Veranstaltung findest du auf der [[:d:Special:MyLanguage/Event:Wikidata and Sister Projects|Veranstaltungsseite Wikidata und Schwesterprojekte]].
<span id="Recent_Changes_in_the_software"></span>
=== Letzte Änderungen an der Software ===
Letzte Woche haben wir, wie oben besprochen, eine unserer geplanten vierteljährlichen Arbeiten sowie eine Reihe anderer Arbeiten abgeschlossen.
Für die Arbeit mit leichtgewichtigen Aufzählungen' ([[:phab:T390558|T390558]]) haben wir eine Benutzeroberfläche ([[:phab:T391918|T391918]]) und spezielle Rechte für deren Erstellung und Bearbeitung hinzugefügt ([[:phab:T391913|T391913]] und [[:phab:T391914|T391914]]). Wie bei den Typen sind diese vorerst nur für Mitarbeiter verfügbar, der Zugang wird aber später ausgeweitet. Um die Erstellungs- und Bearbeitungswerkzeuge zu ermöglichen, haben wir auch unsere Tests für die zulässigen Bearbeitungen und Erstellungen flexibler gestaltet. Es gibt hier noch einiges zu tun, bevor wir dies als abgeschlossen betrachten, aber wir sollten es in Kürze im Wiki demonstrieren können.
Im Rahmen unseres Performance-Arbeitsschwerpunkts in diesem Quartal arbeiten wir an einem besseren Caching des Orchestrierers. Wir haben die Funktionalität auf der MediaWiki-Seite des Codes hinzugefügt, um dieses neue Verhalten auszulösen ([[:phab:T391971|T391971]]). In Kürze werden wir dies zusammenführen und die Auswirkungen messen und darüber berichten.
Als Reaktion auf eine Reihe weitreichender Probleme, die [[User:99of9|Benutzer:99of9]] beim Ausführen von Tests festgestellt hat, haben wir einige Regressionstests hinzugefügt, die sich auf verschiedene gültige 'Formen' von Sprachobjekten beziehen ([[:phab:T391329|T391329]]).
Als Teil der Wikimedia-weiten Unterstützung haben wir eine neue Sprache hinzugefügt: [[Z1970|Z1970/qxp]] ([[:phab:T394068|T394068]]).
<span id="Ongoing_consultation_about_Location_of_Abstract_Content"></span>
=== Laufende Konsultation über den Ort des Abstrakten Inhalts ===
Vielen Dank an alle, die bisher an der Konsultation über den [[:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content|Ort des Abstrakten Inhalts]] teilgenommen haben! Die Konsultation läuft noch zwei Wochen. Wir versuchen, weiterhin Fragen der Community zu beantworten und an der Konsultation mitzuwirken.
Ich persönlich fand die Argumente zum Nachdenken anregend und merke, wie ich meine eigene Meinung ändere, wenn ich neue Ideen und Überlegungen lese, die ich vorher nicht hatte. Nächste Woche werde ich meinen aktuellen Stand meiner Überlegungen darlegen. Also, weiter so mit den Ideen und Argumenten!
<span id="News_in_Types"></span>
=== Neuigkeiten zu Typen ===
Der Typ [[Z86|Unicode-Codepunkt]] wurde mit einer [[Z23041|Lese]]- und einer [[Z24823|Anzeige]]-Funktion ausgestattet. Dies verbessert die Benutzererfahrung von Wikifunctions und ermöglicht die Verwendung von Funktionen mit diesem Typ in eingebetteten Aufrufen. Vielen Dank an [[User:99of9|Benutzer:99of9]] für die Unterstützung dieser Verbesserung und die Arbeit an den Lese- und Anzeigefunktionen.
Im Rahmen unserer aktuellen Arbeit zur Unterstützung des Imports weiterer Wikidata-Inhalte ([[:phab:T390559|T390559]]) laufen Diskussionen über drei neue Typenvorschläge: [[Wikifunctions:Type proposals/Wikidata time|Wikidata-Zeit]], [[Wikifunctions:Type proposals/Wikidata quantity|Wikidata-Menge]] und [[Wikifunctions:Type proposals/Wikidata geocoordinates|Wikidata-Geokoordinaten]]. Kommentare sind willkommen!
<span id="Fresh_Functions_weekly:_17_new_Functions"></span>
=== Wöchentliche neue Funktionen: 17 neue Funktionen ===
Diese Woche hatten wir 17 neue Funktionen. Hier ist eine Liste von Funktionen mit Implementierungen und bestandenen Tests, um einen Eindruck davon zu bekommen, welche Funktionen erstellt wurden. Vielen Dank an alle für ihre Beiträge!
* {{Z|Z24736}}
* {{Z|Z24749}}
* {{Z|Z24757}}
* {{Z|Z24809}}
* {{Z|Z24823}}
Eine [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest vollständige Liste aller Funktionen, sortiert nach Erstellungsdatum], ist verfügbar.
[[Category:Status updates{{#translation:}}|2025-05-29]]
k4palbyu39uavxdlr64749ir7vjzbf9
Wikifunctions:FAQ/ko
4
57912
191359
190771
2025-06-07T04:44:03Z
FuzzyBot
207
Updating to match new version of source page
191359
wikitext
text/x-wiki
<languages/>
{{shortcut|[[WF:FAQ]]}}
이 문서는 위키함수에 관련된 자주 묻는 질문을 다룬 문서입니다. 원하는 답변이 없으시다면 [[Wikifunctions talk:FAQ|토론 문서]]에서 직접 물어보시기 바랍니다!
또한, 위키함수와 추상 위키백과에 대한 보다 구체적인 질문에 대해서는 [[:m:Special:MyLanguage/Abstract Wikipedia/FAQ|메타에 대한 FAQ]]를 고려하시기 바랍니다.
__TOC__
<span id="Introduction"></span>
== 소개 ==
<span id="What_is_this_project_about?"></span>
=== 이 프로젝트는 무엇에 관한 것인가요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is a new Wikimedia project that provides a catalog of all kinds of functions that anyone can call, write, maintain, and use. It also provides the underlying technology that will eventually enable the translation of language-independent articles from Abstract Wikipedia into the language of any Wikipedia. This will allow everyone to contribute and read articles in their preferred languages.
</div>
<span id="What_is_a_function?"></span>
=== 함수가 무엇인가요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Functions are a form of knowledge that can answer questions, such as how many days have passed between two dates or the distance between two cities. More complicated functions can answer more complicated questions, such as the volume of a three-dimensional shape, the distance between Mars and Venus on a certain date, or whether two species were alive at the same time.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We already use functions in many types of knowledge inquiries, such as asking a question to a search engine. The templates, such as [[:w:en:Template:Convert|Template:Convert]] and [[:w:en:Template:Age|Template:Age]] on English Wikipedia, are also examples of functionalities that are already used in many Wikipedias, written in wikitext and Lua and manually copied to each wiki where it's wanted.
</div>
<span id="What_is_an_implementation?"></span>
=== 구현이 무엇인가요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
An implementation is a particular way to execute a function. An implementation is a recipe that lists the steps that are needed to run the function. It may be a piece of code in a programming language or a combination of calls to other functions. A function may have many implementations, which should all be equivalent.
</div>
<span id="What_is_a_test?"></span>
=== 테스트가 무엇인가요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
A test is a way to determine if a given function is doing the right thing. A function will typically have multiple testers, each specifying some input to the function and the conditions the output for the given input must fulfill.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
For example, testers for a “title case” function might include: “<span dir="ltr" lang="en">abc</span>” should become “<span dir="ltr" lang="en">Abc</span>”; “<span dir="ltr" lang="en">war and peace</span>” should become “<span dir="ltr" lang="en">War and Peace</span>”; “<span dir="ltr" lang="ru">война и мир</span>” should become “<span dir="ltr" lang="ru">Война и мир</span>”; and “<span dir="ltr" lang="en">123</span>” should remain “<span dir="ltr" lang="en">123</span>”.
</div>
<span id="Which_features_are_available_now,_which_will_be_soon_available,_and_which_are_further_away?"></span>
=== 현재 사용 가능할지, 곧 사용 가능해질지, 언제 사용될지 모르는 함수가 무엇인가요? ===
* <span lang="en" dir="ltr" class="mw-content-ltr">At launch:</span>
** 문자열과 불리언을 다루는 함수를 가질 수 있습니다.
** 위키함수는 처음부터 완전히 국제화되었습니다. 어떤 언어로든 사용할 수 있습니다.
* [[Wikifunctions:Status|진행 중인 개발]]:
** 일반적인 유형과 함수는 완전히 지원되지 않습니다.
** <span lang="en" dir="ltr" class="mw-content-ltr">Adding types will, for now, be something that is limited to the development team. In the future, the community will be able to add more types. There is a lot of work to be done in the future to make types behave much more smoothly.</span>
*** <span lang="en" dir="ltr" class="mw-content-ltr">One particularly interesting type will be binary data, and particularly files.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">We currently support two programming languages for implementations: JavaScript and Python. In the future, we want to support many more.</span>
** <span lang="en" dir="ltr" class="mw-content-ltr">Currently, it is ''not'' possible to call other functions from implementations written in any programming language. This is currently only possible through composition.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">In the future:</span>
** 다른 위키미디어 프로젝트에서 함수를 호출하여 해당 결과를 문서 출력에 통합할 수 있습니다.
** 함수 내에서 위키데이터의 데이터를 사용할 수 있습니다.
** Commons Data 네임스페이스에서 데이터 세트를 호출할 수 있습니다.
<span id="How_is_Wikifunctions_multilingual?"></span>
=== 위키함수는 어떻게 다국어를 지원하나요? ===
위키함수와 추상 위키백과는 서로 영향을 미치지 않는 여러 가지 방식으로 다국어를 사용합니다:
* '''위키함수는 콘텐츠와 사용자 인터페이스 모두 다국어를 지원합니다.''' 사용자는 모든 자연어로 위키함수의 함수를 읽고 호출할 수 있습니다. 예를 들어, "문자열 추가" 함수에는 [https://www.wikifunctions.org/view/en/Z10000 영어], [https://www.wikifunctions.org/view/pl/Z10000 폴란드어], [https://www.wikifunctions.org/view/he/Z10000 히브리어] 버전이 있으나, 더 많은 언어로도 제공됩니다.
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Contributors can edit and improve Wikifunctions using their language.''' Even implementations can be edited in the natural language of the contributor. For example, the composition of the “and” function can be edited in [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=de German], [https://www.wikifunctions.org/wiki/Z11223?action=edit&uselang=en English], or any other of about 300 languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Wikifunctions functions can be used to create results for any natural language.''' The community is creating a growing number of functions to support the generation of text in many natural languages. We have functions for [[Wikifunctions:Catalogue#Breton|Breton]], [[Wikifunctions:Catalogue#Rohingya|Rohingya]], [[Wikifunctions:Catalogue#English|English]], and many other languages.</span>
* <span lang="en" dir="ltr" class="mw-content-ltr">'''Functions in Wikifunctions can be implemented in various different programming languages.''' For example, the [[Z10000|join function]] is implemented in both [[Z10005|JavaScript]] and [[Z10004|Python]].</span>
<span id="Which_programming_languages_does_Wikifunctions_currently_support?_Which_programming_languages_will_be_supported_in_the_future?"></span>
=== 현재 위키함수는 어떤 프로그래밍 언어를 지원하나요? 앞으로 어떤 프로그래밍 언어가 지원되나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Currently, Wikifunctions supports implementations written in JavaScript and Python. We plan to add support for more programming languages in the future. We hope to add at least one further programming language in 2025 (but have not yet decided which one).
</div>
<span id="How_will_Wikifunctions_be_integrated_into_other_projects?"></span>
=== 위키함수는 다른 프로젝트에 어떻게 통합되나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Wikifunctions is the first step towards building Abstract Wikipedia. Our near-term focus will be on supporting the community and making improvements based on feedback. Concurrently, we will begin the process of integrating it with Wikipedia and Wikidata, which will enable broader real-life applications and get us closer to the vision of Abstract Wikipedia.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Contributors will be able to call functions stored on the Wikifunctions site from within their wikis. The result of the function call will be displayed to readers of the wiki. This can be used, for example, to calculate the age of a person, the population density based on population and area data from Wikidata, or to draw a graph and integrate it into a given article.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Another option to integrate Wikifunctions will be to integrate an interactive function call interface within their wiki. This could be used, for example, in a Wikipedia article to dynamically calculate the result of a physical equation based on reader-provided parameters, draw and interact with mathematical functions, etc.
</div>
<span id="What_Wikifunctions_is_not?"></span>
=== 위키함수란 무엇인가요? ===
자세한 내용은 [[Special:MyLanguage/Wikifunctions:What Wikifunctions is not|위키함수:위키함수가 아닌 것]]을 참고하세요.
<span id="What_license_will_the_functions_and_derived_content_be_under?"></span>
=== 함수 및 파생 콘텐츠에는 어떤 라이선스가 적용되나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Per the discussion happened [[:m:Special:MyLanguage/Abstract Wikipedia/Licensing discussion|on Meta between November and December 2021]], all contributions to Wikifunctions and the wider Abstract Wikipedia projects will be published under free licenses. In particular:
</div>
* 위키함수의 [[Special:MyLanguage/Wikifunctions:Glossary#Content|텍스트 내용]]은 [[w:ko:크리에이티브 커먼즈 라이선스|CC BY-SA 4.0]]에 따라 게시됩니다.
* [[Special:MyLanguage/Wikifunctions:Glossary#Function|함수 서명]] 및 위키함수의 기타 구조화된 콘텐츠는 [[w:ko:크리에이티브 커먼즈 라이선스#CC0|CC0]]으로 게시됩니다.
* 위키함수의 [[Special:MyLanguage/Wikifunctions:Glossary#Implementation|코드 구현]]은 [[w:ko:아파치 라이선스|아파치 2 라이선스]]에 따라 게시됩니다.
* 추상 위키백과의 [[Special:MyLanguage/Wikifunctions:Glossary#Content|추상 내용]]은 CC BY-SA 4.0에 따라 게시됩니다.
<div lang="en" dir="ltr" class="mw-content-ltr">
There are still some points that will need to be addressed in the future, such as the license of the generated content from the abstract content. We plan on drafting a more comprehensive document with the Legal department about how people can re-use code from Wikifunctions as painlessly as possible, while adhering to the license.
</div>
<span id="Contributing"></span>
== 기여 ==
<span id="I'm_new_here._What_is_there_for_me_to_do_and_how_can_I_help?"></span>
=== 제가 처음 와 봤는데, 제가 무엇을 해야 하고 어떻게 도와드려야 하나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Welcome! We're very happy to have you here! There are many opportunities for contributing to Wikifunctions, from creating new functions to improving and translating documentation. If you are looking for ways to get involved, we recommend that maybe, depending on your level of comfort, you suggest a new function on a topic you are interested in. Or even create such a function. Provide some tests. Try your hand at an implementation. Help with translations. Read and improve our documentation. Help with organizing the community.
</div>
<span id="How_do_I_create_a_new_function,_implementation,_or_test?"></span>
=== 새 함수, 구현, 테스트는 어떻게 만드나요? ===
새 기능, 구현, 테스트를 만드는 방법에 대해서는 [[Special:MyLanguage/Wikifunctions:Introduction|위키함수:소개]]를 참고하세요.
구현을 만드는 방법에 대해서는 [[Special:MyLanguage/Wikifunctions:How to create implementations|위키함수:구현을 만드는 방법]]을 참고하세요.
<span id="What_should_I_edit_first?"></span>
=== 무엇을 먼저 편집해야 하나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
If you can write several languages, find functions that don't have labels and descriptions in your languages yet on the page [[Special:ListMissingLabels]], and help to add them.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you have some interest in a domain that could feature functions in Wikifunctions, but yet doesn't, or if you have more ideas for functions, go to the page for [[Wikifunctions:Suggest a new function|suggesting new functions]] and present your ideas.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
If you are a coder in JavaScript or Python, maybe you want to check for functions that don't yet have implementations in JavaScript or Python, and try to write them.
</div>
<span id="Where_can_I_go_for_help?"></span>
=== 어디에서 도움을 받을 수 있나요? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
Your first stop should be the [[Special:MyLanguage/Help:Contents|Help portal]], where you'll find all the documentation related to using and editing Wikifunctions. If you're still stuck, post a message on [[Wikifunctions:Project chat|Project chat]], and someone will answer your question.
</div>
<span id="How_do_we_sort_or_categorize_functions?"></span>
=== 함수를 어떻게 정렬하거나 분류하나요? ===
{{Tracked|T285424}}
<div lang="en" dir="ltr" class="mw-content-ltr">
For now, the best way to sort or categorize functions is to do it by hand through pages in the Wikifunctions namespace. Another option would be through the talk page of the given function. We will monitor these efforts and discuss with the community which changes to the system would be helpful for this task.
</div>
[[Category:FAQ| {{#translation:}}]]
fv6vyig3rf5i19oc4bs18ig482sj062
Z24936
0
58071
191266
2025-06-06T12:10:37Z
Denny
81
191266
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20"
],
"Z8K4": [
"Z14"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
}
]
}
}
pj431e6dmt86vsa5nfn035239fqdrxt
191274
191266
2025-06-06T12:15:50Z
Denny
81
Added Z24937, Z24938, Z24939, Z24940 and Z24941 to the approved list of test cases
191274
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20",
"Z24937",
"Z24938",
"Z24939",
"Z24940",
"Z24941"
],
"Z8K4": [
"Z14"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
}
]
}
}
21fb3ajrwhvs5ja9voac9y4xa8enfkn
191276
191274
2025-06-06T12:18:37Z
Denny
81
Added Z24942 to the approved list of implementations
191276
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20",
"Z24937",
"Z24938",
"Z24939",
"Z24940",
"Z24941"
],
"Z8K4": [
"Z14",
"Z24942"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
}
]
}
}
ika957mvd5xlcw508ntzqbuylr1defn
191278
191276
2025-06-06T12:22:42Z
Denny
81
Added Z24943 to the approved list of implementations
191278
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20",
"Z24937",
"Z24938",
"Z24939",
"Z24940",
"Z24941"
],
"Z8K4": [
"Z14",
"Z24942",
"Z24943"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
}
]
}
}
icbbgtvbktu1lo291apaoaqjg1hpnqa
191280
191278
2025-06-06T12:24:43Z
Denny
81
Added Z24944 to the approved list of implementations
191280
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20",
"Z24937",
"Z24938",
"Z24939",
"Z24940",
"Z24941"
],
"Z8K4": [
"Z14",
"Z24942",
"Z24943",
"Z24944"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
}
]
}
}
47zbw3duvkkpxw6lpwrtfuy8626ub13
191282
191280
2025-06-06T12:35:32Z
Dv103
11127
+it
191282
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24936"
},
"Z2K2": {
"Z1K1": "Z8",
"Z8K1": [
"Z17",
{
"Z1K1": "Z17",
"Z17K1": "Z20420",
"Z17K2": "Z24936K1",
"Z17K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "date"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "data"
}
]
}
}
],
"Z8K2": "Z20342",
"Z8K3": [
"Z20",
"Z24937",
"Z24938",
"Z24939",
"Z24940",
"Z24941"
],
"Z8K4": [
"Z14",
"Z24942",
"Z24943",
"Z24944"
],
"Z8K5": "Z24936"
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "day of year from calendar date"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "giorno dell'anno da data di calendario gregoriano"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31",
{
"Z1K1": "Z31",
"Z31K1": "Z1002",
"Z31K2": [
"Z6",
"date from date",
"calendar day from date"
]
},
{
"Z1K1": "Z31",
"Z31K1": "Z1787",
"Z31K2": [
"Z6",
"giorno dell'anno da giorno di calendario gregoriano",
"giorno di calendario gregoriano in data romana",
"Data di calendario gregoriano in giorno di un anno romano"
]
}
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Given a Gregorian calendar date (e.g. 25 May 2025) return the day of the Roman year (i.e. 25 May)"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Dato un Giorno di calendario gregorianp, restituisce il giorno dell'Anno romano"
}
]
}
}
o9t6r1hrq17lce21nph01xff8sh37zy
Z24937
0
58072
191269
2025-06-06T12:12:05Z
Denny
81
191269
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24937"
},
"Z2K2": {
"Z1K1": "Z20",
"Z20K1": "Z24936",
"Z20K2": {
"Z1K1": "Z7",
"Z7K1": "Z24936",
"Z24936K1": {
"Z1K1": "Z20420",
"Z20420K1": {
"Z1K1": "Z20159",
"Z20159K1": {
"Z1K1": "Z17813",
"Z17813K1": "Z17814"
},
"Z20159K2": {
"Z1K1": "Z13518",
"Z13518K1": "2001"
}
},
"Z20420K2": {
"Z1K1": "Z20342",
"Z20342K1": {
"Z1K1": "Z16098",
"Z16098K1": "Z16101"
},
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "15"
}
}
}
},
"Z20K3": {
"Z1K1": "Z7",
"Z7K1": "Z20348",
"Z20348K2": {
"Z1K1": "Z20342",
"Z20342K1": "Z16101",
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "15"
}
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "15 Jan 2001"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
iqv2q7g42qu5bhmwrlwdvrnrk3dzfzg
Z24938
0
58073
191270
2025-06-06T12:12:53Z
Denny
81
191270
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24938"
},
"Z2K2": {
"Z1K1": "Z20",
"Z20K1": "Z24936",
"Z20K2": {
"Z1K1": "Z7",
"Z7K1": "Z24936",
"Z24936K1": {
"Z1K1": "Z20420",
"Z20420K1": {
"Z1K1": "Z20159",
"Z20159K1": {
"Z1K1": "Z17813",
"Z17813K1": "Z17814"
},
"Z20159K2": {
"Z1K1": "Z13518",
"Z13518K1": "2024"
}
},
"Z20420K2": {
"Z1K1": "Z20342",
"Z20342K1": {
"Z1K1": "Z16098",
"Z16098K1": "Z16102"
},
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "29"
}
}
}
},
"Z20K3": {
"Z1K1": "Z7",
"Z7K1": "Z20348",
"Z20348K2": {
"Z1K1": "Z20342",
"Z20342K1": "Z16102",
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "29"
}
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "29 Feb 2024"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
cdlv28kf81nvsn8j5p4gg4hx6okpvo3
Z24939
0
58074
191271
2025-06-06T12:13:46Z
Denny
81
191271
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24939"
},
"Z2K2": {
"Z1K1": "Z20",
"Z20K1": "Z24936",
"Z20K2": {
"Z1K1": "Z7",
"Z7K1": "Z24936",
"Z24936K1": {
"Z1K1": "Z20420",
"Z20420K1": {
"Z1K1": "Z20159",
"Z20159K1": {
"Z1K1": "Z17813",
"Z17813K1": "Z17815"
},
"Z20159K2": {
"Z1K1": "Z13518",
"Z13518K1": "45"
}
},
"Z20420K2": {
"Z1K1": "Z20342",
"Z20342K1": {
"Z1K1": "Z16098",
"Z16098K1": "Z16103"
},
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "15"
}
}
}
},
"Z20K3": {
"Z1K1": "Z7",
"Z7K1": "Z20348",
"Z20348K2": {
"Z1K1": "Z20342",
"Z20342K1": "Z16103",
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "15"
}
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "15 Mar 45 BC"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
4et75ch9tzppcdj6vvp4g5kaaqwokvm
Z24940
0
58075
191272
2025-06-06T12:14:41Z
Denny
81
191272
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24940"
},
"Z2K2": {
"Z1K1": "Z20",
"Z20K1": "Z24936",
"Z20K2": {
"Z1K1": "Z7",
"Z7K1": "Z24936",
"Z24936K1": {
"Z1K1": "Z20420",
"Z20420K1": {
"Z1K1": "Z20159",
"Z20159K1": {
"Z1K1": "Z17813",
"Z17813K1": "Z17815"
},
"Z20159K2": {
"Z1K1": "Z13518",
"Z13518K1": "65000000"
}
},
"Z20420K2": {
"Z1K1": "Z20342",
"Z20342K1": {
"Z1K1": "Z16098",
"Z16098K1": "Z16107"
},
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "1"
}
}
}
},
"Z20K3": {
"Z1K1": "Z7",
"Z7K1": "Z20348",
"Z20348K2": {
"Z1K1": "Z20342",
"Z20342K1": "Z16107",
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "1"
}
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "65 M ya"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
0tnp8plmxexdib6iod79hbyfobkbc1j
Z24941
0
58076
191273
2025-06-06T12:15:35Z
Denny
81
191273
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24941"
},
"Z2K2": {
"Z1K1": "Z20",
"Z20K1": "Z24936",
"Z20K2": {
"Z1K1": "Z7",
"Z7K1": "Z24936",
"Z24936K1": {
"Z1K1": "Z20420",
"Z20420K1": {
"Z1K1": "Z20159",
"Z20159K1": {
"Z1K1": "Z17813",
"Z17813K1": "Z17814"
},
"Z20159K2": {
"Z1K1": "Z13518",
"Z13518K1": "12850"
}
},
"Z20420K2": {
"Z1K1": "Z20342",
"Z20342K1": {
"Z1K1": "Z16098",
"Z16098K1": "Z16112"
},
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "31"
}
}
}
},
"Z20K3": {
"Z1K1": "Z7",
"Z7K1": "Z20348",
"Z20348K2": {
"Z1K1": "Z20342",
"Z20342K1": "Z16112",
"Z20342K2": {
"Z1K1": "Z13518",
"Z13518K1": "31"
}
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "31 Dec 12850"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
fnecopi9adjd6c8a7hsfgl2urvojrcl
Z24942
0
58077
191275
2025-06-06T12:18:18Z
Denny
81
191275
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24942"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z24936",
"Z14K2": {
"Z1K1": "Z7",
"Z7K1": "Z803",
"Z803K1": {
"Z1K1": "Z39",
"Z39K1": "Z20420K2"
},
"Z803K2": {
"Z1K1": "Z18",
"Z18K1": "Z24936K1"
}
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "value by key"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
3j166qgnvxn3a3hj79n6bphfuujcnq7
Z24943
0
58078
191277
2025-06-06T12:22:30Z
Denny
81
191277
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24943"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z24936",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z24936( Z24936K1 ) {\n\treturn {\n\t\t'K1': Z24936K1.K2,\n\t\t'K2': Z24936K1.K3\n\t};\n}"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
q2io0o7e9zu4ykhjk4k0iv7ynnkfneh
Z24944
0
58079
191279
2025-06-06T12:24:27Z
Denny
81
191279
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24944"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z24936",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z610",
"Z16K2": "def Z24936(Z24936K1):\n\treturn {\n\t\t'K1': Z24936K1['K2'],\n\t\t'K2': Z24936K1['K3']\n\t}"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11"
]
}
}
qdl0mtknlmhg1xw44wqqflacyxwxdq2
Z24945
0
58080
191289
2025-06-06T16:38:37Z
Dv103
11127
191289
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n function languageSpecificOptions(){\n\n\tdefineLiterals({\n\t\tJA:0n,\n\t\tFE:1n,\n\t\tMR:2n,\n\t\tAP:3n,\n\t\tMY:4n,\n\t\tJN:5n,\n\t\tJL:6n,\n\t\tAU:7n,\n\t\tSE:8n,\n\t\tOC:9n,\n\t\tNV:10n,\n\t\tDE:11n,\n\t\tjanuary:0n,\n\t\tfebruary:1n,\n\t\tmarch:2n,\n\t\tapril:3n,\n\t\tmay:4n,\n\t\tjune:5n,\n\t\tjuly:6n,\n\t\taugust:7n,\n\t\tseptember:8n,\n\t\toctober:9n,\n\t\tnovember:10n,\n\t\tdecember:11n\n\t},MONTH);\n\tdefineLiterals({\n\t\tad:1n,\n\t\tbc:-1n,\n\t\tbce:-1n,\n\t\tce:1n,\n\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\"ti zaamani\":1n,\n\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t},EPOCH);\n\t//forced as days\n\tdefineLiterals({\n\t\tdahinyini: 1n,\n\t\tdabaayi: 2n,\n\t\tdabaata: 3n,\n\t\tdabaanahi: 4n,\n\t\tdabaanu: 5n,\n\t\tdabaayɔbu: 6n,\n\t\tdabaapɔin: 7n,\n\t\tdabaanii: 8n,\n\t\tdabaawɔi: 9n,\n\t},DAY,NORMAL);\n\t//days or years\n\tdefineLiterals({\n\t\tyini:1n,\n\t\tayi:2n,\n\t\tata:3n,\n\t\tanahi:4n,\n\t\tanu:5n,\n\t\tayobu:6n,\n\t\tapɔi:7n,\n\t\tanii:8n,\n\t\tawei:9n,\n\t\t\"Pia\": 10n,\n\t\t\"piniyini\": 11n,\n\t\t\"pia ni yini\": 11n,\n\t\t\"pinaayi\": 12n,\n\t\t\"pia ni ayi\": 12n,\n\t\t\"pin ayi\": 12n,\n\t\t\"pinaata\": 13n,\n\t\t\"pin ata\": 13n,\n\t\t\"pia ni ata\": 13n,\n\t\t\"pinaanahi\": 14n,\n\t\t\"pia ni anahi\": 14n,\n\t\t\"pin anahi\": 14n,\n\t\t\"pinaanu\": 15n,\n\t\t\"pia ni anu\": 15n,\n\t\t\"pin anu\": 15n,\n\t\t\"pinaayobu\": 16n,\n\t\t\"pia ni ayobu\": 16n,\n\t\t\"pin ayobu\": 16n,\n\t\t\"pinaapɔin\": 17n,\n\t\t\"pia ni apɔi\": 17n,\n\t\t\"pin apɔi\": 17n,\n\t\t\"pishiayika\": 18n,\n\t\t\"pishi ayi ka\": 18n,\n\t\t\"pisiyinika\": 19n,\n\t\t\"pishi yini ka\": 19n,\n\t\t\"pishi\": 20n,\n\t\t\"pishi ni yini\": 21n,\n\t\t\"pishi ni ayi\": 22n,\n\t\t\"pishi ni ata\": 23n,\n\t\t\"Pishi ni anahi\": 24n,\n\t\t\"Pishi ni anu\": 25n,\n\t\t\"Pishi ni ayobu\": 26n,\n\t\t\"Pishi ni apɔin\": 27n,\n\t\t\"Pihita ayika\": 28n,\n\t\t\"Pihita ayi ka\": 28n,\n\t\t\"Pihitayinika\": 29n,\n\t\t\"Pihita yini ka\": 29n,\n\t\t\"pihita\": 30n,\n\t\t\"pihita ni yini\": 31n,\n\t},[DAY,YEAR],NORMAL);\n\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n }\n \n const DAY =0;\n const MONTH=1;\n const YEAR=2;\n const EPOCH=3;\n \n const BEFORE=10;\n const AFTER=20;\n const BEFORE_OR_AFTER=30;\n \n const LENIENT=true;\n const NORMAL=false;\n \n function defineLiterals(literals,meaning,compMode=LENIENT){\n \t\n }\n function defineLiteralFunction(f,meaning){\n \t\n }\n function defineConstraint(literals, meaning, position, compMode=NORMAL){\n \t\n }\n function defineConstraintFunction(f,meaning,position){\n \t\n }\n\t\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\t\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\t\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\t\n\tfunction extractMonthLiteral(s){\n\t\tfor (let m in monthNames){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn monthNames[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractEpoch(s,iFrom){\n\t\tfor (let m in eraNames){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\treturn [eraNames[m],target.length];\n\t\t\t}\n\t\t\t\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractOrdinal(s){\n\t\tfor (let m of ordinalStrings){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}\n\t\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\t\n\tfunction isYearIdentifier(s){\n\t\treturn yearIdentifiers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isDateForcer(s){\n\t\treturn dateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isAfterDateForcer(s){\n\t\treturn afterDateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\t\n\tfunction extractForcedDayLiteral(s){\n\t\tfor (let m in forcedDayLiterals){\n\t\t\tif (lessLenientComp(s,m)){\n\t\t\t\treturn forcedDayLiterals[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\t\n\tfunction extractNumberLiteral(s, iFrom){\n\t\tlet bestGuess=null;\n\t\tfor (let m in numberLiterals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lessLenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [numberLiterals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t}\n\t\treturn bestGuess;\n\t}\n\t\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\t\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\t\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\t\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\t\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\t\n\t //Wikifunctions.Debug(\"elements:\");\n\t //Wikifunctions.Debug(elements);\n\t\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar constraintsList=[];\n\tfor(let iAtt=0; iAtt\u003Celements.length; ++iAtt){\n\t\tlet p=[];\n\t\tlet n=extractNumber(elements[i]);\n\t\tlet _day=null;\n\t\tlet _month=null;\n\t\tlet _year=null;\n\t\tlet _epoch=null;\n\t\tlet e=extractEpoch(elements,i);\n\t\n\t\t//////////\n\t\t\n\t\tlet nl=extractNumberLiteral(elements,i);\n\t\tif (nl!=null){\n\t\t\tpossibilities.push([nl[0],null,isForcedDate ? null : nl[0],null]);\n\t\t\ti+=nl[1]-1;\n\t\t\tisForcedDate=false;\n\t\t\tcontinue;\n\t\t}\n\t\tlet fdl=extractForcedDayLiteral(elements[i]);\n\t\tif (fdl!=null){\n\t\t\tpossibilities.push([fdl,null,null,null]);\n\t\t\tisForcedDate=false;\n\t\t\tcontinue;\n\t\t}\n\t\tlet yi=isYearIdentifier(elements[i]);\n\t\tif (yi){\n\t\t\tyearIdentifierPos=possibilities.length;\n\t\t\tisForcedDate=false;\n\t\t\tcontinue;\n\t\t}\n\t\tlet adf=isAfterDateForcer(elements[i]);\n\t\tif (adf){\n\t\t\tdayIdentifierPos=possibilities.length;\n\t\t\tisForcedDate=false;\n\t\t\tcontinue;\n\t\t}\n\t\tlet df=isDateForcer(elements[i]);\n\t\tif (df){\n\t\t\tisForcedDate=true;\n\t\t\tcontinue;\n\t\t}\n\t\t\n\t\t\n\t\t//day\n\t\tp.push((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null);\n\t\t//month\n\t\tp.push((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n : (m!=null ? m : null));\n\t\t//year\n\t\tp.push(n!=null ? n : null);\n\t\t//epoch\n\t\tp.push(null);\n\t\t\n\t\tif (isForcedDate){\n\t\t\tp[1]=null;\n\t\t\tp[2]=null;\n\t\t\tp[3]=null;\n\t\t\tisForcedDate=false;\n\t\t} else if (forceToYear(elements[i])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\t// p[3]=null;\n\t\t}\n\t\t\n\t\tpossibilities.push(p);\n\t\t\n\t\t//Force ordinals to be dates\n\t\tif(extractOrdinal(elements[i])){\n\t\t\t// Wikifunctions.Debug(possibilities);\n\t\t\tpossibilities[possibilities.length-2][1]=null;\n\t\t\tpossibilities[possibilities.length-2][2]=null;\n\t\t\tpossibilities[possibilities.length-2][3]=null;\n\t\t}\n\t}\n\tif (yearIdentifierPos!=null){\n\t\tfor (let i=0; i\u003Cpossibilities.length; ++i){\n\t\t\tif (i!=yearIdentifierPos-1 \u0026\u0026 i!=yearIdentifierPos){\n\t\t\t\tpossibilities[i][2]=null;\n\t\t\t}\n\t\t}\n\t}\n\tif (dayIdentifierPos!=null){\n\t\tfor (let i=0; i\u003Cpossibilities.length; ++i){\n\t\t\tif (i!=dayIdentifierPos-1 \u0026\u0026 i!=dayIdentifierPos){\n\t\t\t\tpossibilities[i][0]=null;\n\t\t\t}\n\t\t}\n\t}\n\t\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\t\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\t\t\t\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\t\t\t\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
}
]
}
}
el5a77os7z7zbk2trh3yci1aw2mp0fq
191397
191289
2025-06-07T09:48:53Z
Dv103
11127
191397
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "\nfunction Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tJA:0n,\n\t\t\tFE:1n,\n\t\t\tMR:2n,\n\t\t\tAP:3n,\n\t\t\tMY:4n,\n\t\t\tJN:5n,\n\t\t\tJL:6n,\n\t\t\tAU:7n,\n\t\t\tSE:8n,\n\t\t\tOC:9n,\n\t\t\tNV:10n,\n\t\t\tDE:11n,\n\t\t\tjanuary:0n,\n\t\t\tfebruary:1n,\n\t\t\tmarch:2n,\n\t\t\tapril:3n,\n\t\t\tmay:4n,\n\t\t\tjune:5n,\n\t\t\tjuly:6n,\n\t\t\taugust:7n,\n\t\t\tseptember:8n,\n\t\t\toctober:9n,\n\t\t\tnovember:10n,\n\t\t\tdecember:11n\n\t\t},MONTH);\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\t\"ti zaamani\":1n,\n\t\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t\t},EPOCH);\n\t\t//forced as days\n\t\tdefineLiterals({\n\t\t\tdahinyini: 1n,\n\t\t\tdabaayi: 2n,\n\t\t\tdabaata: 3n,\n\t\t\tdabaanahi: 4n,\n\t\t\tdabaanu: 5n,\n\t\t\tdabaayɔbu: 6n,\n\t\t\tdabaapɔin: 7n,\n\t\t\tdabaanii: 8n,\n\t\t\tdabaawɔi: 9n,\n\t\t},DAY,NORMAL);\n\t\t//days or years\n\t\tdefineLiterals({\n\t\t\tyini:1n,\n\t\t\tayi:2n,\n\t\t\tata:3n,\n\t\t\tanahi:4n,\n\t\t\tanu:5n,\n\t\t\tayobu:6n,\n\t\t\tapɔi:7n,\n\t\t\tanii:8n,\n\t\t\tawei:9n,\n\t\t\t\"Pia\": 10n,\n\t\t\t\"piniyini\": 11n,\n\t\t\t\"pia ni yini\": 11n,\n\t\t\t\"pinaayi\": 12n,\n\t\t\t\"pia ni ayi\": 12n,\n\t\t\t\"pin ayi\": 12n,\n\t\t\t\"pinaata\": 13n,\n\t\t\t\"pin ata\": 13n,\n\t\t\t\"pia ni ata\": 13n,\n\t\t\t\"pinaanahi\": 14n,\n\t\t\t\"pia ni anahi\": 14n,\n\t\t\t\"pin anahi\": 14n,\n\t\t\t\"pinaanu\": 15n,\n\t\t\t\"pia ni anu\": 15n,\n\t\t\t\"pin anu\": 15n,\n\t\t\t\"pinaayobu\": 16n,\n\t\t\t\"pia ni ayobu\": 16n,\n\t\t\t\"pin ayobu\": 16n,\n\t\t\t\"pinaapɔin\": 17n,\n\t\t\t\"pia ni apɔi\": 17n,\n\t\t\t\"pin apɔi\": 17n,\n\t\t\t\"pishiayika\": 18n,\n\t\t\t\"pishi ayi ka\": 18n,\n\t\t\t\"pisiyinika\": 19n,\n\t\t\t\"pishi yini ka\": 19n,\n\t\t\t\"pishi\": 20n,\n\t\t\t\"pishi ni yini\": 21n,\n\t\t\t\"pishi ni ayi\": 22n,\n\t\t\t\"pishi ni ata\": 23n,\n\t\t\t\"Pishi ni anahi\": 24n,\n\t\t\t\"Pishi ni anu\": 25n,\n\t\t\t\"Pishi ni ayobu\": 26n,\n\t\t\t\"Pishi ni apɔin\": 27n,\n\t\t\t\"Pihita ayika\": 28n,\n\t\t\t\"Pihita ayi ka\": 28n,\n\t\t\t\"Pihitayinika\": 29n,\n\t\t\t\"Pihita yini ka\": 29n,\n\t\t\t\"pihita\": 30n,\n\t\t\t\"pihita ni yini\": 31n,\n\t\t},[DAY,YEAR],NORMAL);\n\t\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\t\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\t\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\t\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [numberLiterals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [numberLiterals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess[1];\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess[1];\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\tfunction extractMonthLiteral(s){\n\t\tfor (let m in monthNames){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn monthNames[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractEpoch(s,iFrom){\n\t\tfor (let m in eraNames){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\treturn [eraNames[m],target.length];\n\t\t\t}\n\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractOrdinal(s){\n\t\tfor (let m of ordinalStrings){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\tfunction isYearIdentifier(s){\n\t\treturn yearIdentifiers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isDateForcer(s){\n\t\treturn dateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isAfterDateForcer(s){\n\t\treturn afterDateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\n\tfunction extractForcedDayLiteral(s){\n\t\tfor (let m in forcedDayLiterals){\n\t\t\tif (lessLenientComp(s,m)){\n\t\t\t\treturn forcedDayLiterals[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\n\tfunction extractNumberLiteral(s, iFrom){\n\t\tlet bestGuess=null;\n\t\tfor (let m in numberLiterals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lessLenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [numberLiterals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\treturn bestGuess;\n\t}\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[i]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[i])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tpossibilities.push(p);\n\t}\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c in _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m in c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
}
]
}
}
de63srpow8dy96uat4qi64m9ymp3me1
191398
191397
2025-06-07T10:08:54Z
Dv103
11127
191398
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "\nfunction Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tJA:0n,\n\t\t\tFE:1n,\n\t\t\tMR:2n,\n\t\t\tAP:3n,\n\t\t\tMY:4n,\n\t\t\tJN:5n,\n\t\t\tJL:6n,\n\t\t\tAU:7n,\n\t\t\tSE:8n,\n\t\t\tOC:9n,\n\t\t\tNV:10n,\n\t\t\tDE:11n,\n\t\t\tjanuary:0n,\n\t\t\tfebruary:1n,\n\t\t\tmarch:2n,\n\t\t\tapril:3n,\n\t\t\tmay:4n,\n\t\t\tjune:5n,\n\t\t\tjuly:6n,\n\t\t\taugust:7n,\n\t\t\tseptember:8n,\n\t\t\toctober:9n,\n\t\t\tnovember:10n,\n\t\t\tdecember:11n\n\t\t},MONTH);\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\t\"ti zaamani\":1n,\n\t\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t\t},EPOCH);\n\t\t//forced as days\n\t\tdefineLiterals({\n\t\t\tdahinyini: 1n,\n\t\t\tdabaayi: 2n,\n\t\t\tdabaata: 3n,\n\t\t\tdabaanahi: 4n,\n\t\t\tdabaanu: 5n,\n\t\t\tdabaayɔbu: 6n,\n\t\t\tdabaapɔin: 7n,\n\t\t\tdabaanii: 8n,\n\t\t\tdabaawɔi: 9n,\n\t\t},DAY,NORMAL);\n\t\t//days or years\n\t\tdefineLiterals({\n\t\t\tyini:1n,\n\t\t\tayi:2n,\n\t\t\tata:3n,\n\t\t\tanahi:4n,\n\t\t\tanu:5n,\n\t\t\tayobu:6n,\n\t\t\tapɔi:7n,\n\t\t\tanii:8n,\n\t\t\tawei:9n,\n\t\t\t\"Pia\": 10n,\n\t\t\t\"piniyini\": 11n,\n\t\t\t\"pia ni yini\": 11n,\n\t\t\t\"pinaayi\": 12n,\n\t\t\t\"pia ni ayi\": 12n,\n\t\t\t\"pin ayi\": 12n,\n\t\t\t\"pinaata\": 13n,\n\t\t\t\"pin ata\": 13n,\n\t\t\t\"pia ni ata\": 13n,\n\t\t\t\"pinaanahi\": 14n,\n\t\t\t\"pia ni anahi\": 14n,\n\t\t\t\"pin anahi\": 14n,\n\t\t\t\"pinaanu\": 15n,\n\t\t\t\"pia ni anu\": 15n,\n\t\t\t\"pin anu\": 15n,\n\t\t\t\"pinaayobu\": 16n,\n\t\t\t\"pia ni ayobu\": 16n,\n\t\t\t\"pin ayobu\": 16n,\n\t\t\t\"pinaapɔin\": 17n,\n\t\t\t\"pia ni apɔi\": 17n,\n\t\t\t\"pin apɔi\": 17n,\n\t\t\t\"pishiayika\": 18n,\n\t\t\t\"pishi ayi ka\": 18n,\n\t\t\t\"pisiyinika\": 19n,\n\t\t\t\"pishi yini ka\": 19n,\n\t\t\t\"pishi\": 20n,\n\t\t\t\"pishi ni yini\": 21n,\n\t\t\t\"pishi ni ayi\": 22n,\n\t\t\t\"pishi ni ata\": 23n,\n\t\t\t\"Pishi ni anahi\": 24n,\n\t\t\t\"Pishi ni anu\": 25n,\n\t\t\t\"Pishi ni ayobu\": 26n,\n\t\t\t\"Pishi ni apɔin\": 27n,\n\t\t\t\"Pihita ayika\": 28n,\n\t\t\t\"Pihita ayi ka\": 28n,\n\t\t\t\"Pihitayinika\": 29n,\n\t\t\t\"Pihita yini ka\": 29n,\n\t\t\t\"pihita\": 30n,\n\t\t\t\"pihita ni yini\": 31n,\n\t\t},[DAY,YEAR],NORMAL);\n\t\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\t\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\t\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\t\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tWikifunctions.Debug(\"\"+literals);\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\t\tWikifunctions.Debug(\"bestGuess: \"+bestGuess);\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\tfunction extractMonthLiteral(s){\n\t\tfor (let m in monthNames){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn monthNames[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractEpoch(s,iFrom){\n\t\tfor (let m in eraNames){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\treturn [eraNames[m],target.length];\n\t\t\t}\n\n\t\t}\n\t\treturn null;\n\t}\n\tfunction extractOrdinal(s){\n\t\tfor (let m of ordinalStrings){\n\t\t\tif (lenientComp(s,m)){\n\t\t\t\treturn true;\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\tfunction isYearIdentifier(s){\n\t\treturn yearIdentifiers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isDateForcer(s){\n\t\treturn dateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\tfunction isAfterDateForcer(s){\n\t\treturn afterDateForcers.find((v)=\u003E(lessLenientComp(s,v))) != undefined;\n\t}\n\n\tfunction extractForcedDayLiteral(s){\n\t\tfor (let m in forcedDayLiterals){\n\t\t\tif (lessLenientComp(s,m)){\n\t\t\t\treturn forcedDayLiterals[m];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\n\tfunction extractNumberLiteral(s, iFrom){\n\t\tlet bestGuess=null;\n\t\tfor (let m in numberLiterals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (s[iFrom+t]==undefined || !lessLenientComp(s[iFrom+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [numberLiterals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\treturn bestGuess;\n\t}\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\tWikifunctions.Debug(\"Constrains list: \"+_constraintsList);\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
}
]
}
}
02sv1hj21uefh3t1vuehi2dvogmvyy6
191399
191398
2025-06-07T10:16:52Z
Dv103
11127
191399
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "\nfunction Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tJA:0n,\n\t\t\tFE:1n,\n\t\t\tMR:2n,\n\t\t\tAP:3n,\n\t\t\tMY:4n,\n\t\t\tJN:5n,\n\t\t\tJL:6n,\n\t\t\tAU:7n,\n\t\t\tSE:8n,\n\t\t\tOC:9n,\n\t\t\tNV:10n,\n\t\t\tDE:11n,\n\t\t\tjanuary:0n,\n\t\t\tfebruary:1n,\n\t\t\tmarch:2n,\n\t\t\tapril:3n,\n\t\t\tmay:4n,\n\t\t\tjune:5n,\n\t\t\tjuly:6n,\n\t\t\taugust:7n,\n\t\t\tseptember:8n,\n\t\t\toctober:9n,\n\t\t\tnovember:10n,\n\t\t\tdecember:11n\n\t\t},MONTH);\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\t\"ti zaamani\":1n,\n\t\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t\t},EPOCH);\n\t\t//forced as days\n\t\tdefineLiterals({\n\t\t\tdahinyini: 1n,\n\t\t\tdabaayi: 2n,\n\t\t\tdabaata: 3n,\n\t\t\tdabaanahi: 4n,\n\t\t\tdabaanu: 5n,\n\t\t\tdabaayɔbu: 6n,\n\t\t\tdabaapɔin: 7n,\n\t\t\tdabaanii: 8n,\n\t\t\tdabaawɔi: 9n,\n\t\t},DAY,NORMAL);\n\t\t//days or years\n\t\tdefineLiterals({\n\t\t\tyini:1n,\n\t\t\tayi:2n,\n\t\t\tata:3n,\n\t\t\tanahi:4n,\n\t\t\tanu:5n,\n\t\t\tayobu:6n,\n\t\t\tapɔi:7n,\n\t\t\tanii:8n,\n\t\t\tawei:9n,\n\t\t\t\"Pia\": 10n,\n\t\t\t\"piniyini\": 11n,\n\t\t\t\"pia ni yini\": 11n,\n\t\t\t\"pinaayi\": 12n,\n\t\t\t\"pia ni ayi\": 12n,\n\t\t\t\"pin ayi\": 12n,\n\t\t\t\"pinaata\": 13n,\n\t\t\t\"pin ata\": 13n,\n\t\t\t\"pia ni ata\": 13n,\n\t\t\t\"pinaanahi\": 14n,\n\t\t\t\"pia ni anahi\": 14n,\n\t\t\t\"pin anahi\": 14n,\n\t\t\t\"pinaanu\": 15n,\n\t\t\t\"pia ni anu\": 15n,\n\t\t\t\"pin anu\": 15n,\n\t\t\t\"pinaayobu\": 16n,\n\t\t\t\"pia ni ayobu\": 16n,\n\t\t\t\"pin ayobu\": 16n,\n\t\t\t\"pinaapɔin\": 17n,\n\t\t\t\"pia ni apɔi\": 17n,\n\t\t\t\"pin apɔi\": 17n,\n\t\t\t\"pishiayika\": 18n,\n\t\t\t\"pishi ayi ka\": 18n,\n\t\t\t\"pisiyinika\": 19n,\n\t\t\t\"pishi yini ka\": 19n,\n\t\t\t\"pishi\": 20n,\n\t\t\t\"pishi ni yini\": 21n,\n\t\t\t\"pishi ni ayi\": 22n,\n\t\t\t\"pishi ni ata\": 23n,\n\t\t\t\"Pishi ni anahi\": 24n,\n\t\t\t\"Pishi ni anu\": 25n,\n\t\t\t\"Pishi ni ayobu\": 26n,\n\t\t\t\"Pishi ni apɔin\": 27n,\n\t\t\t\"Pihita ayika\": 28n,\n\t\t\t\"Pihita ayi ka\": 28n,\n\t\t\t\"Pihitayinika\": 29n,\n\t\t\t\"Pihita yini ka\": 29n,\n\t\t\t\"pihita\": 30n,\n\t\t\t\"pihita ni yini\": 31n,\n\t\t},[DAY,YEAR],NORMAL);\n\t\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\t\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\t\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\t\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
}
]
}
}
j9okgrywqpqgafqo1mkrz18b2jtkkwb
191401
191399
2025-06-07T10:19:43Z
Dv103
11127
+en
191401
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "\nfunction Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tJA:0n,\n\t\t\tFE:1n,\n\t\t\tMR:2n,\n\t\t\tAP:3n,\n\t\t\tMY:4n,\n\t\t\tJN:5n,\n\t\t\tJL:6n,\n\t\t\tAU:7n,\n\t\t\tSE:8n,\n\t\t\tOC:9n,\n\t\t\tNV:10n,\n\t\t\tDE:11n,\n\t\t\tjanuary:0n,\n\t\t\tfebruary:1n,\n\t\t\tmarch:2n,\n\t\t\tapril:3n,\n\t\t\tmay:4n,\n\t\t\tjune:5n,\n\t\t\tjuly:6n,\n\t\t\taugust:7n,\n\t\t\tseptember:8n,\n\t\t\toctober:9n,\n\t\t\tnovember:10n,\n\t\t\tdecember:11n\n\t\t},MONTH);\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\t\"ti zaamani\":1n,\n\t\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t\t},EPOCH);\n\t\t//forced as days\n\t\tdefineLiterals({\n\t\t\tdahinyini: 1n,\n\t\t\tdabaayi: 2n,\n\t\t\tdabaata: 3n,\n\t\t\tdabaanahi: 4n,\n\t\t\tdabaanu: 5n,\n\t\t\tdabaayɔbu: 6n,\n\t\t\tdabaapɔin: 7n,\n\t\t\tdabaanii: 8n,\n\t\t\tdabaawɔi: 9n,\n\t\t},DAY,NORMAL);\n\t\t//days or years\n\t\tdefineLiterals({\n\t\t\tyini:1n,\n\t\t\tayi:2n,\n\t\t\tata:3n,\n\t\t\tanahi:4n,\n\t\t\tanu:5n,\n\t\t\tayobu:6n,\n\t\t\tapɔi:7n,\n\t\t\tanii:8n,\n\t\t\tawei:9n,\n\t\t\t\"Pia\": 10n,\n\t\t\t\"piniyini\": 11n,\n\t\t\t\"pia ni yini\": 11n,\n\t\t\t\"pinaayi\": 12n,\n\t\t\t\"pia ni ayi\": 12n,\n\t\t\t\"pin ayi\": 12n,\n\t\t\t\"pinaata\": 13n,\n\t\t\t\"pin ata\": 13n,\n\t\t\t\"pia ni ata\": 13n,\n\t\t\t\"pinaanahi\": 14n,\n\t\t\t\"pia ni anahi\": 14n,\n\t\t\t\"pin anahi\": 14n,\n\t\t\t\"pinaanu\": 15n,\n\t\t\t\"pia ni anu\": 15n,\n\t\t\t\"pin anu\": 15n,\n\t\t\t\"pinaayobu\": 16n,\n\t\t\t\"pia ni ayobu\": 16n,\n\t\t\t\"pin ayobu\": 16n,\n\t\t\t\"pinaapɔin\": 17n,\n\t\t\t\"pia ni apɔi\": 17n,\n\t\t\t\"pin apɔi\": 17n,\n\t\t\t\"pishiayika\": 18n,\n\t\t\t\"pishi ayi ka\": 18n,\n\t\t\t\"pisiyinika\": 19n,\n\t\t\t\"pishi yini ka\": 19n,\n\t\t\t\"pishi\": 20n,\n\t\t\t\"pishi ni yini\": 21n,\n\t\t\t\"pishi ni ayi\": 22n,\n\t\t\t\"pishi ni ata\": 23n,\n\t\t\t\"Pishi ni anahi\": 24n,\n\t\t\t\"Pishi ni anu\": 25n,\n\t\t\t\"Pishi ni ayobu\": 26n,\n\t\t\t\"Pishi ni apɔin\": 27n,\n\t\t\t\"Pihita ayika\": 28n,\n\t\t\t\"Pihita ayi ka\": 28n,\n\t\t\t\"Pihitayinika\": 29n,\n\t\t\t\"Pihita yini ka\": 29n,\n\t\t\t\"pihita\": 30n,\n\t\t\t\"pihita ni yini\": 31n,\n\t\t},[DAY,YEAR],NORMAL);\n\t\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\t\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\t\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\t\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, en, dag (mdy), js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
t5aiwzem4ulm5bp2ock26vrxc7v4juj
191406
191401
2025-06-07T10:29:47Z
Dv103
11127
191406
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24945"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23990",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "\nfunction Z23990( Z23990K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"mdye\",\"mdey\",\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"yedm\",\"eydm\"];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tJA:0n,\n\t\t\tFE:1n,\n\t\t\tMR:2n,\n\t\t\tAP:3n,\n\t\t\tMY:4n,\n\t\t\tJN:5n,\n\t\t\tJL:6n,\n\t\t\tAU:7n,\n\t\t\tSE:8n,\n\t\t\tOC:9n,\n\t\t\tNV:10n,\n\t\t\tDE:11n,\n\t\t\tjanuary:0n,\n\t\t\tfebruary:1n,\n\t\t\tmarch:2n,\n\t\t\tapril:3n,\n\t\t\tmay:4n,\n\t\t\tjune:5n,\n\t\t\tjuly:6n,\n\t\t\taugust:7n,\n\t\t\tseptember:8n,\n\t\t\toctober:9n,\n\t\t\tnovember:10n,\n\t\t\tdecember:11n\n\t\t},MONTH);\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t\t\"pɔi anabi Yisa dɔɣam\":-1n,\n\t\t\t\"ti zaamani\":1n,\n\t\t\t\"Anabi Yisa kpibu nyaaga\":1n\n\t\t},EPOCH);\n\t\t//forced as days\n\t\tdefineLiterals({\n\t\t\tdahinyini: 1n,\n\t\t\tdabaayi: 2n,\n\t\t\tdabaata: 3n,\n\t\t\tdabaanahi: 4n,\n\t\t\tdabaanu: 5n,\n\t\t\tdabaayɔbu: 6n,\n\t\t\tdabaapɔin: 7n,\n\t\t\tdabaanii: 8n,\n\t\t\tdabaawɔi: 9n,\n\t\t},DAY,NORMAL);\n\t\t//days or years\n\t\tdefineLiterals({\n\t\t\tyini:1n,\n\t\t\tayi:2n,\n\t\t\tata:3n,\n\t\t\tanahi:4n,\n\t\t\tanu:5n,\n\t\t\tayobu:6n,\n\t\t\tapɔi:7n,\n\t\t\tanii:8n,\n\t\t\tawei:9n,\n\t\t\t\"Pia\": 10n,\n\t\t\t\"piniyini\": 11n,\n\t\t\t\"pia ni yini\": 11n,\n\t\t\t\"pinaayi\": 12n,\n\t\t\t\"pia ni ayi\": 12n,\n\t\t\t\"pin ayi\": 12n,\n\t\t\t\"pinaata\": 13n,\n\t\t\t\"pin ata\": 13n,\n\t\t\t\"pia ni ata\": 13n,\n\t\t\t\"pinaanahi\": 14n,\n\t\t\t\"pia ni anahi\": 14n,\n\t\t\t\"pin anahi\": 14n,\n\t\t\t\"pinaanu\": 15n,\n\t\t\t\"pia ni anu\": 15n,\n\t\t\t\"pin anu\": 15n,\n\t\t\t\"pinaayobu\": 16n,\n\t\t\t\"pia ni ayobu\": 16n,\n\t\t\t\"pin ayobu\": 16n,\n\t\t\t\"pinaapɔin\": 17n,\n\t\t\t\"pia ni apɔi\": 17n,\n\t\t\t\"pin apɔi\": 17n,\n\t\t\t\"pishiayika\": 18n,\n\t\t\t\"pishi ayi ka\": 18n,\n\t\t\t\"pisiyinika\": 19n,\n\t\t\t\"pishi yini ka\": 19n,\n\t\t\t\"pishi\": 20n,\n\t\t\t\"pishi ni yini\": 21n,\n\t\t\t\"pishi ni ayi\": 22n,\n\t\t\t\"pishi ni ata\": 23n,\n\t\t\t\"Pishi ni anahi\": 24n,\n\t\t\t\"Pishi ni anu\": 25n,\n\t\t\t\"Pishi ni ayobu\": 26n,\n\t\t\t\"Pishi ni apɔin\": 27n,\n\t\t\t\"Pihita ayika\": 28n,\n\t\t\t\"Pihita ayi ka\": 28n,\n\t\t\t\"Pihitayinika\": 29n,\n\t\t\t\"Pihita yini ka\": 29n,\n\t\t\t\"pihita\": 30n,\n\t\t\t\"pihita ni yini\": 31n,\n\t\t},[DAY,YEAR],NORMAL);\n\t\tdefineConstraint([\"st\",\"nd\",\"rd\",\"th\"],DAY,AFTER);\t//forced after a day\n\t\tdefineConstraint([\"yuuni\"],YEAR, BEFORE_OR_AFTER);\t\t//forced before or after a year\n\t\tdefineConstraint([\"biɛɣu\"],DAY, BEFORE);\t\t\t//forced before a day\n\t\tdefineConstraint([\"dali\"],DAY, BEFORE_OR_AFTER);\t\t//forced before or after a day\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "refactoring, js"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, en, dag (mdy), js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1787",
"Z11K2": "Per migliore flessibilità con altre lingue"
},
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
dggr2i1j4i33zsdmmiui5dc44lyge12
Wikifunctions:Status updates/2025-06-06
4
58082
191293
2025-06-06T18:33:33Z
DVrandecic (WMF)
7
Created page with "=== Fresh Functions weekly: 14 new Functions === This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing! * {{Z|Z24876}} * {{Z|Z24880}} * {{Z|Z24884}} * {{Z|Z24901}} * {{Z|Z24846}} * {{Z|Z24849}} * {{Z|Z24936}} A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sort..."
191293
wikitext
text/x-wiki
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24901}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24936}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
4x07z9x6am06phq233sxe9d9a9d8fsf
191294
191293
2025-06-06T18:34:20Z
DVrandecic (WMF)
7
191294
wikitext
text/x-wiki
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
6uctfuku9rww89a3rdglbh1k675s341
191295
191294
2025-06-06T18:36:40Z
DVrandecic (WMF)
7
191295
wikitext
text/x-wiki
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
gew0cs2r9tmzve8vjpmobyjvmj44b1e
191296
191295
2025-06-06T18:40:48Z
DVrandecic (WMF)
7
191296
wikitext
text/x-wiki
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
l0pw0e348j4heakxt70326toa5f3ggu
191297
191296
2025-06-06T18:42:37Z
DVrandecic (WMF)
7
191297
wikitext
text/x-wiki
=== Where will Abstract Content go? ===
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
5ta4m63wgqg1jvaylotsb013jly4b2g
191298
191297
2025-06-06T19:18:24Z
Jdforrester (WMF)
4
Add update navbar, translate outer tag.
191298
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate>Previous update</translate>
| prev = 2025-05-29
| nextlabel = <translate>Next update</translate>
| next =
}}
<translate>
=== Where will Abstract Content go? ===
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</translate>
3dg74cpx85urwb278vpdmmhdkdep1m5
191304
191298
2025-06-06T19:19:34Z
Jdforrester (WMF)
4
More whitespace.
191304
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate>Previous update</translate>
| prev = 2025-05-29
| nextlabel = <translate>Next update</translate>
| next =
}}
<translate>
=== Where will Abstract Content go? ===
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</translate>
qbxixqwor61sd27pj77rald6vt11cok
191305
191304
2025-06-06T19:19:57Z
Jdforrester (WMF)
4
Missed one!
191305
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate>Previous update</translate>
| prev = 2025-05-29
| nextlabel = <translate>Next update</translate>
| next =
}}
<translate>
=== Where will Abstract Content go? ===
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</translate>
9ewyec839fgg9lj5sq4d5a76mzwttyu
191306
191305
2025-06-06T19:20:04Z
Jdforrester (WMF)
4
Marked this version for translation
191306
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate><!--T:1--> Previous update</translate>
| prev = 2025-05-29
| nextlabel = <translate><!--T:2--> Next update</translate>
| next =
}}
<translate>
=== Where will Abstract Content go? === <!--T:3-->
<!--T:4-->
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
<!--T:5-->
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
<!--T:6-->
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
<!--T:7-->
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
<!--T:8-->
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
<!--T:9-->
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
<!--T:10-->
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
<!--T:11-->
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
<!--T:12-->
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
<!--T:13-->
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
<!--T:14-->
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software === <!--T:15-->
<!--T:16-->
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
<!--T:17-->
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
<!--T:18-->
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
<!--T:19-->
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
<!--T:20-->
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
<!--T:21-->
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
<!--T:22-->
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
<!--T:23-->
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project === <!--T:24-->
<!--T:25-->
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available === <!--T:26-->
<!--T:27-->
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions === <!--T:28-->
<!--T:29-->
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
<!--T:30-->
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
<!--T:31-->
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</translate>
1stsabjh423imgi0pvo2df9geq89or2
191393
191306
2025-06-07T05:35:00Z
Eduardogobi
2982
191393
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <translate><!--T:1--> Previous update</translate>
| prev = 2025-05-29
| nextlabel = <translate><!--T:2--> Next update</translate>
| next =
}}
<translate>
=== Where will Abstract Content go? === <!--T:3-->
<!--T:4-->
We are currently running [[<tvar name=1>:meta:Special:MyLanguage/Abstract Wikipedia/Location of Abstract Content</tvar>|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
<!--T:5-->
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
<!--T:6-->
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
<!--T:7-->
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
<!--T:8-->
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
<!--T:9-->
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
<!--T:10-->
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
<!--T:11-->
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
<!--T:12-->
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
<!--T:13-->
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
<!--T:14-->
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software === <!--T:15-->
<!--T:16-->
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
<!--T:17-->
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
<!--T:18-->
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
<!--T:19-->
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
<!--T:20-->
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
<!--T:21-->
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
<!--T:22-->
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
<!--T:23-->
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project === <!--T:24-->
<!--T:25-->
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available === <!--T:26-->
<!--T:27-->
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions === <!--T:28-->
<!--T:29-->
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
<!--T:30-->
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
<!--T:31-->
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</translate>
eb24yxyy0x89p53vt9nizwmyq9ltnxq
Translations:Wikifunctions:Status updates/2025-06-06/Page display title/en
1198
58083
191307
2025-06-06T19:20:04Z
FuzzyBot
207
Importing a new version from external source
191307
wikitext
text/x-wiki
Wikifunctions:Status updates/2025-06-06
sd0o0k68d6bfddp5yvxu3njvblt7tl0
Translations:Wikifunctions:Status updates/2025-06-06/1/en
1198
58084
191308
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191308
wikitext
text/x-wiki
Previous update
9vg8ik5cl54jflmg4oolhxg71iuevnn
Translations:Wikifunctions:Status updates/2025-06-06/2/en
1198
58085
191309
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191309
wikitext
text/x-wiki
Next update
c8d3p3ibb7xo6gugsz9ua4kzsie95pa
Translations:Wikifunctions:Status updates/2025-06-06/3/en
1198
58086
191310
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191310
wikitext
text/x-wiki
=== Where will Abstract Content go? ===
trn5rmhslty30ardgbyjd9u4ney6nev
Translations:Wikifunctions:Status updates/2025-06-06/4/en
1198
58087
191311
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191311
wikitext
text/x-wiki
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
4aq577fzk2jugrh6jfw9sr2poanzcpy
Translations:Wikifunctions:Status updates/2025-06-06/5/en
1198
58088
191312
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191312
wikitext
text/x-wiki
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
oo1gepoy2ge6sf1gablm7oxusjoxdlc
Translations:Wikifunctions:Status updates/2025-06-06/6/en
1198
58089
191313
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191313
wikitext
text/x-wiki
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
2jriwbuqeifxsupq15wwlv1rmtaeez3
Translations:Wikifunctions:Status updates/2025-06-06/7/en
1198
58090
191314
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191314
wikitext
text/x-wiki
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
ap2sjievrtjwokl90wcoqr8u94iynnf
Translations:Wikifunctions:Status updates/2025-06-06/8/en
1198
58091
191315
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191315
wikitext
text/x-wiki
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
b5fnmov1n6k4qnuxxiiys0dlj2hkvuw
Translations:Wikifunctions:Status updates/2025-06-06/9/en
1198
58092
191316
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191316
wikitext
text/x-wiki
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
gb8vopomxi7ivqebm71og3kbvkhh8vu
Translations:Wikifunctions:Status updates/2025-06-06/10/en
1198
58093
191317
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191317
wikitext
text/x-wiki
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
q2w38mhdb4r424lonry1s3970kjjwgd
Translations:Wikifunctions:Status updates/2025-06-06/11/en
1198
58094
191318
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191318
wikitext
text/x-wiki
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
9fkz7mjpp2yhha6qecbst5c090w3hee
Translations:Wikifunctions:Status updates/2025-06-06/12/en
1198
58095
191319
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191319
wikitext
text/x-wiki
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
mt351l1mh3ijgipao6l42axealk9qmt
Translations:Wikifunctions:Status updates/2025-06-06/13/en
1198
58096
191320
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191320
wikitext
text/x-wiki
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
q8hm6ykl6i3ldyuft2hih39eiun5mjg
Translations:Wikifunctions:Status updates/2025-06-06/14/en
1198
58097
191321
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191321
wikitext
text/x-wiki
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
se21pkpkv93sto08r71c8svxwaslwa0
Translations:Wikifunctions:Status updates/2025-06-06/15/en
1198
58098
191322
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191322
wikitext
text/x-wiki
=== Recent Changes in the software ===
0wkgk5zbnz8yeis277kmszjppej85s4
Translations:Wikifunctions:Status updates/2025-06-06/16/en
1198
58099
191323
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191323
wikitext
text/x-wiki
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
6ouff76webtk8kfbhyde3h71t9jmpu3
Translations:Wikifunctions:Status updates/2025-06-06/17/en
1198
58100
191324
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191324
wikitext
text/x-wiki
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
o4ztoxuwjwedbx41aqkyz78ouqbww95
Translations:Wikifunctions:Status updates/2025-06-06/18/en
1198
58101
191325
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191325
wikitext
text/x-wiki
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
4atd3vfen7n1bgpqy5finv3o4so8sja
Translations:Wikifunctions:Status updates/2025-06-06/19/en
1198
58102
191326
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191326
wikitext
text/x-wiki
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
lu0zo4u0xrypsf6ms6x2vp50vpjzkux
Translations:Wikifunctions:Status updates/2025-06-06/20/en
1198
58103
191327
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191327
wikitext
text/x-wiki
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
gi8dnaobfjthrw2c4ak6pu08xc7cubs
Translations:Wikifunctions:Status updates/2025-06-06/21/en
1198
58104
191328
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191328
wikitext
text/x-wiki
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
b1xpdhkbg64gwuyso1k14uo5phkz55a
Translations:Wikifunctions:Status updates/2025-06-06/22/en
1198
58105
191329
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191329
wikitext
text/x-wiki
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
30rz35viarz7wynn5u90cxwe4z9g3s7
Translations:Wikifunctions:Status updates/2025-06-06/23/en
1198
58106
191330
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191330
wikitext
text/x-wiki
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
7miz87ndq8szshs35dfxo6f1x0aqltt
Translations:Wikifunctions:Status updates/2025-06-06/24/en
1198
58107
191331
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191331
wikitext
text/x-wiki
=== Recording of presentation at Wikidata and Sister Project ===
0q92m2tg4awcxo47x7551tuzoad7bal
Translations:Wikifunctions:Status updates/2025-06-06/25/en
1198
58108
191332
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191332
wikitext
text/x-wiki
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
1vlcnc6mdtfvezrltsmgas178gux639
Translations:Wikifunctions:Status updates/2025-06-06/26/en
1198
58109
191333
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191333
wikitext
text/x-wiki
=== Recording of last Volunteers’ Corner available ===
arszpw8pl7x2814fwgihcn8zajkesx8
Translations:Wikifunctions:Status updates/2025-06-06/27/en
1198
58110
191334
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191334
wikitext
text/x-wiki
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
h1fjjngeacjxa64s6o7fsu6q56g2eeq
Translations:Wikifunctions:Status updates/2025-06-06/28/en
1198
58111
191335
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191335
wikitext
text/x-wiki
=== Fresh Functions weekly: 14 new Functions ===
dj1a85omen0d3u3x8ko4knvj15wg7ce
Translations:Wikifunctions:Status updates/2025-06-06/29/en
1198
58112
191336
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191336
wikitext
text/x-wiki
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
0d2bwjqm5svjypvjjkgdo7slg4oxalf
Translations:Wikifunctions:Status updates/2025-06-06/30/en
1198
58113
191337
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191337
wikitext
text/x-wiki
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
7qxpumxk9tbvo841rwyc8d8ebrbrfsv
Translations:Wikifunctions:Status updates/2025-06-06/31/en
1198
58114
191338
2025-06-06T19:20:05Z
FuzzyBot
207
Importing a new version from external source
191338
wikitext
text/x-wiki
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
bkq4fnt0021dhyo86m23si9eplwhv2n
Wikifunctions:Status updates/2025-06-06/en
4
58115
191339
2025-06-06T19:20:07Z
FuzzyBot
207
Updating to match new version of source page
191339
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Previous update
| prev = 2025-05-29
| nextlabel = Next update
| next =
}}
=== Where will Abstract Content go? ===
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
=== Recent Changes in the software ===
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
=== Recording of presentation at Wikidata and Sister Project ===
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
=== Recording of last Volunteers’ Corner available ===
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
=== Fresh Functions weekly: 14 new Functions ===
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
1jewfbecsla9v7jlw1koon0idy8bpxx
Wikifunctions:Report vandalism/Archive/2025/06
4
58116
191343
2025-06-07T03:08:13Z
SpBot
978
archiving 1 section from [[Wikifunctions:Report vandalism]] (after section [[Wikifunctions:Report vandalism/Archive/2025/06#Report_concerning_User:IcelandHertz0|Report_concerning_User:IcelandHertz0]])
191343
wikitext
text/x-wiki
{{Talkarchive}}
== Report concerning User:IcelandHertz0 ==
{{vandal|1=IcelandHertz0}} — '''Reasons:''' Promotional content [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:37, 5 June 2025 (UTC)
:@[[User:Bunnypranav|Bunnypranav]] Isn't it a promotional-only account? Even the accont name is promotional [[User:Dv103|Dv103]] ([[User talk:Dv103|talk]]) 06:52, 5 June 2025 (UTC)
::Now that you say it, I see the username relation, blocked. Thanks! <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 07:08, 5 June 2025 (UTC)
:{{done|Deleted}}, and warned. <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:53, 5 June 2025 (UTC)
::<small>This section was archived on a request by: <span style="font-family:monospace;font-weight:bold">[[User:Bunnypranav|<span style="color:#63b3ed">~/Bunny</span><span style="color:#2c5282">pranav</span>]]:<[[User talk:Bunnypranav|<span style="color:#63b3ed">ping</span>]]></span> 06:47, 5 June 2025 (UTC)</small>
jyfvat667t2j76s8vfnp8m9tzp87vnn
Translations:Wikifunctions:Status updates/2025-06-06/Page display title/pt-br
1198
58117
191371
2025-06-07T05:25:32Z
Eduardogobi
2982
Created page with "Wikifunctions:Atualizações do projeto/6 de junho de 2025"
191371
wikitext
text/x-wiki
Wikifunctions:Atualizações do projeto/6 de junho de 2025
noxilgv9k5aoya8yh9hd7pglr2kxc2m
Wikifunctions:Status updates/2025-06-06/pt-br
4
58118
191372
2025-06-07T05:25:32Z
Eduardogobi
2982
Created page with "Wikifunctions:Atualizações do projeto/6 de junho de 2025"
191372
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = <span lang="en" dir="ltr" class="mw-content-ltr">Previous update</span>
| prev = 2025-05-29
| nextlabel = <span lang="en" dir="ltr" class="mw-content-ltr">Next update</span>
| next =
}}
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where will Abstract Content go? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
pcbo01mvxg67dtyc7fzjlgvvfgn4uq5
191374
191372
2025-06-07T05:25:36Z
Eduardogobi
2982
Created page with "Atualização anterior"
191374
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = <span lang="en" dir="ltr" class="mw-content-ltr">Next update</span>
| next =
}}
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where will Abstract Content go? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
bi4f98d07s238r7ab66irqyzg296p1p
191376
191374
2025-06-07T05:25:39Z
Eduardogobi
2982
Created page with "Próxima atualização"
191376
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Where will Abstract Content go? ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
7syp7ievkwtd09lqd2wqmt7d024x75x
191378
191376
2025-06-07T05:27:18Z
Eduardogobi
2982
Created page with "=== Para onde irá o Conteúdo Abstrato? ==="
191378
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
<div lang="en" dir="ltr" class="mw-content-ltr">
We are currently running [[:meta:Abstract Wikipedia/Location of Abstract Content|a consultation about the location of Abstract Content for Abstract Wikipedia]]. I am extremely thankful to the many thoughtful contributions to that consultation. I have to admit that I started with an opinion about what would be the best answer, but in internal discussions before the consultation I had changed my mind, and with the arguments and points raised in the consultation, I am changing my mind again.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
16ou3pq9v0iod4cfrk3qbiqiyjlg353
191380
191378
2025-06-07T05:29:45Z
Eduardogobi
2982
Created page with "No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia..."
191380
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
<div lang="en" dir="ltr" class="mw-content-ltr">
Today, I want to give a quick overview of my current state of thinking. Note though that I am not making the decision alone, but that it will be a decision by several stakeholders within the movement.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
bg63tno53d7h41rnyfohlrwqhcde7fs
191382
191380
2025-06-07T05:29:58Z
Eduardogobi
2982
Created page with "Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento."
191382
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
<div lang="en" dir="ltr" class="mw-content-ltr">
Originally, I was expecting Wikidata to be the natural host for long-form Abstract Content. But, among other arguments, that would increase the strain and technical challenges on Wikidata.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
frl5t4yqbdwg011bdktu1bn11z5atzk
191384
191382
2025-06-07T05:30:39Z
Eduardogobi
2982
Created page with "Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata."
191384
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
<div lang="en" dir="ltr" class="mw-content-ltr">
The only two options I currently see for long-form Abstract Content are on Wikifunctions, or as an entirely new project. On Wikifunctions it would have the advantage that the creation and maintenance of functions would be located very close to the main user of these functions. With a new project it would have the advantage of cleanly separating the content from the technology, and the two communities could each govern themselves, with their own rules, administrators, and processes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
j9k6c4cevjsbrnnzjx337slt51kywty
191386
191384
2025-06-07T05:31:25Z
Eduardogobi
2982
Created page with "As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores..."
191386
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores e processos.
<div lang="en" dir="ltr" class="mw-content-ltr">
One could argue that by having Abstract Content on Wikidata it would be close to the data which is expected to be heavily used. And whereas I think that is a good argument, the technical challenges mentioned above probably outweigh these.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
n2fkqo29n6cq1nnyepwzdlzhg5c41rw
191388
191386
2025-06-07T05:31:51Z
Eduardogobi
2982
Created page with "Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios."
191388
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores e processos.
Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios.
<div lang="en" dir="ltr" class="mw-content-ltr">
Personally, I think that we should stop thinking of the movement as 800 or 900 individual projects, but as one large project, but that’s a topic for a different time. Shoutout to the stewards, global sysops, and other cross-wiki supporters for their difficult and important global work!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
jf022ta50vd9db0gp5rwwm62az9f29x
191390
191388
2025-06-07T05:32:39Z
Eduardogobi
2982
Created page with "Pessoalmente, acho que deveríamos parar de pensar no movimento como 800 ou 900 projetos individuais, mas sim como um grande projeto, mas esse é um assunto para outro momento. Parabéns aos ''stewards'', administradores globais e outros apoiadores do conceito ''cross-wiki'' por seu difícil e importante trabalho global!"
191390
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores e processos.
Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios.
Pessoalmente, acho que deveríamos parar de pensar no movimento como 800 ou 900 projetos individuais, mas sim como um grande projeto, mas esse é um assunto para outro momento. Parabéns aos ''stewards'', administradores globais e outros apoiadores do conceito ''cross-wiki'' por seu difícil e importante trabalho global!
<div lang="en" dir="ltr" class="mw-content-ltr">
In addition to the repository of long-form Abstract Content, we will also help the Wikidata team introduce Wikifunctions references as a data type on Wikidata. This means that new properties can be created that point to a Wikifunctions object (put simply, Wikidata properties can have ZIDs as values). This will allow for a lot of flexibility in the future and pave the way for Abstract Descriptions, Abstract Glosses, or complex values and multilingual notes.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
svtp6g5rphwxzpvc6l92cx3gmmlz10m
191392
191390
2025-06-07T05:33:40Z
Eduardogobi
2982
Created page with "Além do repositório de Conteúdo Abstrato de formato longo, também ajudaremos a equipe do Wikidata a introduzir referências da Wikifunctions como um tipo de dados no Wikidata. Isso significa que podem ser criadas novas propriedades que apontem para um objeto da Wikifunctions (simplificando, as propriedades do Wikidata podem ter ZIDs como valores). Isso permitirá muita flexibilidade no futuro e abrirá caminho para Descrições Abstratas, Glossários Abstratos ou val..."
191392
wikitext
text/x-wiki
<languages/>
{{Wikifunctions updates
| prevlabel = Atualização anterior
| prev = 2025-05-29
| nextlabel = Próxima atualização
| next =
}}
<span id="Where_will_Abstract_Content_go?"></span>
=== Para onde irá o Conteúdo Abstrato? ===
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores e processos.
Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios.
Pessoalmente, acho que deveríamos parar de pensar no movimento como 800 ou 900 projetos individuais, mas sim como um grande projeto, mas esse é um assunto para outro momento. Parabéns aos ''stewards'', administradores globais e outros apoiadores do conceito ''cross-wiki'' por seu difícil e importante trabalho global!
Além do repositório de Conteúdo Abstrato de formato longo, também ajudaremos a equipe do Wikidata a introduzir referências da Wikifunctions como um tipo de dados no Wikidata. Isso significa que podem ser criadas novas propriedades que apontem para um objeto da Wikifunctions (simplificando, as propriedades do Wikidata podem ter ZIDs como valores). Isso permitirá muita flexibilidade no futuro e abrirá caminho para Descrições Abstratas, Glossários Abstratos ou valores complexos e notas multilíngues.
<div lang="en" dir="ltr" class="mw-content-ltr">
In short: I think that it’s going to be either a new wiki or a new namespace on Wikifunctions. Both of these would be accompanied with a new datatype for Wikifunctions objects on Wikidata for use there.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
As a reminder on the process: we will be closing the consultation next week. Everyone is still invited to add further arguments afterwards, but we won’t be actively tracking and following the page after that point, and anything that comes in later might be missed when considering the answer. We aim to come to a conclusion in the next few weeks, after the consultation period ends, and then to create a plan in the following quarter on how to implement the decision, and finally to implement that plan in the following quarters.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
I want to express my gratitude to everyone who has contributed to this process so far, and I am looking forward to the comments in the final week of the consultation! Thank you!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
''P.S.:'' I understand that the consultation was not as multi-lingual as some have hoped for. We have heard your concerns. It was my decision to reach out to all projects, although we had inadequate translation coverage. We received some great input from members of smaller projects, for which I am thankful for. Note that this process isn’t a vote, and thus the goal is not to have full representation, but rather a consultation, and the idea is to hear many different arguments and ideas in order to help with the decision-making. Other consultations, votes, and Requests for Comments might have different requirements with regards to a multi-lingual outreach.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recent Changes in the software ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
Last week was one of our once-every-two-months regular "Fix It Weeks", where we dedicate the team's time to fixing architectural issues, technical debt, and minor bugs we've noticed during development, though we also made some progress on Quarterly work.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have made more progress on the light-weight enum work ([[:phab:T390558|T390558]]). We have re-built our internal Object search API to allow complex Type and return Type combinations ([[:phab:T394712|T394712]]), and changed how we store details of what Objects' Type and return Type are, to allow us to model the lightweight enum Type-returning Function ([[:phab:T391915|T391915]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We fixed a tricky bug in our visual editor code noticed during the Hackathon last month that meant that checking the visual diff of your edit after making a change to an embedded Function call would delete it from the page ([[:phab:T393319|T393319]]). We also fixed a bug in new, not-yet-deployed code that meant that the language dialog no longer searched for languages correctly ([[:phab:T395469|T395469]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We changed our visual editor integration code to consistently emit field updates on changes, rather than only in validation states, to allow any other forms of change to be consistent ([[:phab:T395540|T395540]]). We also unified the styling of the "chips" for embedded Function call fragments, so they don't have different appearance or cause jumps when transitioning ([[:phab:T395547|T395547]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We have fixed a series of issues related to font size, found as part of preparing for the upstream change of these in Codex last month. This includes in the accordion in the Function Metadata dialog ([[:phab:T392703|T392703]]), in the Function report's icons on Implementation and Test case pages ([[:phab:T392707|T392707]]), in the code editor ([[:phab:T392711|T392711]]), in the expanded toggle control in complex Objects ([[:phab:T392704|T392704]]), in the Function call component's icon sizes for the Function call, argument references, and Wikidata entities ([[:phab:T392706|T392706]]), in the "empty" bubble for the language of a ZMonoLingualString component ([[:phab:T392700|T392700]]), in Type converters' empty states, and in a number of other areas we noticed that didn't have individual tasks.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We replaced our use of the mw.Uri utility with the browser-native URL API ([[:phab:T394820|T394820]]), as our part of Wikimedia-wide work to deprecate the utility.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We've re-factored the code around the code that handles embedded Wikifunctions calls in wikitext, to move most of the cache access code into the isolated database access code, for easier reasoning and testing. We consolidated some of our code around publishing Implementation code, to avoid repeating ourselves and so any future feature changes or bug fixes will need to be done only once ([[:phab:T357696|T357696]]). We also switched our uses of HTTP status codes out for a set of constants, for consistency ([[:phab:T394746|T394746]]).
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
We, along with all Wikimedia-deployed code, are now using the latest version of the Codex UX library, v2.0.0, as of this week. We believe that there should be no user-visible changes on Wikifunctions, so please comment on the Project chat or file a Phabricator task if you spot an issue.
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of presentation at Wikidata and Sister Project ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The recording of the presentation ''[https://www.youtube.com/live/7oKb0DoYEag Wikifunctions: how Wikidata powers language functions (and beyond)]'' by [[User:DMartin (WMF)|David Martin]] and [[User:Sannita (WMF)|Luca Martinelli]] at the [[:d:Event:Wikidata and Sister Projects|Wikidata and Sister Projects event]] is now [https://www.youtube.com/live/7oKb0DoYEag available on YouTube].
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Recording of last Volunteers’ Corner available ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
The [[:commons:File:Abstract Wikipedia Volunteer Corner 2025-06.webm|recording of Monday’s Volunteers’ Corner]] is now available on Wikimedia Commons. We thank all volunteers who joined us, and wish you happy watching!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
=== Fresh Functions weekly: 14 new Functions ===
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
This week we had 14 new functions. Here is a sample of the new functions with implementations and passing tests to get a taste of what functions have been created. Thanks everybody for contributing!
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
* {{Z|Z24876}}
* {{Z|Z24880}}
* {{Z|Z24884}}
* {{Z|Z24846}}
* {{Z|Z24849}}
* {{Z|Z24901}}
</div>
<div lang="en" dir="ltr" class="mw-content-ltr">
A [https://www.wikifunctions.org/wiki/Special:ListObjectsByType?type=Z8&orderby=latest complete list of all functions sorted by when they were created] is available.
</div>
lo6vqk4mb8b93ki61mynkzmuh6teyyb
Translations:Wikifunctions:Status updates/2025-06-06/1/pt-br
1198
58119
191373
2025-06-07T05:25:36Z
Eduardogobi
2982
Created page with "Atualização anterior"
191373
wikitext
text/x-wiki
Atualização anterior
fn25nkej5fxbrxri38n3lwf0lq7chr2
Translations:Wikifunctions:Status updates/2025-06-06/2/pt-br
1198
58120
191375
2025-06-07T05:25:38Z
Eduardogobi
2982
Created page with "Próxima atualização"
191375
wikitext
text/x-wiki
Próxima atualização
he6r0lh1jfjuf1lwc3tyrvwzrjijnwr
Translations:Wikifunctions:Status updates/2025-06-06/3/pt-br
1198
58121
191377
2025-06-07T05:27:17Z
Eduardogobi
2982
Created page with "=== Para onde irá o Conteúdo Abstrato? ==="
191377
wikitext
text/x-wiki
=== Para onde irá o Conteúdo Abstrato? ===
9vxfvtg40j6jv03mmxhdupmkhh66wv6
Translations:Wikifunctions:Status updates/2025-06-06/4/pt-br
1198
58122
191379
2025-06-07T05:29:44Z
Eduardogobi
2982
Created page with "No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia..."
191379
wikitext
text/x-wiki
No momento, estamos realizando [[:meta:Abstract Wikipedia/Location of Abstract Content|uma consulta sobre a localização do Conteúdo Abstrato para a Wikipédia Abstrata]]. Sou extremamente grato às muitas contribuições atenciosas para essa consulta. Tenho que admitir que comecei com uma opinião sobre qual seria a melhor resposta, mas em discussões internas antes da consulta mudei de ideia e, com os argumentos e pontos levantados na consulta, estou mudando de ideia novamente.
7h1lu8jkq64rbzrd010vgz8qa2n1a1p
Translations:Wikifunctions:Status updates/2025-06-06/5/pt-br
1198
58123
191381
2025-06-07T05:29:57Z
Eduardogobi
2982
Created page with "Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento."
191381
wikitext
text/x-wiki
Hoje, quero dar uma rápida visão geral do meu estado atual de pensamento. Observe, porém, que não estou tomando a decisão sozinho, mas que ela será uma decisão de várias partes interessadas do movimento.
bew6dgo02ti8zsa6mimi0odk2svmgjs
Translations:Wikifunctions:Status updates/2025-06-06/6/pt-br
1198
58124
191383
2025-06-07T05:30:38Z
Eduardogobi
2982
Created page with "Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata."
191383
wikitext
text/x-wiki
Originalmente, eu esperava que o Wikidata fosse a “casa” para o Conteúdo Abstrato de formato longo. Mas, entre outros argumentos, isso aumentaria a tensão e os desafios técnicos do Wikidata.
i4gu8w99aeuatwabiw942evn3rkxq3e
Translations:Wikifunctions:Status updates/2025-06-06/7/pt-br
1198
58125
191385
2025-06-07T05:31:24Z
Eduardogobi
2982
Created page with "As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores..."
191385
wikitext
text/x-wiki
As duas únicas opções que vejo atualmente para o conteúdo abstrato de formato longo são a Wikifunctions ou um projeto totalmente novo. Na Wikifunctions, a vantagem seria que a criação e a manutenção das funções estariam localizadas muito perto do usuário principal dessas funções. Com um novo projeto, haveria a vantagem de separar claramente o conteúdo da tecnologia, e as duas comunidades poderiam se autogovernar, com suas próprias regras, administradores e processos.
sbts2zoxzh9pot8un1onk80o1d50jb0
Translations:Wikifunctions:Status updates/2025-06-06/8/pt-br
1198
58126
191387
2025-06-07T05:31:50Z
Eduardogobi
2982
Created page with "Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios."
191387
wikitext
text/x-wiki
Poder-se-ia argumentar que, com o Conteúdo Abstrato no Wikidata, ele estaria próximo dos dados que se espera que sejam muito usados. E, embora eu ache que esse seja um bom argumento, os desafios técnicos mencionados acima provavelmente superam esses desafios.
f001zjmvxyidiirhxtkmk3prtjs9yli
Translations:Wikifunctions:Status updates/2025-06-06/9/pt-br
1198
58127
191389
2025-06-07T05:32:38Z
Eduardogobi
2982
Created page with "Pessoalmente, acho que deveríamos parar de pensar no movimento como 800 ou 900 projetos individuais, mas sim como um grande projeto, mas esse é um assunto para outro momento. Parabéns aos ''stewards'', administradores globais e outros apoiadores do conceito ''cross-wiki'' por seu difícil e importante trabalho global!"
191389
wikitext
text/x-wiki
Pessoalmente, acho que deveríamos parar de pensar no movimento como 800 ou 900 projetos individuais, mas sim como um grande projeto, mas esse é um assunto para outro momento. Parabéns aos ''stewards'', administradores globais e outros apoiadores do conceito ''cross-wiki'' por seu difícil e importante trabalho global!
msyox61b35fj1525y5yettxlpvi780v
Translations:Wikifunctions:Status updates/2025-06-06/10/pt-br
1198
58128
191391
2025-06-07T05:33:39Z
Eduardogobi
2982
Created page with "Além do repositório de Conteúdo Abstrato de formato longo, também ajudaremos a equipe do Wikidata a introduzir referências da Wikifunctions como um tipo de dados no Wikidata. Isso significa que podem ser criadas novas propriedades que apontem para um objeto da Wikifunctions (simplificando, as propriedades do Wikidata podem ter ZIDs como valores). Isso permitirá muita flexibilidade no futuro e abrirá caminho para Descrições Abstratas, Glossários Abstratos ou val..."
191391
wikitext
text/x-wiki
Além do repositório de Conteúdo Abstrato de formato longo, também ajudaremos a equipe do Wikidata a introduzir referências da Wikifunctions como um tipo de dados no Wikidata. Isso significa que podem ser criadas novas propriedades que apontem para um objeto da Wikifunctions (simplificando, as propriedades do Wikidata podem ter ZIDs como valores). Isso permitirá muita flexibilidade no futuro e abrirá caminho para Descrições Abstratas, Glossários Abstratos ou valores complexos e notas multilíngues.
7hzcrvz44uwynahgjy1aygu7j8py2qd
Z24946
0
58129
191402
2025-06-07T10:23:38Z
Dv103
11127
191402
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24946"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t},EPOCH);\n\t\t\n\t\t/// ADD HERE THE LANGUAGE-SPECIFIC OPTIONS\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tZ23990K1=Z23990K1.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(Z23990K1)){\n\t\tZ23990K1=Z23990K1.split(\"T\")[0];\n\t\tvar list=Z23990K1.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003CZ23990K1.length;){\n\t\tlet s=separators.find((v)=\u003E Z23990K1.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=Z23990K1[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n\n}"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
dxg9lu24s2kabggn0jcvaim8c1n9l0d
191403
191402
2025-06-07T10:27:08Z
Dv103
11127
191403
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24946"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tconst input=Z23976K1;\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t},EPOCH);\n\t\t\n\t\t/// ADD HERE THE LANGUAGE-SPECIFIC OPTIONS\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tinput=input.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(input)){\n\t\tinput=input.split(\"T\")[0];\n\t\tvar list=input.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003Cinput.length;){\n\t\tlet s=separators.find((v)=\u003E input.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=input[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
1hctog0qbc78ab9ioyd0r97wg5w8op8
191404
191403
2025-06-07T10:27:56Z
Dv103
11127
191404
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24946"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tvar input=Z23976K1;\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t},EPOCH);\n\t\t\n\t\t/// ADD HERE THE LANGUAGE-SPECIFIC OPTIONS\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tinput=input.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(input)){\n\t\tinput=input.split(\"T\")[0];\n\t\tvar list=input.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1n,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003Cinput.length;){\n\t\tlet s=separators.find((v)=\u003E input.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=input[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
nzhh3n64enohrp2hymuwq5fa1u4anzt
191405
191404
2025-06-07T10:29:11Z
Dv103
11127
191405
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24946"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tvar input=Z23976K1;\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t},EPOCH);\n\t\t\n\t\t/// ADD HERE THE LANGUAGE-SPECIFIC OPTIONS\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tinput=input.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(input)){\n\t\tinput=input.split(\"T\")[0];\n\t\tvar list=input.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003Cinput.length;){\n\t\tlet s=separators.find((v)=\u003E input.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=input[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\telSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\telSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t//Wikifunctions.Debug(\"elements:\");\n\t//Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
0mw1we5dxhxeyemgt8xngadhxvxzegu
191409
191405
2025-06-07T11:57:37Z
Dv103
11127
191409
zobject
text/plain
{
"Z1K1": "Z2",
"Z2K1": {
"Z1K1": "Z6",
"Z6K1": "Z24946"
},
"Z2K2": {
"Z1K1": "Z14",
"Z14K1": "Z23976",
"Z14K3": {
"Z1K1": "Z16",
"Z16K1": "Z600",
"Z16K2": "function Z23976( Z23976K1 ) {\n\tvar input=Z23976K1;\n\tconst separators=[\" \",\"\\t\",\"/\",\"\\\\\",\"'\",'\"',\"|\"];\n\tconst prefOptions=[\"yemd\",\"eymd\",\"dmye\",\"dmey\",\"mdye\",\"mdey\",\"yedm\",\"eydm\",];\n\n\tfunction languageSpecificOptions(){\n\n\t\tdefineLiterals({\n\t\t\tad:1n,\n\t\t\tbc:-1n,\n\t\t\tbce:-1n,\n\t\t\tce:1n,\n\t\t},EPOCH);\n\t\t\n\t\t/// ADD HERE THE LANGUAGE-SPECIFIC OPTIONS\n\t}\n\n\tconst DAY =0;\n\tconst MONTH=1;\n\tconst YEAR=2;\n\tconst EPOCH=3;\n\n\tconst BEFORE=10;\n\tconst AFTER=20;\n\tconst BEFORE_OR_AFTER=30;\n\n\tconst LENIENT=true;\n\tconst NORMAL=false;\n\n\tfunction defineLiterals(literals,meaning,compMode=LENIENT, forced=false){\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m in literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess[1]\u003Ctarget.length){\n\t\t\t\t\tbestGuess = [literals[m],target.length];\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\n\t}\n\tfunction defineLiteralFunction(f,meaning, forced=false){\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\tfor (let m of meaning){\n\t\t\tswitch(m){\n\t\t\t\tcase 0: _day=bestGuess[0]; break;\n\t\t\t\tcase 1: _month=bestGuess[0]; break;\n\t\t\t\tcase 2: _year=bestGuess[0]; break;\n\t\t\t\tcase 3: _epoch=bestGuess[0]; break;\n\t\t\t}\n\t\t}\n\t\t_nSteps=bestGuess[1];\n\t\tif (forced){\n\t\t\t_forced=meaning;\n\t\t}\n\t\treturn true;\n\t}\n\tfunction defineConstraint(literals, meaning, position, compMode=NORMAL){\n\n\t\tlet bestGuess=null;\n\t\tconst compFunc= compMode==LENIENT ? lenientComp : lessLenientComp;\n\t\tfor (let m of literals){\n\t\t\tlet target=m.split(\" \");\n\t\t\tlet ok=true;\n\t\t\tfor (let t=0; t\u003Ctarget.length; ++t){\n\t\t\t\tif (elements[iAtt+t]==undefined || !compFunc(elements[iAtt+t],target[t])){\n\t\t\t\t\tok=false;\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (ok){\n\t\t\t\tif (bestGuess == null || bestGuess\u003Ctarget.length){\n\t\t\t\t\tbestGuess = target.length;\n\t\t\t\t}\n\t\t\t}\n\n\t\t}\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\t\t\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\tfunction defineConstraintFunction(f,meaning,position){\n\n\t\tlet bestGuess=f(elements,iAtt);\n\t\tif (bestGuess==null){\n\t\t\treturn false;\n\t\t}\n\n\t\tif (typeof(meaning)==\"number\"){\n\t\t\tmeaning=[meaning];\n\t\t}\n\t\t_constraintsList.push({pos:possibilities.length, meaning:meaning, type: position});\n\t\t_nSteps=bestGuess;\n\t\t_isToBeIgnored=true;\n\t\treturn true;\n\t}\n\n\tfunction lenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b.substring(0,a.length);\n\t}\n\n\tfunction lessLenientComp(a,b){\n\t\ta=a.toLowerCase().replaceAll(/,|\\.|;|:/g,\"\");\n\t\tb=b.toLowerCase();\n\t\tif (a==\"\") return false;\n\t\treturn a==b;\n\t}\n\n\tfunction extractNumber(s){\n\t\tlet res=/-?[0-9]+/.exec(s);\n\t\tif (res!=null){\n\t\t\treturn BigInt(res);\n\t\t}\n\t\treturn null;\n\t}\n\n\n\tfunction forceToYear(s){\n\t\tlet res=(/-?\\+?[0-9]+/.exec(s))?.[0];\n\t\tif (res==null){\n\t\t\treturn false;\n\t\t}\n\t\t//Wikifunctions.Debug(res);\n\t\tif (res.length\u003E2) return true;\n\t\tif (res[0]==\"-\" || res[0]==\"+\") return true;\n\t\treturn false;\n\t}\n\n\t\n\n\tinput=input.replaceAll(/-|—|‒|–|—|⸺|⸺/g,\"-\");\n\n\tvar isoRegex=/(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d\\.\\d+)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d:[0-5]\\d)|(\\d{4}-[01]\\d-[0-3]\\dT[0-2]\\d:[0-5]\\d)/;\n\tif (isoRegex.exec(input)){\n\t\tinput=input.split(\"T\")[0];\n\t\tvar list=input.split(/(?\u003C=.)-(?=.)/);\n\t\t//Wikifunctions.Debug(list);\n\t\treturn {\n\t\t\tK1: BigInt(list[0]),\n\t\t\tK2: list[1]-1,\n\t\t\tK3: list[2]\n\t\t};\n\t}\n\n\tvar elements=[\"\"];\n\tfor (let i=0; i\u003Cinput.length;){\n\t\tlet s=separators.find((v)=\u003E input.substring(i,i+v.length)==v);\n\t\tif (s!==undefined){\n\t\t\tif(elements[elements.length-1]!=\"\")\n\t\t\t\telements.push(\"\");\n\t\t\ti+=s.length;\n\t\t\tcontinue;\n\t\t}\n\t\telements[elements.length-1]+=input[i++];\n\t}\n\tif(elements[elements.length-1]==\"\") elements.pop();\n\n\tif(elements.length\u003C3){\n\t\tlet elSeparato=[];\n\t\tfor (let i=0; i\u003Celements.length; ++i){\n\t\t\telSeparato.push(elements[i].split(\"-\"));\n\t\t}\n\t\telements=elSeparato.flat();\n\t}\n\t// Wikifunctions.Debug(elements);\n\n\tlet elSeparato=[];\n\tfor (let i=0; i\u003Celements.length; ++i){\n\t\tfor (let e of elements[i].matchAll(/(-?\\+?[0-9]+)?([^0-9]*)/g)){\n\t\t\telSeparato.push(e.splice(1))\n\t\t}\n\t\t// elSeparato.push(/-?\\+?[0-9]+/.exec(elements[i]));\n\t\t// elSeparato.push(elements[i].split(/-?\\+?[0-9]+/));\n\t}\n\telSeparato=elSeparato.flat();\n\telements=elSeparato.filter((v)=\u003E(v!=null \u0026\u0026 v!=\"\"));\n\n\t// Wikifunctions.Debug(\"elements:\");\n\t// Wikifunctions.Debug(elements);\n\n\t//Order of possibilities: dmye\n\tvar possibilities=[];\n\n\tvar _constraintsList=[];\n\tvar _nSteps=1;\n\n\tfor(var iAtt=0; iAtt\u003Celements.length; iAtt+=_nSteps){\n\t\t_nSteps=1;\n\t\tlet n=extractNumber(elements[iAtt]);\n\t\tvar _day=null;\n\t\tvar _month=null;\n\t\tvar _year=null;\n\t\tvar _epoch=null;\n\t\tvar _forced=null;\n\t\tvar _isToBeIgnored=false;\n\n\t\t//////////\n\n\t\tlanguageSpecificOptions();\n\n\t\tlet p=[];\n\t\t//day\n\t\tp.push(_day ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=31n) ? n : null));\n\t\t//month\n\t\tp.push(_month ?? ((n!=null \u0026\u0026 n\u003E0n \u0026\u0026 n\u003C=12n) ? n-1n :null));\n\t\t//year\n\t\tp.push(_year ?? n);\n\t\t//epoch\n\t\tp.push(_epoch);\n\n\t\tif (_forced!=null){\n\t\t\tfor (let j=0; j\u003C=3; ++j){\n\t\t\t\tif (_forced.find((v)=\u003E(v==j)) == undefined){\n\t\t\t\t\tp[j]=null;\t\n\t\t\t\t}\n\t\t\t}\n\t\t} else if (forceToYear(elements[iAtt])){\n\t\t\tp[0]=null;\n\t\t\tp[1]=null;\n\t\t\tp[3]=null;\n\t\t}\n\n\t\tif (!_isToBeIgnored)\n\t\t\tpossibilities.push(p);\n\t}\n\t\n\n\tif (_constraintsList.length\u003E0){\n\t\tfor (let pAtt=0; pAtt\u003C possibilities.length; ++pAtt){\n\t\t\tfor (let c of _constraintsList){\n\t\t\t\tif ((c.type==AFTER \u0026\u0026 pAtt!=c.pos-1) ||\n\t\t\t\t (c.type==BEFORE \u0026\u0026 pAtt!=c.pos) ||\n\t\t\t\t (c.type==BEFORE_OR_AFTER \u0026\u0026 pAtt!=c.pos-1 \u0026\u0026 pAtt!=c.pos)){\n\t\t\t\t\tfor(let m of c.meaning){\n\t\t\t\t\t\tpossibilities[pAtt][m]=null;\t\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\tpossibilities=possibilities.filter((v)=\u003E(v[0]!=null || v[1]!=null || v[2]!=null || v[3]!=null));\n\n\tfor (let i=0; i\u003CprefOptions.length; ++i){\n\t\tlet actPref=prefOptions[i];\n\t\tlet d,m,y,e;\n\t\tif (possibilities.length\u003C4) actPref=actPref.replace(\"e\",\"\");\n\t\tfor (let j=0; j\u003CactPref.length; ++j){\n\t\t\tswitch(actPref[j]){\n\t\t\t\tcase \"d\":{\n\t\t\t\t\td=possibilities[j]?.[0]; break;\n\t\t\t\t}\n\t\t\t\tcase \"m\":{\n\t\t\t\t\tm=possibilities[j]?.[1]; break;\n\t\t\t\t}\n\t\t\t\tcase \"y\":{\n\t\t\t\t\ty=possibilities[j]?.[2]; break;\n\t\t\t\t}\n\t\t\t\tcase \"e\":{\n\t\t\t\t\te=possibilities[j]?.[3];break;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (d!=null \u0026\u0026 m!=null \u0026\u0026 y!=null){\n\t\t\tlet year;\n\t\t\tif (e!=null){\n\t\t\t\tyear = e==-1n ? -(y\u003C0n ? -y : y)+1n : (y\u003C0n ? -y : y);\n\t\t\t} else{\n\t\t\t\tyear=y;\n\t\t\t}\n\n\t\t\t// Wikifunctions.Debug({\n\t\t\t// \tK3: d,\n\t\t\t// \tK2: m,\n\t\t\t// \tK1: year\n\t\t\t// });\n\n\t\t\treturn{\n\t\t\t\tK3: Number(d),\n\t\t\t\tK2: Number(m),\n\t\t\t\tK1: (year)\n\t\t\t};\n\t\t}\n\t}\n\n}\n"
}
},
"Z2K3": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "refactored code, mul, js"
}
]
},
"Z2K4": {
"Z1K1": "Z32",
"Z32K1": [
"Z31"
]
},
"Z2K5": {
"Z1K1": "Z12",
"Z12K1": [
"Z11",
{
"Z1K1": "Z11",
"Z11K1": "Z1002",
"Z11K2": "Refactored to make it easier to adapt to other languages"
}
]
}
}
3afgx8e8r8yfi9vyg4hiotcswizqa3b