Agent chat: the feed draws no check-in of a call (#1)
jonas, 2026-11-27 11:45 UTC Β· f7eb903f703a8cf81ea7061539dcbff9f48d2c9b Β· parent 2000e8b
2 files changed
M src/components/agent-chat/agent-ui-reducer.test.ts
@@ -136,6 +136,29 @@ ]); }); +test("a call's check-in is drawn nowhere, and the call's quiet notes and a person's words still are", () => { + const quiet = { llmRequestPolicy: { behaviour: "dont-trigger-request" } }; + const note = (offset: number, content: string, more: object) => + fact(offset, "agent/context-added", { + role: "user", + actor: { type: "user" }, + content, + ...more, + }); + const state = reduceAll([ + note(1, '[call] Ada said: "hello"', { ...quiet, callNote: { kind: "said", text: "hello" } }), + note(2, "[call] Check-in: 1 new line was said in the callβ¦", { + callNote: { kind: "check-in", lines: 1 }, + }), + said(3, "what did I miss?"), + ]); + expect(state.items).toMatchObject([ + { kind: "background", messages: [{ text: '[call] Ada said: "hello"' }] }, + { kind: "user", text: "what did I miss?" }, + ]); + expect(state.items).toHaveLength(2); +}); + test("streams thinking and response deltas into the live llm step", () => { const state = reduceAll([ said(1, "count the inputs"),
M src/components/agent-chat/agent-ui-reducer.ts
@@ -565,6 +565,11 @@ const text = readString(event, "content"); // oxlint-disable-next-line iterate/simple-truthiness-check -- empty content is a real message: a person can send files alone if (text == null || role === "assistant" || role === "system") return state; + // A CALL'S CHECK-IN is a prompt that the mind's code writes to the agent about once a minute + // while people talk (`callNote.kind: "check-in"`), and no person's words: it is drawn nowhere + // (Jonas, 27 Nov 2026: "I don't need to see that here"). The turn that it starts is drawn as + // any turn, and the Events tab and that turn's trace show the prompt. + if (readRecord(event, "callNote")?.kind === "check-in") return state; // THE AGENT'S TRANSCRIPTION of a raw fact (agent-facts.ts): the bubble is the raw fact's const transcribed = role === "user" ? transcribedFactOf(event) : undefined; const fromRaw = transcribed && reduceTranscription(state, event, transcribed, items);