Giter Site home page Giter Site logo

sentence_encoder_distillation's Introduction

sentence_encoder_distillation

This is a script for distilling the following model = SentenceTransformer("all-MiniLM-L6-v2") into smaller dimension models.

we reduce the popular sentence encoder: "all-MiniLM-L6-v2" which is 384 dimensional bert based sentence encoder (see sbert library or huggingface), to lower dimensional models: [256, 128, 64, 48, 32, 16, 8] Scores for each model are:

256 Dim Model STS Score: 0.8261079485369712

128 Dim Model STS Score: 0.816830899095272

64 Dim Model STS Score: 0.7966557914485638

48 Dim Model STS Score: 0.7757417906216884

32 Dim Model STS Score: 0.745332350705585

16 Dim Model STS Score: 0.665596114418915

8 Dim Model STS Score: 0.596041263085443

This script takes a few minutes on an average computer.

sentence_encoder_distillation's People

Contributors

dorenwick avatar

Stargazers

 avatar

Watchers

 avatar

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.