ProsusAI / finBERT

Financial Sentiment Analysis with BERT
Apache License 2.0
1.45k stars 417 forks source link

What is the news_id? #25

Closed RawCheer closed 4 years ago

RawCheer commented 4 years ago

Could anyone explain what is the news_id in predict()?

Screen Shot 2020-07-28 at 9 35 17 PM Screen Shot 2020-07-28 at 9 35 33 PM
gench commented 4 years ago

It must be your own addition, predict function in FinBERT doesnt have such a parameter.

def predict(text, model, write_to_csv=False, path=None):
    """
    Predict sentiments of sentences in a given text. The function first tokenizes sentences, make predictions and write
    results.
    Parameters
    ----------
    text: string
        text to be analyzed
    model: BertForSequenceClassification
        path to the classifier model
    write_to_csv (optional): bool
    path (optional): string
        path to write the string
    """