Origin is a farmer-controlled AI agent that turns messy field evidence into the smallest safe data share—then autonomously handles repeat partner requests only within an explicit consent boundary.
Inspiration
Farmers repeatedly enter the same spray, harvest, and compliance records into elevator, retailer, insurer, and certification portals. This is tedious, but simply giving an AI agent unrestricted access to farm data creates a more serious problem: the agent may share the right information with the wrong recipient, for a new purpose, or after permission has expired.
That tension inspired Origin. We wanted to build an agent that could perform real work—not merely answer questions—while keeping the farmer in control. The central product question became:
How can an agent automate repetitive agricultural paperwork without turning one approval into unlimited authority?
Origin is our answer for the Taskmaster track: a durable request-to-action agent with tools, asynchronous execution, external delivery, retry recovery, and precise human checkpoints.
What it does
Origin captures a field operation once from a voice note, image, or typed record. Gemini converts the evidence into a structured draft, but the farmer confirms the facts before they become usable records.
When a partner requests information, Origin:
- Creates a durable and traceable AgentRun.
- Finds the confirmed record for the requested parcel.
- Compiles only the fields required by that partner’s rule.
- Checks the request against the farmer’s permission boundary.
- Delivers the approved package or pauses for a field-level consent decision.
- Records the result as a receipt with provenance and a trace ID.
A standing permission is valid only when:
[ \text{same partner} \land \text{same purpose} \land \text{requested fields} \subseteq \text{allowed fields} \land \text{permission not expired} ]
If a repeat request satisfies every condition, Origin can fulfill it automatically. If the partner changes the purpose, requests an additional field, targets another parcel, or uses an expired permission, the agent stops and returns control to the farmer.
Gemini helps interpret evidence and explain decisions, but it never decides whether information may be shared. That authority remains in a deterministic policy gate.
Farmers can inspect exact shared values, review agent timelines and delivery receipts, revoke Origin-issued access, and export their activity. Private tenants can also erase Origin-managed copies while recording honest recipient notices rather than claiming that previously downloaded data has disappeared.
How we built it
We separated ambiguous AI work from deterministic authority.
The responsive web application is built with Next.js and hosted on Render. It supports touch-friendly field capture for farmers while expanding into a desktop-oriented Partner Desk for detailed office workflows.
The agent API is built with FastAPI and runs on Google Cloud Run. We use the Google Gen AI SDK with Gemini 3.7 Flash on Vertex AI for multimodal extraction and concise farmer-facing explanations.
Every partner request becomes a persistent AgentRun. Cloud Tasks dispatches these runs asynchronously and retries transient failures. Firestore stores farm records, permissions, run steps, receipts, provenance, and delivery state. Cloud Storage holds evidence and recipient-specific delivery packages, while optional signed webhooks support external partner systems. Correlated trace IDs connect the product timeline with Cloud Logging.
We deliberately used the Google Gen AI SDK directly instead of adding a general-purpose orchestration framework. Cloud Tasks and our AgentRun state machine provide the durable execution model the workflow needs, while the consent engine, geometry checks, and rule compiler remain deterministic and independently testable.
The same lifecycle can run locally with a JSON store and deterministic fallbacks, allowing contributors to test the complete workflow without cloud credentials.
Challenges we ran into
The hardest challenge was defining where model intelligence should stop. Gemini is useful for interpreting an image or voice note, but permission cannot depend on probabilistic output. We therefore made field extraction model-assisted and sharing decisions deterministic.
Human approval also turns a normal API request into a long-running workflow. An agent may begin today, wait for the farmer, and resume later. We had to make run state durable and protect it against duplicate tasks, retries, webhook failures, and concurrency between a background worker and a farmer’s decision.
Idempotency required careful design. Retrying a failed task must not create a second request, consent, or delivery. We introduced stable identifiers and compare-and-set state transitions so completed work cannot be overwritten by a delayed worker.
Data deletion and revocation presented another challenge. Once a recipient has downloaded information, no system can honestly promise that every external copy has vanished. Origin therefore distinguishes between deleting Origin-managed copies, disabling future access, and notifying recipients.
Finally, designing for a real farm workflow meant supporting two different environments without creating two disconnected products: quick capture and approval in the field, and detailed review at an office computer.
Accomplishments that we're proud of
We built and deployed a complete agent workflow rather than a static prototype. The live system can extract a record with Gemini, request exact consent, deliver a partner package, autonomously fulfill a covered repeat request, and stop when the purpose changes.
We are especially proud that:
- The agent performs an observable external action instead of only generating text.
- Every share displays the exact field names and values before approval.
- Sensitive yield and revenue fields are blocked by the compiler.
- A later record from another parcel cannot satisfy the wrong request.
- Background execution is durable, authenticated, retryable, and idempotent.
- Model provenance and fallback status are visible instead of hidden.
- Revocation and deletion messages accurately describe their limits.
The offline test suite contains 73 tests covering the lifecycle, safety rules, tenancy, retries, concurrency, authentication, and erase semantics.
The public demonstration uses synthetic farm data and exposes no real agricultural or personal information.
What we learned
We learned that trustworthy agents depend less on elaborate prompts and more on explicit authority, durable state, and observable actions.
Consent becomes much more useful when represented as executable policy rather than a one-time checkbox. A narrow standing permission can remove repetitive work while still stopping the agent whenever the recipient, purpose, parcel, fields, or expiry changes.
We also learned that “human in the loop” is not merely a confirmation dialog. It is a persistent workflow state that must survive time, retries, process restarts, and concurrent execution.
Most importantly, an agent earns trust by making its limits visible. Users should be able to understand what the model inferred, what deterministic rules decided, what was delivered, and what the system cannot undo.
What's next for Origin: An Agricultural-Informatization-Intelligent-Agent
Next, we want to pilot Origin with US grain elevators, cooperatives, and agricultural service providers using real questionnaire formats and sandbox integrations.
Planned improvements include:
- Production Firebase authentication and organization-level tenant administration.
- Additional partner connectors and agricultural data interoperability formats.
- Offline-first capture for unreliable rural connectivity.
- Farmer-approved rule updates generated from new questionnaires.
- Richer delivery-failure recovery and partner acknowledgment workflows.
- Policy simulation showing what a standing permission would allow before activation.
- Evaluation dashboards for extraction quality, consent interruptions, and time saved.
- Independent security and privacy review before handling production farm data.
Our long-term goal is not to make an agent that shares more data. It is to make routine agricultural coordination faster while ensuring that every autonomous action remains bounded, explainable, and accountable.e built it
Log in or sign up for Devpost to join the conversation.