Template:Festival source

From PickiPedia: A knowledge base of bluegrass, old time psychedelic jams, and other public domain music
Jump to navigationJump to search

Festival source

Marks a page as a place an Artificial Dumb tool can read a festival lineup from, and says how to read it.

One source page per festival per year. The page is config, not an article: it exists so that the knowledge of where a lineup is published lives with the people who go to festivals rather than with the people who have commit access.

Usage

{{Festival source
|url=https://example.com/festivals/thing-2026/
|kind=html-list
|festival=Thing
}}

Then, on the same page, the patterns:

<pre class="lineup-patterns">
scope-from: class="lineupblock"
scope-to: </ul>
^(?P<artist>[A-Z0-9][^|]{1,70})$
</pre>

Why the patterns go in a <pre> block

Because "|" is syntax to template parameters and to SMW properties, and a regex made of alternations is mostly pipes. A pattern containing (?:Main Stage|Dance Tent) comes back truncated from either. Read as raw wikitext, a <pre class="lineup-patterns"> block survives byte for byte. The podcast parsers learned this first and the hard way.

Parameters

  • url - Where the lineup is published.
  • kind - How to read it. In order of preference:
    • json-ld — the site's own schema.org markup. Best: it cannot be broken by a redesign.
    • ical — a calendar feed. Unambiguous dates.
    • html-table — a schedule table. Needs a cols: line.
    • html-list — anything else, read with regexes. Needs a scope.
    • pdf-text — not implemented. Many schedules are only a PDF poster; this is left undone rather than done badly.
  • festival - The series page, for the wikitext the reader offers to write.

Directives

These go in the pattern block alongside the regexes.

  • scope-from:, scope-to: - Regexes bounding the region the lineup is in. Use them. A pattern loose enough to match a bare band name is loose enough to match "Privacy Policy", and a scope that stops matching is treated as an error so that a redesign halts the run instead of quietly shortening the lineup.
  • cols: - For html-table: the column meanings, in order, e.g. cols: time, artist, stage. Deliberately not read from the table's own headers, which work until a festival writes "Who" instead of "Artist".

A caution about aggregators

A listing site is a secondary source and should be marked as one on the pages it feeds. It is often the only machine-readable lineup available — festival sites are frequently a single poster image — but it is one remove from the festival, and festivals change their lineups.