A multi-agent system dramatically improves the method of targeted groundwater replenishment, which increases the amount of fresh water and biodiversity.