skills/vendix-ai-chat/SKILL.md
AI Chat system: conversation CRUD, sync and SSE message endpoints, agent/RAG routing, NgRx chat state, and chat widget. Trigger: When working with AI conversations, the chat widget, chat API endpoints, or NgRx chat state.
npx skillsauth add rzyfront/vendix vendix-ai-chatInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
apps/backend/src/domains/store/ai-chat/apps/frontend/src/app/core/store/ai-chat/apps/frontend/src/app/core/services/ai-chat-api.service.tsapps/frontend/src/app/shared/components/ai-chat-widget/Base route: /store/ai-chat.
POST /conversations with AiAccessGuard and @RequireAIFeature('conversations').GET /conversations.GET /conversations/:id.POST /conversations/:id/messages with @RequireAIFeature('streaming_chat').SSE /conversations/:id/stream with @RequireAIFeature('streaming_chat').PATCH /conversations/:id/archive.PATCH /conversations/:id/title.user_id; store/org scope is handled by StorePrismaService.chat_assistant.system|user|assistant messages plus the new user message.AI_CHAT_002.deleted, so archived conversations may still be returned unless frontend removes/filters them.Sync message routing:
metadata.agent_enabled === true -> AIAgentService.runAgent().metadata.rag_enabled === true -> RAGService.queryWithContext().AIEngineService.run(appKey, undefined, contextMessages).Streaming message routing currently always calls AIEngineService.runStream() and does not use agent/RAG routing.
AIChatFacade exposes observables and signal parallels with initialValue for conversations, active id, messages, streaming content, sending/loading flags, and errors.
app.config.ts registers provideState('aiChat', aiChatReducer) and AIChatEffects.
Reducer supports optimistic user messages and streaming chunk accumulation. Current effects use sync HTTP sendMessage; no effect currently wires AIStreamService or dispatches receiveStreamChunk/streamComplete.
app-ai-chat-widget is a standalone FAB/panel component with no inputs/outputs. It mirrors facade observables into local signals and provides conversation list/message UI.
Current caveats:
<app-ai-chat-widget> in apps/frontend/src/app.getStreamUrl() does not append the required content query param for backend SSE chat stream.toSignal(..., { initialValue }) in facades.vendix-ai-platform-corevendix-ai-streamingvendix-ai-agent-toolsvendix-ai-embeddings-ragvendix-subscription-gatedevelopment
Mobile app development rules for Vendix Expo/React Native project. Trigger: When editing, creating, or modifying any file under apps/mobile, or when developing mobile-specific features.
development
Feature gating by store subscription state: global store write guard, AI feature gate, Redis feature resolution, quota consumption, frontend paywall interceptor, banner, and subscription UI states. Trigger: When adding feature gates, paywalls, subscription-based access control, protecting store write operations, AI feature gates, or rollout flags.
testing
SaaS subscription billing for Vendix stores: plan pricing, invoices, Wompi platform payments, manual payments, partner commissions, payouts, proration, and dunning. Trigger: When creating SaaS invoices, working with partner rev-share, margin/surcharge pricing, invoice sequence allocation, partner payout batches, subscription payments, manual payments, or dunning flows.
development
Periodic quota counters with Redis, UTC period keys, Lua-based idempotent AI quota consumption, request-id deduplication, and post-success consumption. Trigger: When building quota counters, enforcing monthly/daily feature caps, or reusing AI quota patterns for uploads, emails, exports, or rate-limited features.