File size: 1,835 Bytes
c4c2b3f
431f428
 
 
c4c2b3f
 
c79fae1
c272249
c4c2b3f
 
431f428
c4c2b3f
 
 
431f428
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
c272249
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
---
title: CronosPMC HR Enterprise Chatbot
emoji: πŸ—οΈ
colorFrom: indigo
colorTo: red
sdk: gradio
sdk_version: 5.49.1
python_version: "3.11"
app_file: app.py
pinned: false
short_description: AI-powered HR assistant for CronosPMC
license: mit
---

# CronosPMC HR Enterprise Chatbot

A production-grade Retrieval-Augmented Generation (RAG) chatbot built for **CronosPMC** β€” a Dubai-based construction project management consulting and professional training practice serving GCC clients.

## What it does

Answers HR questions by retrieving relevant passages from four policy documents indexed in Pinecone:

- CronosPMC Employee Handbook (v1)
- CronosPMC Leave Policy (v1)
- CronosPMC Remote Work Policy (v1)
- CronosPMC HR FAQ (v1)

It uses GPT-4o-mini + `text-embedding-3-large`, with a strict guardrail prompt that scopes answers to HR topics only and routes confidential matters to `Info@CronosPMC.com`.

## Architecture

```
User β†’ Gradio UI β†’ LlamaIndex chat_engine β†’ Pinecone (top-k retrieval)
                                          ↓
                     GPT-4o-mini ← retrieved chunks + system prompt
```

## Required Space Secrets

Configure these under **Space Settings β†’ Variables and secrets**:

| Name | Description |
|---|---|
| `OPENAI_API_KEY` | OpenAI API key for the LLM and embeddings |
| `PINECONE_API_KEY` | Pinecone API key (free tier supports this scale) |

## Files

- `app.py` β€” main application (Gradio UI + RAG pipeline)
- `requirements.txt` β€” Python dependencies
- `data/` β€” the four CronosPMC policy PDFs
- `assets/` β€” branding assets (logo, avatar)

## Disclaimer

These policies are internal synthetic templates for demonstration. They do not constitute legal advice and do not override active UAE labour law or any employment contract.

Β© CronosPMC Β· Project Solution Experts