Open-source AI coworkers that each get a computer of their own: a browser, files and tools, with every action decided before it happens and recorded after. Bring any AG-UI agent.
import type { AuthenticatedUser } from "./queries";
/** Keep the welcome out of message history, and never guess a first name. */
export function firstConversationGreeting(
user: AuthenticatedUser | null | undefined,
noConversations: boolean,
): string {
const name = user?.name?.trim();
if (!noConversations || !name || user?.needsName || name === user?.email)
return "Start a conversation";
return `Hi ${name}, what would you like to work on?`;
}