// Package advertising holds what is known about the shape of inserted advertising, for the // packages that have to recognise it. // // It exists because one measured figure -- the length of an ad slot -- had been written out four // times, in skips, transcript (twice) and signature, each copy carrying a comment pointing at the // others: "the same unit skips.Classify uses", "the same figure the length-gap rule uses", "one // ad unit from the start". The agreement was real and deliberate, and recorded only in prose, so // a corpus that revised the figure would have moved one copy and left three. package advertising // UnitMs is the length of one advertising slot. // // Advertising is sold in units of roughly fifteen seconds -- the owner's own observation, borne // out by the corpus -- and three separate rules depend on that same fact: // // - a served file exceeding its declared length by less than one unit cannot carry a real // insertion; it is the feed being approximate, the way encoders disagree about a file's // length by a fraction of a second; // - anything briefer than one unit is a mention rather than a break, and skipping it would // clip the programme; // - one unit from the start of a guessed break is far more audio than a landmark fingerprint // needs, and is the part most certainly advertising rather than programme. // // Changing this changes all three, which is the point of it being one constant. const UnitMs int64 = 15_000