Researchers have developed an artificial intelligence model that can predict, before anything goes into the ground, whether biochar, a charcoal-like material made by burning plant waste, will boost phosphorus availability for crops or hold it back to prevent waterway pollution. The study, led by Yutao Peng of Sun Yat-Sen University in Shenzhen, drew on 534 measurements from 32 earlier studies and ran them through three machine learning systems. One model, called Random Forest, outperformed the others significantly, achieving a prediction accuracy of around 91 per cent on data it had never seen. The findings, published in the journal
Biochar, mark a significant step towards taking the guesswork out of one of sustainable agriculture's most promising but frustratingly unpredictable soil tools.
Why phosphorus waste in agriculture is a growing problem for soil and water
Phosphorus is one of the most important nutrients in farming, but crops are remarkably bad at using what is applied to them.
Only around 20 per cent of fertiliser phosphorus is actually taken up by plants in the growing season in which it is applied. The rest either binds chemically to iron, aluminium, or calcium in the soil and becomes locked away from plant roots, or it runs off into streams, rivers, and ponds, feeding algae blooms that starve water of oxygen in a process called eutrophication.
This is not just an environmental problem. Phosphorus comes from mined phosphate rock, a finite, non-renewable resource.
Its transfer from agricultural soils into surface waters is one of the leading causes of water quality degradation globally, making every kilogram of wasted fertiliser a double loss for the farmer's budget and for the health of nearby waterways.
What is biochar and why has it been so hard to use reliably?
Biochar is produced by heating crop leftovers, wood, or other plant matter at high temperatures with very little oxygen. The process called pyrolysis leaves behind a porous, carbon-rich black solid that farmers can mix into their fields. It has gained real traction as a low-cost way to improve soil structure, store carbon, and manage nutrient availability.
The problem is that its effect on phosphorus has never been consistent. A
meta-analysis found that biochar's impact on plant-available phosphorus varies widely across soil types and conditions, sometimes releasing locked nutrients for crop uptake, sometimes binding phosphorus even more tightly than before. For a farmer staring at a bag of biochar, there has historically been no reliable way to know which outcome a particular field will produce.
How the AI model cracked the biochar phosphorus prediction problem
The research team assembled their dataset of 534 real-world measurements, each recording what happened to soil phosphorus after biochar was applied. Nineteen variables were fed into three machine learning systems: Random Forest, Support Vector Regression, and Artificial Neural Networks. The Random Forest model, which builds its answer by running data through hundreds of separate decision trees and averaging the results, pulled ahead clearly. Its R² score of 0.91 means it explained most of the variation in phosphorus outcomes across the test data.
When the team asked the model which factor mattered most, one answer rose above the rest: the temperature at which the biochar was originally produced. Biochar cooked at moderate heat, roughly 460 to 482 degrees Celsius, developed a balanced pore structure and active surface chemistry that helped regulate phosphorus without locking it away or releasing it too fast. Biochar fired at higher temperatures behaved differently, showing lower phosphorus availability, which can actually be useful when the goal is to stop phosphorus from leaching into water rather than feeding crops. Heat, the model showed, is essentially a dial that can be turned for different outcomes.
Soil pH and application rate are the other key variables
The pyrolysis temperature did not act alone. The amount of biochar applied came in as the second-strongest factor, followed by the soil's own acidity and its existing phosphorus levels. Soil pH turned out to steer much of the interaction. In acidic soils, phosphorus tends to bind with iron and aluminium and become inaccessible, and biochar has less room to help. Neutral to slightly alkaline soils, however, give biochar more to work with. When those reactive metal ions are less dominant, biochar's mild alkalising effect can nudge phosphorus into forms that plant roots can actually reach.
These factors did not interact in simple, straight lines. The model detected complex, non-linear relationships between variables, exactly the kind of pattern that traditional statistical approaches miss, and the reason a machine learning framework outperformed simpler methods.
Plain biochar can match lab-engineered versions
One of the study's more surprising findings pushes back against a long-held assumption in the field. Chemically modified biochar engineered in laboratories to enhance performance has often been treated as the higher-tier option. This study suggests that plain, untreated biochar can match or even outperform the modified kind when soil conditions and production temperatures align correctly.
The model also found that biochar's benefit may come less from any phosphorus it contains itself and more from how it interacts with phosphorus already sitting in the soil. That changes the economics meaningfully. No chemical treatment means lower production cost and less environmental burden. Crop- or wood-based biochars also require less energy to produce than manure-based ones while delivering comparable results.
What this means for precision agriculture and sustainable farming
Until now, matching biochar to a specific field was largely trial and error, with farmers absorbing the cost of every wrong application. A data-driven model that can predict outcomes before a single handful of biochar hits the ground represents a genuine shift for precision agriculture. Farmers and their advisors could use such a tool to decide not just whether to apply biochar, but which type, produced at what temperature, and at what rate, tailored to the specific chemistry of their soil.
The model is a starting framework rather than a finished product, and wider field testing across different soil types and climates will determine how broadly its predictions hold. But the direction is clear: a cheap, carbon-rich material made from agricultural waste can increasingly be applied with something closer to data-backed precision than guesswork.
Follow Us On Social Media