Archilyzer · Source

archilyzer

Archilyzer
git clone https://archilyzer.pages.dev/source/archilyzer.git
Log | Files | Refs | README | LICENSE

commit 0cdf617498f831b04d40e7eb3fc54f7078e7a610
parent 2b6fcbdb3298966d08d43200d5f8ba1403adb773
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date:   Wed,  4 Nov 2026 13:15:43 -0500

umtool: a linked post's transcript is matched by word pairs only (SaberXVeritas's "this you?" read off his post, never the screenshot's); a context picture shown, not read, while his own words are read is a look at it (2.4 s), then his own attachment again

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>

Diffstat:
Mumtool/report-to-video/post-thread.mjs | 15+++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)

diff --git a/umtool/report-to-video/post-thread.mjs b/umtool/report-to-video/post-thread.mjs @@ -146,10 +146,10 @@ const pairsOf = (keys) => keys.slice(1).map((k, i) => `${keys[i]} ${k}`); export function readTexts(entry) { const out = []; const spoken = (t) => (str(t).trim() ? draftScript(t).script : ""); - const add = (role, forms) => { + const add = (role, forms, pic = false) => { const lists = forms.filter((t) => str(t).trim()).map(keysOf); if (!lists.some((l) => l.length)) return; - out.push({ role, keys: new Set(lists.flat()), pairs: new Set(lists.flatMap(pairsOf)) }); + out.push({ role, keys: new Set(lists.flat()), pairs: new Set(lists.flatMap(pairsOf)), ...(pic ? { pic: true } : {}) }); }; parentsOf(entry).forEach((p, i) => add(`parent:${i}`, [contextText(p), str(p.text), spoken(contextText(p)), spoken(p.text)])); if (isObj(entry?.quoted)) { @@ -157,13 +157,18 @@ export function readTexts(entry) { add("quoted", [contextText(q), str(q.text), spoken(contextText(q)), spoken(q.text)]); } // A post its words link to (`links[]`): read in place when the take reads it. - linksOf(entry).forEach((l, i) => add(`linked:${i}`, [contextText(l), str(l.text), spoken(contextText(l)), spoken(l.text), str(l.transcript), spoken(l.transcript)])); + linksOf(entry).forEach((l, i) => { + add(`linked:${i}`, [contextText(l), str(l.text), spoken(contextText(l)), spoken(l.text)]); + // The words read off its picture: matched by their word pairs only (a two-word part is never a picture's). + add(`linked:${i}`, [str(l.transcript), spoken(l.transcript)], true); + }); add("post", [cardText(entry), str(entry?.narration?.script), spoken(cardText(entry))]); return out; } /** The share of a piece's words a text holds: by word pairs, in order (one word a pair: by words). */ function shareOf(keys, text) { + if (text.pic && keys.length < 3) return 0; if (keys.length >= 3) { const pairs = pairsOf(keys); return pairs.filter((p) => text.pairs.has(p)).length / pairs.length; @@ -851,7 +856,9 @@ export function panelSchedule(entry, follow, total, { lead = 0.4 } = {}) { cand.forEach((c, i) => { if (c.scope === "own") return; const next = cand[i + 1]; - const end = next ? next.on : total; + // A context post's picture shown (not read) while his own words are read: a look at it, then his own attachment again. + const ownAt = cand.find((x) => x.scope === "own")?.on ?? null; + const end = next ? next.on : !c.read && ownAt !== null && c.on >= ownAt ? Math.min(total, c.on + 2 * PANEL.minUnread) : total; const t1 = r3(Math.min(total, Math.max(end, c.read ? end : c.on + PANEL.minUnread))); if (t1 <= c.on + 0.05) return; const show = { scope: c.scope, media: c.media, t0: c.on, t1 };