Suppose we have a text like Today is a very bad day. Very bad day is today. I wont come to play.

What kind of technique should I use to summarize similar texts like above? From articles, I found over the web till now I think that extractive summarization will give importance to the first two sentences because major key points of the texts(according to the frequency of words) are present in the first two sentences. Similarly, the abstractive summarization technique will also make a summary certainly considering the first two sentences. But, in the ideal case, the third sentence is a must.

What should be my approach considering my text may have many sentences with similar meanings??

I am very new to this any kind of suggestion or help will be great.


In case by 'summarize' you mean in fact 'classify', e.g. 'bad', 'good', etc, then an LSTM/GRU will do the job, just input the whole (truncated probably) sequence, and take the last state:

out, _ = lstm(embedding)
out_state = out[:,-1,:]

Here embedding is whatever word embedding you are using, out is the whole output of LSTM, and batch_first=True (in pytorch), so you take the last state as the input in the fully connected layer.

If you need to make predictions about parts of the text, just add a loop and truncate sentences rather than the whole text.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.