Map: decide what the narration document shows and render it on request

未關閉
#472 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

評估

難度
5/5
預估耗時
一週以上
新手友好度
35/100
Issue 類型
功能
描述清晰度
基本清楚
活躍度
活躍
技術堆疊
typescript

研究方向

Read libs/narration-document-creation/src/narration-document-creation.ts and the linked ADRs 0001 and 0014, then review docs/architecture/r2-storage.md and docs/architecture/conversion.md. Define storage and request-time rendering while preserving synchronization unit boundaries, IDs, and narration text; specify presentation rules for links, inline markup, and block elements. Done means a GitHub spec is ready for /to-tickets, with the wiki pages and ADR to follow when the build lands.

由索引模型根據 Issue 內容生成。

描述

wayfinder:map

Destination

A spec on GitHub, ready for /to-tickets, for (a) storing the fetched page and the selected HTML with each conversion, (b) a request-time renderer that turns the selected HTML into the narration document's presentation HTML while reproducing the stored synchronization units exactly, and (c) the chosen presentation rules (links, inline markup, block elements). The ADR and the wiki pages (docs/architecture/r2-storage.md, docs/architecture/conversion.md, the glossary's narration document) follow when the build lands.

Notes

  • Origin: Linear CUP-52. The operator's trigger is that the narration document renders links today: they look clickable but are covered by the reader's invisible "play segment" button once the track is ready, a relative href points at cup.audio, and they get no target/rel. Whether to keep links at all is open.
  • Today: createNarrationDocument (libs/narration-document-creation/src/narration-document-creation.ts) sanitizes the AI-selected HTML once during preparation; only the sanitized HTML and the synchronization units land in audiobook.json. The fetched page and the selected HTML live only in expiring Workflow step results.
  • Invariant: synchronization unit boundaries, unit IDs and each unit's narrationText never change after preparation, since each unit has its own paid audio segment. Everything else about presentation should be free to change.
  • Only the web app reads the narration document (the mobile apps are shells around it); the HTML reaches the reader through the listener API.
  • Related ADRs: 0001 (one canonical synchronized audiobook), 0014 (cut the source material at the visible headline, source subtitle in the narration document).
  • Skills: grilling and domain-modeling for HITL tickets, prototype for prototype tickets, research for research tickets. Use the glossary's terms (narration document, synchronization unit, segment, narration block, source material).
  • Paid probes (a few real conversions) are fine; prefer fixtures where they suffice and report the spend.

Decisions so far

Not yet specified

  • How the reader styles the markup that is kept (link styling, code, emphasis) once the inline-markup and links decisions are made.
  • How the spec stages the build: storage change first or renderer first, and what ships together.

Out of scope

  • Images in the narration document: they stay with Linear CUP-82, which builds on this map's renderer. The renderer must merely not rule them out.
  • Backfilling existing conversions by re-running AI selection: their fetched pages and selected HTML are gone, and a re-run could change the narrated units and their paid audio. Existing conversions get only what can be rendered from the HTML they already store.
主要語言
TypeScript
星號
1
分支
0
PR 合併指標
30 天內沒有已合併 PR

環境準備

這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

patricktree/cup 的其他 Issue

查看 patricktree/cup 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。