useChat
function useChat(options): ChatValue;Defined in: react/src/hooks.ts:121
A conversation: its messages, its run, and the commands the person gives.
const chat = useChat({ transport });<button onClick={() => chat.send("Summarize this page.")}>Summarize</button>;Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
options |
UseChatOptions |