Enrichment Layers

Beyond core demographics, the library offers four progressive depth layers, designed for simulation, fairness audits and AI training data.

The 4 layers

LayerNameDescription
1Core DemographicsState, gender, religion, caste, names, languages, biological markers, address
2Socio-Economic OutcomesCIBIL credit score, health risk, literacy, employment vulnerability (configurable bias)
3Narrative DocumentsLoan applications, OPD records, Hinglish WhatsApp chats, school admissions, resumes, support chats
4Agent Persona PromptsLLM-ready system prompts, worldview beliefs, stress responses, memory seeds

Layer 2 — Outcomes

Simulated socio-economic outcomes calibrated to CMIE/CIBIL observed gaps.

# CLI
indian-fakedata -c 100 --outcomes

# Python
from indian_fakedata import generate_enriched

enriched = generate_enriched(count=10, include_outcomes=True, bias_level=0.3)[0]
credit = enriched["outcomes"]["credit"]["creditScore"]
health = enriched["outcomes"]["health"]["healthRisk"]

The bias dial

bias_level (CLI: --bias <0-1>) controls how strongly historical discrimination shapes outcomes:

ValueMeaning
0.0Pure meritocracy
0.3Default; calibrated to observed CMIE/CIBIL gaps
1.0Max historical discrimination

Layer 3 — Narratives

Realistic Indian text documents generated from a profile:

TypeDocument
loan_applicationBank loan application text
medical_consultationDoctor's OPD consultation record
school_enrollmentSchool admission form narrative
ration_card_applicationPDS ration card application
hinglish_conversationWhatsApp-style Hinglish chat
resumeCV built from education timeline, work history and skills (v2.0.9)
customer_support_chatHinglish bank helpline dialogue, masked phone (v2.0.9)
# CLI
indian-fakedata -c 1000 --narrative loan_application --narrative hinglish_conversation

# Python
from indian_fakedata import generate, generate_narrative

profile = generate(count=1)[0]
doc = generate_narrative(profile, "loan_application")
print(doc["content"])

Layer 4 — Agent personas

LLM-ready agent personas: a short system prompt plus a complete fullPrompt roleplay prompt (identity, appearance, education timeline, personality traits, movie/anime preferences, habits, beliefs, memory seeds and behavior rules), ready to inject into any LLM. Since v2.0.9 personas accept a language — english (default), hindi (Devanagari prompt + Hindi headers) or hinglish (roman mix). CLI: --persona --persona-lang hindi.

# CLI
indian-fakedata -c 500 --persona -f jsonl -o agents.jsonl

# Python
from indian_fakedata import generate_persona

out = generate_persona(seed="011")
persona = out["persona"]

print(persona["systemPrompt"])     # ready to use as a chat system prompt
print(persona["fullPrompt"])       # complete self-contained roleplay prompt
print(persona["beliefs"]["worldview"])
print(persona["memorySeeds"])      # conversation-starting memories
print(persona["behaviorRules"])    # what the agent will and will not do

Everything at once

indian-fakedata -c 100 --enrich

--enrich = outcomes + all narrative types + persona.