<commit_before><div id="content2">

<h1>How can I add a product?</h1>

<p>Open Food Facts is a collaborative project where each citizen can contribute by adding or completing product information.</p>

<p>We try to offer the most user-friendly interface to make it easy and fast to add products. Here are some images with each stage involve in adding a product (with a few tricks to go faster.)</p>

<h2>First of all, register on Open Food Facts and login.</h2>

<p>If it's not done yet, you can <a href="https://world.openfoodfacts.org/cgi/user.pl">register in 30 seconds</a>.</p>

<h2>Take pictures of the product</h2>

<p>The photos are better taken in the following order:</p>

<ol>
<li>The barcode</li>
<li>The product main visual: It's best to place it on a white surface (a sheet of paper) and take the picture vertically</li>
<li>The ingredients list</li>
<li>The nutritional composition</li>
</ol>

<img src="/images/misc/ajout-produit-photo-face.jpg" alt="Take a photo of the product, if possible on a white background" style="border:1px solid grey">

<p>Few tips on taking pictures:</p>
<ol>
<li>Take pictures in portrait or landscape mode, you can crop them later on the website.</li>
<li>Respect the aspect ratio of the product.</li>
<li>The more the image is focused, the less there is of shadows and reflections, the better.</li>
<li>Don't "rework" photos in software before sending them on the site (resizing, cropping, white balance, etc.). All this will be done directly on the site.</li>
</ol>

<h2>Add the product</h2>

<p>You will find an "Add a product" link on the right hand column.</p>

<img src="/images/misc/ajout-produit-code.png" alt="" style="border:1px solid grey">

<p>Send the photo that contains the bar code by clicking on the button "Upload Image".</p>

<img src="/images/misc/ajout-produit-code-photo.png" alt="" style="border:1px solid grey">


<p>Note for Chrome and Firefox users: the photo is automatically resized to a reasonable size, hence upload is fast even with 20 million pixels camera.</p>

<p>The bar code will be recognized automatically if the picture is not too blurry. When the product is already in the database, you will be redirected to the product page.
Then you can check the accuracy of the information. Provided your pictures are better, do not hesitate to edit the product and upload yours. If the product does not exist, you will be provided with a form to enter the information</p>

<h3>Send the product main visual photo</h3>

<img src="/images/misc/ajout-produit-envoyer-photo-face.png" alt="" style="border:1px solid grey">

<p>Click "Add a photo" to add it, unless you already uploaded a photo that contains both the bar code and the main visual in the previous step.</p>

<img src="/images/misc/ajout-produit-redresser.jpg" alt="" style="border:1px solid grey">

<p>If required, you can correct the image with the rotate left/right buttons.</p>

<p>Crop the product within the image by "click and drag" with the mouse, then hit "Validate and/or resize image".</p>

<img src="/images/misc/ajout-produit-recadrer.jpg" alt="" style="border:1px solid grey">

<p>If done on white background, try "Photo on white background: try to remove the background" which slightly grays out edges of the photo and enhance colors.</p>

<p>Photo with the box unticked:</p>

<img src="/images/misc/ajout-produit-photo.jpg" alt="" style="border:1px solid grey">

<p>Photo with the box ticked:</p>

<img src="/images/misc/ajout-produit-photo-sans-fond.jpg" alt="" style="border:1px solid grey">


<p>The result depends on the amount of shadows, keep the original photo if the colors are too saturated.</p>

<h3>Add product information</h3>

<img src="/images/misc/ajout-produit-caracteristiques.png" alt="" style="border:1px solid grey;">

<p>The product name is the one that appears on the packaging.</p>

<p>The generic name is the "legal" product name, without indication of brand.Usually found on the packaging too</p>

<p>The fields "Packaging", "Brands", "Categories", "Origin", "Labels" are keywords lists (tags) under which the product will be referenced. You can type these keywords separated by a comma or by hitting enter.</p>

<p>You can fill in all the keywords that you think are relevant (check products already listed). When the number of products in the base will be more significant, we can sort through all the keywords and create a category tree and correspondences between multiple spellings ("doughnut" and "donut"), etc. We can also offer suggestions on the fly (by typing a few letters) for brands etc.</p>

<h3>Send ingredients photo</h3>

<img src="/images/misc/ajout-produit-ingredients.jpg" alt="" style="border:1px solid grey">

<p>As for the other photo, upload the ingredient list one.</p>

<img src="/images/misc/ajout-produit-ingredients-cadre.jpg" alt="" style="border:1px solid grey">

<p>Crop the area containing the list and hit "Validate and/or resize image".</p>

<img src="/images/misc/ajout-produit-ingredients-extraire.jpg" alt="" style="border:1px solid grey">

<p>You can avoid typing the list of ingredients with the "Extract the ingredients from the picture". Recognition works better when the picture is sharp and the text straight. On the other hand if the text is curved (photo of a can for example) or if the background is not uniform, the ingredients are not generally recognised.</p>

