GithubHelp home page GithubHelp logo

Comments (1)

GokuMohandas avatar GokuMohandas commented on May 1, 2024

Hey @guotong1988 , you'll want to first gather enough data for the types of entities (fruit, vegetable etc.) that you care about. You can use an off-the-shelf set of embeddings (ex. GloVe) to train because these are common tokens and the embeddings for entities in the same class will already be clustered since they all used large, generic datasets to learn embeddings from.

In the second example, where you have labels like "Chinese fruit", you'll want to treat this as a multiclass classification problem (ex. output is [0, 1, 1, 0] instead of being one unique class [0, 1, 0, 0]. However, you can just make more classes like "fruit", "chinese fruit" but your model is going to start confusing classes because there will be a lot of overlap. You can also create two separate models to predict "fruit" and then "chinese" from the set of keywords but this is assuming every prediction has both labels.

Hope that helps.

from madewithml.

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.