How kerb0y/authenkixx-gen-ai works
This is a prototype Indonesian shop-assistant API. Its main workflow accepts a message from the Full-Stack backend, preprocesses it, classifies intent, retrieves dummy FAQ/product context, applies out-of-context refusal checks, and returns a RAG/template answer or an intent-specific manual-order/owner response. Optional generative AI can replace the RAG answer when configured. The README documents the broader routing and dummy-data capabilities; the graph omits unsampled implementation details and does not imply real order or complaint processing.
Main entry points: main.py Chat API · rag.py TF-IDF retriever · classifier.py Intent classifier · refusal.py Refusal checker
Components 15
API workflow
- Chat API
app/main.py
Intent and guardrails
- Text preprocessing
app/preprocessing.py - Intent classifier
app/classifier.py - Refusal checker
app/refusal.py - Keyword guardrail
app/main.py
Dummy knowledge
- TF-IDF retriever
app/rag.py - Intent examples
data/dummy_intents.csv - FAQ examples
data/dummy_faq.csv - Product catalogue
data/dummy_products.csv
Answer routing
- Prompt and route rules
app/prompts.py - Manual-order reply
app/prompts.py - Owner complaint reply
app/prompts.py
External services
- Generative client
app/generative.py - Generative model service
Other components
- Full-Stack backend
Connections 16
- Full-Stack backend → Chat API: sends request
README.md - Chat API → Full-Stack backend: returns response
app/main.py - Chat API → Text preprocessing: cleans message
app/main.py - Chat API → Keyword guardrail: checks topics
app/main.py - Chat API → Intent classifier: classifies intent
app/main.py - Chat API → TF-IDF retriever: retrieves context
app/main.py - Chat API → Refusal checker: checks refusal
app/main.py - Intent classifier → Intent examples: trains from
app/classifier.py - TF-IDF retriever → FAQ examples: loads documents
app/rag.py - TF-IDF retriever → Product catalogue: loads documents
app/rag.py - Chat API → Prompt and route rules: builds prompt
app/main.py - Chat API → Manual-order reply: returns order guidance
app/main.py - Chat API → Owner complaint reply: returns complaint guidance
app/main.py - Chat API → Generative client: requests generation
app/main.py - Generative client → Generative model service: sends prompt
app/generative.py - Refusal checker → Intent examples: loads examples
app/refusal.py