/syncfusion-winui:syncfusion-winui-ai-assistviewfrom Syncfusion WinUI Controls
Guide for implementing the Syncfusion WinUI AI AssistView control for creating AI chat interfaces and conversational UI. Use this skill when implementing AI chat interfaces, AI assistants, conversational UI, or chatbots in WinUI applications. Essential for creating AI-powered chat experiences, integrating AI services, displaying AI responses, showing typing indicators, providing AI suggestions, managing conversation history with a navigation view, customizing empty states with EmptyView/EmptyViewTemplate, or setting input placeholder text in conversational interfaces with AI services in WinUI.
Ships in Syncfusion WinUI Controls. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Use this skill when the user needs to:
Always apply this skill when the user mentions: AI chat, AI assistant, chatbot, conversational UI, AI responses, chat interface, AI integration, typing indicator, AI suggestions, conversation history, multi-conversation, navigation view, empty state, placeholder text, or AI-powered conversations in WinUI applications.
SfAIAssistView is a Syncfusion WinUI control that provides a comprehensive AI chat interface for building intelligent and responsive applications with AI services. It offers a user-friendly conversational UI with built-in support for suggestions, typing indicators, response toolbars, conversation history, customizable empty states, and input placeholder text.
Namespace: Syncfusion.UI.Xaml.Chat
NuGet Package: Syncfusion.Chat.WinUI
Platform: WinUI 3 Desktop (.NET 5+, Windows App SDK 1.0+)
Key Advantage: Provides a complete AI chat experience out-of-the-box with built-in toolbars, suggestions, typing indicators, and stop responding features—no need to build a chat UI from scratch.
📄 Read: references/getting-started.md
📄 Read: references/suggestions.md
📄 Read: references/response-toolbar.md
📄 Read: references/input-toolbar.md
📄 Read: references/typing-and-stop-responding.md
📄 Read: references/theming-and-events.md
📄 Read: references/conversation-history.md
📄 Read: references/customization.md
<Page
xmlns:syncfusion="using:Syncfusion.UI.Xaml.Chat">
<Grid>
<syncfusion:SfAIAssistView
x:Name="aiAssistView"
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
Suggestions="{Binding Suggestions}"
ShowTypingIndicator="{Binding IsProcessing}"
TypingIndicator="{Binding TypingIndicator}"/>
</Grid>
</Page>
using Syncfusion.UI.Xaml.Chat;
using System.Collections.ObjectModel;
public class ViewModel : INotifyPropertyChanged
{
private ObservableCollection<object> chats;
private Author currentUser;
private IEnumerable<string> suggestions;
private TypingIndicator typingIndicator;
private bool isProcessing;
public ViewModel()
{
this.CurrentUser = new Author { Name = "User" };
this.Chats = new ObservableCollection<object>();
this.TypingIndicator = new TypingIndicator { Author = new Author { Name = "AI" } };
this.Suggestions = new ObservableCollection<string>();
InitializeChat();
}
private async void InitializeChat()
{
// User asks a question
this.Chats.Add(new TextMessage
{
Author = CurrentUser,
Text = "What is WinUI?"
});
// Show typing indicator
IsProcessing = true;
await Task.Delay(1000);
// AI responds
IsProcessing = false;
this.Chats.Add(new TextMessage
{
Author = new Author { Name = "AI" },
Text = "WinUI is a user interface layer that contains modern controls and styles for building Windows apps."
});
// Update suggestions
Suggestions = new ObservableCollection<string>
{
"What is the future of WinUI?",
"What is XAML?",
"What is the difference between WinUI 2 and WinUI 3?"
};
}
public ObservableCollection<object> Chats
{
get => chats;
set { chats = value; RaisePropertyChanged(nameof(Chats)); }
}
public Author CurrentUser
{
get => currentUser;
set { currentUser = value; RaisePropertyChanged(nameof(CurrentUser)); }
}
public IEnumerable<string> Suggestions
{
get => suggestions;
set { suggestions = value; RaisePropertyChanged(nameof(Suggestions)); }
}
public TypingIndicator TypingIndicator
{
get => typingIndicator;
set { typingIndicator = value; RaisePropertyChanged(nameof(TypingIndicator)); }
}
public bool IsProcessing
{
get => isProcessing;
set { isProcessing = value; RaisePropertyChanged(nameof(IsProcessing)); }
}
public event PropertyChangedEventHandler PropertyChanged;
private void RaisePropertyChanged(string propertyName) =>
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
}
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"/>
public class ViewModel
{
public Author CurrentUser { get; set; } = new Author { Name = "John" };
public ObservableCollection<object> Chats { get; set; } = new();
public ViewModel()
{
Chats.Add(new TextMessage { Author = CurrentUser, Text = "Hello!" });
Chats.Add(new TextMessage { Author = new Author { Name = "Bot" }, Text = "Hi! How can I help you?" });
}
}
When to use: Simple AI chat without suggestions or typing indicators.
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
ShowTypingIndicator="{Binding IsAIProcessing}"
TypingIndicator="{Binding TypingIndicator}"/>
private async void SendMessageToAI(string userMessage)
{
Chats.Add(new TextMessage { Author = CurrentUser, Text = userMessage });
// Show typing indicator
IsAIProcessing = true;
// Call AI service
var aiResponse = await CallAIService(userMessage);
// Hide typing indicator and show response
IsAIProcessing = false;
Chats.Add(new TextMessage { Author = new Author { Name = "AI" }, Text = aiResponse });
}
When to use: Show real-time feedback while AI generates responses.
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
Suggestions="{Binding CurrentSuggestions}"/>
private void UpdateSuggestions(string lastAIResponse)
{
// Generate contextual suggestions based on AI response
CurrentSuggestions = new ObservableCollection<string>
{
"Tell me more",
"Show me an example",
"What are the alternatives?"
};
}
When to use: Expedite conversation flow with contextual quick responses.
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
IsResponseToolbarVisible="True"
ResponseToolbarItemClicked="ResponseToolbar_ItemClicked"/>
private void ResponseToolbar_ItemClicked(object sender, ResponseToolbarItemClickedEventArgs e)
{
switch (e.Item.ItemType)
{
case ResponseToolbarItemType.Copy:
CopyToClipboard(e.Message.Text);
break;
case ResponseToolbarItemType.Regenerate:
RegenerateAIResponse(e.Message);
break;
case ResponseToolbarItemType.Like:
SendFeedback("like", e.Message);
break;
case ResponseToolbarItemType.Dislike:
SendFeedback("dislike", e.Message);
break;
}
}
When to use: Allow users to interact with AI responses (copy, regenerate, rate).
<syncfusion:SfAIAssistView IsInputToolbarVisible="True">
<syncfusion:SfAIAssistView.InputToolbarItems>
<syncfusion:InputToolbarItem Tooltip="Attach file">
<syncfusion:InputToolbarItem.ItemTemplate>
<DataTemplate><Button Click="AttachFile_Click"><SymbolIcon Symbol="Attach"/></Button></DataTemplate>
</syncfusion:InputToolbarItem.ItemTemplate>
</syncfusion:InputToolbarItem>
</syncfusion:SfAIAssistView.InputToolbarItems>
</syncfusion:SfAIAssistView>
When to use: Allow users to attach files to AI prompts. See input-toolbar.md for full implementation.
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
EnableStopResponding="True"
StopResponding="StopResponding_Event"/>
private CancellationTokenSource aiCancellationToken;
private async void SendToAI(string prompt)
{
aiCancellationToken = new CancellationTokenSource();
try
{
var response = await CallAIServiceAsync(prompt, aiCancellationToken.Token);
Chats.Add(new TextMessage { Author = new Author { Name = "AI" }, Text = response });
}
catch (OperationCanceledException)
{
Chats.Add(new TextMessage { Author = new Author { Name = "AI" }, Text = "Response canceled." });
}
}
private void StopResponding_Event(object sender, EventArgs e)
{
aiCancellationToken?.Cancel();
}
When to use: Allow users to cancel long-running AI responses.
private void PromptRequest_Event(object sender, PromptRequestEventArgs e)
{
if (string.IsNullOrWhiteSpace(e.InputMessage.Text))
{
e.Handled = true;
ShowError("Please enter a message.");
}
}
When to use: Validate or preprocess user input before AI processing.
private async Task<string> CallOpenAI(string prompt)
{
var client = new OpenAIClient(apiKey);
var response = await client.CompleteChatAsync("gpt-4", new ChatCompletionOptions
{
Messages = { new SystemChatMessage("You are a helpful assistant."), new UserChatMessage(prompt) }
});
return response.Value.Content[0].Text;
}
When to use: Integrate with OpenAI GPT models. See theming-and-events.md for theme configuration.
<syncfusion:SfAIAssistView
Messages="{Binding Chats}"
CurrentUser="{Binding CurrentUser}"
Conversations="{Binding Conversations}"
ShowNavigationView="True"
NavigationHeader="Sync AI Assist" />
public ObservableCollection<AssistConversationItem> Conversations { get; set; } = new()
{
new AssistConversationItem
{
Title = "Scotland",
DateTime = DateTime.Today,
AssistItems = new ObservableCollection<object>
{
new TextMessage { Author = CurrentUser, Text = "Tell me about Scotland." },
new TextMessage { Author = new Author { Name = "AI" }, Text = "Scotland is known for its castles and landscapes." }
}
}
};
When to use: Build a multi-conversation AI assistant where users can switch between archived chats. See conversation-history.md for full implementation.
<syncfusion:SfAIAssistView
CurrentUser="{Binding CurrentUser}"
Messages="{Binding Chats}"
InputPlaceholderText="Type your message here..." />
When to use: Guide the user with a hint (e.g., "Type your question here…") inside the input area before they type.
<!-- Simple empty state -->
<syncfusion:SfAIAssistView EmptyView="How can I help you?" />
<!-- Rich empty state with a template -->
<syncfusion:SfAIAssistView InputPlaceholderText="Type your message here...">
<syncfusion:SfAIAssistView.EmptyViewTemplate>
<DataTemplate>
<StackPanel VerticalAlignment="Center" HorizontalAlignment="Center">
<TextBlock Text="Hi, How can I help you?" FontSize="20" FontWeight="Bold" />
<TextBlock Text="Ask anything to get started." FontSize="16" />
</StackPanel>
</DataTemplate>
</syncfusion:SfAIAssistView.EmptyViewTemplate>
</syncfusion:SfAIAssistView>
When to use: Display a welcome message, image, or call-to-action before a conversation starts. Empty view is shown only when Messages is empty. If BannerTemplate is also provided, the banner is shown instead. See customization.md for full details.
| Property | Type | Default | Description |
|---|---|---|---|
Messages | ObservableCollection<object> | null | Collection of chat messages (TextMessage objects). |
CurrentUser | Author | null | Current user author information. Required to distinguish user messages from AI responses. |
Suggestions | IEnumerable<string> | null | AI-driven suggestions displayed in bottom-right corner for quick responses. |
ShowTypingIndicator | bool | false | Shows/hides typing indicator during AI processing. |
TypingIndicator | TypingIndicator | null | Typing indicator configuration (author, text). |
IsResponseToolbarVisible | bool | true | Shows/hides response toolbar (Copy, Regenerate, Like, Dislike). |
ResponseToolbarItems | ObservableCollection<ResponseToolbarItem> | Built-in items | Custom toolbar items for response actions. |
IsInputToolbarVisible | bool | false | Shows/hides input toolbar in text input area. |
InputToolbarItems | ObservableCollection<InputToolbarItem> | null | Custom toolbar items for input area (e.g., attach file). |
InputToolbarPosition | ToolbarPosition | Right | Position of input toolbar (Left or Right). |
InputToolbarHeaderTemplate | DataTemplate | null | Custom template for input area header (e.g., file upload info). |
EnableStopResponding | bool | false | Enables stop responding button to cancel ongoing AI responses. |
StopRespondingTemplate | DataTemplate | null | Custom template for stop responding button. |
StopRespondingCommand | ICommand | null | Command executed when stop responding button is clicked. |
RequestedTheme | ElementTheme | Default | Theme for the control (Light, Dark, or Default). Set in App.xaml. |
ShowNavigationView | bool | false | Shows/hides the built-in conversation history navigation view. |
Conversations | ObservableCollection<AssistConversationItem> | null | Data source for archived conversations rendered in the navigation view. |
NavigationHeader | string | string.Empty | Header text shown at the top of the navigation view. |
InputPlaceholderText | string | null | Placeholder text shown in the input box before the user types a message. |
EmptyView | object | null | Simple content (text or UI element) shown in the chat area when Messages is empty. |
EmptyViewTemplate | DataTemplate | null | DataTemplate used to render rich content in the empty state. |
| Event | Description |
|---|---|
PromptRequest | Fired when user submits a prompt. Provides InputMessage and Handled properties. |
ResponseToolbarItemClicked | Fired when response toolbar item is clicked. Provides item details. |
InputToolbarItemClicked | Fired when input toolbar item is clicked. Provides item details. |
StopResponding | Fired when stop responding button is clicked. Use to cancel AI operations. |
Best Approach: Use Messages for conversation history, Suggestions for common queries, typing indicator for feedback.
Best Approach: Enable response toolbar for copying code, regenerating responses. Use input toolbar for file/code uploads.
Best Approach: Use suggestions for learning paths, response toolbar for rating answers, typing indicator for engagement.
Best Approach: Enable ShowNavigationView and bind Conversations. Combine with EmptyViewTemplate to welcome first-time users before they start a new chat.
Best Approach: Enable copy/regenerate in response toolbar, use suggestions for content variations.
Best Approach: Use input toolbar for data uploads, stop responding for long queries, response toolbar for export actions.
Message Management: Use ObservableCollection for Messages to automatically update UI when adding/removing messages.
Typing Indicator: Show during async AI calls, hide when response arrives. Bind to ViewModel boolean property.
Suggestions: Update dynamically based on conversation context. Clear after user selects or after few exchanges.
Error Handling: Use PromptRequest event to validate input. Catch AI service errors gracefully.
Performance: For long conversations, consider implementing message pagination or limiting visible message count.
AI Service Integration: Use async/await for AI service calls. Implement cancellation tokens with stop responding feature.
Response Toolbar: Default items (Copy, Regenerate, Like, Dislike) work automatically. Handle ResponseToolbarItemClicked for custom logic.
Input Toolbar: Use for frequently needed actions like file upload, voice input, or emoji picker.
Theme Support: Set RequestedTheme in App.xaml for app-wide theme. Control auto-adapts to light/dark mode.
Accessibility: Set Author.Name for screen readers. Ensure sufficient contrast in custom templates.
Conversation History: Bind Conversations as an ObservableCollection<AssistConversationItem> so the navigation view stays in sync. Use NavigationHeader to brand the side panel (e.g., "Sync AI Assist").
Empty State vs Banner: If both BannerTemplate and EmptyView/EmptyViewTemplate are defined, the banner takes precedence. Use the empty view for a centered welcome, and the banner for persistent top-of-chat branding.
Input Placeholder: Keep InputPlaceholderText short and action-oriented (e.g., "Type your message here..."). It disappears as soon as the user starts typing.
references/conversation-history.md (opens in a new tab)references/customization.md (opens in a new tab)references/getting-started.md (opens in a new tab)references/input-toolbar.md (opens in a new tab)references/response-toolbar.md (opens in a new tab)references/suggestions.md (opens in a new tab)references/theming-and-events.md (opens in a new tab)references/typing-and-stop-responding.md (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub syncfusion/boldcreate-plugins --plugin syncfusion-winui39 skills in this plugin
/syncfusion-winui-autocompleteGuide implementation of the Syncfusion WinUI AutoComplete control (SfAutoComplete) for creating searchable dropdowns with single or multiple selection, filtering suggestions, and customizable token display. Use this skill when implementing search-as-you-type functionality, autocomplete dropdowns with multi-select, tagging systems with token/chip display, or filtered suggestion boxes in WinUI applications./syncfusion-winui-avatar-viewGuide for implementing the Syncfusion WinUI AvatarView control to display user avatars and profile pictures. Use this when implementing user profiles, contact lists, or chat interfaces requiring visual user representation in WinUI applications. This skill covers initials display, image avatars, group avatars, and pre-defined avatar characters./syncfusion-winui-badgeGuide implementation of the Syncfusion WinUI Badge control (SfBadge) for displaying notification badges and status indicators. Use this skill when working with badge notifications, unread count badges, BadgeContainer, or notification overlays in WinUI applications. Covers shapes, colors, positioning, alignment, animations, and customization patterns./syncfusion-winui-barcodeImplement Syncfusion WinUI Barcode (SfBarcode) control to generate and display machine-readable barcodes in desktop applications. Use this when working with barcodes, QR codes, or product labeling systems. This skill covers symbology types (DataMatrix, Code39, Code128, Codabar, UPC), barcode customization, text alignment, rotation, and visual encoding for WinUI applications./syncfusion-winui-busy-indicatorGuide for implementing the Syncfusion WinUI BusyIndicator control to display loading indicators and progress status. Use this skill when implementing loading indicators, showing progress status, indicating background operations, or creating waiting screens in WinUI applications. Essential for async data loading, file operations, API calls, and any scenario requiring user notification during processing tasks./syncfusion-winui-calendarImplements Syncfusion WinUI Calendar (SfCalendar) control for date selection in desktop applications. Use this when building date pickers, date selection interfaces (single, multiple, or range), month/year navigation, or calendar views. This skill covers calendar configuration, date restrictions, blackout dates, week numbers, localization, and customization for Windows desktop applications.