# AIUI Plan 2 — Automated Loop Task List > **Format**: `- [ ]` = pending, `- [x]` = done. > Make at least 30 attempts on any difficult task before moving on. Loop reads this file. Specs are in `PLAN2.md`. Design rules are in `loop/prompt.md`. ## M8: Chat UX Polish - [x] **M8.1** — Message editing & regeneration (pencil icon on hover, re-send clears subsequent messages) - [x] **M8.2** — Conversation branching (fork from any message, branch switcher pill, each branch stored in IDB) - [x] **M8.3** — Reply-to threading (quoted excerpt in input, thread line visual, prepend `> quote` to message) - [x] **M8.4** — Conversation search (`Cmd+F` glass panel, real-time highlight, up/down to jump between matches) - [x] **M8.5** — Auto-title generation (background AI call after first exchange, silently replaces "New Chat") - [x] **M8.6** — Context window visualiser (slim progress bar, token estimate, orange → red > 80%) - [x] **M8.7** — Conversation export (Markdown / JSON / plain text, File System Access API + `` fallback) - [x] **M8.8** — Import conversations (drag-and-drop JSON, AIUI format + Claude.ai export format, merge into IDB) - [x] **M8.9** — Long-press / right-click context menus (messages + content cards, `ContextMenu.vue` glass-card) - [x] **M8.10** — Scroll position memory (restore per conversation ID, works with virtual scroller) - [x] **TEST:M8** — Run `pnpm test` and `pnpm typecheck && pnpm lint`. Fix all failures before proceeding. ## M9: AI Experience - [x] **M9.1** — Multi-model comparison mode (split-screen same prompt → 2 models, swipeable on mobile) - [x] **M9.2** — System prompt editor / personas (named personas, model preference, accent, per-conversation) - [x] **M9.3** — Prompt template library (`/` command palette, `{{variable}}` substitution, IDB-persisted) - [x] **M9.4** — Vision input (drag-and-drop image, base64 in message content, only when model supports vision) - [x] **M9.5** — Response feedback (thumbs up/down per message, stored in IDB, exported with conversations) - [x] **M9.6** — Token & cost estimator (badge per message, running total in context bar, model pricing table) - [x] **M9.7** — AI memory panel (pinned facts injected into every system prompt, encrypted IDB, max 20 items) - [x] **M9.8** — Model capabilities badge (Vision / Tools / Long context badges in model selector) - [x] **M9.9** — Temperature & params sliders (temperature, max tokens, top-P, persisted per conversation) - [x] **M9.10** — Stop sequence configuration (comma-separated stop sequences in advanced settings) - [x] **TEST:M9** — Run `pnpm test` and `pnpm typecheck && pnpm lint`. Fix all failures before proceeding. ## M10: Advanced Content Renderers - [ ] **M10.1** — Full article renderer (TOC sidebar, reading time, font-size control, print mode, markdown-it) - [ ] **M10.2** — PDF viewer (`pdfjs-dist` lazy loaded, page nav, zoom, text selection, page 1 thumbnail preview) - [ ] **M10.3** — Map renderer (Leaflet + OpenStreetMap lazy loaded, pins for all places, cluster > 10, fullscreen) - [ ] **M10.4** — Recipe renderer (new `recipe` content type, ingredients checklist, numbered steps, scale slider) - [ ] **M10.5** — Event renderer (new `event` content type, countdown, ICS download, Google Calendar URL) - [ ] **M10.6** — Math renderer (KaTeX lazy loaded, `$...$` inline + `$$...$$` block, batch render on stream end) - [ ] **M10.7** — Mermaid diagram renderer (lazy loaded, dark theme, flowchart/sequence/gantt, pan/zoom mobile) - [ ] **M10.8** — Audio waveform player (WaveSurfer.js lazy loaded, orange waveform, click-to-seek) - [ ] **M10.9** — Table renderer (sortable columns, row filter, CSV export, virtualise > 500 rows) - [ ] **M10.10** — Timeline renderer (new `timeline` content type, vertical layout, animate in during streaming) - [ ] **M10.11** — Code runner (HTML/CSS/JS sandboxed iframe, `sandbox="allow-scripts"`, output console) - [ ] **M10.12** — Video renderer (native `