Jump to content

Template:Indexing

From Insurer Brain
Revision as of 12:39, 4 July 2026 by Wikilah admin (talk | contribs) (Deploy Template:Indexing (H6 heading + Has topic subobject))

This is the section-indexing template. A doc_archive content unit is written as:

====== heading ======
Key figures
Employees1,014 (Dec 31, 2025)

It renders a level-6 heading (====== heading ======) AND records one SMW subobject linking Has topic = [[ID:<id>]] per topic id (page-links, so ID:<id> and Special:WhatLinksHere resolve back to the section), plus Has description, Has indexed heading and Has unit kind (named parameter kind: prose or table, derived by the indexer from the unit body — retrieval filters on it: slide building wants tables, answer drafting wants prose).

Key figures: up to 6 label/value pairs (f1/v1f6/v6), PROSE units only — facts that live only in the narrative (headcounts, founding dates, business mix). Each pair renders a row in a right-floating unit-figures card (styled by Common.css §12) after the heading, and stores a Has figure Text fact ("label = value") on the same subobject. The indexer verifies every digit-bearing value verbatim against the unit body before writing; a label without a value (or vice versa) is ignored.

Up to 6 topic ids (positional args 3–8). Ids come from the section_topics vocabulary in Data:term_map.json — each has a page in the ID: namespace. Written and kept current by tools/indexing/indexer.py; humans review via Module:PageMap, they do not edit this by hand.

The subobject's closing }} butts directly against ====== so the heading starts at column 0 (MediaWiki parses a heading only at line start).