Skip to content

feat: conversation list + manage for "Ask your library" (P13d-2b)#146

Merged
blokzdev merged 1 commit into
mainfrom
claude/p13d2b-chat-list
Jun 3, 2026
Merged

feat: conversation list + manage for "Ask your library" (P13d-2b)#146
blokzdev merged 1 commit into
mainfrom
claude/p13d2b-chat-list

Conversation

@blokzdev
Copy link
Copy Markdown
Owner

@blokzdev blokzdev commented Jun 3, 2026

P13d-2b — Conversation list + manage

Makes the "Ask your library" GraphRAG chat multi-conversation. No schema change (v14 already forward-included chats.title, chats.archivedAt, chat_messages.citationsJson) and no new deps — repository methods + providers + two list screens + a resumable controller.

List-first entry

The Dashboard "Ask" tile (/ask) now opens a ConversationsScreen: past chats most-recent-first, each with a last-message preview + relative time, a "New chat" FAB, and an empty-state CTA. Archived threads live behind /ask/archived (ArchivedChatsScreen), reached from the app-bar overflow.

  • /ask → conversation list · /ask/chat → new chat · /ask/chat/:id → continue · /ask/archived → archived.
  • Per-row overflow: Rename / Archive / Delete (active) or Unarchive / Delete (archived); delete confirms and cascades its messages.

Resumable chat

AskController is now a family keyed by String? chatId — a seeded id continues that thread (its bounded history feeds back into the next turn via the existing messagesToHistory + fitHistory path), while null creates the chat on first send (the d-2a behaviour). AskScreen takes a chatId and shows the live, renamable conversation title.

Repository

ChatRepository gains watchChatList({archived}) (one reactive query with a correlated latest-message preview subquery — no N+1), renameChat (blank ignored), setArchived, deleteChat, and watchChatTitle; plus activeChatsProvider / archivedChatsProvider / chatTitleProvider.

Tests (CI-verifiable; native generation is APK-verified)

  • Repo: recency + preview ordering, active-vs-archived split, archive toggle round-trip, rename (incl. blank-ignored), and cascade delete.
  • Controller: continuing a seeded chat appends to it and feeds prior turns as history (no new chat created); existing new-chat/no-sources/error cases adapted to the family key.
  • Widget: ConversationsScreen renders rows + preview, shows the empty-state CTA, and exposes the row Rename/Archive/Delete menu.
  • Full suite green (867 tests), dart format + flutter analyze clean.

Docs

  • docs/design/P13-PLAN.md — d-2b → [~] with as-built status.
  • docs/VERIFICATION.md — P13d-2b APK checklist (two chats listed; reopen continues with context offline; rename/archive/unarchive/delete; empty-state CTA).
  • docs/BACKLOG.md — deferrals: conversation search/pin, bulk actions + swipe-to-archive, content-based re-titling.

Verification

  • ✅ CI gates green locally (format · analyze · 867 tests).
  • APK spot-check owed: two chats list with previews; reopen → continues with retained context offline; rename persists; archive hides/restores; delete removes (and its messages); empty-state CTA starts a chat.

Next: d-3 (low/ineligible-tier retrieval-only fallback + tier-aware history depth + LLM/Cozo HNSW RAM co-residency), which closes P13d.

https://claude.ai/code/session_013JoYmLCosYt5tQ8qwdbL1T


Generated by Claude Code

List-first entry: the Dashboard tile opens a ConversationsScreen of past
chats (most-recent-first, preview + relative time), with continue, rename,
archive (kept + restorable, behind /ask/archived), and delete. AskController
becomes a family keyed by an optional chatId — a seeded id continues a thread
(its bounded history feeds back), null creates on first send. No schema change
(v14 already carried title/archivedAt); no new deps.

https://claude.ai/code/session_013JoYmLCosYt5tQ8qwdbL1T
@blokzdev blokzdev merged commit 341323f into main Jun 3, 2026
1 check passed
@blokzdev blokzdev deleted the claude/p13d2b-chat-list branch June 3, 2026 07:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants