Interface SentimentAnalysisOptions

interface SentimentAnalysisOptions {
    method?: string;
    modelId?: string;
    providerId?: string;
    lexiconNameOrPath?: string;
    language?: string;
    methodOptions?: Record<string, any>;
}

Properties

method?: string

Read by HybridUtilityAI alone, which sends 'llm' to its LLM-backed class and 'lexicon_based' to its statistical class. LLMUtilityAI asks a provider and StatisticalUtilityAI scores with a lexicon, whatever it names.

modelId?: string
providerId?: string

The provider LLMUtilityAI calls: this, else methodOptions.providerId, else its defaultProviderId.

lexiconNameOrPath?: string

StatisticalUtilityAI: a lexicon natural ships, by name (afinn, afinnFinancialMarketNews, pattern, senticon), or the path of a lexicon file, which is then the lexicon alone.

language?: string
methodOptions?: Record<string, any>