Skip to content

VibeCoding4-JC/pdp-mcp-server

Repository files navigation

PDP MCP Server

MCP Server untuk menjawab pertanyaan seputar UU Nomor 27 Tahun 2022 tentang Perlindungan Data Pribadi (UU PDP) menggunakan RAG (Retrieval-Augmented Generation) dengan Pinecone sebagai vector database.

🚀 Features

  • RAG-powered Q&A: Menjawab pertanyaan berdasarkan isi UU PDP
  • 6 MCP Tools:
    • tanya_pdp - Pertanyaan umum tentang UU PDP
    • cari_pasal - Cari pasal berdasarkan nomor/keyword
    • definisi_istilah - Cari definisi istilah hukum
    • hak_subjek_data - Hak-hak pemilik data pribadi
    • kewajiban_pengendali - Kewajiban pengendali/prosesor data
    • sanksi_pelanggaran - Sanksi administratif dan pidana

📋 Requirements

  • Python 3.11+
  • Pinecone Account (Free tier available)
  • OpenAI API Key

🛠️ Installation

  1. Clone repository:
git clone <repository-url>
cd pdp-mcp-server
  1. Create virtual environment:
python -m venv venv
source venv/bin/activate  # Linux/Mac
# atau
.\venv\Scripts\activate  # Windows
  1. Install dependencies:
pip install -r requirements.txt
  1. Setup environment variables:
cp .env.example .env
# Edit .env dengan API keys Anda

📚 Data Ingestion

  1. Ekstrak PDF UU PDP:
python scripts/extract_pdf.py
  1. Ingest data ke Pinecone:
python scripts/ingest_data.py

🖥️ Running the Server

python -m src.server

🧪 Testing

pytest tests/ -v

📖 Usage with Claude Desktop

Add to your Claude Desktop config (claude_desktop_config.json):

{
  "mcpServers": {
    "pdp-assistant": {
      "command": "python",
      "args": ["-m", "src.server"],
      "cwd": "/path/to/pdp-mcp-server"
    }
  }
}

📄 License

MIT License

📚 References

About

MCP Server untuk UU Perlindungan Data Pribadi (PDP) dengan RAG dan Pinecone

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published