Difference between revisions of "Global stores taxonomy"

From Open Food Facts wiki
Jump to navigation Jump to search
Line 24: Line 24:
  
 
=== Store brand ===
 
=== Store brand ===
The current implementation of OFF already supports a field for Stores. It is a free text field where the user can enter whatever s/he wants. A variety of entries is the consequence. But most of all it is used to enter the value for the Store brand, i.e. the name of the store as is shown outside the store and on receipts.  
+
The current implementation of OFF already supports a field for Stores. It is a free text field where the user can enter whatever s/he wants. A variety of entries is the consequence. But most of all it is used to enter the value for the Store brand, i.e. the name of the store as is shown outside the store and on receipts.
There are also ideas how to kickstart a list of store brands from external sources. Note that this can also be imported from OSM by means of the receipts. On OSM it is indicated with the tag ''brand''.
+
 
 +
Note that this can also be imported from OSM by means of the receipts. On OSM it is indicated with the tag ''brand''.
 +
 
 +
OSM also indicates a link to wikidata (for instance [https://www.wikidata.org/wiki/Q151954 Lidl]).
 +
 
 +
There are also ideas how to kickstart a list of store brands from external sources.
  
 
=== Example Taxonomy Entry===
 
=== Example Taxonomy Entry===

Revision as of 17:55, 6 March 2024

See Global taxonomies for instructions.

Introduction

The stores taxonomy contains a list of locations where products (food products, beauty products, etc.) can be obtained.

Store entries

An entry in the taxonomy describes a single location. This taxonomy can combine data pulled from various sources: receipts from prices, osm, wikidata, etc or provided by the user (honour system). OFF should be careful not copy to much data already maintained by other parties. And if data is copied, it is to provide a snapshot in time.

Receipts

Example of store information on a receipt

The basis could be the receipts that users have added on prices. As all OFF data, any information should be backed up by image proofs. In the case for a store, this could be a receipt. The store information available on the receipt can be extracted to the taxonomy. What can be extracted depends on the receipt. In the example shown here, it is possible to extract the store name, the operator (useful for franchises), the address, phone number, siret, naf and tva. Analysus of more receipts might reveal other country specific information. Hopefully this information is enough to unambiguously identify a store.

Prices

The stores taxonomy can be based on OFF Prices. The receipts corresponding to a shop are entered on Prices. Prices has a unique identifier for each shop, which should be used as a linking pin. In addition Prices offers a link with Openstreetmap, which can be used to pull in additional information. Some of this information is already cached by Prices.

Open Street Map

All stores are linked to Open Street Map (OSM) through the unique OSM id. The link refers to a basic object in OSM:

  • Node - is used to refer to a single location, like BP Service;
  • (Closed) Way - is used to refer to a building, like IKEA;
  • Relation - is used to refer multiple ways used by the shop, like Carrefour;

Using a Way to designate a shopping location might lead to inconsistencies, like this actual location. Which shop on the street is meant? Using a relation might lead to inconsistencies as well, like this actual location. This can be limited to OSM objects that have the tag shop.

Several of the fields are pulled from OSM (name, postcode, city, country, lat, lon). These need to be regularly updated, so that OSM is followed. Any deleted location should be kept.

Store brand

The current implementation of OFF already supports a field for Stores. It is a free text field where the user can enter whatever s/he wants. A variety of entries is the consequence. But most of all it is used to enter the value for the Store brand, i.e. the name of the store as is shown outside the store and on receipts.

Note that this can also be imported from OSM by means of the receipts. On OSM it is indicated with the tag brand.

OSM also indicates a link to wikidata (for instance Lidl).

There are also ideas how to kickstart a list of store brands from external sources.

Example Taxonomy Entry

An example for an entry / location / store / shop in the taxonomy:
store_brand:en: Biocoop
price_id:en: 45
osm_id:en: 9815975601
osm_type:en: NODE
osm_display_name:en: "Biocoop, Rue de Tolbiac, Quartier de la Maison-Blanche, Paris 13e Arrondissement, Paris, Île-de-France, France métropolitaine, 75013, France"
osm_address_postcode:en: 75013
osm_address_city:en: en:Paris
osm_address_country:en: en:france
osm_lat:en: 48.8259597
osm_lon:en: 2.3511541

Maintenance

The stores taxonomy needs to be regularly updated from the data entered through OFF Prices. This means any changed values and any added entries/

Discussion points

  • What information should be stored by OFF and what can be left to OSM or Wikidata?
  • What to be done with shops that go out of business?

Note

  • We need to associate stores with brands that are sold in thoses stores (Auchan for Auchan…)
  • We should try to add Wikidata relations (and thus OSM ones) whenever possible
  • Chains - if a store is part of a chain with multiple stores it can be added through a wikidata link

Moved to GitHub: https://github.com/openfoodfacts/openfoodfacts-server/blob/master/taxonomies/stores.txt