<img src="/images/misc/ajout-produit-ingredients-texte.png" alt="" style="border:1px solid grey">

<p>With this product, recognition is almost perfect (an 'a' as been recognized as a '1'). The text automatically extracted often needs correction.</p>

<p>This automatic recognition should improve with time: the more product we have, the better the dictionary of ingredients we can generate to help the text recognition algorithm.</p>

<p>Next fill in the potentially allergens "Traces" in the products. This information is crucial and sometimes vital for allergy sufferers.</p>

<img src="/images/misc/ajout-produit-ingredients-traces.png" alt="" style="border:1px solid grey">


<h3>Send nutritional information photo</h3>

<p>We see more and more products that indicate the nutritional composition on the packaging. As for the ingredients, upload and optimise the corresponding picture.</p>

<img src="/images/misc/ajout-produit-photo-nutrition.jpg" alt="" style="border:1px solid grey">


<p>Nutritional tables are more difficult to recognize than the ingredients list, therefore it is not automated yet.</p>

<p>Currently we provide a list of the most frequently listed nutrients with their common quantity unit.</p>

<img src="/images/misc/ajout-produit-nutrition-tableau.png" alt="" style="border:1px solid grey">

<p>The European legislation allows manufacturers to list other nutrients (vitamins and minerals in particular). If they are listed on the packaging, you can add them in the last line of the table. By typing the first few letters you will get a drop down list with the corresponding nutrients and the most common corresponding units (mg for vitamin C for example). If you can not find the nutrient, you can type it in full</p>

<img src="/images/misc/ajout-produit-nutrition-vitamines.png" alt="" style="border:1px solid grey">


<h3>Save the product</h3>

<p>Now you only need to hit the "Save" button.</p>

<p>Thanks in advance for all the products you will contribute to the database!</p>

<p>Ready for your first product? See you at the top right of this page.</p>
</div>
<commit_msg>Apply suggestions from code review<commit_after><div id="content2">

<h1>How can I add a product?</h1>

<p>Open Food Facts is a collaborative project where each citizen can contribute by adding or completing product information.</p>

<p>We try to offer the most user-friendly interface to make it easy and fast to add products. Here are some images with each stage involve in adding a product (with a few tricks to go faster.)</p>

<h2>First of all, register on Open Food Facts and login.</h2>

<p>If it's not done yet, you can <a href="https://world.openfoodfacts.org/cgi/user.pl">register in 30 seconds</a>.</p>

<h2>Take pictures of the product</h2>

<p>The photos are better taken in the following order:</p>

<ol>
<li>The barcode</li>
<li>The product main visual: It's best to place it on a white surface (a sheet of paper) and take the picture vertically</li>
<li>The ingredients list</li>
<li>The nutritional composition</li>
</ol>

<img src="/images/misc/ajout-produit-photo-face.jpg" alt="Take a photo of the product, if possible on a white background" style="border:1px solid grey">

<p>Few tips on taking pictures:</p>
<ol>
<li>Take pictures in portrait or landscape mode, you can crop them later on the website.</li>
<li>Respect the aspect ratio of the product.</li>
<li>The more the image is focused, the less there is of shadows and reflections, the better.</li>
<li>Don't "rework" photos in software before sending them on the site (resizing, cropping, white balance, etc.). All this will be done directly on the site.</li>
</ol>

<h2>Add the product</h2>

<p>You will find an "Add a product" link on the right hand column.</p>

<img src="/images/misc/ajout-produit-code.png" alt="Add a product by sending an image with a barcode, or typing the barcode" style="border:1px solid grey">


<p>Send the photo that contains the bar code by clicking on the button "Upload Image".</p>

<img src="/images/misc/ajout-produit-code-photo.png" alt="The photo is being uploaded." style="border:1px solid grey">



<p>Note for Chrome and Firefox users: the photo is automatically resized to a reasonable size, hence upload is fast even with 20 million pixels camera.</p>

<p>The bar code will be recognized automatically if the picture is not too blurry. When the product is already in the database, you will be redirected to the product page.
Then you can check the accuracy of the information. Provided your pictures are better, do not hesitate to edit the product and upload yours. If the product does not exist, you will be provided with a form to enter the information</p>

<h3>Send the product main visual photo</h3>

<img src="/images/misc/ajout-produit-envoyer-photo-face.png" alt="Image manager in the product addition form" style="border:1px solid grey">


<p>Click "Add a photo" to add it, unless you already uploaded a photo that contains both the bar code and the main visual in the previous step.</p>

<img src="/images/misc/ajout-produit-redresser.jpg" alt="You can start adjusting your photo by cropping, rotating or color correcting it." style="border:1px solid grey">


<p>If required, you can correct the image with the rotate left/right buttons.</p>

<p>Crop the product within the image by "click and drag" with the mouse, then hit "Validate and/or resize image".</p>

