Exit
MI
Microsoft Azure AIEnterprise RAG & GraphRAG
Principal Applied AI / GraphRAG Architect • $320K – $620K TC (L64–L66)
GenAI & Enterprise RAGWith-AI Coding Allowed
Codebase 3: Enterprise Policy RAG & Salary-Leak Audit
Inspect a company HR & Policy RAG chatbot over Leave Policy Markdown and Payroll JSON. Trigger both real-world failures: (1) hallucinating intern leave carry-forward rules from cut tables, and (2) leaking Priya Sharma's confidential salary to interns due to missing RBAC pre-filtering + bloated FP64 linear scan.
System Design Perspective
Enterprise RAG & GraphRAG
Before You Start (Microsoft Azure AI)
Run Codebase 3 (`python app.py` on port 8100) and trigger both the intern leave hallucination and salary PII leak before designing your GraphRAG fix.
Download & Run LocallyDownload .zip
Runtime: Python 3.9+ (Pure stdlib — zero pip install required)
unzip enterprise-policy-rag.zip cd enterprise-policy-rag python app.py # Open http://localhost:8100, keep Role = intern, and click Test 1 & Test 2!
Google / Microsoft / Deloitte / Morgan Stanley RAG Style
VECTOR_DIM = 256 # Unnormalized FP64 dense list -> bloated memory!
# BUG 1: Fixed 180-char slicing breaks Markdown leave tables mid-row!
for i in range(0, len(raw), 180):
self.chunks.append({"source": "hr_leave_policy.md", "access_role": "all", "text": raw[i:i+180]})
# BUG 2: Confidential payroll JSON embedded into SAME flat index!
for rec in records:
self.chunks.append({
"source": "payroll_confidential.json",
"access_role": rec["required_access_role"], # NEVER checked in retrieve()!
"text": f"Employee {rec['name']} earns annual CTC INR {rec['annual_ctc_inr']}..."
})