Git Product home page Git Product logo

Comments (1)

raphael0202 avatar raphael0202 commented on September 25, 2024

Successful test on structured parsing with romanian language:

Parse the ingredient lists in JSON format.
[INGREDIENTS] Potato, vegetable oils (corn, sunflower, rapeseed in varying proportions), seasoning with chicken with spices flavour [maltodextrin, salt, flavourings (contain onion powder, garlic powder, chicken meat powder 0,03%), sugar, spices (paprika powder 0,3%, cayenne pepper powder 0,06%, black pepper), potassium chloride, herbs (parsley 0,06%, thyme 0,06%, basil 0,03%), acid (citric acid), colour (paprika extract)]
[RESULT] [{"text":"Potato"},{"ingredients":[{"text":"corn"},{"text":"sunflower"},{"text":"rapeseed in varying proportions"}],"text":"vegetable oils"},{"ingredients":[{"text":"maltodextrin"},{"text":"salt"},{"ingredients":[{"text":"contain onion"},{"text":"garlic powder"},{"text":"chicken meat"}],"text":"flavourings"},{"text":"sugar"},{"ingredients":[{"percent":0.3,"text":"paprika powder"},{"percent":0.06,"processing":"en:powder","text":"cayenne pepper"},{"text":"black pepper"}],"text":"spices"},{"text":"potassium chloride"},{"ingredients":[{"percent":0.06,"text":"parsley"},{"percent":0.06,"text":"thyme"},{"percent":0.03,"text":"basil"}],"text":"herbs"},{"ingredients":[{"text":"citric acid"}],"text":"acid"},{"ingredients":[{"text":"paprika extract"}],"text":"colour"}],"text":"seasoning with chicken with spices flavour"}]

[INGREDIENTS] Cartofi, uleiuri vegetale (porumb, floarea soarelui, rapiță, în proporţii variabile), mix de ingrediente cu gust de pui cu mirodenii [maltodextrină, sare, arome (conțin ceapă pudră, usturoi pudră, carne de pui pudră 0,03%), zahăr, condimente (paprica pudră 0,3%), ardei cayenne pudră 0,06%, piper negru), clorură de potasiu, plante aromatice (pătrunjel 0,06%, cimbru 0,06%, busuioc 0,03%), acidifiant (citric acid), colorant (extract de ardei roşu)].
[RESULTS]

ChatGPT (3.5) result:

[
    {
        "text": "Cartofi"
    },
    {
        "ingredients": [
            {
                "text": "porumb"
            },
            {
                "text": "floarea soarelui"
            },
            {
                "text": "rapiță"
            },
            {
                "text": "în proporţii variabile"
            }
        ],
        "text": "uleiuri vegetale"
    },
    {
        "ingredients": [
            {
                "text": "maltodextrină"
            },
            {
                "text": "sare"
            },
            {
                "ingredients": [
                    {
                        "text": "conțin ceapă pudră"
                    },
                    {
                        "text": "usturoi pudră"
                    },
                    {
                        "percent": 0.03,
                        "text": "carne de pui pudră"
                    }
                ],
                "text": "arome"
            },
            {
                "text": "zahăr"
            },
            {
                "ingredients": [
                    {
                        "percent": 0.3,
                        "text": "paprica pudră"
                    },
                    {
                        "percent": 0.06,
                        "processing": "en:powder",
                        "text": "ardei cayenne"
                    },
                    {
                        "text": "piper negru"
                    }
                ],
                "text": "condimente"
            },
            {
                "text": "clorură de potasiu"
            },
            {
                "ingredients": [
                    {
                        "percent": 0.06,
                        "text": "pătrunjel"
                    },
                    {
                        "percent": 0.06,
                        "text": "cimbru"
                    },
                    {
                        "percent": 0.03,
                        "text": "busuioc"
                    }
                ],
                "text": "plante aromatice"
            },
            {
                "ingredients": [
                    {
                        "text": "citric acid"
                    }
                ],
                "text": "acidifiant"
            },
            {
                "ingredients": [
                    {
                        "text": "extract de ardei roşu"
                    }
                ],
                "text": "colorant"
            }
        ],
        "text": "mix de ingrediente cu gust de pui cu mirodenii"
    }
]

from openfoodfacts-ai.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.