Archilyzer · Source

archilyzer

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

commit 7e0011b281ac8afe659e1159dd2b3eeed7bfe910
parent 742ea8d42ed8a8b762a1acc58467f4868978e34a
Author: I Mean I'm Just Saying <imeanimjustsaying@kiwifarms.st>
Date:   Wed, 14 Oct 2026 11:25:33 -0400

Merge main (R4–R6 plans, f95ce80c) into ux/p4a3

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

Diffstat:
Mplans/umtool-redesign.md | 108+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++----
1 file changed, 103 insertions(+), 5 deletions(-)

diff --git a/plans/umtool-redesign.md b/plans/umtool-redesign.md @@ -183,10 +183,13 @@ Each phase: its own branch from `main` (or the current integration branch), gate ``` NOW (beside r28) AFTER r28 IS ON main -P0 design ─► P1 foundation ─┬─► P3 inbox/work/tools/URLs ─┬─► P2b jobs+drafts ─► P4a-1 ─► P4a-2 ─► P4a-3 ─► P4b ─► P6 - P2a engine ────┘ ├─► P5 create+settings (after P3) - └─► R1 research: search+reader+inventory ─► R2 boards ─► R3 transparent runs (after r28) +P0 design ─► P1 foundation ─┬─► P3 inbox/work/tools/URLs ─┬─► P2b jobs+drafts ─► P4a-1 ─► P4a-2 ─► P4a-3 ─► P4b ─┐ + P2a engine ────┘ ├─► P5 create+settings (after P3) ├─► P6 + └─► R1 research: search+reader+inventory ─► R2 boards ─► R3 transparent runs ─► R4 refresh ─► R5 recurring ─► R6 triage ─┘ ``` +R4, R5 and R6 were added 2026-10-14 at the operator's request (see their sections), and the operator approved +building all three and the co-host pilot. R4 runs beside P4a-3/P4b; its Iterations-tab entry waits for P4b. R5 builds +on R4 and on P5's Create; R6 on R4 and R5. The pilot runs after R6. ### P0 — Design (no app code; operator sign-off gates P1) - Use the frontend-design skill: @@ -297,6 +300,84 @@ P0 design ─► P1 foundation ─┬─► P3 inbox/work/tools/URLs ─┬─ - on-screen (moved out of Build), narration, and "Draft with <model>" / "Draft everything" per section. - One `JobProgress` for chain and editor jobs. +### R4 — Refresh: re-fetch, see what changed, update (operator, 2026-10-14) +A report iteration that is "fetch what's new, check it, update" — cheap and deterministic until something changed. +- **Where:** a **Refresh** action on the article piece (head ⋯ menu; the Next card when a refresh is suggested; the + Iterations tab once P4b lands), and `umtool refresh <article>` / `pnpm ops report-draft {"task":"refresh"}`. +- **Stage 1 — fetch (Archilyzer, no model).** Scope: the current report's iteration scope (channels, from/to) plus every + channel its citations touch. Plan, then the editor's own paced actions: `sync` per video channel, `fetch-posts` per + posts channel, `transcribe-bucket` for what lands — refused for a platform held or cooling down (polite scraping); + then a **local build** of the site whose build holds those channels (build only, never a deploy — through the publish + lock; Candace and other local-only channels stay local), because `report-draft` reads a composed build + (`corpusSource.ts`) and fresh videos are invisible to it until a build includes them (the research run's + `autoContinue: held` already waits on the same thing). The jobs show in the Running list. +- **Stage 2 — what changed (deterministic, no model).** Re-run the original enumerate with the iteration's recorded + terms and scope (R3's trace `scope`/`terms`/`enumerate.ids`; a pre-R3 iteration: its question + channels, with the + citations as the old set) → **new** recordings (ids not matched before, including old videos that only now have a + transcript) and **changed** ones; re-verify every cited quote against today's transcript (R2's verify: changed words, + `en` vs `en-orig`, deleted sources). Written as the new iteration's `refresh.json`; shown as "4 new recordings + match · 2 quotes changed · 1 source deleted". **Nothing changed → the iteration ends "no change", $0.** +- **Stage 3 — update (model) runs on its own** (operator ruling 2026-10-14) when stage 2 found anything, within the + policy's caps (per-job cap, daily cap; a cap refusal becomes a **Your call** card with the delta and the estimate). + Engine: `report-draft {"task":"refresh","article","iteration"}` = a sweep restricted to the new ids (a new + `ids` restriction on the sweep — channels and dates alone would miss late transcripts) over the parent's question, + then a revision of the parent report with those findings and the drift fixes, keeping everything still verified. + The result is a new iteration and an **iteration-ready** Review card — making it current stays the operator's call. +- **Optional suggestion (operator: include it):** a cheap daily check per active or published article (stage 2's + enumerate only — no fetch, no model) → a `refresh-available` Inbox card "3 new recordings mention this since + <date>" whose action is **Refresh**. Muted/parked/done pieces are skipped. +- Gates: common + editor tests and builds (the engine change), the full editor e2e at merge, an editor restart at ship. + +### R5 — Recurring reports (operator, 2026-10-14) +The same topic, updated at an interval — e.g. a daily or weekly report of co-host updates. +- **Create → "A recurring report"**: topic/question, scope (channels or a board's scope), cadence (daily · weekly on + <day> · every N days, at a time), and one of two shapes, each one sentence on the form: + - **Living report** — one article kept current: each tick runs R4's Refresh (stages 1–3) and lands an + iteration-ready card. Optionally "make current automatically" per series (default off). + - **Series** — a new dated **edition** each tick covering only the window since the previous edition + ("Co-host updates · week of 2026-10-13"): a sweep with `from` = the last edition's window end, after R4's stage 1 + fetch + build. An empty window is recorded as a quiet edition (no article, $0). Editions belong to a series piece + `s:<series>` with its own page (editions newest first, the next tick, pause/resume, cadence) and one Work row. +- **Scheduler: the editor**, the always-on process with the heartbeat, the caps, the pause gate and + `ARCHILYZER_IDLE_BOOT` — a `report-schedule` runner lane; the schedule is stored beside the article/series in the + article store, written only through an ops action (`pnpm ops report-schedule`). umtool shows and edits it; it never + runs a timer itself. +- Surfaces: a cadence chip in the piece head ("weekly · next Mon 06:00", pause/resume); Work's "recurring" facet; each + finished edition or refresh → a Review card; a failed tick → Your call; spend per tick in the Running list. +- The existing hand-kept co-host timeline (`quartering-leads`, `cohosts/UPDATE.md`) is the first candidate series — a + pilot after R5 ships, with the operator's go. + +### R6 — Triage first: a cheap pass that flags what is worth researching (operator, 2026-10-14) +A consistent fetch, a cheap or local model that flags what is worth a look, and the better model with tools only on +what it flags. Facts it builds on (surveyed 2026-10-14): per-video **digests** already exist (chapters + topic tags, +local `qwen2.5:7b`, the `digest` lane yielding the GPU to transcription; `ai-digest.json`); the **local sweep pipeline** +(`sweep-pipeline.ts`) is code around a small local model that already judges each window `relevant`/`on_topic`; the API +sweep already splits a cheap extractor (`models.extractor`, Haiku) under the main model; there is no watch/saved-search +concept and no standing relevance filter yet. +- **Tier 0 — code, $0:** after R4's fetch + local build, the candidates are the recordings new since the last tick in + scope that match the watch's terms/aliases (enumerate) OR whose digest topic tags match the watch's topics. +- **Tier 1 — the local model, $0 marginal:** the sweep pipeline's window judge, run over the candidates' matching + windows only (`draft:local`, through the GPU arbiter, yielding to transcription; ticks default to overnight). Each + flag: recording, window, a verbatim line (code-checked), a score and one-line reason. Dismissals are kept too. +- **Escalation rule:** any flag at or above the watch's threshold (default: one strong flag, or N weak ones) → **Tier 2: + the better model with tools** — an API sweep restricted to the flagged ids (R4's `ids` restriction), within the caps, + running on its own (the operator's R4 ruling). Below threshold → the tick ends with its triage log, $0 API spend. +- **Where the result goes**, per shape: a **living report** → R4's update (an iteration-ready card); a **series** → the + edition; a **watch** (R5's third shape: no article until something is found) → an Inbox **"Worth researching"** card + with the flags and the escalated findings, plus a board (R2 case) with the flags pinned `by: "triage"`, whose + hand-offs make an article or a video. +- **Transparent and tunable:** the run page (R3) shows the tiers — candidates, each flag and dismissal with its reason, + what escalated and why, the spend per tier. The operator can mark a flag right or wrong; the watch keeps its precision + and suggests a threshold. Settings: the triage model (local by default; `models.extractor` allowed), the threshold, the + daily escalation cap. +- **Engine:** a `report-draft` step `triage` (the window judge as a standalone pass over given ids, structured flags), + reused by R5's scheduler; `trace.jsonl` gains `triage {candidates, flagged, dismissed}`. + +**Pilot (operator-approved 2026-10-14), after R6:** the hand-kept co-host timeline (`quartering-leads`, +`cohosts/UPDATE.md`; the co-host attribution hazard applies — a triage flag on a co-host line is a speaker check, not a +finding) becomes a weekly **series** with triage first: one tick run end to end on the live corpus, its triage log and +edition reviewed with the operator before the schedule is left on. + ### P6 — Cleanup, docs, audit - Redirects become 308. - Delete `/drafts`, `BrowseHeader`, the dashboard panels and dead components. @@ -354,10 +435,15 @@ P0 design ─► P1 foundation ─┬─► P3 inbox/work/tools/URLs ─┬─ | R2 research boards | `ux/r2` → `main` `b8561669` | LIVE 2026-10-14 (editor N0OAYPyM…, umtool 9lPefuiS…) | | P4a-1 piece frame | `ux/p4a` → `main` `a92251aa` | LIVE 2026-10-14 (umtool ErWqdPdg…) | | P5 create + settings | `ux/p5` → `main` `20ee628a` | LIVE 2026-10-14 (umtool ZfQXZuNF…) | -| P4a-2 article-rooted merge | `ux/p4a2` | shipped on the branch | +| P4a-2 article-rooted merge | `ux/p4a2` → `main` `d84cf4d7` | LIVE 2026-10-14 (umtool UFg8z3yd…) | | P4a-3 song pieces | `ux/p4a3` | shipped on the branch | | R3 transparent runs | `ux/r3` → `main` `6362cf40` | LIVE 2026-10-14 (editor HqcZW4aJ…, umtool 85Ultdj2…) | -| P4b, P6 | — | after P4a / all | +| P4b benches + Media | `ux/p4b` | in progress | +| R4 refresh | `ux/r4` | in progress | +| R5 recurring reports | — | after R4 | +| R6 triage first | — | after R5 | +| Co-host pilot | — | after R6 (operator-approved) | +| P6 cleanup, docs, audit | — | after P4a-3, P4b, R4–R6 | ### P2a, as shipped @@ -1940,6 +2026,18 @@ the r28 session: editor built (53 s) and restarted (`scripts/r3-editor-{build,re `/research/runs`, `/research/runs/piratesoftware-ai-friends/1` (the real turns.jsonl fallback, the question as title), `/research`, `/work`, `/` 200; editor 200. +### P4a-2 rollout (orchestrator, 2026-10-14) + +Rulings: Overview is every article's default tab; ONE policy href (`generationPolicyHref()` → `/settings/generation`); +ONE stage rule for the stepper and Work's facet (`pieceSteps`/`stageOfPiece`; the furthest stage reached is current); +the reader's note and citation buttons wait for hydration; the Iterations tab links a sweep's run page (R3's +`runHref`). Gates on `243d2494` (R3 merged): full umtool e2e 431 passed, 0 failed, 6 skipped (9.7 min); test:scripts +995 pass, 0 fail; capped build ok. `main` (R3's records merged, plan-only conflict resolved) fast-forwarded to +`d84cf4d7`; umtool built (41 s) and restarted (`scripts/p4a2-umtool.sh`). Live: `/articles/piratesoftware-ai-friends` +and its `?tab=iterations|cut|media` 200; the claimed project `/projects/articles/piratesoftware-ai-friends/i1?tab=cut` +307 → the article's Cut tab; its clip bench stays 200 at the project URL; the Iterations tab links +`/research/runs/piratesoftware-ai-friends/1`; decisions API 828 rows, notes' hrefs intact. + ### P4a-3, as shipped **What.** A song's page (`/projects/<song>`) is a piece page: the P4a frame around one of five tabs, Overview · Cuts ·