Skip to content

T-FDZ3-agent-chat-markdown-answers

State: closed/done · Impact: medium · Complexity: small

Agent answers in the agent-chat experience are shown as pre-wrap text, so lists, fences and emphasis the model writes arrive as raw syntax. This task renders the answer turn through MdViewer; user turns and tool traces stay plain.

LocationRole today
solutions/determined/experiences/agent-chat/app/components/AgentChatMessage.vueAnswer is <p class="turn-agent__text">{{ row.text }}</p> with white-space: pre-wrap
solutions/determined/experiences/agent-chat/package.jsonDepends on @determined/platform only
solutions/determined/experiences/agent-chat/nuxt.config.tsEmpty layer config
solutions/determined/products/agent-chat/nuxt.config.tsExtends shell, vaults and the agent-chat experience; moon id product-agent-chat

The answer block is <MdViewer :source="row.text" :provider="chatProvider" /> where chatProvider.resolveLink returns { kind: 'missing' } for every target: agent output is untrusted and has no vault index behind it, so wikilinks render as unresolved text with no href. highlight, math and mermaid stay at the viewer defaults (off). The turn-agent__text rule is deleted. User turns, thinking steps and tool results are unchanged.

  1. package.json: add @sksizer/markdown-ui (workspace:*); nuxt.config.ts: extends: ['@sksizer/markdown-ui'].
  2. AgentChatMessage.vue: replace the answer <p> with MdViewer and a module-level provider whose resolveLink always answers missing; delete the turn-agent__text style.
  3. Root bun install; bun install --frozen-lockfile.
  4. Verify: moon run product-agent-chat:check; a conversation whose answer has a list, a fence and a wikilink in light and dark (screenshots); nuxi analyze on the product shows mermaid and KaTeX as lazy chunks only; moon run :check :test --affected.
LocationKindChange
solutions/determined/experiences/agent-chat/package.jsonmodifyAdd @sksizer/markdown-ui
solutions/determined/experiences/agent-chat/nuxt.config.tsmodifyExtend the layer
solutions/determined/experiences/agent-chat/app/components/AgentChatMessage.vuemodifyAnswer through MdViewer; delete the pre-wrap answer rule
bun.lockmodifyRoot lockfile regen
  • AC-1: AgentChatMessage.vue has no turn-agent__text element and mounts MdViewer for the answer.
  • AC-2: An answer containing Home renders the wikilink without an href attribute.
  • AC-3: moon run product-agent-chat:check passes.
  • AC-4: Light and dark screenshots of an answer with a list, a fence and a wikilink are attached to the PR.
  • AC-5: bun install --frozen-lockfile passes at the root.
  • Rendering user turns or tool-call results as markdown.
  • Resolving wikilinks against the vault the agent read; a later task can pass the notes provider.
  • Streaming re-render tuning; the viewer re-renders on each text change as today’s <p> did.

Member of milestone M-931L; wave 3a of D-K3EM-markdown-editor-chrome-and-plugin-environment.

T-A0HT-md-ui-layer-skeleton


← Back to Tasks