<img src="/images/misc/ajout-produit-recadrer.jpg" alt="You can crop your photo." style="border:1px solid grey">


<p>If done on white background, try "Photo on white background: try to remove the background" which slightly grays out edges of the photo and enhance colors.</p>

<p>Photo with the box unticked:</p>

<img src="/images/misc/ajout-produit-photo.jpg" alt="Product photo without color correction" style="border:1px solid grey">


<p>Photo with the box ticked:</p>

<img src="/images/misc/ajout-produit-photo-sans-fond.jpg" alt="Product photo with color correction" style="border:1px solid grey">



<p>The result depends on the amount of shadows, keep the original photo if the colors are too saturated.</p>

<h3>Add product information</h3>

<img src="/images/misc/ajout-produit-caracteristiques.png" alt="Product addition form with values filled in" style="border:1px solid grey;">


<p>The product name is the one that appears on the packaging.</p>

<p>The generic name is the "legal" product name, without indication of brand.Usually found on the packaging too</p>

<p>The fields "Packaging", "Brands", "Categories", "Origin", "Labels" are keywords lists (tags) under which the product will be referenced. You can type these keywords separated by a comma or by hitting enter.</p>

<p>You can fill in all the keywords that you think are relevant (check products already listed). When the number of products in the base will be more significant, we can sort through all the keywords and create a category tree and correspondences between multiple spellings ("doughnut" and "donut"), etc. We can also offer suggestions on the fly (by typing a few letters) for brands etc.</p>

<h3>Send ingredients photo</h3>

<img src="/images/misc/ajout-produit-ingredients.jpg" alt="Photo manager to choose a fitting ingredients photo" style="border:1px solid grey">


<p>As for the other photo, upload the ingredient list one.</p>

<img src="/images/misc/ajout-produit-ingredients-cadre.jpg" alt="Cropped ingredients photo, ready to validate" style="border:1px solid grey">


<p>Crop the area containing the list and hit "Validate and/or resize image".</p>

<img src="/images/misc/ajout-produit-ingredients-extraire.jpg" alt="The ingredients are tightly cropped, ready for automated text extraction" style="border:1px solid grey">


<p>You can avoid typing the list of ingredients with the "Extract the ingredients from the picture". Recognition works better when the picture is sharp and the text straight. On the other hand if the text is curved (photo of a can for example) or if the background is not uniform, the ingredients are not generally recognised.</p>

<img src="/images/misc/ajout-produit-ingredients-texte.png" alt="The automated text extraction has been performed. It's now up to you to check it." style="border:1px solid grey">


<p>With this product, recognition is almost perfect (an 'a' as been recognized as a '1'). The text automatically extracted often needs correction.</p>

<p>This automatic recognition should improve with time: the more product we have, the better the dictionary of ingredients we can generate to help the text recognition algorithm.</p>

<p>Next fill in the potentially allergens "Traces" in the products. This information is crucial and sometimes vital for allergy sufferers.</p>

<img src="/images/misc/ajout-produit-ingredients-traces.png" alt="Make sure to fill all the traces, without forgetting any." style="border:1px solid grey">



<h3>Send nutritional information photo</h3>

<p>We see more and more products that indicate the nutritional composition on the packaging. As for the ingredients, upload and optimise the corresponding picture.</p>

<img src="/images/misc/ajout-produit-photo-nutrition.jpg" alt="A correctly cropped nutrition table photo." style="border:1px solid grey">



<p>Nutritional tables are more difficult to recognize than the ingredients list, therefore it is not automated yet.</p>

<p>Currently we provide a list of the most frequently listed nutrients with their common quantity unit.</p>

<img src="/images/misc/ajout-produit-nutrition-tableau.png" alt="You can type all the various nutrients you see on the photo." style="border:1px solid grey">


<p>The European legislation allows manufacturers to list other nutrients (vitamins and minerals in particular). If they are listed on the packaging, you can add them in the last line of the table. By typing the first few letters you will get a drop down list with the corresponding nutrients and the most common corresponding units (mg for vitamin C for example). If you can not find the nutrient, you can type it in full</p>

<img src="/images/misc/ajout-produit-nutrition-vitamines.png" alt="You can add extra nutrients that are not shown by default in the edit form." style="border:1px solid grey">



<h3>Save the product</h3>

<p>Now you only need to hit the "Save" button.</p>

<p>Thanks in advance for all the products you will contribute to the database!</p>

<p>Ready for your first product? See you at the top right of this page.</p>
</div>

{'fraction_non_alphanumeric': 0.09637286457043823, 'fraction_numerical': 0.005075513741025006, 'mean_word_length': 4.281791435109513, 'pattern_counts': {'":': 0, '<': 253, '<?xml version=': 0, '>': 253, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7377397', 'n_tokens_mistral': 4712, 'n_tokens_neox': 4408, 'n_words': 2151}