Reference Design: Farmer Registry

The OpenG2P Farmer Registry is designed to streamline the identification, registration, and verification of farmers in a structured and scalable manner. It aligns with the use case documented in OpenG2P Farmer Registry Use Case and provides a reference implementation based on OpenG2P principles. This reference design can be a base to start off your farmer registry implementation and further you may modify as per your farmer registry specification.

Use case

Refer Farmer Registry

Source code

The entire source code for the reference design can be found in the GitHub repository.

Components

Included The Farmer Registry solution comprises the following components, as reflected in the OpenG2P Reference Designs GitHub repository:

  • g2p_farmer: Core farmer registry model.

  • g2p_farmer_rest_api: REST API for accessing and managing farmer data.

  • g2p_farmer_service_provider_portal: Portal for service providers to manage farmer and household in their respective administrative area.

  • g2p_lock_unlock: Functionality for locking and unlocking farmer records.

  • g2p_odk_importer_farmer: Component for importing data collected via ODK (Open Data Kit).

Farmer model

(Some of the fields are inherited from the OpenG2P core, so please refer to the base repositories to find them)

Category

Field Name

Type

Description

Basic information

name

Char

Farmer's full name

unique_id

Numeric

Farmer ID

gender

Selection

Gender of the farmer

date_of_birth

Date

Farmer's date of birth

phone_number

Char

Contact phone number

email

Char

Email address

address

Text

Residential address

registration_date

Date

Date of registration

tags_ids

Many2many

Tags associated with the registrant

civil_status

Char

Marital status of the registrant

reg_ids

One2many

IDs for the farmer

phone_number_ids

One2many

List of phone numbers

Socio-economic data

education_level

Selection

Highest level of education attained

employment_status

Selection

Farmer's employment status

household_income

Float

Total household income

hh_income_type

Selection

Income type

Membership

cooperative_id

Many2one

Cooperative membership

is_member_of_primary_cooperative

Selection

Whether the farmer is a member of a primary cooperative

primary_cooperatives

Many2one

Primary cooperative the farmer belongs to

is_member_of_cooperative_union

Selection

Whether the farmer is a member of a cooperative union

cooperative_unions

Many2one

Cooperative union the farmer belongs to

is_member_in_farmer_cluster

Selection

Whether the farmer is a member of a farmer cluster

primary_commodity

Many2one

Primary commodity the farmer produces

role_in_farmer_cluster

Selection

Role of the farmer in the cluster

state

Selection

State of the membership

Land information

total_land_area

Float

Size of land owned/leased

land_certificate

Many2one

Certificate file upload

land_id

Char

Land ID as per land administration records

ownership_type

Selection

Owner or rented

Crop information

crop

Selection

Type of crops grown

collected_gc

Date

Date of plantation

season

Selection

Season

Livestock information

livestock_type

Selection

Type of livestock raised

livestock_count

Integer

Number of livestock owned

Agricultural input

do_you_use_fertilizer

Boolean

Whether fertilizer is used

amount_fertilizer_utilized

Float

The amount Of fertilizer

do_you_use_pesticide

Boolean

Whether pesticide is used

amount_pesticide_utilized

Float

The amount Of pesticide

do_you_use_insecticide

Boolean

Whether insecticide is used

amount_insecticide_utilized

Float

The amount Of insecticide

do_you_use_improved_seed

Boolean

Whether improved seed is used

amount_improved_seed_utilized

Float

The amount Of improved seed used

Access to resources

crop_water_source

Selection

Primary water source for crops

livestock_water_sources

Selection

Water source for livestock

access_to_machinery

Selection

Access to machinery

type_of_machinery

Selection

Type to machinary

Access to finance

has_finance_access

Boolean

Has finance access

finance_accesses

Selection

Types of finances

Household

individual_membership_ids

One2many

Household membership

Other household members

household_members

One2many

List of other household members

How to setup

Follow the developer installation guide provided for setting up OpenG2P on Linux: Developer Install Guide.

Once the OpenG2P setup is completed, proceed with the following steps specific to the Farmer Registry:

  1. Navigate to the OpenG2P addons directory

    cd ~/odoo/custom-addons/
  2. Clone the farmer registry repository

    git clone https://github.com/OpenG2P/openg2p-reference-designs.git
  3. Adjust Odoo configuration

    • Update the odoo.conf file to include the Farmer Registry module path:

    addons_path = /home/odoo/odoo/addons,/home/odoo/custom-addons/openg2p-reference-designs/farmer-registry
  4. Restart odoo

    sudo systemctl restart odoo
  5. Activate the farmer registry module

    • Log into Odoo and navigate to Apps.

    • Enable Developer Mode.

    • Search for Farmer Registry and install the module.

  6. Configure farmer registry settings

    • Set up deduplication rules and ODK integration under module settings.

Last updated

Was this helpful?