GithubHelp home page GithubHelp logo

Comments (4)

Geethi2020 avatar Geethi2020 commented on May 26, 2024 1

Thank you for the quick response Housen and for the direction.

from transformersum.

HHousen avatar HHousen commented on May 26, 2024

Whoops! Yes, the number of top sentences to select was hardcoded to 2 in the ExtractiveSummarizer.predict() function. Yes, the top n sentences are returned. I've updated the library so the ExtractiveSummarizer.predict() function has a num_summary_sentences argument to specify the number of sentences in the output summary. The default is 3 sentences. Let me know if this works 😄.

from transformersum.

Geethi2020 avatar Geethi2020 commented on May 26, 2024

Hi, Is there any upper limit for num_summary_sentences ? Wanted to create a summary of 100 sentences from an article of 200+ sentences using MobileBERT. It gives only 8 sentences (or below if num_summary_sentences is smaller), regardless of num_summary_sentences value. Please advise. Thank you.

from transformersum.

HHousen avatar HHousen commented on May 26, 2024

Yes, there is an upper limit since the decoder of most BART-Like models can only output 512 tokens. Transformers generally cannot handle long sequences of input or output. The Longformer would be your best option since it can handle an input of about 8000/16000 (depending on the version) tokens but still only outputs 512 tokens. If you wanted a summary that long then you should use a standard algorithm like TextRank.

from transformersum.

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.