Skip to content

UI revamp Phase 4: Ask Lumen (threads, memory, Ask anything, Sky look, Next: fix) - #95

Open
coderconnoisseur wants to merge 13 commits into
ui-revamp/phase3-home-backendfrom
ui-revamp/phase4-ask
Open

coderconnoisseur wants to merge 13 commits into
ui-revamp/phase3-home-backendfrom
ui-revamp/phase4-ask

Conversation

@coderconnoisseur

Copy link
Copy Markdown
Owner

UI revamp Phase 4: Ask Lumen. Stacked on #94 → #92 → #91 → #89. Merge them in that order and retarget each PR to refactor as its parent lands. All five branches already include the latest refactor (#93); STORY entries were renumbered after the merge.
Spec: docs/superpowers/specs/2026-10-20-ui-revamp-design.md §7. Plan: docs/superpowers/plans/2026-10-21-ui-revamp-phase4-ask.md.

What changes

  • Conversations.
    • Opening Ask starts a fresh chat with suggestions drawn from Home's "Lumen found" (e.g. "Why is Food up this month?") plus the usual ones.
    • Past chats sit in a rail: a column on desktop, a sheet on small screens. One click resumes a chat; delete asks once.
    • Old history becomes one "Earlier chats" thread.
    • Backend: a chat_threads table, chat_messages.thread_id, and GET /chat/threads, GET/DELETE /chat/threads/<id>. POST /chat takes an optional thread_id. /chat/history is removed. Another user's thread gives a 404.
  • Memory (owner decision). The agent gets the thread's last 6 messages (user/assistant only, 1,500 characters each), so "and last month?" works. With no history the prompt is byte-identical, so the evals are unchanged.
  • The stray "Next:" fixed. The splitter now handles "Next :", the full-width "Next:" and "Next -". A frontend guard never shows a bare trailing "Next:", which covers older saved answers too.
  • Ask anything. A sidebar button or ⌘/Ctrl+K anywhere (Caps Lock safe, e.code) opens a one-line box. Enter starts a new Ask chat with the question; it's sent once and never resent on reload, including when you're already on Ask.
  • Sky look.
    • Beautiful UI's tokens are remapped to Sky inside the app, so the chat is light with no component rewrites.
    • The send button reads clearly in both states.
  • Backlog.
    • Proposals are now claimed with a conditional UPDATE, so concurrent approvals can't both apply.
    • Home's draft dialog says "This draft was replaced. Draft again." instead of erroring.
    • Activity refreshes after budget decisions.
    • Found items carry a subject.
  • Phase 1 bug the screenshots exposed: the sidebar divider overflowed by 24 px, causing a horizontal scrollbar. Fixed.

Checks

  • Backend: pytest -q gives 978 passed, 15 skipped. The 26 new tests cover:
    • per-user threads and legacy folding, including a lost race
    • memory isolation between threads
    • the prompt unchanged without history
    • the "Next" variants
    • the atomic claim
    • non-string thread ids
  • The -m eval suite passes too.
  • Frontend: npm run test:e2e gives 102/102. These cover:
    • a fresh chat with suggestions, a thread created on first send, follow-ups staying in the same thread, resume, new chat and delete
    • the ?q= handoff sending once (and from Ask itself, every time), and a blank q sending nothing
    • no bare "Next:", and a rail that doesn't move the conversation or turn the active row unreadable
    • the palette: Ctrl+K, Caps Lock, no page shift
    • the sidebar never scrolling sideways, and Ask using the Sky palette at AA contrast
  • tsc, lint and build are clean; /ask and /home are static.

Review (whole branch, Opus)

  • Fixed with tests:
    • Using the palette while on Ask appended to the open thread, a second use did nothing, and a reload resent the question.
    • Two concurrent first lists could leave an empty "Earlier chats".
    • A non-string thread_id returned 500 on Postgres.
    • The send button's states were nearly identical on Sky.
  • Deferred minors are in spec §12:
    • a thread is committed before its messages
    • a stale 409 message
    • the thread_id index on existing databases
    • the rail's busy/focus/touch details
    • the palette inside the mobile sheet
    • whether the review-queue suggestion can be answered

Manual check

  • On a demo account: ask, follow up with "and last month?", open an older chat, press Ctrl+K from Home and from Ask.

@vercel

vercel Bot commented Oct 21, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
lumen Ready Ready Preview Oct 21, 2026 6:25pm UTC

This branch was successfully deployed

1 active deployment
Preview — 05ce4f71 Deployed Oct 21, 2026 by vercel[bot]
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.

1 participant