e30e75b5d4
Changesets / Create Version PR (push) Has been cancelled
Deploy Shadcn Registry / Deploy Production (push) Has been cancelled
Template Metrics / LOC + Bundle Size (push) Has been cancelled
Code Quality / Oxlint + Oxfmt (push) Has been cancelled
Code Quality / Template Sync (push) Has been cancelled
Code Quality / Build Changed Packages (push) Has been cancelled
Code Quality / Test Changed Packages (push) Has been cancelled
Deploy Expo Example / Deploy Production (push) Has been cancelled
Deploy Ink Example / Deploy Production (push) Has been cancelled
Python Tests / pytest (assistant-stream, 3.10) (push) Has been cancelled
Python Tests / pytest (assistant-stream, 3.12) (push) Has been cancelled
Python Tests / pytest (assistant-ui-sync-server-api, 3.10) (push) Has been cancelled
Python Tests / pytest (assistant-ui-sync-server-api, 3.12) (push) Has been cancelled
35 lines
801 B
TypeScript
35 lines
801 B
TypeScript
"use client";
|
|
|
|
import { Thread } from "@/components/assistant-ui/thread";
|
|
import { useAui, AuiProvider, Suggestions } from "@assistant-ui/react";
|
|
|
|
function ThreadWithSuggestions() {
|
|
const aui = useAui({
|
|
suggestions: Suggestions([
|
|
{
|
|
title: "Send a test message",
|
|
label: "to see the external store in action",
|
|
prompt: "Hello! How does the external store work?",
|
|
},
|
|
{
|
|
title: "Tell me a story",
|
|
label: "to generate multiple messages",
|
|
prompt: "Tell me a short story about a robot learning to paint.",
|
|
},
|
|
]),
|
|
});
|
|
return (
|
|
<AuiProvider value={aui}>
|
|
<Thread />
|
|
</AuiProvider>
|
|
);
|
|
}
|
|
|
|
export default function Home() {
|
|
return (
|
|
<main className="h-dvh">
|
|
<ThreadWithSuggestions />
|
|
</main>
|
|
);
|
|
}
|