ID_REG_MD_RAG / README.md
Azzindani's picture
Update README.md
6b7b0fd verified
metadata
license: apache-2.0
language:
  - id
tags:
  - legal
  - indonesia
  - regulations
  - knowledge-graph
  - rag
task_categories:
  - text-retrieval
  - question-answering
size_categories:
  - 100K<n<1M

Indonesian Legal RAG Processed Database

This repository contains a fully preprocessed Indonesian legal regulation database ready for RAG (Retrieval Augmented Generation) systems.

Dataset Information

  • Total Records: 199,994
  • Processing Date: 2025-08-23
  • Embedding Model: Qwen/Qwen3-Embedding-0.6B
  • Embedding Dimension: 1024

Files Description

Main Database

  • processed_legal_database.parquet - Complete preprocessed database with all features
  • embeddings.npy - Pre-computed embeddings array for fast loading

Supporting Components

  • tfidf_components.pkl - TF-IDF vectorizer and matrix for keyword matching
  • knowledge_graph.json - Legal concept relationships and hierarchy
  • config.json - Processing configuration and parameters
  • processing_summary.json - Processing statistics and metadata

Utilities

  • database_loader.py - Helper class for easy database loading

Features Included

Each record contains:

  • Basic Information: Regulation type, number, year, enacting body, content
  • Authority Score: Hierarchical legal authority level (0-1)
  • Temporal Score: Regulation currency/relevance (0-1)
  • Legal Richness: Legal term density and complexity (0-1)
  • Cross-Reference Strength: Inter-regulation connectivity (0-1)
  • Completeness Score: Information completeness (0-1)
  • Knowledge Graph Features: Entity extraction and concept relationships
  • Pre-computed Embeddings: Ready-to-use vector representations

Usage

from database_loader import ProcessedLegalDatabaseLoader

# Load complete database
loader = ProcessedLegalDatabaseLoader(".", local_mode=True)
df, embeddings, tfidf, kg, config = loader.load_all()

# Ready for RAG system - no preprocessing needed!

Memory Requirements

  • Database: ~1260MB
  • Embeddings: ~781MB
  • Total: ~2747MB

License

Please ensure compliance with Indonesian legal data usage regulations.