@if (chat.messages().length === 0) {
}
@for (message of chat.messages(); track message.id) {
@if (isRenderable(message)) {
@if (message.role === 'activity') {
Powered by signals · 5 client tools
What can I help you ship?
A streaming chat built with injectChat and the OpenAI adapter. The model can call browser-side tools — try one below.
@for (s of suggestions; track s) {
}
{{
activityType(message)
}}
@if (activitySteps(message).length > 0) {
} @else {
-
@for (step of activitySteps(message); track $index) {
- {{ step.content }} }
{{
activityPayload(message)
}}
}
@if (message.role !== 'user') {
AI
}
}
}
}
@if (chat.isLoading()) {
@for (part of message.parts; track $index) {
@if (part.type === 'text' && part.content) {
{{ part.content }}
} @else if (part.type === 'tool-call') {
⚙
{{ part.name }}
@if (formatArgs(part.arguments)) {
}
}
{{
formatArgs(part.arguments)
}}
}
@if (hasOutput(part.output)) {
→
{{
formatOutput(part.output)
}}
}
AI
Thinking
}