Introducing AgriFarm, an intelligent decision support system for managing agricultural resources to optimize water and energy consumption with the aim of supporting the restoration of the Lake Urmia ecosystem.
2025-12-20
Agriculture, as a part of the main ecosystem of the country, especially in dry and water-deficient areas of Iran, is one of the most important economic sectors and has an impact on the environment. With the reduction of rainfall, illegal harvesting and unsustainable exploitation of underground and surface water resources, it has created serious challenges in the management of water and energy resources and has led to the crisis of water scarcity and threats to water ecosystems. It has a wide environmental and economic impact. In such a situation, technological and data-oriented solutions are necessary for the sustainable management of resources. AgriFarm intelligent decision support system by using artificial intelligence algorithms and data analysis of soil, water, energy, climate and cultivation pattern, provides the possibility of scientific and data-oriented decision making for farmers and resource managers. This system provides the ability to simulate different irrigation scenarios, optimize energy consumption, recommend low-water and profitable products, and provide economic and ecological forecasting. The preliminary results of MVP show that the widespread use of AgriFarm can reduce the excessive consumption of water, increase the economic productivity of farmers and accelerate the restoration process of the Lake Urmia ecosystem. This system is an example of the application of artificial intelligence and data science in sustainable agriculture and paves the way for the development of similar technologies in natural resource management.
Objectives of the research
The main objective of AgriFarm is:
- Optimizing water and energy consumption in agriculture and reducing unauthorized harvesting of water resources.
- Increasing the economic productivity of farmers through the recommendation of a low water and profitable product.
- Data-driven decision support for resource managers and policy makers.
- Supporting the restoration of Lake Urmia by reducing the pressure on surface and underground water sources.
- Creation of scientific and technological infrastructure for the development of sustainable agriculture and resource management in the region.
In recent years, several researches have been conducted in the field of water and energy resource management in agriculture using artificial intelligence. Studies have shown that machine learning algorithms can:
- Forecasting the water requirement of crops based on climatic conditions and soil type
- Optimizing the time and amount of irrigation to reduce energy consumption
- Low water and economical product recommendation
- Simulation of economic and ecological scenarios
Due to the limited resources and specific climatic conditions of Lake Urmia region, a localized and data-oriented system is necessary. AgriFarm was developed based on this need, and in addition to agricultural use, it has a significant environmental and economic role. Methods and system architecture
The overall architecture of AgriFarm consists of three main parts:
- Frontend: Framework: Next.js 14 (React) Charts: Recharts Forms: React Hook Form Display dashboard and product recommendation
- Backend: Framework: FastAPI (Python) Database: PostgreSQL ORM: SQLAlchemy AI algorithms: scikit-learn, pandas, numpy Providing RESTful API to communicate with Frontend
- Data model and algorithms: Soil, water, energy and climate data analysis, water and energy consumption prediction models (Multivariate Data Modeling), machine learning algorithms for product recommendation, simulation of economic and ecological scenarios
system operation process
- Farm data collection (soil type, area, water/energy source)
- Data analysis and prediction of water and energy consumption
- Providing product recommendations based on low water consumption and economic profitability
- Simulation of different irrigation scenarios and climatic effects
- Display the results in the management dashboard
Primary Results (MVP)
The initial version of the system (MVP) offers the following features:
- Farm and products registration form
- Prediction of water and energy consumption (daily and monthly)
- Product recommendation with confidence score and predicted profit
- Management dashboard with resource consumption graphs
- Possibility of PDF and CSV output
Preliminary results show that the use of AgriFarm can reduce water consumption by 30-40% and increase economic productivity. Available and executable example: https://github.com/naserhha/AgriFarm

Picture 1 - Home Page: Introducing the project goal, CTA to add a farm and view the dashboard, summary statistics and benefits blocks

Picture 2 - Product recommendation for Ahmed's sample vegetable farm: List of recommended products with confidence score, water/energy consumption and expected profit

Picture 3 - Management Dashboard: Statistics of the number of farms, total area, water/energy consumption and monthly graphs

Picture 4 - Swagger UI: List of API endpoints (fields, products, predictions, recommendations and dashboard) for quick testing
بحث و تحلیل
According to the capabilities of AgriFarm, this system offers the following benefits:
- Sustainable management of resources: Reducing the pressure on underground and surface water resources
- Data driven decision making: Support for policy makers and farmers
- Predicting climate effects: Helping long-term planning and reducing production risk
- Increasing economic productivity: Choosing a low-water and profitable product
- Education and awareness: Improving the knowledge of smart agriculture
conclusion and future perspective
AgriFarm is an intelligent decision-making system that combines data science, artificial intelligence and analysis of agricultural systems, provides the possibility of optimization of water and energy consumption and plays an important role in restoration of Lake Urmia. Future development prospects include the following:
- Connection to real climate data and water resources
- Development of advanced ML/DL algorithms
- Connecting to IoT sensors and analyzing satellite images
- Mobile application for farmers and resource managers
Suggested resources
- Articles of artificial intelligence in agriculture
- Urmia lake crisis studies
- Researches on decision support systems and management of water and energy resources
- Smart agriculture global standards and reports