Umbraco.Community.AI.Chatbot.Persistence.SqlServer
1.0.0
dotnet add package Umbraco.Community.AI.Chatbot.Persistence.SqlServer --version 1.0.0
NuGet\Install-Package Umbraco.Community.AI.Chatbot.Persistence.SqlServer -Version 1.0.0
<PackageReference Include="Umbraco.Community.AI.Chatbot.Persistence.SqlServer" Version="1.0.0" />
<PackageVersion Include="Umbraco.Community.AI.Chatbot.Persistence.SqlServer" Version="1.0.0" />
<PackageReference Include="Umbraco.Community.AI.Chatbot.Persistence.SqlServer" />
paket add Umbraco.Community.AI.Chatbot.Persistence.SqlServer --version 1.0.0
#r "nuget: Umbraco.Community.AI.Chatbot.Persistence.SqlServer, 1.0.0"
#:package Umbraco.Community.AI.Chatbot.Persistence.SqlServer@1.0.0
#addin nuget:?package=Umbraco.Community.AI.Chatbot.Persistence.SqlServer&version=1.0.0
#tool nuget:?package=Umbraco.Community.AI.Chatbot.Persistence.SqlServer&version=1.0.0
Umbraco.Community.AI.Chatbot
A community Umbraco package that exposes a public-facing, AI-powered chat widget on a website's frontend. Visitors ask questions in natural language; the package runs a semantic search over your site's content (Umbraco.AI.Search), feeds matched pages into an Umbraco.AI.Agent, and streams a grounded answer back with cited source pages and follow-up suggestions.
Requirements
- Umbraco CMS 17.3+
Umbraco.AI1.10+Umbraco.AI.Agent1.9+ — at least one configured AgentUmbraco.AI.Search— a populated index over your site's content
Quickstart
Install the NuGet package in your Umbraco site project.
Build the search index under AI → Add-ons → Search — the chat package reads from
UmbAI_Search.Create an Agent under AI → Add-ons → Agents. Put your brand voice / persona in the agent's Instructions field.
Create a Chat Instance under AI → Add-ons → Chatbot → Create. Pick the agent you just made, set a welcome message and a fallback message.
Drop the widget script into the public layout (e.g.
Views/Master.cshtml):<script type="module" src="/App_Plugins/UmbracoCommunityAIChatbot/widget.js" data-instance="my-chat-alias"></script>Optional attributes:
data-welcome="..."— overrides the welcome message configured in the backofficedata-title="..."— overrides the panel titledata-api-base="..."— only needed for cross-origin embedding
A floating chat button appears bottom-right on every page that includes the script.
How it works
Website visitor
│ POST /umbraco/community/chatbot/api/v1/chat (anonymous, SSE)
▼
ChatController ── rate limit + agent-active check
▼
ChatOrchestrator
├── ISearcher → top-K matched documents
├── ContentResolver → IPublishedContent → title, URL, body text
├── GroundingPromptBuilder → strict "answer ONLY from sources" prompt
├── IAIAgentService.StreamAgentAsync → streamed answer (uses agent's Instructions)
└── FollowUpGenerator → suggested follow-up questions
▼
SSE: sources → delta* → suggestions → done
The agent's persona/tone lives on the agent's Instructions field. Our orchestrator only owns the grounding rules and the source block — so the two prompts don't fight.
Configuration
Each chat instance has:
| field | description |
|---|---|
Name |
Display name (alias auto-derives from this — connection-style lock) |
Alias |
URL-safe identifier the public endpoint accepts |
AgentAlias |
Pick from a dropdown of configured Umbraco.AI.Agent instances |
WelcomeMessage |
Shown by the widget when a visitor opens the chat |
FallbackMessage |
Returned verbatim when the search has no relevant content |
Sources per answer |
How many top-ranked pages to inject as grounding context (1–50) |
Follow-up suggestions |
How many suggested questions to generate (0 disables them) |
Status |
Active / Inactive — disables the public endpoint without deletion |
Migrations run automatically on application start.
Rate limit (public endpoint)
The public chat endpoint is anonymous and LLM-backed, so by default we apply a per-IP sliding-window limit of 30 requests / 5 minutes. Override in appsettings.json:
{
"Umbraco": {
"Community": {
"Chatbot": {
"RateLimit": {
"RequestsPerWindow": 30,
"WindowSeconds": 300
}
}
}
}
}
Set RequestsPerWindow to 0 to disable. Tighten it on production sites that don't expect heavy traffic — there's no practical reason a single visitor needs more than a handful of chat turns per minute.
Per-request size caps are also enforced: max 50 messages in the conversation, max 4 000 characters per message. Exceeding either returns a 400.
⚠️ Security caveats — read before deploying
Anonymous LLM access costs money
Even with the rate limiter on, a determined attacker behind a botnet can still drive up your inference bill. If you have any concern about this, put a CDN/WAF in front (Cloudflare Turnstile, AWS WAF rate rules, etc.) and consider a tighter RequestsPerWindow.
Member-protected content
The chat endpoint is anonymous. The package's IChatPrincipalAccessor is wired but ships an anonymous-only implementation. If your search index contains member-protected content, all of it is reachable through the public chat. Until a Member-aware accessor lands, the safe path is to keep member-only documents out of the UmbAI_Search index, or build a custom IChatPrincipalAccessor that maps the cookie member into the access context.
XSS posture
The widget renders the model's response through marked and unsafeHTML. The model is grounded in your own published content, so practical XSS surface is small — but if you index user-generated text (comments, forum posts), pipe model output through DOMPurify before rendering or strip HTML tags entirely.
Things explicitly not in MVP
- Server-side conversation history / analytics — the widget owns history in
localStorage, capped at 20 turns - Multi-instance scoping by content sub-tree
- Member-aware content filtering implementation (the abstraction is wired)
- SignalR (we use SSE)
- Cross-origin (CORS) embedding — assume same-origin
License
MIT — see LICENSE.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Umbraco.Cms.Persistence.EFCore.SqlServer (>= 17.3.0 && < 17.999.999)
- Umbraco.Community.AI.Chatbot.Persistence (>= 1.0.0)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on Umbraco.Community.AI.Chatbot.Persistence.SqlServer:
| Package | Downloads |
|---|---|
|
Umbraco.Community.AI.Chatbot.Startup
Composer that wires Umbraco.Community.AI.Chatbot into Umbraco. |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0 | 119 | 5/8/2026 |