Difference between revisions of "Food Traceability Codes"

From Open Food Facts wiki
Jump to navigation Jump to search
Line 1: Line 1:
This project aims to investigate all non-standard codes, usually printed on the packaging using a machine, such as batch numbers, the quality numbers ... and get the most information possible.
+
This project aims to investigate packaging codes and all non-standard codes, usually printed on the packaging using a machine, such as batch numbers, the quality numbers ... and get the most information possible.
 
+
==Codes==
 
=== EMB Codes ===
 
=== EMB Codes ===
  
Line 51: Line 51:
 
**There is a general csv file with the general link to the data repository for each country: https://github.com/openfoodfacts/eu-food-data/blob/master/list-eu-and-partner-countries.csv
 
**There is a general csv file with the general link to the data repository for each country: https://github.com/openfoodfacts/eu-food-data/blob/master/list-eu-and-partner-countries.csv
 
**There are individual folders for each target country (specific url-list for each European Agreement Section and data files)
 
**There are individual folders for each target country (specific url-list for each European Agreement Section and data files)
* A google sheet document is used to map all files available in the target countries. It also map the section name for every country in its own language (or translation in English) and the related European Section, which is used as a general taxonomy.
+
* A google sheet document is used to map all files available in the target countries. It also map the section name for every country in its own language (or translation in English) and the related European Section, which is used as a general taxonomy. This Google Sheet can be found here: https://docs.google.com/spreadsheets/d/1egdo58Ds8PNi5G_4F2UtWOWC1V0k3tXBgPhZXs5FRqM/edit?usp=sharing
This Google Sheet can be found here: https://docs.google.com/spreadsheets/d/1egdo58Ds8PNi5G_4F2UtWOWC1V0k3tXBgPhZXs5FRqM/edit?usp=sharing
+
*We can usually find txt or csv file but for some countries the data is only available in PDF. Those need OCR treatment before data extraction.
 
===France===
 
===France===
 
*I just build a script that takes all the french agreement info from Agriculture Ministry and concatenate them in one file. Next step is to do the same for UK. The step after that is to cleverly agregate the duplicates (some companies have several health agreements under the same agreement number)
 
*I just build a script that takes all the french agreement info from Agriculture Ministry and concatenate them in one file. Next step is to do the same for UK. The step after that is to cleverly agregate the duplicates (some companies have several health agreements under the same agreement number)

Revision as of 15:11, 4 October 2015

This project aims to investigate packaging codes and all non-standard codes, usually printed on the packaging using a machine, such as batch numbers, the quality numbers ... and get the most information possible.

Codes

EMB Codes

EU Food Establishments

EU Organic Codes

FSC Codes

MSC Codes

For example 3256224531289 Product code indicating the MSC "MML-C-1021." By putting this code in the URL of the MSC, it gets the name and origin of the fisherman http://cert.msc.org/supplierdirectory/VController.aspx?CertNr=MML-C-1021

PLU Codes

Soil Association

Spanish wines

I found the "Bodegas" directory in the "Consejo Regulador" site: http://es.riojawine.com/multimedia/files/directorio.xls There you can find the row: Pernod Ricard Winemakers Spain (Campo Viejo) with "Reg Embotellador" = "1.850-LO" Our number!! This is in the city of Logroño (the capital of La Rioja) and the street is "La Rad de Santa Cruz, s/n".

Then if you look at the spanish packaging codes site (the RGSEAA number that is used to build the ES RGSEAA EC number) in the http://rgsa-web-aesan.msssi.es/rgsa/formulario_principal_js.jsp web, with that information (Razón Social=Pernod Ricard Winemakers Spain; Localidad=Logroño), you get the only number: 30.00641/LO (i.e. ES 30.00641/LO CE). The adress also match the data.

The winery celler (bodega) is this, just by curiosity :simple_smile: http://www.pernodricardbodegas.com/bodegas/campo-viejo/la-bodega/?lang=en http://www.aesan.msssi.gob.es/aesa/web/AESA.jsp

Import / Export Codes of the Russian Federation

Egg Codes

Bio Codes

Methodology to extract data

General

France

  • I just build a script that takes all the french agreement info from Agriculture Ministry and concatenate them in one file. Next step is to do the same for UK. The step after that is to cleverly agregate the duplicates (some companies have several health agreements under the same agreement number)

https://github.com/openfoodfacts/eu-food-data/blob/master/scripts/FR-script.py This script use this file to get the list of URL to retrieve https://github.com/openfoodfacts/eu-food-data/blob/master/fr/urls-fr.txt

  • First work performed on

UK

  • As UK is divided in 4 regions (Ireland, England, Wales and Scotland) and because they have different file format, we use a 3-file script

https://github.com/openfoodfacts/eu-food-data/blob/master/scripts/UK-urls.txt => all UK urls https://github.com/openfoodfacts/eu-food-data/blob/master/scripts/UK-methods.txt => list which method to use depending on the file type https://github.com/openfoodfacts/eu-food-data/blob/master/scripts/UK-script.py => the script itself

DE

  • @vince has per


fr:Projet:Codes_propriétaires