DEV Community

Cover image for From Satellite Pixels to Farmer Decisions: What Building FieldLens Taught Me
Liang Jacky
Liang Jacky

Posted on Originally published at carbontool.cn AI-assisted

From Satellite Pixels to Farmer Decisions: What Building FieldLens Taught Me

This post is part of the Monthly MLH × DEV Writing Challenge — a look back at what I built, how I built it, and what I'd do differently.

This post is part of the Monthly MLH × DEV Writing Challenge — a look back at what I built, how I built it, and what I'd do differently.*

The problem nobody asked me to solve

I grew up around pomelo orchards in Meizhou, Guangdong. Every year, growers there make the same high-stakes guesses: which blocks are underperforming, where to fertilize, whether the irrigation is actually reaching the trees. Satellite data could answer all of this — Sentinel-2 flies over every five days, free for anyone to use. But "free data" and "usable answers" are very different things. No grower I know is going to open Google Earth Engine and write JavaScript.

There's a part of this origin story I didn't tell in my submission post. In July, I joined the fieldwork for a Guangdong provincial research project — a Natural Science Foundation–funded study of farmland protection, including the "farmland chief" system (田长制), led by a South China University of Technology team. For a week I walked villages in Fengshun and Jiaoling doing door-to-door farmer interviews and organizing the survey data.

The farmland chief system is simple to describe and exhausting to run: named local officials are personally responsible for watching specific plots — walking them on foot, checking that nothing illegal gets built and nothing is abandoned. Sitting in farmers' homes, working through a 29-question survey on how this system actually runs, I kept coming back to the same thought: the whole oversight system runs on human legs and human eyes, a few times a month if that. A satellite passes over those same fields every five days, for free.

And one farmland chief (田长) said the quiet part out loud. He wasn't asking for software — he was just tired of the work. If there were automatic monitoring, he told me, he wouldn't have to go out and check the fields under a blazing sun or in the wind and rain.

That week is where FieldLens really started: the very person whose job is walking the fields, naming the pain in plain words — and me realising the data that could answer it was already falling from the sky, for free.

So for Hacktoberfest Week 2 ("Side Hustle"), I built "FieldLens": draw your orchard on a map, get a vigor report that reads like advice from an agronomist, not a data dump. NDVI time series go in; plain-language actions come out — in Chinese for the growers, in English under the hood.

🎥 Live demo: https://fieldlens-api.onrender.com/app

How it works (the honest version)

The pipeline is deliberately boring where it should be, and interesting where it matters:

  1. Draw a polygon on the map (or use the sample orchard — more on that below).
  2. Sentinel-2 NDVI time series pulled through Google Earth Engine, composited into vigor zones across the block.
  3. A local Gemma model via Ollama writes the advisory report. This was a deliberate choice, not a gimmick: grower data never leaves the machine, there's no per-report API bill, and it works where connectivity is flaky. The report takes a lang parameter — Chinese for the actual farmer reading it, English for the code comments and the DEV crowd.
  4. A 199 RMB/plot/year pricing story, because the Week 2 theme was "build something someone would actually pay for." I priced it like a utility bill, not a SaaS moonshot.

Two decisions I'm proudest of are both about honesty with data:

  • During research I found that NDVI ≥ 0.70 is a drone canopy-pixel reference, not a Sentinel-2 block-average threshold. Mixing those up is exactly how ag-tech demos lie to farmers. I added an explicit caveat to the model's prompt so it never presents one as the other.
  • Every screenshot and demo polygon is a sample geometry with a visible "Sample" badge. I never drew a real orchard boundary in any public material. Real growers' land stays private, full stop.

What I learned

Writing is the product.Hacktoberfest's judging criteria weight writing quality above everything else, and building FieldLens taught me why: the demo took a week; explaining why it matters to a specific person took longer and mattered more. "A grower in Meizhou deciding where to fertilize this week" beats "a satellite analytics platform" every time.

Local AI is a feature, not a compromise.Running Gemma locally wasn't just cheaper — it became the trust story. "Your orchard data never leaves your computer" is the sentence that makes a skeptical grower keep listening.

Cold starts are a design constraint.The demo runs on Render's free tier, which sleeps. Instead of fighting it, I documented it in the post and designed the UI to degrade gracefully. Constraints you name honestly stop being embarrassments.

First users are slower than code. I reached out to a pomelo-growing relative in Meizhou through a carefully written WeChat message. No reply yet. The code shipped in a week; trust takes a season. That's fine — the field validation is scheduled for November, and the product will be shaped by what actually happens in the orchard, not by what I imagine happens.

What's next about the future

  • Radar-optical fusion. Southern China is cloudy for months; optical imagery alone has gaps. A recent paper hit 93% early-season crop classification by fusing Sentinel-1 radar with optical time series — that's going straight into the FieldLens method library.
  • A second software copyright if the November validation works — because in my world, shipped and validated beats shipped and demoed.

Why open matters here

None of this works closed. Open satellite data (Sentinel-2), an open-weight model (Gemma) running on my own machine, open tooling throughout. If FieldLens depended on a proprietary API, every report would cost money, every grower's data would travel somewhere, and the whole "199 RMB a year" story would collapse. Open is what makes this deployable, not just demoable.


Built with open-source AI for Hacktoberfest 2026. If you work on ag-tech, remote sensing, or just like the idea of satellites helping small growers — I'd love to hear what you'd build differently.

Top comments (0)