Skip to content

Answers: notice at the end, knowledge spaces in colour, hover highlights - #4

Merged
bl0rb merged 3 commits into
mainfrom
claude/gifted-faraday-g6y58h
Nov 6, 2026
Merged

bl0rb merged 3 commits into
mainfrom
claude/gifted-faraday-g6y58h

Conversation

@bl0rb

@bl0rb bl0rb commented Nov 6, 2026

Copy link
Copy Markdown
Owner

Desktop counterpart of the chat changes in bl0rb/Weave#443.

Changes

  • The answer's notice (e.g. "Nur intern") moves below the answer text.
  • An answer that mixes knowledge spaces colours each space: its [N] citation badges, the passages they back (underlined) and its source chips, with a legend naming the spaces. Each notice carries its space's colour.
  • [N] markers render as badges. Hovering (or focusing) a source chip highlights the passages it backs; hovering a badge highlights its passage.
  • Source chips show the [N] they back; duplicate chunks of one page merge into one chip.
  • Only sources with an explicit ref resolve a marker (agent turns number facts, not sources), so their markers stay plain text.

Same rules as the Weave web chat (services/chat) and Weave-API's new knowledge_spaces answer metadata. The logic lives in the new ui/citations.js (no dependencies); ui/panel.js, ui/style.css (space colours for light and dark) and ui/common.js (EN strings) are wired to it.

Testing

  • ui/citations.js checked in jsdom: space order and colours, passage/marker segmentation (incl. [2][3], nested lists, code blocks untouched, unknown [7] left as text), highlight on/off.
  • node --check on ui/panel.js and ui/citations.js.
  • Not yet clicked through in the built app.

A release (0.1.10) is needed to ship it.


Generated by Claude Code

- the answer's notice moves below the answer text
- an answer mixing knowledge spaces colours each space: its [N] citation
  badges, the passages they back (underlined) and its source chips, with
  a legend naming the spaces; each notice carries its space's colour
- [N] markers render as badges; hovering (or focusing) a source chip
  highlights the passages it backs, hovering a badge its passage
- source chips show the [N] they back; duplicates of one page merge
- only sources with an explicit ref resolve a marker (agent turns number
  facts, not sources)

Same rules as the Weave web chat and Weave-API's knowledge_spaces
answer metadata (bl0rb/Weave, services/chat and services/api).

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01W9t7FbB4c9JMD1Viygu2k8
The answer renderer showed tables as raw "|" lines, restarted numbering
at 1 after any interruption, flattened nested lists, left block quotes,
rules, __bold__ and <br> as raw text and split every line into its own
paragraph. It now renders tables, nested lists, numbered lists with
their start number (indented lines continue an item), block quotes,
rules, __bold__, <https://…> links and <br>, and keeps single line breaks
inside a paragraph. Still HTML-escaped first; only the tags built here
are produced. Citation marking also covers table cells and headings.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01W9t7FbB4c9JMD1Viygu2k8
The mark picked one of four motions per start (weave, turn, flip,
shuttle) and ended a finite run with a small scale pulse. It now only
weaves (the weft rows unweave and shuttle back in); the mark itself
stays still and the end-of-run settle has no visible motion. Mirrors
bl0rb/Weave's packages/weave-mark and web apps.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01W9t7FbB4c9JMD1Viygu2k8
@bl0rb
bl0rb merged commit 31ee8a4 into main Nov 6, 2026
3 checks passed
@bl0rb
bl0rb deleted the claude/gifted-faraday-g6y58h branch November 6, 2026 10:20
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