Files
homarr/apps/nextjs/src/components/assistant/assistant-human-tool-status.ts
T

8 lines
366 B
TypeScript

import type { ToolCallMessagePartStatus } from "@assistant-ui/react";
export const hasCompleteAssistantToolArguments = (status: ToolCallMessagePartStatus | undefined) =>
status?.type !== "running" && status?.type !== "incomplete";
export const hasFailedAssistantToolArguments = (status: ToolCallMessagePartStatus | undefined) =>
status?.type === "incomplete";