Inspiration
What it does# कृषिCRED — Project Story
The Moment That Started Everything
One of our team members grew up watching his grandfather — a rice farmer in rural Tamil Nadu — get turned away from the bank every single season. Not because he wasn't creditworthy. But because he couldn't prove it. No salary slips. No CIBIL history. Just decades of growing food for people who would never know his name.
That image stayed with us. And when this hackathon came around, we knew exactly what we wanted to build.
The Problem We Couldn't Ignore
India disburses over ₹20 lakh crore in agricultural credit annually — and still, 100 million smallholder farmers remain locked out of the formal credit system.
The math of exclusion is brutal. A farmer with 0.5 hectares has:
- No CIBIL score
- No collateral a bank will accept
- No income proof that fits a standard loan form
So they turn to moneylenders. Interest rates of 30–60%. Loans that compound across seasons. Debt that outlives the borrower.
The cruellest part? These farmers do have financial behaviour. They recharge their phones every month. They collect PMKISAN installments. They buy seeds on UPI. They show up at the mandi every harvest.
Nobody was counting any of it.
We decided to count it.
What We Built
कृषिCRED is an end-to-end AI-powered credit scoring engine for rural India — built entirely on Databricks, designed for farmers the formal system forgot.
The Data Pipeline
We started with raw UPI transaction data and built a full Bronze → Silver → Gold lakehouse architecture on Delta Lake:
- Bronze Layer — Raw UPI transactions ingested via PySpark
- Silver Layer — Feature engineering across 15 alternative data signals
- Gold Layer — The final
krishi_credit_engine_datatable, MLflow-tracked and ready for scoring
The 15 signals we engineered include:
| Signal | What it reveals |
|---|---|
| UPI merchant vs P2P ratio | Spending discipline & commercial activity |
| Telecom recharge streak | Digital consistency & reliability |
| PMKISAN installments YTD | Govt scheme engagement |
| FASTag trips (last 6 months) | Mobility & market access |
| PDS ration withdrawals | Subsidy utilisation patterns |
| Aadhaar eKYC + AgriStack ID | Verified identity & land linkage |
| Land area (hectares) | Farm scale & asset base |
| PMFBY insurance enrolled | Financial planning behaviour |
The Credit Score Formula
The Krishi Credit Score is computed as:
$$ S = 400 + 5T + 15P + 2F + 30I + 40L + 20M + 50K + 20A + 30G $$
Where:
- $T$ = Telecom recharge streak (months)
- $P$ = PMKISAN installments year-to-date
- $F$ = FASTag trips in last 6 months
- $I$ = PMFBY insurance enrolled (binary)
- $L$ = Land record verified (binary)
- $M$ = UPI merchant vs P2P ratio
- $K$ = Aadhaar eKYC verified (binary)
- $A$ = Aadhaar address matches mandi (binary)
- $G$ = AgriStack ID linked (binary)
The score is capped at 900, keeping it within the RBI-standard 400–900 range.
The ML Layer
We trained and compared three models using MLflow experiment tracking:
| Model | Train RMSE | Test RMSE | R² Score |
|---|---|---|---|
| Linear Regression | — | — | Baseline |
| Gradient Boosting | Lower | Competitive | High |
| Random Forest | Lowest | Lowest | 0.9987 ✅ |
Random Forest won decisively — its ability to handle non-linear interactions between
agricultural signals made it the natural fit. The winning model was saved via joblib
and served through a Streamlit dashboard connected to Databricks Unity Catalog.
Making It Human
A score without explanation is just another black box — and farmers have been hurt by enough of those.
So we added two layers that we're genuinely proud of:
DBRX GenAI Rationale — Every credit decision generates a plain-language explanation. Not "your score is 672." But "Your consistent telecom recharges and verified land record are your strongest signals. Here's what would improve your score next season."
Sarvam AI Voice Advisory — That rationale is then read back to the farmer in all 22 Scheduled languages of India. Because a decision you can't understand isn't a decision — it's just a verdict.
What We Learned
Honestly? More than we expected.
We came in thinking this was a data engineering problem. We left understanding it's a dignity problem.
The moment we mapped out the 15 signals and realised every single one of them was already present in a farmer's life — just uncollected, unstructured, uncounted — something shifted. The data was always there. The intent to look for it wasn't.
We also learned that explainability isn't a nice-to-have feature. For a first-generation loan borrower who has never interacted with formal credit, understanding why they got a score is as important as the score itself. Maybe more.
And on the technical side — building a production-grade lakehouse pipeline from scratch during a hackathon taught us to make fast, irreversible architectural decisions and live with them. Delta Lake's ACID guarantees saved us more than once.
The Challenges We Faced
1. No real farmer data exists in one place. Agricultural alternative data is scattered across PMKISAN portals, mandi records, AgriStack, and telecom APIs — none of which talk to each other. We had to simulate realistic distributions from NABARD reports and ground-truth patterns to build our dataset.
2. Making the score fair, not just accurate. An R² of 0.9987 sounds great. But we kept asking: accurate to what? We had to continuously audit our feature weights to ensure we weren't inadvertently penalising farmers in low-connectivity regions, or those who don't use FASTag simply because they don't own a vehicle. Fairness and accuracy pulled in different directions. We're still not fully satisfied — and that's intentional. It keeps us honest.
3. The language gap. Building a multilingual voice advisory isn't just a translation problem. Agricultural terminology varies enormously across regions. What a farmer in Vidarbha calls a "season" is not what a farmer in Punjab means. Getting Sarvam AI to handle this contextually — not just literally — was harder than we anticipated.
4. Keeping it human. Every time we got deep into PySpark transforms or MLflow runs, we'd pull up a photo of a farmer and ask: would this make sense to him? That question slowed us down sometimes. But it made the product better every time.
What's Next
कृषिCRED is a prototype built in a hackathon. But the problem it addresses is not.
Our roadmap:
- Pilot with a regional cooperative bank or MFI — live data, real farmers, actual loans
- RBI Regulatory Sandbox submission — to validate the scoring model under formal oversight
- AgriStack API integration — replacing simulated data with live land and crop records
- Crop-cycle aligned EMIs — repayment schedules that follow Kharif and Rabi harvest windows, not calendar months
A Final Thought
India's farmers produce enough food to feed 1.4 billion people. They manage risk every single season — drought, pest, flood, price crash — with almost no safety net and no formal financial identity.
If a Random Forest model trained on 15 behavioural signals can predict creditworthiness with 99.87% accuracy, the question isn't whether alternative credit scoring works.
The question is: what took us so long?
The hand that feeds India finally gets the credit it is owed.
Built with: Databricks · PySpark · Delta Lake · MLflow · Scikit-learn · Streamlit · DBRX · Sarvam AI · Python · AgriStack APIs
Team कृषिCRED — IIT Madras Hackathon 2025
Log in or sign up for Devpost to join the conversation.