text:
Module:affix

local export = {}

local debug_force_cat = false -- if set to true, always display categories even on userspace pages

local m_links = require("Module:links") local m_str_utils = require("Module:string utilities") local m_table = require("Module:table") local etymology_module = "Module:etymology" local pron_qualifier_module = "Module:pron qualifier" local scripts_module = "Module:scripts" local utilities_module = "Module:utilities" -- Export this so the category code in Module:category tree/poscatboiler/data/terms by etymology can access it. export.affix_lang_data_module_prefix = "Module:affix/lang-data/"

local rsub = m_str_utils.gsub local usub = m_str_utils.sub local ulen = m_str_utils.len local rfind = m_str_utils.find local rmatch = m_str_utils.match local pluralize = m_str_utils.pluralize local u = m_str_utils.char local ucfirst = m_str_utils.ucfirst

-- Export this so the category code in Module:category tree/poscatboiler/data/terms by etymology can access it. export.langs_with_lang_specific_data = { ["az"] = true, ["fi"] = true, ["izh"] = true, ["la"] = true, ["tr"] = true, }

local default_pos = "term"

--[==[ intro:

About different types of hyphens ("template", "display" and "lookup"):
affix. This is always a single Unicode char, but there may be multiple possible hyphens for a given script. Normally this is just the regular hyphen character "-", but for some non-Latin-script languages (currently only right-to-left languages), it is different. to indicate that a term is an affix. Currently this is always either the same as the template hyphen or an empty string, but the code below is written generally enough to handle arbitrary display hyphens. Specifically: *# For East Asian languages, the display hyphen is always blank. *# For Arabic-script languages, either tatweel (ـ) or ZWNJ (zero-width non-joiner) are allowed as template hyphens, where ZWNJ is supported primarily for Farsi, because some suffixes have non-joining behavior. The display hyphen corresponding to tatweel is also tatweel, but the display hyphen corresponding to ZWNJ is blank (tatweel is also	 the default display hyphen, for calls to prefix/suffix/etc. that don't include an explicit hyphen). discussed in more detail below when discussing link affixes.) It depends only on the script of the affix in question. Most scripts (including East Asian scripts) use a regular hyphen "-" as the lookup hyphen, but Hebrew and Arabic  have their own lookup hyphens (respectively maqqef and tatweel). Note that for Arabic in particular, there are  three possible template hyphens that are recognized (tatweel, ZWNJ and regular hyphen), but mappings must use tatweel.
 * The "template hyphen" is the per-script hyphen character that is used in template calls to indicate that a term is an
 * The "display hyphen" is the string (which might be an empty string) that is added onto a term as displayed and linked,
 * The "lookup hyphen" is the hyphen that is used when looking up language-specific affix mappings. (These mappings are

About different types of affixes ("template", "display", "link", "lookup" and "category"):
an attached template hyphen (see above) to indicate that it is an affix and indicate what type of affix it is (prefix, suffix, interfix/infix or circumfix), but some of the older-style templates such as suffix, prefix, confix, etc. have "positional" affixes where the presence of the affix in a certain position (e.g. the second or third parameter) indicates that it is a certain type of affix, whether or not it has an attached template hyphen. from the template affix for various reasons: *# The display affix may be specified explicitly using the alt N parameter, the `` inline modifier or a piped link of the form e.g. ` -käs ` (here indicating that the affix should	 display as `-käs` but be linked as `-kas`). Here, the template affix is arguably the entire piped link, while the display affix is `-käs`. *# Even in the absence of alt N parameters, `` inline modifiers and piped links, certain languages have differences between the "template hyphen" specified in the template (which always needs to be	 specified somehow or other in templates like affix, to indicate that the term is an affix and what type of	 affix it is) and the display hyphen (see above), with corresponding differences between template and display affixes. the same as the display affix, but will differ in one of three circumstances: *# The display and link affixes are explicitly made different using alt N parameters, `` inline modifiers or piped links, as described above under "display affix". *# For certain languages, certain affixes are mapped to canonical form using language-specific mappings. For example, in Finnish, the adjective-forming suffix -kas appears as -käs after front vowels, but logically both forms are the same suffix and should be linked and categorized the same. Similarly, in Latin, the negative and intensive prefixes spelled in- (etymologically two distinct prefixes) appear variously as il-, im- or ir- before certain consonants. Mappings are supplied in Module:affix/lang-data/LANGCODE to convert Finnish -käs to -kas for linking and categorization purposes. Note that the affixes in the mappings use "lookup hyphens" to indicate the different types of affixes, which is usually the same as the template hyphen but differs for Arabic scripts, because there are multiple possible template hyphens recognized but only one lookup hyphen (tatweel). The form of the affix as used to look up in the mapping tables is called the "lookup affix"; see below. may strip certain diacritics: e.g. macrons in Latin and Old English (indicating length); acute and grave accents in Russian and various other Slavic languages (indicating stress); vowel diacritics in most Arabic-script languages; and also tatweel in some Arabic-script languages (currently, for example, Persian, Arabic and Urdu strip tatweel, but Ottoman Turkish does not). Stripped link affixes are currently what are used in category names. under link affixes. There are actually two lookup stages: *# First, the affix is looked up in a modified display form (specifically, the same as the display affix but using	 lookup hyphens). Note that this lookup does not occur if an explicit display form is given using alt N or an `` inline modifier, or if the template affix contains a piped or embedded link. *# If no entry is found, the affix is then looked up in a modified link form (specifically, the modified display	 form passed through the language's `makeEntryName` function, which strips out certain diacritics, but with the	 lookup hyphen re-added if it was stripped out, as in the case of tatweel in many Arabic-script languages). The reason for this double lookup procedure is to allow for mappings that are sensitive to the extra diacritics, but also allow for mappings that are not sensitive in this fashion (e.g. Russian -ливый occurs both stressed and unstressed, but is the same prefix either way). The category affix is currently always the same as the stripped link affix. This means that for Arabic-script languages, it may or may not have a tatweel, even if the correponding display affix and regular link affix have a tatweel. As mentioned above, makeEntryName strips tatweel for Arabic, Persian and Urdu, but not for Ottoman Turkish. Hence affix categories for Arabic, Persian and Urdu will be missing the tatweel, but affix categories for Ottoman Turkish will have it. An additional complication is that if the template affix contains a ZWNJ, the display (and hence the link and category affixes) will have no hyphen attached in any case. ]==]
 * A "template affix" is an affix in its source form as it appears in a template call. Generally, a template affix has
 * A "display affix" is the corresponding affix as it is actually displayed to the user. The display affix may differ
 * A (regular) "link affix" is the affix that is linked to when the affix is shown to the user. The link affix is usually
 * A "stripped link affix" is a link affix that has been passed through the language's `makeEntryName` function, which
 * A "lookup affix" is the form of the affix as it is looked up in the language-specific lookup mappings described above
 * A "category affix" is the affix as it appears in categories such as Category:Finnish terms suffixed with -kas.

- --                              Template and display hyphens                          -- -

--[=[ Per-script template hyphens. The template hyphen is what appears in the ///etc. template (in the wikicode). See above.

They key below is a script code, after removing a hyphen and anything preceding. Hence, script codes like 'fa-Arab' and 'ur-Arab' will match 'Arab'.

The value below is a string consisting of one or more hyphen characters. If there is more than one character, the default hyphen must come last and a non-default function must be specified for the script in display_hyphens[] so the correct display hyphen will be specified when no template hyphen is given (in //etc.).

Script detection is normally done when linking, but we need to do it earlier. However, under most circumstances we don't need to do script detection. Specifically, we only need to do script detection for a given language if

(a) the language has multiple scripts; and (b) at least one of those scripts is listed below or in display_hyphens. ]=]

local ZWNJ = u(0x200C) -- zero-width non-joiner local template_hyphens = { ["Arab"] = "ـ" .. ZWNJ .. "-", -- tatweel + zero-width non-joiner + regular hyphen ["Hebr"] = "־", -- Hebrew-specific hyphen termed "maqqef" -- This covers all Arabic scripts. See above. ["Mong"] = "᠊", ["mnc-Mong"] = "᠊", ["sjo-Mong"] = "᠊", ["xwo-Mong"] = "᠊", -- FIXME! What about the following right-to-left scripts? -- Adlm (Adlam) -- Armi (Imperial Aramaic) -- Avst (Avestan) -- Cprt (Cypriot) -- Khar (Kharoshthi) -- Mand (Mandaic/Mandaean) -- Mani (Manichaean) -- Mend (Mende/Mende Kikakui) -- Narb (Old North Arabian) -- Nbat (Nabataean/Nabatean) -- Nkoo (N'Ko) -- Orkh (Orkhon runes) -- Phli (Inscriptional Pahlavi) -- Phlp (Psalter Pahlavi) -- Phlv (Book Pahlavi) -- Phnx (Phoenician) -- Prti (Inscriptional Parthian) -- Rohg (Hanifi Rohingya) -- Samr (Samaritan) -- Sarb (Old South Arabian) -- Sogd (Sogdian) -- Sogo (Old Sogdian) -- Syrc (Syriac) -- Thaa (Thaana) }

-- Hyphens used when looking up an affix in a lang-specific affix mapping. Defaults to regular hyphen (-). The keys -- are script codes, after removing a hyphen and anything preceding. Hence, script codes like 'fa-Arab' and 'ur-Arab' -- will match 'Arab'. The value should be a single character. local lookup_hyphens = { ["Hebr"] = "־", -- This covers all Arabic scripts. See above. ["Arab"] = "ـ", }

-- Default display-hyphen function. local function default_display_hyphen(script, hyph) if not hyph then return template_hyphens[script] or "-" end return hyph end

local function arab_get_display_hyphen(script, hyph) if not hyph then return "ـ" -- tatweel elseif hyph == ZWNJ then return "" else return hyph end end

local function no_display_hyphen(script, hyph) return "" end

-- Per-script function to return the correct display hyphen given the script and template hyphen. The function should -- also handle the case where the passed-in template hyphen is nil, corresponding to the situation in -- //etc. where no template hyphen is specified. The key is the script code after removing a hyphen -- and anything preceding, so 'fa-Arab', 'ur-Arab' etc. will match 'Arab'. local display_hyphens = { -- This covers all Arabic scripts. See above. ["Arab"] = arab_get_display_hyphen, ["Bopo"] = no_display_hyphen, ["Hani"] = no_display_hyphen, ["Hans"] = no_display_hyphen, ["Hant"] = no_display_hyphen, -- The following is a mixture of several scripts. Hopefully the specs here are correct! ["Jpan"] = no_display_hyphen, ["Jurc"] = no_display_hyphen, ["Kitl"] = no_display_hyphen, ["Kits"] = no_display_hyphen, ["Laoo"] = no_display_hyphen, ["Nshu"] = no_display_hyphen, ["Shui"] = no_display_hyphen, ["Tang"] = no_display_hyphen, ["Thaa"] = no_display_hyphen, ["Thai"] = no_display_hyphen, }

- --                                Basic Utility functions                             -- -

local function glossary_link(entry, text) text = text or entry return "" .. text .. "" end

local function track(page) if type(page) == "table" then for i, pg in ipairs(page) do page[i] = "affix/" .. pg		end else page = "affix/" .. page end require("Module:debug/track")(page) end

local function ine(val) return val ~= "" and val or nil end

- --                                     Compound types                                 -- -

local function make_compound_type(typ, alttext) return { text = glossary_link(typ, alttext) .. " compound", cat = typ .. " compounds", } end

-- Make a compound type entry with a simple rather than glossary link. -- These should be replaced with a glossary link when the entry in the glossary -- is created. local function make_non_glossary_compound_type(typ, alttext) local link = alttext and "" .. alttext .. "" or "" .. typ .. "" return { text = link .. " compound", cat = typ .. " compounds", } end

local function make_raw_compound_type(typ, alttext) return { text = glossary_link(typ, alttext), cat = pluralize(typ), } end

export.compound_types = { ["alliterative"] = make_non_glossary_compound_type("alliterative"), ["allit"] = "alliterative", ["antonymous"] = make_non_glossary_compound_type("antonymous"), ["ant"] = "antonymous", ["bahuvrihi"] = make_compound_type("bahuvrihi", "bahuvrīhi"), ["bahu"] = "bahuvrihi", ["bv"] = "bahuvrihi", ["coordinative"] = make_compound_type("coordinative"), ["coord"] = "coordinative", ["descriptive"] = make_compound_type("descriptive"), ["desc"] = "descriptive", ["determinative"] = make_compound_type("determinative"), ["det"] = "determinative", ["dvandva"] = make_compound_type("dvandva"), ["dva"] = "dvandva", ["dvigu"] = make_compound_type("dvigu"), ["dvi"] = "dvigu", ["endocentric"] = make_compound_type("endocentric"), ["endo"] = "endocentric", ["exocentric"] = make_compound_type("exocentric"), ["exo"] = "exocentric", ["izafet I"] = make_compound_type("izafet I"), ["iz1"] = "izafet I", ["izafet II"] = make_compound_type("izafet II"), ["iz2"] = "izafet II", ["izafet III"] = make_compound_type("izafet III"), ["iz3"] = "izafet III", ["karmadharaya"] = make_compound_type("karmadharaya", "karmadhāraya"), ["karma"] = "karmadharaya", ["kd"] = "karmadharaya", ["kenning"] = make_raw_compound_type("kenning"), ["ken"] = "kenning", ["rhyming"] = make_non_glossary_compound_type("rhyming"), ["rhy"] = "rhyming", ["synonymous"] = make_non_glossary_compound_type("synonymous"), ["syn"] = "synonymous", ["tatpurusa"] = make_compound_type("tatpurusa", "tatpuruṣa"), ["tat"] = "tatpurusa", ["tp"] = "tatpurusa", }

local function process_compound_type(typ, nocap, notext, has_parts) local text_sections = {} local categories = {}

if typ then local typdata = export.compound_types[typ] if type(typdata) == "string" then typdata = export.compound_types[typdata] end if not typdata then error("Internal error: Unrecognized type '" .. typ .. "'") end local text = typdata.text if not nocap then text = ucfirst(text) end local cat = typdata.cat local oftext = typdata.oftext or " of"

if not notext then table.insert(text_sections, text) if has_parts then table.insert(text_sections, oftext) table.insert(text_sections, " ") end end table.insert(categories, cat) end

return text_sections, categories end

- --                                    Utility functions                               -- -

-- Iterate an array up to the greatest integer index found. local function ipairs_with_gaps(t) local indices = m_table.numKeys(t) local max_index = #indices > 0 and math.max(unpack(indices)) or 0 local i = 0 return function while i < max_index do			i = i + 1 return i, t[i] end end end

export.ipairs_with_gaps = ipairs_with_gaps

--[==[ Join formatted parts (in `parts_formatted`) together with any overall lit spec (in `lit`) plus categories, which are formatted by prepending the language name as found in `lang`. The value of an entry in `categories` can be either a string (which is formatted using `sort_key`) or a table of the form `{ {cat= category , sort_key= sort_key, sort_base= sort_base }`, specifying the sort key and sort base to use when formatting the category. If `nocat` is given, no categories are added; otherwise, `force_cat` causes categories to be added even on userspace pages. ]==] function export.join_formatted_parts(data) local cattext local lang = data.data.lang local force_cat = data.data.force_cat or debug_force_cat if data.data.nocat then cattext = "" else for i, cat in ipairs(data.categories) do			if type(cat) == "table" then data.categories[i] = require(utilities_module).format_categories({lang:getFullName .. " " .. cat.cat},					lang, cat.sort_key, cat.sort_base, force_cat) else data.categories[i] = require(utilities_module).format_categories({lang:getFullName .. " " .. cat}, lang,					data.data.sort_key, nil, force_cat) end end cattext = table.concat(data.categories) end local result = table.concat(data.parts_formatted, " + ") .. (data.data.lit and ", literally " ..		m_links.mark(data.data.lit, "gloss") or "") local q = data.data.q	local qq = data.data.qq	local l = data.data.l	local ll = data.data.ll	if q and q[1] or qq and qq[1] or l and l[1] or ll and ll[1] then result = require(pron_qualifier_module).format_qualifiers { lang = lang, text = result, q = q,			qq = qq, l = l,			ll = ll, }	end

return result .. cattext end

--[==[ Older entry point for calling `join_formatted_parts. FIXME: Convert callers. ]==] function export.concat_parts(lang, parts_formatted, categories, nocat, sort_key, lit, force_cat) return export.join_formatted_parts { data = { lang = lang, nocat = nocat, sort_key = sort_key, lit = lit, force_cat = force_cat, },		parts_formatted = parts_formatted, categories = categories, } end

local function pluralize(pos) if pos ~= "nouns" and usub(pos, -5) ~= "verbs" and usub(pos, -4) ~= "ives" then if pos:find("[sx]$") then pos = pos .. "es" else pos = pos .. "s" end end return pos end

-- Remove links and call lang:makeEntryName(term). local function make_entry_name_no_links(lang, term) -- Double parens because makeEntryName returns multiple values. Yuck. return (lang:makeEntryName(m_links.remove_links(term))) end

--[=[ Convert a raw part as passed into an entry point into a part ready for linking. `lang` and `sc` are the overall language and script objects. This uses the overall language and script objects as defaults for the part and parses off any fragment from the term. We need to do the latter so that fragments don't end up in categories and so that we correctly do affix mapping even in the presence of fragments. ]=] local function canonicalize_part(part, lang, sc) if not part then return end -- Save the original (user-specified, part-specific) value of `lang`. If such a value is specified, we don't insert -- a '*fixed with' category, and we format the part using format_derived in Module:etymology rather than -- full_link in Module:links. part.part_lang = part.lang part.lang = part.lang or lang part.sc = part.sc or sc	local term = part.term if not term then return elseif not part.fragment then part.term, part.fragment = m_links.get_fragment(term) else part.term = m_links.get_fragment(term) end end

--[==[ Construct a single linked part based on the information in `part`, for use by `show_affix` and other entry points. This should be called after `canonicalize_part` is called on the part. This is a thin wrapper around `full_link` in Module:links unless `part.part_lang` is specified (indicating that a part-specific language was given), in which case `format_derived` in Module:etymology is called to display a term in a language other than the language of the overall term (specified in `data.lang`). `data` contains the entire object passed into the entry point and is used to access information for constructing the categories added by `format_derived`. ]==] function export.link_term(part, data) local result

if part.part_lang then result = require(etymology_module).format_derived(data.lang, part, data.sort_key, data.nocat,			data.force_cat or debug_force_cat) else -- language (e.g. in a pseudo-loan). result = m_links.full_link(part, "term") end

if part.q and part.q[1] or part.qq and part.qq[1] or part.l and part.l[1] or part.ll and part.ll[1] or		part.refs and part.refs[1] then result = require(pron_qualifier_module).format_qualifiers { lang = part.lang, text = result, q = part.q,			qq = part.qq, l = part.l,			ll = part.ll, refs = part.refs, }	end

return result end

local function canonicalize_script_code(scode) -- Convert fa-Arab, ur-Arab etc. to Arab. return (scode:gsub("^.*%-", "")) end

- --                                 Affix-handling functions                           -- -

-- Figure out the appropriate script for the given affix and language (unless the script is explicitly passed in), and -- return the values of template_hyphens[], display_hyphens[] and lookup_hyphens[] for that script, substituting -- default values as appropriate. Four values are returned: --	DETECTED_SCRIPT, TEMPLATE_HYPHEN, DISPLAY_HYPHEN, LOOKUP_HYPHEN local function detect_script_and_hyphens(text, lang, sc) local scode -- 1. If the script is explicitly passed in, use it. if sc then scode = sc:getCode else local possible_script_codes = lang:getScriptCodes -- YUCK! `possible_script_codes` comes from loadData so #possible_scripts doesn't work (always returns 0). local num_possible_script_codes = m_table.length(possible_script_codes) if num_possible_script_codes == 0 then -- This shouldn't happen; if the language has no script codes, -- the list {"None"} should be returned. error("Something is majorly wrong! Language " .. lang:getCanonicalName .. " has no script codes.") end if num_possible_script_codes == 1 then -- 2. If the language has only one possible script, use it. scode = possible_script_codes[1] else -- 3. Check if any of the possible scripts for the language have non-default values for template_hyphens[] --   or display_hyphens[]. If so, we need to do script detection on the text. If not, just use "Latn", --   which may not be technically correct but produces the right results because Latn has all default --   values for template_hyphens[] and display_hyphens[]. local may_have_nondefault_hyphen = false for _, script_code in ipairs(possible_script_codes) do				script_code = canonicalize_script_code(script_code) if template_hyphens[script_code] or display_hyphens[script_code] then may_have_nondefault_hyphen = true break end end if not may_have_nondefault_hyphen then scode = "Latn" else scode = lang:findBestScript(text):getCode end end end scode = canonicalize_script_code(scode) local template_hyphen = template_hyphens[scode] or "-" local lookup_hyphen = lookup_hyphens[scode] or "-" local display_hyphen = display_hyphens[scode] or default_display_hyphen return scode, template_hyphen, display_hyphen, lookup_hyphen end

--[=[ Given a template affix `term` and an affix type `affix_type`, change the relevant template hyphen(s) in the affix to the display or lookup hyphen specified in `new_hyphen`, or add them if they are missing. `new_hyphen` can be a string, specifying a fixed hyphen, or a function of two arguments (the script code `scode` and the discovered template hyphen, or nil of no relevant template hyphen is present). `thyph_re` is a Lua pattern (which must be enclosed in parens) that matches the possible template hyphens. Note that not all template hyphens present in the affix are changed, but only the "relevant" ones (e.g. for a prefix, a relevant template hyphen is one coming at the end of the affix). ]=] local function reconstruct_term_per_hyphens(term, affix_type, scode, thyph_re, new_hyphen) local function get_hyphen(hyph) if type(new_hyphen) == "string" then return new_hyphen end return new_hyphen(scode, hyph) end

if not affix_type then return term elseif affix_type == "circumfix" then local before, before_hyphen, after_hyphen, after = rmatch(term, "^(.*)" .. thyph_re .. " " .. thyph_re			.. "(.*)$") if not before or ulen(term) <= 3 then -- Unlike with other types of affixes, don't try to add hyphens in the middle of the term to convert it to -- a circumfix. Also, if the term is just hyphen + space + hyphen, return it. return term end return before .. get_hyphen(before_hyphen) .. " " .. get_hyphen(after_hyphen) .. after elseif affix_type == "infix" or affix_type == "interfix" then local before_hyphen, middle, after_hyphen = rmatch(term, "^" .. thyph_re .. "(.*)" .. thyph_re .. "$") if before_hyphen and ulen(term) <= 1 then -- If the term is just a hyphen, return it. return term end return get_hyphen(before_hyphen) .. (middle or term) .. get_hyphen(after_hyphen) elseif affix_type == "prefix" then local middle, after_hyphen = rmatch(term, "^(.*)" .. thyph_re .. "$") if middle and ulen(term) <= 1 then -- If the term is just a hyphen, return it. return term end return (middle or term) .. get_hyphen(after_hyphen) elseif affix_type == "suffix" then local before_hyphen, middle = rmatch(term, "^" .. thyph_re .. "(.*)$") if before_hyphen and ulen(term) <= 1 then -- If the term is just a hyphen, return it. return term end return get_hyphen(before_hyphen) .. (middle or term) else error(("Internal error: Unrecognized affix type '%s'"):format(affix_type)) end end

--[=[ Look up a mapping from a given affix variant to the canonical form used in categories and links. The lookup tables are language-specific according to `lang`, and may be ID-specific according to `affix_id`. The affixes as they appear in the lookup tables (both the variant and the canonical form) are in "lookup affix" format (approximately speaking, they use a regular hyphen for most scripts, but a tatweel for Arabic-script entries and a maqqef for Hebrew-script entries), but the passed-in `affix` param is in "template affix" format (which differs from the lookup affix for Arabic-script entries, because more types of hyphens are allowed in template affixes; see the comments at the top of the file). The remaining parameters to this function are used to convert from template affixes to lookup affixes; see the reconstruct_term_per_hyphens function above.

If the affix contains brackets, no lookup is done. Otherwise, a two-stage process is used, first looking up the affix directly and then stripping diacritics and looking it up again. The reason for this is documented above in the comments at the top of the file (specifically, the comments describing lookup affixes).

The value of a mapping can either be a string (do the mapping regardless of affix ID) or a table indexed by affix ID (where the special value `false` indicates no affix ID). The values of entries in this table can also be strings, or tables with keys `affix` and `id` (again, use `false` to indicate no ID). This allows an affix mapping to map from one ID to another (for example, this is used in English to map the an- prefix with no ID to the a- prefix with the ID 'not').

The Given a template affix `term` and an affix type `affix_type`, change the relevant template hyphen(s) in the affix to the display or lookup hyphen specified in `new_hyphen`, or add them if they are missing. `new_hyphen` can be a string, specifying a fixed hyphen, or a function of two arguments (the script code `scode` and the discovered template hyphen, or nil of no relevant template hyphen is present). `thyph_re` is a Lua pattern (which must be enclosed in parens) that matches the possible template hyphens. Note that not all template hyphens present in the affix are changed, but only the "relevant" ones (e.g. for a prefix, a relevant template hyphen is one coming at the end of the affix). ]=] local function lookup_affix_mapping(affix, affix_type, lang, scode, thyph_re, lookup_hyph, affix_id) local function do_lookup(affix) -- Ensure that the affix uses lookup hyphens regardless of whether it used a different type of hyphens before -- or no hyphens. local lookup_affix = reconstruct_term_per_hyphens(affix, affix_type, scode, thyph_re, lookup_hyph) local function do_lookup_for_langcode(langcode) if export.langs_with_lang_specific_data[langcode] then local langdata = mw.loadData(export.affix_lang_data_module_prefix .. langcode) if langdata.affix_mappings then local mapping = langdata.affix_mappings[lookup_affix] if mapping then if type(mapping) == "table" then mapping = mapping[affix_id or false] if mapping then return mapping end else return mapping end end end end end

-- If `lang` is an etymology-only language, look for a mapping both for it and its full parent. local langcode = lang:getCode local mapping = do_lookup_for_langcode(langcode) if mapping then return mapping end local full_langcode = lang:getFullCode if full_langcode ~= langcode then mapping = do_lookup_for_langcode(full_langcode) if mapping then return mapping end end return nil end

if affix:find("%[%[") then return nil end

-- Double parens because makeEntryName returns multiple values. Yuck. return do_lookup(affix) or do_lookup((lang:makeEntryName(affix))) or nil end

--[==[ For a given template term in a given language (see the definition of "template affix" near the top of the file), possibly in an explicitly specified script `sc` (but usually nil), return the term's affix type ({"prefix"}, {"infix"}, {"suffix"}, {"circumfix"} or {nil} for non-affix) along with the corresponding link and display affixes (see definitions near the top of the file); also the corresponding lookup affix (if `return_lookup_affix` is specified). The term passed in should already have any fragment (after the # sign) parsed off of it. Four values are returned: `affix_type`, `link_term`, `display_term` and `lookup_term`. The affix type can be passed in instead of autodetected (pass in {false} if the term is not an affix); in this case, the template term need not have any attached hyphens, and the appropriate hyphens will be added in the appropriate places. If `do_affix_mapping` is specified, look up the affix in the lang-specific affix mappings, as described in the comment at the top of the file; otherwise, the link and display terms will always be the same. (They will be the same in any case if the template term has a bracketed link in it or is not an affix.) If `return_lookup_affix` is given, the fourth return value contains the term with appropriate lookup hyphens in the appropriate places; otherwise, it is the same as the display term. (This functionality is used in Module:category tree/poscatboiler/data/terms by etymology to convert link affixes into lookup affixes so that they can be looked up in the affix mapping tables.) ]==] function export.parse_term_for_affixes(term, lang, sc, affix_type, do_affix_mapping, return_lookup_affix, affix_id) if not term then return nil, nil, nil, nil end

if term:find("^%^") then -- If term begins with ^, it's not an affix no matter what. Strip off the ^ and return "no affix". term = usub(term, 2) return nil, term, term, term end

-- Remove an asterisk if the morpheme is reconstructed and add it back at the end. local reconstructed = "" if term:find("^%*") then reconstructed = "*" term = term:gsub("^%*", "") end

local scode, thyph, dhyph, lhyph = detect_script_and_hyphens(term, lang, sc) thyph = "([" .. thyph .. "])"

if affix_type == nil then if rfind(term, thyph .. " " .. thyph) then affix_type = "circumfix" else local has_beginning_hyphen = rfind(term, "^" .. thyph) local has_ending_hyphen = rfind(term, thyph .. "$") if has_beginning_hyphen and has_ending_hyphen then affix_type = "infix" elseif has_ending_hyphen then affix_type = "prefix" elseif has_beginning_hyphen then affix_type = "suffix" end end end

local link_term, display_term, lookup_term if affix_type then display_term = reconstruct_term_per_hyphens(term, affix_type, scode, thyph, dhyph) if do_affix_mapping then link_term = lookup_affix_mapping(term, affix_type, lang, scode, thyph, lhyph, affix_id) -- The return value of lookup_affix_mapping may be an affix mapping with lookup hyphens if a mapping -- was found, otherwise nil if a mapping was not found. We need to convert to display hyphens in -- either case, but in the latter case we can reuse the display term, which has already been converted. if link_term then link_term = reconstruct_term_per_hyphens(link_term, affix_type, scode, thyph, dhyph) else link_term = display_term end else link_term = display_term end if return_lookup_affix then lookup_term = reconstruct_term_per_hyphens(term, affix_type, scode, thyph, lhyph) else lookup_term = display_term end else link_term = term display_term = term lookup_term = term end

link_term = reconstructed .. link_term display_term = reconstructed .. display_term lookup_term = reconstructed .. lookup_term

return affix_type, link_term, display_term, lookup_term end

export.get_affix_type = export.parse_term_for_affixes

--[==[ Add a hyphen to a term in the appropriate place, based on the specified affix type, stripping off any existing hyphens in that place. For example, if `affix_type` == {"prefix"}, we'll add a hyphen onto the end if it's not already there (or is of the wrong type). Three values are returned: the link term, display term and lookup term. This function is a thin wrapper around `parse_term_for_affixes`; see the comments above that function for more information. ]==] function export.make_affix(term, lang, sc, affix_type, do_affix_mapping, return_lookup_affix, affix_id) if not (affix_type == "prefix" or affix_type == "suffix" or affix_type == "circumfix" or affix_type == "infix" or		affix_type == "interfix") then error("Internal error: Invalid affix type " .. (affix_type or "(nil)")) end

local _, link_term, display_term, lookup_term = export.parse_term_for_affixes(term, lang, sc, affix_type,		do_affix_mapping, return_lookup_affix, affix_id) return link_term, display_term, lookup_term end

- --                                    Main entry points                               -- -

--[==[ Implementation of affix and surface analysis. `data` contains all the information describing the affixes to be displayed, and contains the following:

be passed to `full_link`, except that the `.lang` field should be missing unless the term is of a language different from the overall `.lang` value (in such a case, the language name is shown along with the term and		  an additional "derived from" category is added). WARNING: The data in `.parts` will be destructively modified. compound type is displayed before the parts (normally capitalized, unless `.nocap` is given). `.surface_analysis` is given).
 * `.lang` (required): Overall language object. Different from term-specific language objects (see `.parts` below).
 * `.sc`: Overall script object (usually omitted). Different from term-specific script objects.
 * `.parts` (required): List of objects describing the affixes to show. The general format of each object is as would
 * `.pos`: Overall part of speech (used in categories, defaults to {"terms"}). Different from term-specific part of speech.
 * `.sort_key`: Overall sort key. Normally omitted except e.g. in Japanese.
 * `.type`: Type of compound, if the parts in `.parts` describe a compound. Strictly optional, and if supplied, the
 * `.nocap`: Don't capitalize the first letter of text displayed before the parts (relevant only if `.type` or
 * `.notext`: Don't display any text before the parts (relevant only if `.type` or `.surface_analysis` is given).
 * `.nocat`: Disable all categorization.
 * `.lit`: Overall literal definition. Different from term-specific literal definitions.
 * `.force_cat`: Always display categories, even on userspace pages.
 * `.surface_analysis`: Implement ; adds `By surface analysis, ` before the parts.

WARNING: This destructively modifies both `data` and the individual structures within `.parts`. ]==] function export.show_affix(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

local text_sections, categories = process_compound_type(data.type, data.surface_analysis or data.nocap, data.notext,		#data.parts > 0)

-- Process each part local parts_formatted = {} local whole_words = 0 local is_affix_or_compound = false

-- Canonicalize and generate links for all the parts first; then do categorization in a separate step, because when -- processing the first part for categorization, we may access the second part and need it already canonicalized. for i, part in ipairs_with_gaps(data.parts) do		part = part or {} data.parts[i] = part canonicalize_part(part, data.lang, data.sc)

-- Determine affix type and get link and display terms (see text at top of file). Store them in the part -- (in fields that won't clash with fields used by full_link in Module:links or link_term), so they -- can be used in the loop below when categorizing. part.affix_type, part.affix_link_term, part.affix_display_term = export.parse_term_for_affixes(part.term,			part.lang, part.sc, nil, not part.alt, nil, part.id)

-- If link_term is an empty string, either a bare ^ was specified or an empty term was used along with inline -- modifiers. The intention in either case is not to link the term. part.term = ine(part.affix_link_term) -- If part.alt would be the same as part.term, make it nil, so that it isn't erroneously tracked as being -- redundant alt text. part.alt = part.alt or (part.affix_display_term ~= part.affix_link_term and part.affix_display_term) or nil

-- Make a link for the part. table.insert(parts_formatted, export.link_term(part, data)) end

-- Now do categorization. for i, part in ipairs_with_gaps(data.parts) do		local affix_type = part.affix_type if affix_type then is_affix_or_compound = true -- We cannot distinguish interfixes from infixes by appearance. Prefer interfixes; infixes will need to -- use ⟨⟩. if affix_type == "infix" then affix_type = "interfix" end

-- Make a sort key. For the first part, use the second part as the sort key; the intention is that if the -- term has a prefix, sorting by the prefix won't be very useful so we sort by what follows, which is -- presumably the root. local part_sort_base = nil local part_sort = part.sort or data.sort_key

if i == 1 and data.parts[2] and data.parts[2].term then local part2 = data.parts[2] -- If the second-part link term is empty, the user requested an unlinked term; avoid a wikitext error -- by using the alt value if available. part_sort_base = ine(part2.affix_link_term) or ine(part2.alt) if part_sort_base then part_sort_base = make_entry_name_no_links(part2.lang, part_sort_base) end end

if part.pos and rfind(part.pos, "patronym") then table.insert(categories, {cat = "patronymics", sort_key = part_sort, sort_base = part_sort_base}) end

if data.pos ~= "terms" and part.pos and rfind(part.pos, "diminutive") then table.insert(categories, {cat = "diminutive " .. data.pos, sort_key = part_sort,					sort_base = part_sort_base}) end

-- Don't add a '*fixed with' category if the link term is empty or is in a different language. if ine(part.affix_link_term) and not part.part_lang then table.insert(categories, {cat = data.pos .. " " .. affix_type .. "ed with " ..					make_entry_name_no_links(part.lang, part.affix_link_term) ..						(part.id and " (" .. part.id .. ")" or ""),					sort_key = part_sort, sort_base = part_sort_base}) end else whole_words = whole_words + 1

if whole_words == 2 then is_affix_or_compound = true table.insert(categories, "compound " .. data.pos) end end end

-- Make sure there was either an affix or a compound (two or more regular terms). if not is_affix_or_compound then error("The parameters did not include any affixes, and the term is not a compound. Please provide at least one affix.") end

if data.surface_analysis then local text = "by " .. glossary_link("surface analysis") .. ", "		if not data.nocap then text = ucfirst(text) end

table.insert(text_sections, 1, text) end

table.insert(text_sections, export.join_formatted_parts { data = data, parts_formatted = parts_formatted,		categories = categories }) return table.concat(text_sections) end

function export.show_surface_analysis(data) data.surface_analysis = true return export.show_affix(data) end

--[==[ Implementation of compound.

WARNING: This destructively modifies both `data` and the individual structures within `.parts`. ]==] function export.show_compound(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

local text_sections, categories = process_compound_type(data.type, data.nocap, data.notext, #data.parts > 0)

local parts_formatted = {} table.insert(categories, "compound " .. data.pos)

-- Make links out of all the parts local whole_words = 0 for i, part in ipairs(data.parts) do		canonicalize_part(part, data.lang, data.sc) -- Determine affix type and get link and display terms (see text at top of file). local affix_type, link_term, display_term = export.parse_term_for_affixes(part.term, part.lang, part.sc,			nil, not part.alt, nil, part.id)

-- If the term is an infix, recognize it as such (which means e.g. that we will display the term without		-- hyphens for East Asian languages). Otherwise, ignore the fact that it looks like an affix and display as -- specified in the template (but pay attention to the detected affix type for certain tracking purposes). if affix_type == "infix" then -- If link_term is an empty string, either a bare ^ was specified or an empty term was used along with -- inline modifiers. The intention in either case is not to link the term. Don't add a '*fixed with' -- category in this case, or if the term is in a different language. -- If part.alt would be the same as part.term, make it nil, so that it isn't erroneously tracked as being -- redundant alt text. if link_term and link_term ~= "" and not part.part_lang then table.insert(categories, {cat = data.pos .. " interfixed with " .. make_entry_name_no_links(part.lang, link_term), sort_key = part.sort or data.sort_key}) end part.term = link_term ~= "" and link_term or nil part.alt = part.alt or (display_term ~= link_term and display_term) or nil else if affix_type then local langcode = data.lang:getCode -- If `data.lang` is an etymology-only language, track both using its code and its full parent's code. track { affix_type, affix_type .. "/lang/" .. langcode } local full_langcode = data.lang:getFullCode if langcode ~= full_langcode then track(affix_type .. "/lang/" .. full_langcode) end else whole_words = whole_words + 1 end end table.insert(parts_formatted, export.link_term(part, data)) end

if whole_words == 1 then track("one whole word") elseif whole_words == 0 then track("looks like confix") end

table.insert(text_sections, export.join_formatted_parts { data = data, parts_formatted = parts_formatted,		categories = categories }) return table.concat(text_sections) end

--[==[ Implementation of blend, univerbation and similar "compound-like" templates.

WARNING: This destructively modifies both `data` and the individual structures within `.parts`. ]==] function export.show_compound_like(data) local parts_formatted = {} local categories = {}

if data.cat then table.insert(categories, data.cat) end

-- Make links out of all the parts for i, part in ipairs(data.parts) do		canonicalize_part(part, data.lang, data.sc) table.insert(parts_formatted, export.link_term(part, data)) end

local text_sections = {} if data.text then table.insert(text_sections, data.text) end if #data.parts > 0 and data.oftext then table.insert(text_sections, " ") table.insert(text_sections, data.oftext) table.insert(text_sections, " ") end table.insert(text_sections, export.join_formatted_parts { data = data, parts_formatted = parts_formatted,		categories = categories }) return table.concat(text_sections) end

--[==[ Make `part` (a structure holding information on an affix part) into an affix of type `affix_type`, and apply any relevant affix mappings. For example, if the desired affix type is "suffix", this will (in general) add a hyphen onto the beginning of the term, alt, tr and ts components of the part if not already present. The hyphen that's added is the "display hyphen" (see above) and may be script-specific. (In the case of East Asian scripts, the display hyphen is an empty string whereas the template hyphen is the regular hyphen, meaning that any regular hyphen at the beginning of the part will be effectively removed.) `lang` and `sc` hold overall language and script objects.

Note that this also applies any language-specific affix mappings, so that e.g. if the language is Finnish and the user specified -käs in the affix and didn't specify an `.alt` value, `part.term` will contain -kas and `part.alt` will contain -käs.

This function is used by the "legacy" templates (prefix, suffix, confix, etc.) where the nature of the affix is specified by the template itself rather than auto-determined from the affix, as is the case with affix.

WARNING: This destructively modifies `part`. ]==] local function make_part_into_affix(part, lang, sc, affix_type) canonicalize_part(part, lang, sc) local link_term, display_term = export.make_affix(part.term, part.lang, part.sc, affix_type, not part.alt, nil, part.id) part.term = link_term -- When we don't specify `do_affix_mapping` to make_affix, link and display terms (first and second retvals of	-- make_affix) are the same. -- If part.alt would be the same as part.term, make it nil, so that it isn't erroneously tracked as being -- redundant alt text. part.alt = part.alt and export.make_affix(part.alt, part.lang, part.sc, affix_type) or (display_term ~= link_term and display_term) or nil local Latn = require(scripts_module).getByCode("Latn") part.tr = export.make_affix(part.tr, part.lang, Latn, affix_type) part.ts = export.make_affix(part.ts, part.lang, Latn, affix_type) end

local function track_wrong_affix_type(template, part, expected_affix_type) if part then local affix_type = export.parse_term_for_affixes(part.term, part.lang, part.sc) if affix_type ~= expected_affix_type then local part_name = expected_affix_type or "base" local langcode = part.lang:getCode local full_langcode = part.lang:getFullCode require("Module:debug/track") { template, template .. "/" .. part_name, template .. "/" .. part_name .. "/" .. (affix_type or "none"), template .. "/" .. part_name .. "/" .. (affix_type or "none") .. "/lang/" .. langcode }			-- If `part.lang` is an etymology-only language, track both using its code and its full parent's code. if full_langcode ~= langcode then require("Module:debug/track")(					template .. "/" .. part_name .. "/" .. (affix_type or "none") .. "/lang/" .. full_langcode				) end end end end

local function insert_affix_category(categories, pos, affix_type, part, sort_key, sort_base) -- Don't add a '*fixed with' category if the link term is empty or is in a different language. if part.term and not part.part_lang then local cat = pos .. " " .. affix_type .. "ed with " .. make_entry_name_no_links(part.lang, part.term) .. (part.id and " (" .. part.id .. ")" or "") if sort_key or sort_base then table.insert(categories, {cat = cat, sort_key = sort_key, sort_base = sort_base}) else table.insert(categories, cat) end end end

--[==[ Implementation of circumfix.

WARNING: This destructively modifies both `data` and `.prefix`, `.base` and `.suffix`. ]==] function export.show_circumfix(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

canonicalize_part(data.base, data.lang, data.sc) -- Hyphenate the affixes and apply any affix mappings. make_part_into_affix(data.prefix, data.lang, data.sc, "prefix") make_part_into_affix(data.suffix, data.lang, data.sc, "suffix")

track_wrong_affix_type("circumfix", data.prefix, "prefix") track_wrong_affix_type("circumfix", data.base, nil) track_wrong_affix_type("circumfix", data.suffix, "suffix")

-- Create circumfix term. local circumfix = nil

if data.prefix.term and data.suffix.term then circumfix = data.prefix.term .. " " .. data.suffix.term data.prefix.alt = data.prefix.alt or data.prefix.term data.suffix.alt = data.suffix.alt or data.suffix.term data.prefix.term = circumfix data.suffix.term = circumfix end

-- Make links out of all the parts. local parts_formatted = {} local categories = {} local sort_base if data.base.term then sort_base = make_entry_name_no_links(data.base.lang, data.base.term) end

table.insert(parts_formatted, export.link_term(data.prefix, data)) table.insert(parts_formatted, export.link_term(data.base, data)) table.insert(parts_formatted, export.link_term(data.suffix, data))

-- Insert the categories, but don't add a '*fixed with' category if the link term is in a different language. if not data.prefix.part_lang then table.insert(categories, {cat=data.pos .. " circumfixed with " .. make_entry_name_no_links(data.prefix.lang, circumfix), sort_key=data.sort_key, sort_base=sort_base}) end

return export.join_formatted_parts { data = data, parts_formatted = parts_formatted, categories = categories } end

--[==[ Implementation of confix.

WARNING: This destructively modifies both `data` and `.prefix`, `.base` and `.suffix`. ]==] function export.show_confix(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

canonicalize_part(data.base, data.lang, data.sc) -- Hyphenate the affixes and apply any affix mappings. make_part_into_affix(data.prefix, data.lang, data.sc, "prefix") make_part_into_affix(data.suffix, data.lang, data.sc, "suffix")

track_wrong_affix_type("confix", data.prefix, "prefix") track_wrong_affix_type("confix", data.base, nil) track_wrong_affix_type("confix", data.suffix, "suffix")

-- Make links out of all the parts. local parts_formatted = {} local prefix_sort_base if data.base and data.base.term then prefix_sort_base = make_entry_name_no_links(data.base.lang, data.base.term) elseif data.suffix.term then prefix_sort_base = make_entry_name_no_links(data.suffix.lang, data.suffix.term) end

-- Insert the categories and parts. local categories = {}

table.insert(parts_formatted, export.link_term(data.prefix, data)) insert_affix_category(categories, data.pos, "prefix", data.prefix, data.sort_key, prefix_sort_base)

if data.base then table.insert(parts_formatted, export.link_term(data.base, data)) end

table.insert(parts_formatted, export.link_term(data.suffix, data)) -- FIXME, should we be specifying a sort base here? insert_affix_category(categories, data.pos, "suffix", data.suffix)

return export.join_formatted_parts { data = data, parts_formatted = parts_formatted, categories = categories } end

--[==[ Implementation of infix.

WARNING: This destructively modifies both `data` and `.base` and `.infix`. ]==] function export.show_infix(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

canonicalize_part(data.base, data.lang, data.sc) -- Hyphenate the affixes and apply any affix mappings. make_part_into_affix(data.infix, data.lang, data.sc, "infix")

track_wrong_affix_type("infix", data.base, nil) track_wrong_affix_type("infix", data.infix, "infix")

-- Make links out of all the parts. local parts_formatted = {} local categories = {}

table.insert(parts_formatted, export.link_term(data.base, data)) table.insert(parts_formatted, export.link_term(data.infix, data))

-- Insert the categories. -- FIXME, should we be specifying a sort base here? insert_affix_category(categories, data.pos, "infix", data.infix)

return export.join_formatted_parts { data = data, parts_formatted = parts_formatted, categories = categories } end

--[==[ Implementation of prefix.

WARNING: This destructively modifies both `data` and the structures within `.prefixes`, as well as `.base`. ]==] function export.show_prefix(data) data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

canonicalize_part(data.base, data.lang, data.sc) -- Hyphenate the affixes and apply any affix mappings. for i, prefix in ipairs(data.prefixes) do		make_part_into_affix(prefix, data.lang, data.sc, "prefix") end

for i, prefix in ipairs(data.prefixes) do		track_wrong_affix_type("prefix", prefix, "prefix") end

track_wrong_affix_type("prefix", data.base, nil)

-- Make links out of all the parts. local parts_formatted = {} local first_sort_base = nil local categories = {}

if data.prefixes[2] then first_sort_base = ine(data.prefixes[2].term) or ine(data.prefixes[2].alt) if first_sort_base then first_sort_base = make_entry_name_no_links(data.prefixes[2].lang, first_sort_base) end elseif data.base then first_sort_base = ine(data.base.term) or ine(data.base.alt) if first_sort_base then first_sort_base = make_entry_name_no_links(data.base.lang, first_sort_base) end end

for i, prefix in ipairs(data.prefixes) do		table.insert(parts_formatted, export.link_term(prefix, data)) insert_affix_category(categories, data.pos, "prefix", prefix, data.sort_key, i == 1 and first_sort_base or nil) end

if data.base then table.insert(parts_formatted, export.link_term(data.base, data)) else table.insert(parts_formatted, "") end

return export.join_formatted_parts { data = data, parts_formatted = parts_formatted, categories = categories } end

--[==[ Implementation of suffix.

WARNING: This destructively modifies both `data` and the structures within `.suffixes`, as well as `.base`. ]==] function export.show_suffix(data) local categories = {}

data.pos = data.pos or default_pos data.pos = pluralize(data.pos)

canonicalize_part(data.base, data.lang, data.sc) -- Hyphenate the affixes and apply any affix mappings. for i, suffix in ipairs(data.suffixes) do		make_part_into_affix(suffix, data.lang, data.sc, "suffix") end

track_wrong_affix_type("suffix", data.base, nil) for i, suffix in ipairs(data.suffixes) do		track_wrong_affix_type("suffix", suffix, "suffix") end

-- Make links out of all the parts. local parts_formatted = {}

if data.base then table.insert(parts_formatted, export.link_term(data.base, data)) else table.insert(parts_formatted, "") end

for i, suffix in ipairs(data.suffixes) do		table.insert(parts_formatted, export.link_term(suffix, data)) end

-- Insert the categories. for i, suffix in ipairs(data.suffixes) do -- FIXME, should we be specifying a sort base here? insert_affix_category(categories, data.pos, "suffix", suffix)

if suffix.pos and rfind(suffix.pos, "patronym") then table.insert(categories, "patronymics") end end

return export.join_formatted_parts { data = data, parts_formatted = parts_formatted, categories = categories } end

return export

title: Module:affix


text:
フラッシュ

Etymology 1
Borrowed from.

Noun

 * 1)  a flashbulb

Etymology 2
Borrowed from.

Noun

 * 1)  a flush

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

title: フラッシュ


text:
Thread:User talk:CodeCat/Unicode tables broke/reply (2)

...huh. It's gone now. Strange.


text:
互い

Noun

 * 1) a mutual relationship, doing with each other

Usage notes
This is often used with the honorific as.

title: 互い


text:
pronunzier

Verb

 * 1) To pronounce

title: pronunzier


text: pronunzian

title: pronunzian


text: pronunzié

title: pronunzié


text: pronunziés

title: pronunziés


text: pronunzieda

title: pronunzieda


text: pronunziedes

title: pronunziedes


text: pronunzieie

title: pronunzieie


text: pronunzies

title: pronunzies


text: pronunzieies

title: pronunzieies


text: pronunzieia

title: pronunzieia


text: pronunziea

title: pronunziea


text: pronunzion

title: pronunzion


text: pronunzieis

title: pronunzieis


text: pronunziove

title: pronunziove


text: pronunzioves

title: pronunzioves


text: pronunziova

title: pronunziova


text: pronunziovan

title: pronunziovan


text: pronunziovais

title: pronunziovais


text: pronunziaré

title: pronunziaré


text: pronunziaras

title: pronunziaras


text: pronunziarà

title: pronunziarà


text: pronunziaron

title: pronunziaron


text: pronunziareis

title: pronunziareis


text: pronunziasses

title: pronunziasses


text: pronunziassa

title: pronunziassa


text: pronunziassan

title: pronunziassan


text: pronunziassais

title: pronunziassais


text: pronunziede

title: pronunziede


text:
青葉

Noun

 * 1) green leaves

Proper noun

 * 1) A place name, such as that of  in the city of.

title: 青葉


text: recursc

title: recursc


text:
desvier

Verb

 * 1) to deflect, divert
 * 2) to distract

title: desvier


text: desvian

title: desvian


text: desviés

title: desviés


text: desvieda

title: desvieda


text: desviedes

title: desviedes


text: desvieie

title: desvieie


text: desvieies

title: desvieies


text: desvieia

title: desvieia


text: desviea

title: desviea


text: desvion

title: desvion


text: desviove

title: desviove


text: desvioves

title: desvioves


text: desviova

title: desviova


text: desviovan

title: desviovan


text: desviovais

title: desviovais


text: desviarà

title: desviarà


text:
延びる

Etymology
From the classical upper bigrade verb(バ行上二段活用) のぶ. Cognate with 🇨🇬.

Verb

 * 1) become longer; be extended; be lengthened
 * 2) be postponed
 * 3) live long; achieve longevity
 * 1) be postponed
 * 2) live long; achieve longevity
 * 1) live long; achieve longevity

title: 延びる


text: desviassa

title: desviassa


text: desviassan

title: desviassan


text: desviassais

title: desviassais


text: desviede

title: desviede


text:
一例

Adverb

 * 1) alike; in the same way

Noun

 * 1) one example

title: 一例


text: limiteda

title: limiteda


text: limitedes

title: limitedes


text: limiteie

title: limiteie


text: limiteies

title: limiteies


text: limiteia

title: limiteia


text: limitea

title: limitea


text: limitove

title: limitove


text: limitoves

title: limitoves


text: limitova

title: limitova


text: limitovan

title: limitovan


text: limitovais

title: limitovais


text: limitassa

title: limitassa


text: limitassan

title: limitassan


text: limitassais

title: limitassais


text: limitede

title: limitede


text:
ciun

Adjective

 * 1) what, which

Etymology
.

Noun

 * 1) soapwort

title: ciun


text: ciuna

title: ciuna


text: ciugn

title: ciugn


text: ciunes

title: ciunes


text:
anuler

Verb

 * 1) To annul

title: anuler


text: anulés

title: anulés


text: anuleda

title: anuleda


text: anuledes

title: anuledes


text: anuleie

title: anuleie


text: anuleies

title: anuleies


text: anuleia

title: anuleia


text: anulea

title: anulea


text: anulon

title: anulon


text: anulove

title: anulove


text: anuloves

title: anuloves


text: anulova

title: anulova


text: anulovan

title: anulovan


text: anulovais

title: anulovais


text: anularà

title: anularà


text: anulassa

title: anulassa


text: anulassan

title: anulassan


text: anulassais

title: anulassais


text: anulede

title: anulede


text:
chemun

Noun

 * 1) commune

title: chemun


text: chemuns

title: chemuns


text:
zità

Etymology
.

Noun

 * 1) town, city

title: zità


text: ziteies

title: ziteies


text: metropolitanes

title: metropolitanes


text:
capitela

Noun

 * 1) capital

title: capitela


text:
Trentin

Etymology
Borrowed from.

Proper noun

 * 1) Trentino

Etymology
Borrowed from.

title: Trentin


text:
Südtirol

Etymology
From.

title: Südtirol


text:
Trënt

Proper noun

 * 1) Trento

title: Trënt


text:
Bulsan

Proper noun

 * 1) Bolzano

title: Bulsan


text:
segondo

Etymology
From ; cf. Italian.

Adjective

 * 1) second

title: segondo


text: segonda

title: segonda


text: segondi

title: segondi


text: segondes

title: segondes


text: haragei

title: haragei


text:
はらげい

Noun

 * 1)  a technique used by actors to convey emotion without verbal speech or gesture; a performance carried out on top of someone's belly; a performance using a face drawn on someone's belly; going with one's gut, using one's intuition

title: はらげい


text:
nteressà

Adjective

 * 1) interested

title: nteressà


text: nteresseda

title: nteresseda


text:
nteressé

Adjective

 * 1) interested

title: nteressé


text: nteressedes

title: nteressedes


text: esteres

title: esteres


text:
europeich

Adjective

 * 1) European

title: europeich


text:
munizion

Noun

 * 1)  munitions

title: munizion


text: munizions

title: munizions


text: Category:Japanese terms spelled with 自 read as じ


text:
marcià

Etymology
.

Adjective

 * 1) Martian

Noun

 * 1) Martian

Etymology
From.

Noun

 * 1) market

title: marcià


text: marcei

title: marcei


text:
concurenza

Noun

 * 1) competition (commercial rivalry)

title: concurenza


text:
agochar

Etymology
. Compare 🇨🇬 and 🇨🇬.

Verb

 * 1) to bend down, crouch
 * 2) to bow
 * 3)  to abase
 * 4) to cover, wrap up (with clothes)
 * 5) to cover, shelter
 * 6) to hide
 * 7)  to cover the chicks with the wings
 * 1) to hide
 * 2)  to cover the chicks with the wings
 * 1)  to cover the chicks with the wings
 * 1)  to cover the chicks with the wings

title: agochar


text: acochar

title: acochar


text:
póla

Etymology
Probably from *punulla, *pululla, metathesis/dissimilation from.

Noun

 * 1) branch part of a tree

title: póla


text: pólas

title: pólas


text:
varelo

Etymology
Probably related to.

Noun

 * 1) twig, branch part of a tree

title: varelo


text: varelos

title: varelos


text: polisóns

title: polisóns


text:
Camassia

Etymology
, from.

Hypernyms

 * ; - subfamily

Hyponyms

 * - type species;, , , , - other species

title: Camassia


text: rock stars

title: rock stars


text: Category:gl:Fabrics

title: Category:gl:Fabrics


text:
buxeo

Etymology
From, from , of origin. Cognate with 🇨🇬.

Noun

 * 1) butcher
 * 2) executioner, hangman
 * 1) executioner, hangman

title: buxeo


text: buxeos

title: buxeos


text: confirmed bachelors

title: confirmed bachelors


text:
ressorsa

Noun

 * 1) resource

title: ressorsa


text: ressorses

title: ressorses


text:
variedat

Etymology
From.

Noun

 * 1) variety

title: variedat


text:
قمپز درکردن

Etymology
Compound of.

Verb

 * 1)  to exaggerate, to overstate

title: قمپز درکردن


text: Category:Persian terms derived from Ottoman Turkish


text: anagrafs

title: anagrafs


text: 巫術士

title: 巫術士


text: adchectivo

title: adchectivo


text:
pruzessuel

Adjective

 * 1) Of or pertaining to the legal process

title: pruzessuel


text: pruzessuela

title: pruzessuela


text: pruzessuei

title: pruzessuei


text: pruzessueles

title: pruzessueles


text:
巫術師

Etymology
Compound of.

Noun

 * 1) magician, sorcerer, shaman

title: 巫術師


text: livela

title: livela


text: livei

title: livei


text: liveles

title: liveles


text: Category:an:Chemical elements

title: Category:an:Chemical elements


text:
veyer

Etymology
From, present active infinitive of.

Verb

 * 1) to see

title: veyer


text:
Module:affix/documentation

This module, accessed through Module:affix/templates, powers most of the morphology templates, including, , , , , , and various others, as well as  and.

title: Module:affix/documentation


text: Category:Etymology modules

title: Category:Etymology modules


text:
granodiorita

Noun

 * 1)  intrusive igneous rock

Noun

 * 1)  granodiorite

title: granodiorita


text: granodioritas

title: granodioritas


text:
granodioritic

Adjective

 * 1)  of or related to granodiorite

title: granodioritic


text:
niable

Adjective

 * 1) deniable

title: niable


text: ruovikkoineen

title: ruovikkoineen


text:
ಸಿಡಿಗುಂಡು

Noun

 * 1) bomb explosive device

title: ಸಿಡಿಗುಂಡು


text:
bombă

Etymology
,.

Noun

 * 1) bomb explosive device

title: bombă


text: biomase

title: biomase


text:
ಬಿಡುಗಡೆ

Noun

 * 1) salvation

title: ಬಿಡುಗಡೆ


text:
ವಿಮುಕ್ತಿ

Noun

 * 1) salvation

title: ವಿಮುಕ್ತಿ


text:
ವಿಮೋಚನೆ

Noun

 * 1) salvation

title: ವಿಮೋಚನೆ


text:
animal tester

Noun

 * 1) One who engages in animal testing

title: animal tester


text:
klozo

Noun

 * 1) occlusion

title: klozo


text: klozi

title: klozi


text:
klozeso

Noun

 * 1) occlusion

title: klozeso


text: klozesi

title: klozesi


text:
desklozar

Etymology
From.

Verb

 * 1)  to unclose, throw open

title: desklozar


text:
cirkumklozar

Etymology
From.

Verb

 * 1)  to enclose, encompass, inclose

title: cirkumklozar


text:
cirkum

Etymology
Borrowed from.

Preposition

 * 1) about, around, roundabout place, time, quantity

title: cirkum


text:
klozita

Adjective

 * 1) closed

title: klozita


text:
apertita

Adjective

 * 1) open

title: apertita


text:
disponebla

Adjective

 * 1) disposable
 * 2) unattached
 * 3) available, ready for use

title: disponebla


text: diagnozi

title: diagnozi


text:
diagnozar

Verb

 * 1)  to diagnose a patient with a sickness

title: diagnozar


text:
maladeyo

Noun

 * 1) sick ward, infirmary

title: maladeyo


text: maladeyi

title: maladeyi


text:
maladeta

Adjective

 * 1) unwell, indisposed, poorly

title: maladeta


text:
maladatra

Adjective

 * 1) sickish, sickly
 * 2) morbid

title: maladatra


text:
malado

Etymology 1
From, attested in local High Medieval Latin charters as mallato; ultimately from , perhaps through.

Noun

 * 1)  servant; agent

Noun

 * 1) patient, sick person

title: malado


text:
Thread:User talk:CodeCat/Filter 25

You seem to know how to write abuse filters... can you take a look at filter 25 and figure out why it's catching so many things that seem totally unrelated to it? It's supposed to tag (and, once it's working right, block) edits in which people who've made few edits add links or certain keywords... but it's actually tagging such random edits as this and this.

title: Thread:User talk:CodeCat/Filter 25


text:
maladulo

Noun

 * 1) patient sick person

title: maladulo


text: maladuli

title: maladuli


text:
maladino

Noun

 * 1) patient sick person

title: maladino


text: maladini

title: maladini


text:
Thread:User talk:CodeCat/Filter 25/reply

I don't really know how to write them that well. I don't know what the \b is for. Maybe you should ask at the GP instead?


text:
maladesar

Verb

 * 1)  to be sick

title: maladesar


text:
Schizachyrium

Etymology
From, referring to either the glume or the toothed lemmas.

Hypernyms

 * ; - subfamily;  - tribe;  - subtribe

Hyponyms

 * - type species;,  ,  ,  ,  ,  (little bluestem),  ,   - selected species
 * For additional species see or

title: Schizachyrium


text:
maladigar

Verb

 * 1)  to make sick, to sicken

title: maladigar


text:
maladeskar

Verb

 * 1)  to sicken

title: maladeskar


text:
malvarozo

Noun

 * 1) hollyhock

title: malvarozo


text: malvarozi

title: malvarozi


text:
makronukleo

Noun

 * 1)  macronucleus

title: makronukleo


text: makronuklei

title: makronuklei


text:
makrosporangio

Etymology
(see 🇨🇬).

Noun

 * 1)  megasporangium

title: makrosporangio


text: makrosporangii

title: makrosporangii


text:
mikrosporangio

Etymology
(see 🇨🇬).

Noun

 * 1)  microsporangium

title: mikrosporangio


text: mikrosporangii

title: mikrosporangii


text:
makrosporo

Noun

 * 1)  megaspore, macrospore

title: makrosporo


text:
makrospori

Etymology
(see 🇨🇬).

Noun

 * 1)  macrospore

title: makrospori


text:
megasporo

Noun

 * 1)  megaspore

title: megasporo


text:
megaspori

Etymology
From or akin to.

Noun

 * 1)  megaspore

title: megaspori


text:
mikrosporo

Noun

 * 1)  microspore

title: mikrosporo


text:
mikrospori

Etymology
(see 🇨🇬).

Noun

 * 1)  microspore

title: mikrospori


text:
makrogameto

Noun

 * 1) macrogamete, megagamete

title: makrogameto


text: makrogameti

title: makrogameti


text:
mikrogameto

Noun

 * 1) microgamet, microgamete

title: mikrogameto


text: mikrogameti

title: mikrogameti


text:
Module talk:affix

English as the default language
It's a good idea to make this similar to other linking templates, by considering "und" as the default language code, and passing the language code to the first parameter, instead of a named one. --Z 20:34, 3 August 2013 (UTC)
 * But that would break compatibility, so it would need more discussion and work. Not to mention a new name... 20:42, 3 August 2013 (UTC)
 * We only need a new title actually. And we eventually should change the title, because "compound" is not a correct word for affixed forms I think. --Z 20:47, 3 August 2013 (UTC)
 * That's assuming we do merge the templates. That's still far from certain, it's only been a few hours. 20:50, 3 August 2013 (UTC)

Support for other scripts
Other scripts use different characters and rules for hyphen, e.g. in Persian alphabet "ـ" is used, and it shouldn't be used after certain letters, so some prefixes should be displayed without any extra sign. --Z 20:40, 3 August 2013 (UTC)

sc
Regarding -- TODO: If we can assume that all terms will have the same script, -- then we can do script detection before calling full_link, -- rather than letting it try to detect the script for each term individually. we can move this from Module:links to Module:utilities as a function named say determine_script with arguments  and   (optional) and use it in full_link in Module:links and here in Module:compound before calling full_link. --Z 19:44, 5 August 2013 (UTC)

No part of the compound specified
I think it shouldn't be required to specify at least one part of the compound. i.e.

should return the text 'Compound' instead of module error. It would be useful because some languages have specific link templates, for example 나가다. Wyang (talk) 00:59, 1 May 2014 (UTC)
 * But what should the template do if there is nothing to do it with? 01:02, 1 May 2014 (UTC)
 * Just return the word 'Compound' and place the entry in the corresponding compound category, and allow the user to write the rest. Wyang (talk) 01:08, 1 May 2014 (UTC)
 * Why would we want to complicate the template just for it to categorise? You can use other things if you want categories... 01:12, 1 May 2014 (UTC)
 * Like...? Wyang (talk) 01:19, 1 May 2014 (UTC)
 * , etc. Or even just writing the plain category wikitext.  01:25, 1 May 2014 (UTC)
 * If done right, it should simplify the template rather than complicate it. --WikiTiki89 01:30, 1 May 2014 (UTC)
 * I agree. Wouldn't it involve just moving the category section in the code above the test for parts of the compound, and letting 'else' return 'Compound' .. categories? Wyang (talk) 01:52, 1 May 2014 (UTC)

When parts of a word are from different langauges
Suggestion: add a new langs parameter. Currently there is no easy way to do that.

Maybe like this?
 * langs=la&en

--Dixtosa (talk) 17:33, 26 August 2014 (UTC)
 * Are words ever compounded as part of the loaning process? —CodeCat 17:37, 26 August 2014 (UTC)

 * Solution:  +  . --WikiTiki89 18:01, 26 August 2014 (UTC)
 * That's not a solution as much as it's a workaround. I'd rather know for sure if there are legitimate reasons to add this feature. —CodeCat 18:04, 26 August 2014 (UTC)
 * It's a solution. What's the point of the template anyway? It doesn't make anyone's lives any easier. The only thing useful it does is categorize. --WikiTiki89 18:14, 26 August 2014 (UTC)
 * My initial thought: what to do with words like ?
 * This word is formed by unattested + . The first part is surely from Persian.
 * One may be tempted to think of this word as formed by some other word related to Afghanistan (like, ), but this is obviously alogical because at least one of them was first created by suffixing to the foreign word.
 * P.S. in order to avoid misunderstandings is actually a word nowadays, but it is a recent borrowing (from English).
 * @Wikitiki, And how is your solution going to categorize?
 * You are wrong that is a recent borrowing from English. See the word in Rayfield, A Comprehensive Georgian-English Dictionary, page 50, where  is glossed as 1. cruel, bad-tempered; 2 (Kiziqi dialect) poor, destitute; 3 (obsolete) Afghan. So your word is formed as   . --Vahag (talk) 19:25, 26 August 2014 (UTC)
 * If you remove the silly requirement of providing "at least two parts of a compound", then you could do this: . In this case, you can already do this:  :  . Even if Vahag is right and this does not apply to this particular word, it does apply to other words. --WikiTiki89 19:50, 26 August 2014 (UTC)
 * Vahag, that does not matter... you get the picture.
 * Examples again: vexillology, French neologisme, protologism, dynode and many more neologisms that btw are more prone to be mixtures, because it is more like a boss xD. There is also (I think) a very important type of words that have seemingly ordinary affixes, but actually those words predated the emergence of a particular affix. (I am still short of examples but you get the picture again xD).
 * Actually this type of words have a name. This pdf expands on it.
 * @Wikitiki89, you are adding categories, making it look like as if compound template were used and stuff, but this is less parsable. The more parsable the better.--Dixtosa (talk) 21:47, 26 August 2014 (UTC)
 * You mean humanly parsable? My version is definitely more humanly parsable. --WikiTiki89 22:28, 26 August 2014 (UTC)
 * My preference is to add,   parameters to the morphology templates. They would specify the foreign language of each term.   would still be required, because it would be used to determine how to categorise the entry. For : . Is this ok? —CodeCat 23:02, 26 August 2014 (UTC)
 * I'm satisfied with that, although I'm personally going to continue doing it my way. --WikiTiki89 01:37, 27 August 2014 (UTC)
 * I've added,   etc. as parameters to ,  and . —CodeCat 14:46, 27 August 2014 (UTC)

complex nouns?
d1g (talk) 17:45, 13 April 2017 (UTC)
 * колхоз (2 prefixes)
 * паровоз (2 prefixes + interfix -о-)
 * Question mark? —CodeCat 17:59, 13 April 2017 (UTC)
 * I'm not sure which template to use and how exactly d1g (talk) 18:05, 13 April 2017 (UTC)
 * There aren't two prefixes in these cases. колхоз is an abbreviation. паро- is the compounding form of пар. воз is a stem in and of itself, which is extracted from возить by removing the suffix -ить. --WikiTiki89 18:10, 13 April 2017 (UTC)
 * If there were multiple affixes you could use, which will analyze the pattern of hyphens and categorize appropriately. DTLHS (talk) 18:12, 13 April 2017 (UTC)
 * I don't think it's necessary to treat as different from  though. The latter automatically turns into the former when it's added to a compound. —CodeCat 18:16, 13 April 2017 (UTC)
 * That's what I said, isn't it? --WikiTiki89 18:22, 13 April 2017 (UTC)
 * I don't know. Ignore me, I don't know what I'm doing. —CodeCat 18:59, 13 April 2017 (UTC)
 * , first, I confused "prefix" with "roots" and "stems".
 * 2: according to Словообразование "через соединительную гласную (о, е): корень+корень = паровоз" is similar to speedometer, but I'm not able to find this exact example in -о- (585, 775)
 * 3: which template to use at колхоз and how? d1g (talk) 08:32, 15 April 2017 (UTC)

option?
Could we add a notext option so that the template merely categorizes by suffix, or is it a bad idea? Crom daba (talk) 12:36, 17 August 2017 (UTC)

Don't put ids into generated categories
It might be useful in some cases to keep the default category when linking to a sense id with id. Right now it always creates "prefixed with Foo- (id)" – Jberkel 08:29, 22 March 2022 (UTC)

 * Agreed. The  option works, but also removes other categories, which is not desirable. —Justin ( koavf ) ❤T☮C☺M☯ 17:55, 22 March 2022 (UTC)
 * Compounds don't generate these subcategories, affixes do, and in the case of affixes I strongly oppose even just making it possible to suppress the more granular categorization on the grounds that we eventually want to put all elements in their respective subcategories, a task for which the parent category serves as a cleanup todo list, see e.g. the RFC in Category:English words suffixed with -er. Furthermore, having an entry in both the most granular category as well as a parent category is usually wrong; for instance, we put in Category:en:Pizza but not in its parent category Category:en:Foods. — Fytcha〈 T | L | C 〉 21:05, 22 March 2022 (UTC)
 * Yeah right, but the affix template uses this module. Can you list them all in one page? I think you can have too much categorization, where it's hard to figure out in which categories the entries actually are. On the other hand, I'm not too bothered about red-linked categories. From a usability perspective anchor links are more important, especially for large entries. –Jberkel 21:12, 22 March 2022 (UTC)

Now,  adds categories, but not   where n=/=1. E.g. see McShit. Thoughts? —Justin ( koavf ) ❤T☮C☺M☯ 21:17, 22 March 2022 (UTC)
 * That's normal, only affixes are categorized. Why did you add 3 ids for non-existent sense ids? – Jberkel 21:25, 22 March 2022 (UTC)
 * Because there were three context labels. Why choose just one of them for the sense id? How do you choose which one? —Justin ( koavf ) ❤T☮C☺M☯ 21:29, 22 March 2022 (UTC)
 * Because in, the ID "A" applies to prefix-, "B" to word and "C" to -suffix. Only affixes (such as prefixes and suffixes) get categories; morphemes that are not affixes, such as "dog" and "house" in , do not. 70.172.194.25 21:36, 22 March 2022 (UTC)
 * I think the lesson learned here is to not mess with stuff, let alone revert others, when one has no idea what's going on. Talk about being confidently incorrect... — Fytcha〈 T | L | C 〉 21:32, 22 March 2022 (UTC)
 * Boy, it sure would be nice if you were not condescending and were instead civil and stuff. Why choose one of the labels as, then? —Justin ( koavf ) ❤T☮C☺M☯ 01:36, 23 March 2022 (UTC)
 * Maybe this will help clarify. The number N in  tells the module which morpheme (either an affix, like pre- or -ing, or a regular word) the label applies to. Only one ID applies per morpheme, it's not like you're stacking them on top of each other. So, for example (using made up senseids), if you had on catfisher:
 * The  applies to the word catfish, and disambiguates it from the online slang meaning. The   applies to the suffix -er and disambiguates it from other meanings of the suffix (such as the comparative -er in bigger). Both IDs have the effect of making the link highlight the correct sense. However, only the -er would be categorized. This is because, in general, affixes are categorized, but words that make up parts of compounds are not.
 * In the example you gave (McShit),  seemed special because in that example the structure is prefix + word. In the example of catfisher, it is word + suffix, so   would be the one that gets the category. If you had another structure like prefix + word + suffix, e.g. *recatfisher, "a person who once more fishes for catfish":
 * You could have multiple affix categories, but you would still not have categories for non-affix morphemes. 70.172.194.25 05:02, 23 March 2022 (UTC)
 * Can you make the changes you suggested regarding noidcat? I had more changes reverted by because of "accidental" categorization. The goal of my edits was just to avoid hardcoding fragment links in the HTML. – Jberkel 18:06, 19 April 2022 (UTC)
 * Well, previously the change I had implemented was to double categorize both with and without the ID. However, I can have a go at implementing the noidcat change if this is deemed preferable. 70.172.194.25 18:09, 19 April 2022 (UTC)
 * Yes, but the problem are the unwanted category red links, it seems. With your proposed change they'd still be there. Thanks! – Jberkel 18:20, 19 April 2022 (UTC)
 * User:Jberkel: and  should implement noidcat . Whether to move this into the main modules is up to others, but the technical solution is available. 70.172.194.25 19:01, 19 April 2022 (UTC)
 * Looking at the code, it feels a bit strange to first add the ids to the categories, only to remove them later. – Jberkel 19:40, 19 April 2022 (UTC)
 * You're right, it's not the most elegant way. But the other way would require modifying all of the affix-specific functions like show_prefix, etc. I could do it the right way, if desired, though. 70.172.194.25 20:42, 19 April 2022 (UTC)
 * Yes if you can, it'll be less fragile if it doesn't depend on the way the category is formatted. – Jberkel 21:34, 19 April 2022 (UTC)
 * User:Jberkel, This should work: . The /templates submodule needs the same changes as before. 70.172.194.25 03:10, 25 April 2022 (UTC)
 * Just to be clear, I have no problem with adding new categories: just make sure that they are part of a hierarchy in the modules and that they are sensible categories to have. Either option is fine with me, but just not redlink cats. Let me know if I can help. —Justin ( koavf ) ❤T☮C☺M☯ 18:28, 19 April 2022 (UTC)
 * User:Jberkel, This should work: . The /templates submodule needs the same changes as before. 70.172.194.25 03:10, 25 April 2022 (UTC)
 * Just to be clear, I have no problem with adding new categories: just make sure that they are part of a hierarchy in the modules and that they are sensible categories to have. Either option is fine with me, but just not redlink cats. Let me know if I can help. —Justin ( koavf ) ❤T☮C☺M☯ 18:28, 19 April 2022 (UTC)

No hyphen for Vietnamese
Vietnamese uses Latin script, but all syllables are (usually) written with spaces in between. Given that affixes are usually separate syllables, they aren’t written together with the base word, so using a hyphen doesn’t make sense. As one can see, almost all entries in Category:Vietnamese suffixes and Category:Vietnamese prefixes are without hyphens. Could the template be edited to give the correct behaviour? Currently, most Vietnamese affixed entries are categorised as compounds, which is not always a good thing. Thank you! MuDavid 栘𩿠 (talk) 01:50, 19 October 2022 (UTC)

Italicize affix

 * E.g., results in the text “English terms suffixed with -ly”. The suffix should be in italics (“English terms suffixed with -ly”). J3133 (talk) 00:36, 4 June 2023 (UTC)

 * Do you know if this is possible or do I need to clarify? Should I post this at the Grease pit instead? J3133 (talk) 14:11, 7 June 2023 (UTC)

 * I found out that it uses the CategoryTree extension, which does not have a way to change the display. J3133 (talk) 15:26, 9 June 2023 (UTC)
 * Thanks and apologies for the delay; I've been traveling. Benwing2 (talk) 21:35, 9 June 2023 (UTC)

Incomplete cats when langs don't match
See for example. This should be placed into the cat "Proto-Georgian-Zan terms suffixed with *-el". კვარია (talk) 07:10, 29 October 2023 (UTC)

title: Module talk:affix


text:
Reconstruction:Proto-Balto-Slavic/saušás

Etymology
From, from.

Adjective

 * 1) dry

Descendants

 * East Baltic:
 * the result of assimilation >, or inherited from a Balto-Slavic dialect in which the RUKI sound change didn't occur
 * the result of assimilation >, or inherited from a Balto-Slavic dialect in which the RUKI sound change didn't occur
 * the result of assimilation >, or inherited from a Balto-Slavic dialect in which the RUKI sound change didn't occur


text:
chumico

Noun

 * 1)  soapberry

title: chumico


text: chumicos

title: chumicos


text: Chicksaw

title: Chicksaw


text: Chicksaws

title: Chicksaws


text: Chickasaws

title: Chickasaws


text:
Cedrus

Etymology
From, from.

Hyponyms

 * (Lebanon cedar) - type species; (Atlas cedar),  (Cyprus cedar),  (deodar cedar) - other species

title: Cedrus


text:
Template:Pinaceae Hypernyms

 * Pinaceae - family

title: Template:Pinaceae Hypernyms


text:
Template:Pinaceae Hypernyms/documentation

This is a typing shortcut intended for use as is under the header Hyponyms for taxa in Pinaceae. It can be used with subst:.


text:
lezitent

Adjective

 * 1) zealous

title: lezitent


text: lezitenta

title: lezitenta


text: lezitenc

title: lezitenc


text: lezitentes

title: lezitentes


text:
zedola

Etymology
From, (compare 🇨🇬), the diminutive of ,  ultimately from.

Noun

 * 1) banknote
 * 2) coupon, voucher

title: zedola


text: zedoles

title: zedoles


text:
hemoglobino

Noun

 * 1)  hemoglobin

title: hemoglobino


text:
hemoglobini

Etymology
.

Noun

 * 1)  hemoglobin

title: hemoglobini


text: albuminoids

title: albuminoids


text:
albuminoido

Noun

 * 1) albuminoid

title: albuminoido


text:
alambiko

Noun

 * 1) alembic, still for distilling

title: alambiko


text: alambiki

title: alambiki


text: rechtdoorzee

title: rechtdoorzee


text:
alantoido

Noun

 * 1) allantoid

title: alantoido


text: recht door zee

title: recht door zee


text:
desquietiganta

Adjective

 * 1) disquieting

title: desquietiganta


text:
desquietigar

Verb

 * 1)  to worry someone
 * 2)  to make someone uneasy

title: desquietigar


text:
desquieta

Adjective

 * 1) disquiet, uneasy, anxious

title: desquieta


text:
quieteso

Noun

 * 1) tranquility, quietude

title: quieteso


text: quietesi

title: quietesi


text:
osafke

Noun

 * 1) sofkee, grits

title: osafke


text:
Talk:𒄠𒋛

Etymology
What does "Mediated via Middle Egyptian..." mean? Is it supposed to mean "Influenced by"? Also, the Egyptian word doesn't have an initial p-. Hopefully Ivan Štambuk or someone else can answer this for me.

--Foreverknowledge (talk) 21:48, 3 August 2013 (UTC)

 * p is the definite article in Egyptian, so that's how we know it came via Eyptian (and was not merely influenced by). --Ivan Štambuk (talk) 21:57, 3 August 2013 (UTC)

 * So the Akkadian word is a loan from Egyptian rather than a cognate? --Foreverknowledge (talk) 22:00, 3 August 2013 (UTC)

 * Yes. Although the word was borrowed all of the place, so it's hard to pinpoint the exact origin - but initial /p/ betrays Egyptian, and since Akkadian piru is "older" (=attested earlier) than anything else, we put it as the original etymon. --Ivan Štambuk (talk) 22:23, 3 August 2013 (UTC)

 * Actually, wouldn't the Egyptian word be the original etymon since it's the source of the Akkadian word? What reference did you use for the etymology?  Thank you. --Foreverknowledge (talk) 22:39, 3 August 2013 (UTC)
 * I mean the etymon of those words listed under the ====Descendants==== section. I don't really remember where exactly I saw it (it was a few years ago after all, back then we didn't use references as much as today), but after some quick googling it appears that the p- prefixation theory originates in Hommel's Die Namen Der Saugethiere Bei Den Sudsemitischen Volkern, and that this Wanderwort has had a spectacular array of explanations over the last few centuries . (Personally I think that the Berber-Egyptian compound theory of ἐλέφας is BS as well). If you want to add an alternative explanation, or compile all of the prominent ones (becasue of NPOV), be my guest! --Ivan Štambuk (talk) 23:14, 3 August 2013 (UTC)

Proto-Semitic reconstruction looks very fishy. Can you source it? --Ivan Štambuk (talk) 07:28, 11 August 2013 (UTC)

 * Yes. Part of it is from the article link you posted before.  The rest is from this etymology site. [1 ][2 ] --Foreverknowledge (talk) 11:05, 11 August 2013 (UTC)
 * The problem is that the first is a research paper and the second is an obscure Russian web site, containing a bunch of original research. I can't speak for Proto-Semitic with assurance, but their (of STARLING database) Proto-Indo-European etymologies still use pre-laryngeal notation and are largely based on Pokorny. Blažek's reconstruction is simply *pirl-, and the rest of the forms are described as later assimilations with compensatory lengthening. The forms that you added in the etymology: "*p-r-l, *palpal-, *pīr-, or *pīl-" seem to be simply copied from various sources without any due consideration on their plausibility. Just as the (anonymous?) author on that Russian website, you seem to to go at great length to explain this as an inherited Proto-Semitic word, as opposed to Kulturwort borrowed across languages. Until you come up with a more reliable source, I'll change the etymology to a more neutral wording. --Ivan Štambuk (talk) 09:33, 14 August 2013 (UTC)
 * Although I agree with you about the Indo-European etymology being outdated, that is not true for the Semitic. I would hardly call the authors for the Semitic etymology "obscure."  As explained here 1, the Semitic etymology is based on the work of Militarev and Kogan, who are scholars.  The explanation I gave for the etymology is based on what they wrote. --Foreverknowledge (talk) 05:55, 16 August 2013 (UTC)
 * Yeah, but how do you know they haven't altered the PS reconstruction and interpretation to fit their Nostratic agenda? If you have access to the book (which doesn't seem to be available at pirate websites), it's best to check there. It's a credible source. --Ivan Štambuk (talk) 11:02, 17 August 2013 (UTC)

OP from Indic?
This source derives the Old Persian pīru- from Indic languages. --Z 17:43, 14 June 2017 (UTC)

Akkadian or Sumerian?
The only entry on the page at the moment is for Akkadian, but the quotation given as an example is clearly Sumerian? —Pinnerup (talk) 00:50, 22 February 2021 (UTC)
 * Thanks for pointing it out. I don't feel comfortable creating the Sumerian entry, so I'll move to quote to the Citations tab. —Μετάknowledge discuss/deeds 01:32, 22 February 2021 (UTC)

title: Talk:𒄠𒋛


text:
desfidar

Verb

 * 1)  to distrust, to mistrust, to doubt

title: desfidar


text:
fidar

Etymology
.

Verb

 * 1)  to trust, have confidence, have faith

title: fidar


text:
desfidemeso

Etymology
From.

Noun

 * 1) mistrust

title: desfidemeso


text: desfidemesi

title: desfidemesi


text:
desfidema

Etymology
From.

Adjective

 * 1) mistrustful, distrustful

title: desfidema


text:
desfideleso

Noun

 * 1) unfaithfulness

title: desfideleso


text: desfidelesi

title: desfidelesi


text: 神气

title: 神气


text:
snash

Noun

 * 1)  Verbal abuse; insolence; guff.

Verb

 * 1)  To talk impudently.

Noun

 * 1) Verbal abuse, guff

title: snash


text:
神氣

Noun

 * 1) manner; air

Adjective

 * 1) spirited; vigorous
 * 2) aloof; cocky

title: 神氣


text:
Juniperus

Etymology
From.

Hypernyms

 * ; - subfamily

Hyponyms

 * (common juniper) - type species; for other species see or

title: Juniperus


text: thurses

title: thurses


text:
神情

Noun

 * 1) facial expression; look

title: 神情


text:
茫然

Adjective

 * 1) boundless; borderless
 * 2) clueless; directionless
 * 3) dazed; confused; frustrated

Adjective

 * 1) clueless

title: 茫然


text: 适宜

title: 适宜


text: 实质

title: 实质


text:
實質

Noun

 * 1) essence; substance
 * 2)  parenchyma

title: 實質


text: 收缩

title: 收缩


text:
收縮

Verb

 * 1) to shrink; to contract
 * 2) to keep down ; to reduce ; to cut; to tighten

title: 收縮


text:
水利

Noun

 * 1) management of water as a resource, including conservation and irrigation
 * 2) hydraulic engineering

title: 水利


text:
User:Ronan McGurrin

Hello, I'm  Ronan . Feel free to leave me a message  or send me an  e-mail  if you have something to discuss.

title: User:Ronan McGurrin


text:
User talk:Ronan McGurrin

Hello, I'm  Ronan . This is my talk page; feel free to leave a message.  Sign and date your posts by typing four tildes ( ~ ). Put new text under old text. [ Click here to start a new topic].

title: User talk:Ronan McGurrin


text: 思维

title: 思维


text:
思維

Verb

 * 1) to reflect on; to ponder over; to consider

Noun

 * 1) thought; thinking

Proper noun

 * 1)  Sylvester

title: 思維


text:
搜集

Verb

 * 1) to collect; to gather

title: 搜集


text: 松树

title: 松树


text:
松樹

Noun

 * 1) pine tree

title: 松樹


text: 踏实

title: 踏实


text:
踏實

Adjective

 * 1) firm; steady; sure; dependable
 * 2)  at ease; free from anxiety; not tense
 * 3) workable; practical; feasible

Verb

 * 1)  to walk steadily

title: 踏實


text: 提议

title: 提议


text:
Talk:شاهین

Middle Armenian is attested the earliest in the 12th century, so it is risky to take it all the way back to Middle Iranian. And none of my sources do. But if was indeed pronounced /ʃɒːˈhiːn/ in Classical Persian, it cannot have yielded the Middle Armenian word. Middle Iranian origin is corroborated by the given name attested since Old Armenian. --Vahag (talk) 22:57, 3 August 2013 (UTC)
 * Yes, New Persian form was certainly ʃɒːˈhiːn, since MP [eː] always becomes [iː] before final [n] in NP, and, if it was [eː], it must have been preserved in Hindustani and Tajik, which are respectively šāhīn and шоҳин, so I think we can say it was from Old Armenian, from MIr. --Z 23:34, 3 August 2013 (UTC)

title: Talk:شاهین


text:
mucc mara

Noun

 * 1) "sea-pig", porpoise, dolphin.
 * mucc mora glosses
 * mucc mora glosses

title: mucc mara


text:
traks

Etymology
From, , from , , from the stem. The meaning probably evolved from “turning, drilling” to “moving quickly” ( > “aggressively”) to “crazy, mad.” Cognates include 🇨🇬.

Adjective

 * 1)  mad, rabid affected with rabies
 * 2)  mad, crazy, insane having mental, psychological problems; behaving as one who has lost his mind; expressing such condition
 * 3) crazy which acts, behaves, speaks very loud, making noise, being fast, unrestrained; such that it expresses such behavior
 * 4) crazy daring, reckless, careless; aggressive, turbulent
 * 5)  crazy very strong, very intense
 * 6) crazy very intense, very powerful, having strong effects
 * 7) crazy very strong, very powerful, possibly destructive
 * 8)  crazily; very, very much, terribly
 * 9)  crazy unexpected; undesirable; unpleasant
 * 10)  crazy about liking, wanting something very much
 * 1) crazy which acts, behaves, speaks very loud, making noise, being fast, unrestrained; such that it expresses such behavior
 * 2) crazy daring, reckless, careless; aggressive, turbulent
 * 3)  crazy very strong, very intense
 * 4) crazy very intense, very powerful, having strong effects
 * 5) crazy very strong, very powerful, possibly destructive
 * 6)  crazily; very, very much, terribly
 * 7)  crazy unexpected; undesirable; unpleasant
 * 8)  crazy about liking, wanting something very much
 * 1)  crazy very strong, very intense
 * 2) crazy very intense, very powerful, having strong effects
 * 3) crazy very strong, very powerful, possibly destructive
 * 4)  crazily; very, very much, terribly
 * 5)  crazy unexpected; undesirable; unpleasant
 * 6)  crazy about liking, wanting something very much
 * 1) crazy very intense, very powerful, having strong effects
 * 2) crazy very strong, very powerful, possibly destructive
 * 3)  crazily; very, very much, terribly
 * 4)  crazy unexpected; undesirable; unpleasant
 * 5)  crazy about liking, wanting something very much
 * 1) crazy very strong, very powerful, possibly destructive
 * 2)  crazily; very, very much, terribly
 * 3)  crazy unexpected; undesirable; unpleasant
 * 4)  crazy about liking, wanting something very much
 * 1)  crazy unexpected; undesirable; unpleasant
 * 2)  crazy about liking, wanting something very much
 * 1)  crazy unexpected; undesirable; unpleasant
 * 2)  crazy about liking, wanting something very much
 * 1)  crazy unexpected; undesirable; unpleasant
 * 2)  crazy about liking, wanting something very much
 * 1)  crazy about liking, wanting something very much

title: traks


text: Category:English terms derived from Makah


text:
muccach

Etymology
From.

Adjective

 * 1) pertaining to swine

title: muccach


text: flashgeheugens

title: flashgeheugens


text:
junipero

Etymology
,.

Noun

 * 1) juniper, shrub or tree of the genus

title: junipero


text: juniperi

title: juniperi


text:
Citations:kotata

 * 1991, Restaurant Business, volume 90, issues 10-14, page 215:
 * Whether your basket is filled with kotatas or strawberries, there are a few tips to picking and storing berries.

title: Citations:kotata


text: Category:Japanese terms spelled with kanji read as まん


text: Category:Japanese terms spelled with kanji read as ま


text: Category:Japanese terms spelled with kanji read as ばん


text: Category:Japanese terms spelled with kanji read as よろず


text:
hidastella

Etymology
From.

Verb

 * 1) to drag one's feet

title: hidastella


text: Category:Japanese terms spelled with kanji read as こ


text: Category:Japanese terms spelled with 年 read as とし


text: Category:Japanese terms spelled with kanji read as とし


text: Eve teasing

title: Eve teasing


text:
چشا

Noun

 * 1) * 1996,, "Maste Cheshat", Atre To
 * "fa"
 * "fa"

- اون دوتا مست چشات منو خوابم می‌کنه

title: چشا


text: eve teasing

title: eve teasing


text: eve-teasing

title: eve-teasing


text: eve teasings

title: eve teasings


text: eve-teasings

title: eve-teasings


text: Eve-teasings

title: Eve-teasings


text: Category:Japanese terms spelled with 願 read as がん


text: Category:Japanese terms spelled with kanji read as がん


text: Category:Japanese terms spelled with kanji read as じ


text: Category:Japanese terms spelled with 熱 read as ねつ


text: Category:Japanese terms spelled with kanji read as ねつ


text:
Template:Magnoliaceae Hypernyms/documentation

This is a typing shortcut, intended for use under the Hypernyms heading for entries for taxa under family Magnoliaceae. I can also be used with subst:.


text: Category:Japanese terms spelled with 学 read as がく


text:
Template:Magnoliaceae Hypernyms

, magnoliids - clades; Magnoliales - order; Magnoliaceae - family

title: Template:Magnoliaceae Hypernyms


text: Category:Japanese terms spelled with kanji read as がく


text:
Liriodendron

Synonyms

 * ,, ; yellow poplar, tulip poplar; canoewood, ,

Hypernyms

 * ; - subfamily

Hyponyms

 * , (tulip poplar) - species

title: Liriodendron


text: Category:Japanese terms spelled with kanji read as か


text: Category:Japanese terms spelled with 性 read as せい


text: Category:Japanese terms spelled with kanji read as せい


text: Category:Japanese terms spelled with 怪 read as かい


text: Category:Japanese terms spelled with kanji read as かい


text: Template:et-decl-käsi/documentation

title: Template:et-decl-käsi/documentation


text: Category:Japanese terms spelled with 化 read as か


text: Category:Japanese terms spelled with 器 read as き


text: Category:Japanese terms spelled with kanji read as き


text: Category:Japanese terms spelled with kanji read as ぶつ


text:
mucár

Etymology
From.

Noun

 * 1)  pig-slaughter

title: mucár


text: Category:Japanese terms spelled with 見 read as けん


text: Category:Japanese terms spelled with kanji read as けん


text: Category:Japanese terms spelled with 見 read as み


text: Category:Japanese terms spelled with kanji read as み


text:
Thread:User talk:CodeCat/Proto-Germanic reflex/reply (2)

Would the -u- have come from the syllabic r?


text: Category:Japanese terms spelled with 抗 read as こう


text: Category:Japanese terms spelled with kanji read as こう


text: Category:Japanese terms spelled with 生 read as せい


text: Category:Japanese terms spelled with 好 read as こう


text:
打瞌睡

Verb

 * 1) to doze off; to nod off; to take a nap

title: 打瞌睡


text: Category:Japanese terms spelled with 酸 read as さん


text: Category:Japanese terms spelled with kanji read as さん


text: Category:Japanese terms spelled with 実 read as じつ


text: Category:Japanese terms spelled with kanji read as じつ


text: Category:Japanese terms spelled with 臭 read as しゅう


text: Category:Japanese terms spelled with kanji read as しゅう


text: Category:Japanese terms spelled with 障 read as しょう


text: Category:Japanese terms spelled with kanji read as しょう


text: Category:Japanese terms spelled with 害 read as がい


text: Category:Japanese terms spelled with kanji read as がい


text: Category:Japanese terms spelled with 植 read as しょく


text: Category:Japanese terms spelled with kanji read as しょく