* Name a run's chat once when its group carries the bot's name A project's main conversation is named after its lead bot, so Today showed "Chief · Chief". Web and mobile now share one title helper that drops the repeated name. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tgvrj34NMnaqvtgvruYQZZ * Drop the "1:1 with" line under a conversation's title The stage header repeated what the chat already shows, such as "1:1 with Chief" under a project's name. The title and the phase pill remain. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tgvrj34NMnaqvtgvruYQZZ * Let the stage's translated thinking lines speak while a bot works A running bot raised a "working" awareness event whose English line, such as "Chief is working on your request.", replaced the translated thinking lines and added an "In progress" strip next to the phase pill. The strip now only shows collaboration. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tgvrj34NMnaqvtgvruYQZZ * Ask bots to describe their steps without naming tools Long runs showed lines such as "I'm using browser_navigate" in the chat. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tgvrj34NMnaqvtgvruYQZZ * Announce the stage phase as status and keep following after a tap The working strip used to be the only status region while a bot worked; the stage's phase pill now carries that role. A tap at the latest message no longer stops the transcript from following new messages. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Tgvrj34NMnaqvtgvruYQZZ --------- Co-authored-by: Claude <noreply@anthropic.com>
41 lines
1.3 KiB
TypeScript
41 lines
1.3 KiB
TypeScript
import * as fc from "fast-check";
|
|
import { describe, expect, it } from "vitest";
|
|
import { assertTransition, canTransition, runChatTitle } from "./run-state.js";
|
|
|
|
describe("run state machine", () => {
|
|
it("allows takeover resume onto a lease", () => {
|
|
expect(canTransition("waiting_takeover", "leased")).toBe(true);
|
|
expect(canTransition("waiting_takeover", "running")).toBe(false);
|
|
});
|
|
|
|
it("rejects rewriting a completed run", () => {
|
|
expect(() => assertTransition("completed", "running")).toThrow(/illegal/i);
|
|
});
|
|
|
|
it("never leaves a terminal state except failed retry", () => {
|
|
fc.assert(
|
|
fc.property(
|
|
fc.constantFrom("completed" as const, "cancelled" as const),
|
|
fc.constantFrom(
|
|
"queued" as const,
|
|
"leased" as const,
|
|
"running" as const,
|
|
"waiting_input" as const,
|
|
"completed" as const,
|
|
),
|
|
(from, to) => {
|
|
expect(canTransition(from, to)).toBe(false);
|
|
},
|
|
),
|
|
);
|
|
});
|
|
});
|
|
|
|
describe("runChatTitle", () => {
|
|
it("names the group unless it repeats the bot's name", () => {
|
|
expect(runChatTitle({ botName: "Writer", groupName: "Launch" })).toBe("Writer · Launch");
|
|
expect(runChatTitle({ botName: "Chief", groupName: "Chief" })).toBe("Chief");
|
|
expect(runChatTitle({ botName: "Chief", groupName: null })).toBe("Chief");
|
|
});
|
|
});
|