Problem: Ethiopian smallholder farmers face increasing challenges from climate change, including erratic rainfall and soil degradation. While data-driven agriculture can offer solutions, traditional centralized systems risk exposing sensitive farm data (e.g., precise location, yields), leading to privacy concerns and lack of adoption.
Motivation: There is a critical need for a system that can provide personalized, climate-smart agricultural advice without compromising the privacy of individual farmers. This project aims to bridge the gap between advanced AI capabilities and data sovereignty.
Approach: We developed a Privacy-Preserving Multi-Agent System that utilizes Federated Learning (FL) principles and Differential Privacy (DP). The system consists of five specialized agents orchestrated by LangGraph. It processes sensitive data locally on the "farm" (simulated), aggregates insights using DP noise to mask individual contributions, and generates context-aware recommendations using Retrieval-Augmented Generation (RAG) with real-time climate data.
Key Outcomes: The system successfully generates personalized crop and weather plans while maintaining a high level of privacy. Benchmarks demonstrate that lower privacy budgets (epsilon < 0.5) significantly reduce the risk of membership inference attacks (success rate < 5%) while preserving the utility of the aggregated insights for regional trend analysis.
The system is built on a modular multi-agent architecture using LangGraph for orchestration. The workflow mimics a federated learning cycle:
graph TD User[User Input] --> Local[Local Data Analyzer] Local -->|Anonymized Features| Fed[Federated Collaborator] Fed -->|Regional Trends| Planner[Crop/Weather Planner] Planner -->|Draft Plan| Auditor[Privacy Auditor] Auditor -->|Approved| Synth[Synthesizer] Auditor -->|Rejected| Planner Synth -->|Final Report| Output[Multilingual Output]
gpt-4o to extract features (soil pH, crop type) from natural language input. It applies local differential privacy noise before any data leaves this node.We evaluated the system's resilience against Membership Inference Attacks, where an adversary attempts to determine if a specific user's data was included in the aggregated result.
Test Setup:
Findings:
| Epsilon ( | Attack Success Rate | Interpretation |
|---|---|---|
| 0.01 | 0.0000 | Perfect Privacy: The output is indistinguishable from noise. |
| 0.1 | 0.0100 | High Privacy: Extremely difficult for an adversary to infer membership. |
| 0.5 | 0.0480 | Strong Privacy: Good balance for most applications. |
| 1.0 | 0.0940 | Moderate Privacy: Acceptable for less sensitive data. |
| 5.0 | 0.3990 | Low Privacy: Higher utility but significant risk of leakage. |
Note: A success rate of ~0.0 implies the attack is no better than random guessing in this simplified model.
Privacy Auditor successfully flags and blocks outputs that inadvertently contain raw location coordinates or PII.The Privacy-Preserving Multi-Agent Climate-Resilient Farming Advisor demonstrates that it is possible to leverage the power of modern AI and collaborative learning without compromising the digital sovereignty of smallholder farmers. By embedding privacy by design via Federated Learning and Differential Privacy, we pave the way for more trustworthy and scalable digital agriculture solutions.