Guardrails & AI Behavior
J.O.S.I.E is designed to be helpful but bounded — not a general-purpose chatbot.
Pipeline overview
User message
↓
Content filter (off-topic / unsafe signals)
↓
RAG retrieval (Pro+ only, if corpus exists)
↓
Context guard (require evidence for factual claims)
↓
LLM with system prompt + static knowledge + RAG context
↓
Response to user
Content filter
Before any model call, server-side checks evaluate the message for:
- Off-topic requests relative to configured scope
- Prompt injection patterns
- Disallowed categories (configurable via prompt)
Blocked requests return a polite refusal without calling the LLM.
Context guard
For factual questions (pricing, policies, product specs):
- If RAG chunks or static knowledge cover the topic → answer allowed
- If no evidence → assistant explains it doesn't have that information
- Prevents inventing refund windows, prices, or features
This is why good documentation matters on Pro plans.
RAG grounding
When chunks are retrieved:
- Context is injected with clear boundaries
- Model instructed to prefer provided text
- Distance thresholds vary by tier (Pro/Enterprise are more permissive for FAQ phrasing)
Demo vs. live behavior
| Context | Model | Purpose |
|---|---|---|
Demo chat (/chat) | Groq (demo key) | Platform showcase |
| Dashboard preview | Groq or configured preview | Tenant testing |
| Live widget (paid) | OpenAI gpt-4o-mini | Production quality |
Behavioral guardrails are the same; model quality differs.
Tuning behavior without code
- Tighten system prompt — explicit "never discuss X"
- Add static knowledge for must-not-get-wrong facts
- Upload RAG docs for detailed catalogs
- Test refusal paths — "write me a poem", competitor questions
What J.O.S.I.E is not
- Not a replacement for legal/medical/financial advice
- Not trained on your data globally — only your tenant config + docs
- Not guaranteed 100% accurate without proper knowledge coverage
Human escalation paths should stay in your prompt and static knowledge.