-
-
Notifications
You must be signed in to change notification settings - Fork 399
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: move dev journey tutorials to a better location (#11187)
also fix some links
- Loading branch information
Showing
17 changed files
with
71 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,20 @@ | ||
## Tutorials for Common developer journeys | ||
|
||
### READ only journeys | ||
- []()Dev Journey 1: <a href="../reference/api-tutorials/comparing-sodas.md">Comparing sodas</a> | ||
- []()Dev Journey 2: <a href="../reference/api-tutorials/finding-healthy-cereals.md">Finding healthy breakfast cereals</a> | ||
|
||
- Dev Journey 1: [Comparing sodas](./tutorials/comparing-sodas.md) | ||
- Dev Journey 2: [Finding healthy breakfast cereals](./tutorials/finding-healthy-cereals.md) | ||
|
||
### READ and WRITE journeys | ||
- []()Dev Journey 3: <a href="../reference/api-tutorials/adding-missing-products.md">Adding missing products</a> | ||
- []()Dev Journey 4: <a href="../reference/api-tutorials/get-the-nutri-score.md">Get the Nutri-Score</a> | ||
- []()Dev Journey 5: <a href="../reference/api-tutorials/get-the-eco-score.md">Get the Eco-Score</a> | ||
- []()Dev Journey 6: <a href="../reference/api-tutorials/get-ingredient-related-analysis.md">Get ingredient related analysis on new or existing products (Nova, allergens, additives…)</a> | ||
- []()Dev Journey 7: <a href="../reference/api-tutorials/folksonomy-engine.md">Adding non-standard fields to a food product using Folksonomy (coming soon for cosmetics, pet food, and other products)</a> | ||
- []()Dev Journey 8: <a href="../reference/api-tutorials/product-prices.md">Retrieving and adding prices to products using Open Prices</a> | ||
|
||
- Dev Journey 3: [Adding missing products](./tutorials/adding-missing-products.md) | ||
- Dev Journey 4: [Get the Nutri-Score](./tutorials/get-the-nutri-score.md) | ||
- Dev Journey 5: [Get the Green-Score](./tutorials/get-the-green-score.md) | ||
- Dev Journey 6: [Get ingredient related analysis on new or existing products (Nova, allergens, additives…)](./tutorials/get-ingredient-related-analysis.md) | ||
- Dev Journey 7: [Adding non-standard fields to a food product using Folksonomy (coming soon for cosmetics, pet food, and other products)](./tutorials/folksonomy-engine.md) | ||
- Dev Journey 8: [Retrieving and adding prices to products using Open Prices](./tutorials/product-prices.md) | ||
|
||
## Adding more journeys | ||
|
||
* If you feel a developer journey is missing, feel free <a href="https://github.com/openfoodfacts/openfoodfacts-server/tree/main/docs/reference/api-tutorials">to create a Pull Request</a>, or propose it at [email protected] | ||
* If you feel a developer journey is missing, or want to correct one, | ||
feel free <a href="https://github.com/openfoodfacts/openfoodfacts-server/tree/main/docs/api/tutorials">to create a Pull Request</a>, or propose it at [email protected] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -26,7 +26,7 @@ You can get information about absence or unawareness of the presence of: | |
|
||
## Flow | ||
### The product does not exist | ||
* You can use our [adding products tutorial](https://openfoodfacts.github.io/openfoodfacts-server/reference/api-tutorials/adding-missing-products/) | ||
* You can use our [adding products tutorial](./adding-missing-products.md) | ||
|
||
### The product does exist: Get the status of the product and show prompts in case of incomplete ingredients or category (also required for NOVA ultra-processing levels) | ||
|
||
|
@@ -51,7 +51,7 @@ then "Add ingredients to see the level of food processing and potential additive | |
* Once the user has entered once of your completion flow, proceed to the next step | ||
|
||
### Upload ingredient photo | ||
* [Please follow our dedicated tutorial on photo upload](https://openfoodfacts.github.io/openfoodfacts-server/api/tutorial-uploading-photo-to-a-product/) | ||
* [Please follow our dedicated tutorial on photo upload](../tutorial-uploading-photo-to-a-product.md) | ||
* The DART SDK is offering support for photo upload, and we encourage you to implement it in one of the official Open Food Facts SDKs if it's not supported yet. | ||
* Ensure that your users crop language by language, or take all languages at once, but you perform server side cropping on one specific language before performing the OCR | ||
* We're working on a ML solution to detect languages and performing auto-crops per language ([[email protected]](mailto:[email protected]) to learn more) | ||
|
@@ -64,39 +64,55 @@ then "Add ingredients to see the level of food processing and potential additive | |
* The actions described in this topic do not modify the image, but provide metadata on how to use it (the data of the corners in the case of selection and the data of the rotation). That is, you send an image to the API, provide an id, you define, for example, the cropping and rotation parameters and as a response, the server generates a new image as requested and you can call this new version of the image. | ||
|
||
#### Selecting photos | ||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/tutorial-uploading-photo-to-a-product/) | ||
|
||
* [Please look at the specific tutorial](../tutorial-uploading-photo-to-a-product.md) | ||
|
||
#### Rotating a photo | ||
|
||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#get-/cgi/product_image_crop.pl) | ||
|
||
#### Cropping Photos | ||
|
||
**Note**: Cropping is only relevant for editing already selected images. You need to upload it first to the system, select it, retrieve its id, and then crop it. | ||
This is a non destructive crop. If there's an issue with the image, you should report it using the dedicated NutriPatrol API. | ||
Moderators will either perform a destructive crop, or more likely delete the image. | ||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#post-/cgi/product_image_crop.pl) | ||
|
||
#### Unselecting photos | ||
|
||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#post-/cgi/product_image_unselect.pl) | ||
|
||
### Get the Optical Character Recognition (OCR) output of the ingredients photo | ||
|
||
Open Food Facts uses optical character recognition (OCR) to retrieve ingredient data and other information (using Robotoff) from the photos of the product labels. | ||
**Notes**: | ||
* The OCR may contain errors. Encourage your users to correct the output using the ingredients WRITE API. | ||
* You can also use your own on-device OCR, especially if you're superconfident about it performing better than the server's cloudvision and if you plan to send a high number of queries. | ||
* Please DO NOT translate and send us the OCR output. We want to store only actual data. If you want translated version of the ingredient list, please send us an email to [email protected] | ||
|
||
#### API solution | ||
|
||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#get-/cgi/ingredients.pl) | ||
|
||
#### Dart SDK solution | ||
|
||
* [https://openfoodfacts.github.io/openfoodfacts-dart/model_OcrIngredientsResult/OcrIngredientsResult-class.html](https://openfoodfacts.github.io/openfoodfacts-dart/model_OcrIngredientsResult/OcrIngredientsResult-class.html) | ||
* [https://openfoodfacts.github.io/openfoodfacts-dart/utils_OcrField/OcrField-class.html](https://openfoodfacts.github.io/openfoodfacts-dart/utils_OcrField/OcrField-class.html) | ||
* [https://openfoodfacts.github.io/openfoodfacts-dart/utils_OcrField/OcrFieldExtension.html](https://openfoodfacts.github.io/openfoodfacts-dart/utils_OcrField/OcrFieldExtension.html) | ||
|
||
|
||
### Present the result of the Optical Character Recognition (OCR) output to your user for human review | ||
|
||
* Create a UI that encourages careful review, and encourages dropping the output if it's not right | ||
* Create a UI that encourages taking a less blurry, better framed photo to fix the output | ||
* Create a UI that handles multilinguism well | ||
|
||
### Send the ingredients | ||
|
||
* [Please look at the reference located](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v2/#post-/cgi/product_jqm2.pl) | ||
|
||
### Refresh product to display the result to your user | ||
|
||
* [Please look at the reference](https://openfoodfacts.github.io/openfoodfacts-server/api/ref-v3/#get-/api/v3/product/-barcode-) | ||
![alt_text](images/image1.png "image_tooltip") | ||
|
Oops, something went wrong.